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

Do not fail silently when mocking a non-existing method #1039

Closed
bartfeenstra opened this issue Oct 28, 2013 · 1 comment
Closed

Do not fail silently when mocking a non-existing method #1039

bartfeenstra opened this issue Oct 28, 2013 · 1 comment

Comments

@bartfeenstra
Copy link

When configuring a method that did not previously exist on a mocked class or interface, PHPUnit fails silently; it does not let you know that it ignores your configuration. Instead, it should trigger an error or throw an exception, so some "calling undefined method" errors in the code under test can be prevented.

@whatthejeff
Copy link
Contributor

Thanks for the bug report, @bartfeenstra. This is actually a duplicate of sebastianbergmann/phpunit-mock-objects#12.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants