PhpBench\Tests\Unit\Benchmark\Metadata\Driver\AnnotationDriverTest::testLoadIgnoreNonPrefixed PHP Метод

testLoadIgnoreNonPrefixed() публичный Метод

It should ignore non-prefixed subjects without the Subject annotation.
    public function testLoadIgnoreNonPrefixed()
    {
        $reflection = new ReflectionClass();
        $reflection->class = 'Test';
        $hierarchy = new ReflectionHierarchy();
        $hierarchy->addReflectionClass($reflection);
        $method = new ReflectionMethod();
        $method->reflectionClass = $reflection;
        $method->class = 'Test';
        $method->name = 'foo';
        $method->comment = <<<'EOT'
/**
 * @Iterations(10)
 */
EOT;
        $reflection->methods[$method->name] = $method;
        $metadata = $this->createDriver()->getMetadataForHierarchy($hierarchy);
        $subjects = $metadata->getSubjects();
        $this->assertCount(0, $subjects);
    }