AbstractAnnotationLoaderTest.php 1016 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.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\Routing\Loader;
  11. use Symfony\Component\Config\Loader\LoaderResolver;
  12. use Symfony\Component\Routing\Loader\AnnotationFileLoader;
  13. use Symfony\Component\Routing\Route;
  14. use Symfony\Component\Routing\RouteCollection;
  15. abstract class AbstractAnnotationLoaderTest extends \PHPUnit_Framework_TestCase
  16. {
  17. public function getReader()
  18. {
  19. return $this->getMockBuilder('Doctrine\Common\Annotations\Reader')
  20. ->disableOriginalConstructor()
  21. ->getMock()
  22. ;
  23. }
  24. public function getClassLoader($reader)
  25. {
  26. return $this->getMockBuilder('Symfony\Component\Routing\Loader\AnnotationClassLoader')
  27. ->setConstructorArgs(array($reader))
  28. ->getMockForAbstractClass()
  29. ;
  30. }
  31. }