Skip to content

Commit

Permalink
Merge pull request #12 from cakephp/remove-settiwg
Browse files Browse the repository at this point in the history
Removed TwigView::setTwig()
  • Loading branch information
othercorey authored Mar 24, 2020
2 parents 59cb571 + e3cd0b5 commit ac8ebb1
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
10 changes: 0 additions & 10 deletions src/View/TwigView.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,16 +104,6 @@ public function getTwig(): Environment
return $this->twig;
}

/**
* @param \Twig\Environment $twig Twig environment.
* @return void
* @internal
*/
public function setTwig(Environment $twig): void
{
$this->twig = $twig;
}

/**
* @return array
*/
Expand Down
3 changes: 0 additions & 3 deletions tests/TestCase/View/TwigViewTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,7 @@ public function test_renderPhp()
$output = 'foo:bar with a beer';
$filename = 'cakephp';

$twig = $this->prophesize(Environment::class);

$view = new TwigView();
$view->setTwig($twig->reveal());
$renderedView = $view->render($filename);

self::assertSame($output, $renderedView);
Expand Down

0 comments on commit ac8ebb1

Please sign in to comment.