Skip to content

Conversation

@realFlowControl
Copy link
Contributor

This pull requests belongs to #4105, deprecates the old test suite loader and gives deprecation warnings about:

  • multiple test classes in a single file
  • test case class name does not match filename

@realFlowControl realFlowControl force-pushed the deprecate-old-test-suite-loader-4105 branch from 9e3639e to 9d78571 Compare February 19, 2020 19:11
@realFlowControl realFlowControl force-pushed the deprecate-old-test-suite-loader-4105 branch from 9d78571 to 1c4f6c9 Compare February 19, 2020 19:16
@realFlowControl realFlowControl force-pushed the deprecate-old-test-suite-loader-4105 branch from 1c4f6c9 to b871370 Compare February 19, 2020 19:19
@realFlowControl realFlowControl marked this pull request as ready for review February 19, 2020 19:19
@realFlowControl
Copy link
Contributor Author

Hey @sebastianbergmann,
the deprecation message is a bit, let's say explicit, but I think its good to help a bit in such a case, what do you think?

$ ./phpunit tests/_files/OneClassPerFile/wrongClassName/
PHPUnit 9.0-gb87137081 by Sebastian Bergmann and contributors.

Runtime:       PHP 7.3.14 with Xdebug 2.9.2
Configuration: /home/bowman/Work/flowcontrol/phpunit/phpunit.xml

Warning: Test case class not matching filename is deprecated
         in /home/bowman/Work/flowcontrol/phpunit/tests/_files/OneClassPerFile/wrongClassName/WrongClassNameTest.php
         class name was 'WrongClassNameBar', expected 'WrongClassNameTest', see #4105

.                                                                   1 / 1 (100%)

Time: 48 ms, Memory: 6.00 MB

OK (1 test, 1 assertion)

/Flo

@sebastianbergmann sebastianbergmann added feature/test-runner CLI test runner type/deprecation Something will be/is deprecated labels Mar 30, 2020
@sebastianbergmann sebastianbergmann added this to the PHPUnit 9.1 milestone Mar 31, 2020
@sebastianbergmann sebastianbergmann self-assigned this Mar 31, 2020
@sebastianbergmann
Copy link
Owner

Merged manually, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature/test-runner CLI test runner type/deprecation Something will be/is deprecated

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants