ReflectionMethod $method:
boolean
public static function isTestMethod(ReflectionMethod $method) {
if (strpos($method->name, 'test') === 0) {
return TRUE;
}
// @scenario on TestCase::testMethod()
// @test on TestCase::testMethod()
return strpos($method
->getDocComment(), '@test') !== FALSE || strpos($method
->getDocComment(), '@scenario') !== FALSE;
}