You are here

public function Twig_Tests_Loader_ChainTest::testAddLoader in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php \Twig_Tests_Loader_ChainTest::testAddLoader()

File

vendor/twig/twig/test/Twig/Tests/Loader/ChainTest.php, line 56

Class

Twig_Tests_Loader_ChainTest

Code

public function testAddLoader() {
  $loader = new Twig_Loader_Chain();
  $loader
    ->addLoader(new Twig_Loader_Array(array(
    'foo' => 'bar',
  )));
  $this
    ->assertEquals('bar', $loader
    ->getSource('foo'));
}