PhpBench\Tests\Unit\Benchmark\Metadata\Driver\AnnotationDriverTest::testClassMethodsOnException PHP Method

testClassMethodsOnException() public method

It should raise an exception if either before or after class methods are specified at the method level rather than the class level.
public testClassMethodsOnException ( $annotation )
    public function testClassMethodsOnException($annotation)
    {
        $reflection = new ReflectionClass();
        $reflection->class = 'Test';
        $hierarchy = new ReflectionHierarchy();
        $hierarchy->addReflectionClass($reflection);
        $method = new ReflectionMethod();
        $method->reflectionClass = $reflection;
        $method->class = 'Test';
        $method->name = 'benchFoo';
        $method->comment = sprintf('/** %s */', $annotation);
        $reflection->methods[$method->name] = $method;
        $this->createDriver()->getMetadataForHierarchy($hierarchy);
    }