StorageTest.php 751 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien.potencier@symfony-project.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Tests\Component\Templating\Storage;
  11. use Symfony\Component\Templating\Storage\Storage;
  12. use Symfony\Component\Templating\Renderer\PhpRenderer;
  13. class StorageTest extends \PHPUnit_Framework_TestCase
  14. {
  15. public function testMagicToString()
  16. {
  17. $storage = new TestStorage('foo');
  18. $this->assertEquals('foo', (string) $storage, '__toString() returns the template name');
  19. }
  20. }
  21. class TestStorage extends Storage
  22. {
  23. public function getContent()
  24. {
  25. }
  26. }