New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DX: Enforce consistent naming in tests #7556
DX: Enforce consistent naming in tests #7556
Conversation
Thank you @kubawerlos, great work 🍻! |
$extraMethods = []; | ||
foreach ($class->getMethods(\ReflectionMethod::IS_PUBLIC) as $method) { | ||
if ($method->getDeclaringClass()->getName() !== $class->getName()) { | ||
continue; | ||
} | ||
if (\in_array($method->getName(), $methodNames, true)) { | ||
continue; | ||
} | ||
$extraMethods[] = $method->getName(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
array_filter ? non blocking, only a habit foreach { push() } -> filter()
(it would avoid extending array size iteration after iteration)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done: #7558
No description provided.