class AnnotationFileLoaderTest extends TestCase
{ private AnnotationFileLoader
$loader;
private TraceableAnnotationClassLoader
$classLoader;
protected function setUp(): void
{ parent::
setUp();
$this->classLoader =
new TraceableAnnotationClassLoader();
$this->loader =
new AnnotationFileLoader(new FileLocator(),
$this->classLoader
);
} public function testLoad() { self::
assertCount(0,
$this->loader->
load(__DIR__.'/../Fixtures/AnnotatedClasses/FooClass.php'
));
self::
assertSame([FooClass::
class],
$this->classLoader->foundClasses
);
} public function testLoadTraitWithClassConstant() { self::
assertCount(0,
$this->loader->
load(__DIR__.'/../Fixtures/AnnotatedClasses/FooTrait.php'
));