Codeception / Stub

Flexible Stub wrapper for PHPUnit's Mock Builder
MIT License
296 stars 17 forks source link

Remove shim.php to set legacy class aliases #12

Closed zebraf1 closed 5 years ago

zebraf1 commented 6 years ago

Legacy class aliases are no longer needed in PHPUnit 6.5.0 or later, updated composer requirements.

PHPUnit 6.5.0 is the first version to require phpunit/phpunit-mock-objects: ^5.0 https://packagist.org/packages/phpunit/phpunit#6.5.0

phpunit/phpunit-mock-objects 5.0 is the first version where Mock classes were namespaced: https://github.com/sebastianbergmann/phpunit-mock-objects/commit/b98a0791b426861a9055c91615b19627716c8950

Since PHPUnit 7.2.0 phpunit/phpunit-mock-objects was merged back into the main repository, so it should work with any version since 6.5 (up to current 7.3.5)

Apparently this bumps PHP version requirement to 7.0 which is to be expected at some point. Perhaps there should be a codeception/stub 3.0 version for PHP7 and keep PHP5 support for 2.* versions?

Fixes https://github.com/Codeception/Codeception/issues/5508

Naktibalda commented 5 years ago

@zebraf1 I apologize for a very late response. If you could update this branch (rebasing it on Codeception:master would be the best) to resolve conflicts, I would release 3.0.0.

Direct dependency on phpunit was replaced with dependency on "codeception/phpunit-wrapper": ">6.0.15 <6.1.0 | ^6.6.1 | ^7.7.1 | ^8.0.3" To drop support for PHPUnit 5 and PHPUnit 6 < 6.5 change it to "^6.6.1 | ^7.7.1 | ^8.0.3"

zebraf1 commented 5 years ago

Merged with master and resolved conflicts

Naktibalda commented 5 years ago

I cleaned up your pull request and raised a new PR at #17

zebraf1 commented 5 years ago

Thanks!