Skip to content
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

Fix support tests #26663

Merged
merged 1 commit into from Apr 20, 2021
Merged

Fix support tests #26663

merged 1 commit into from Apr 20, 2021

Conversation

nickvergessen
Copy link
Member

  1. Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #0 (35, 15, 2, false)
    Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

  2. Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set Name the repository "server" #1 (35, 45, 15, false)
    Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

  3. Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set Some more links, structure adjustment and CoC #2 (35, 45, 5, true)
    Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

  4. Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set Use shields for IRC links #3 (35, 45, 55, false)
    Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

Had to use the Database user backend, as using multiple interfaces is deprecated:
sebastianbergmann/phpunit#3955

This functionality should be deprecated as "having to use it" is almost always a symptom of bad design.
More importantly, though, the support for the creation of test doubles that implement multiple interfaces
resulted in code that is hard to maintain.

Signed-off-by: Joas Schilling coding@schilljs.com

2) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #0 (35, 15, 2, false)
Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

3) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #1 (35, 45, 15, false)
Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

4) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #2 (35, 45, 5, true)
Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

5) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #3 (35, 45, 55, false)
Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist

Had to use the Database user backend, as using multiple interfaces is deprecated:
sebastianbergmann/phpunit#3955
> This functionality should be deprecated as "having to use it" is almost always a symptom of bad design.
> More importantly, though, the support for the creation of test doubles that implement multiple interfaces
> resulted in code that is hard to maintain.

Signed-off-by: Joas Schilling <coding@schilljs.com>
Copy link
Member

@PVince81 PVince81 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@rullzer rullzer merged commit cd5dd31 into master Apr 20, 2021
@rullzer rullzer deleted the bugfix/noid/fix-support-test branch April 20, 2021 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants