Implement group
attribute on <directory>
and <file>
elements (children of <testsuite>
) to add all tests found in a directory or file to a specified group
#5620
Labels
feature/configuration/xml
feature/test-runner
CLI test runner
type/enhancement
A new idea that should be implemented
Problem:
We like to keep our unit tests fast (<1s). If they are slow, we want them to fail. Adding
@small
to every (100s) test class is a bit verbose and prone to forgetting to add it for new unit test classes.Solution < v10:
We had a
UnitTestCase
that extendedTestCase
. That class overrode thegetSize
method to returnreturn PHPUnit\Util\Test::SMALL
. (I knowgetSize
was marked as internal, but it was a workaround for the time being). All of our unit tests extendedUnitTestCase
.Proposal :
It would be nice if there was a way to mark a directory as a certain size or if the
@small
annotation could be added to parent classes. In our case, we could add the@small
annotation toUnitTestCase
and then all of the children of that class would inherit that annotation.The text was updated successfully, but these errors were encountered: