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

Inconsistent Naming: toHaveBeenCalledOnce vs. toHaveBeenCalledExactlyOnceWith #706

Open
jeengbe opened this issue Jan 11, 2025 · 0 comments

Comments

@jeengbe
Copy link

jeengbe commented Jan 11, 2025

Because toHaveBeenCalledExactlyOnceWith includes "exactly", this suggests that toHaveBeenCalledOnce actually checks for at least one call. But the documentation (and implementation) explain that both check for exactly one call. This naming discrepancy is misleading at best. I don't have an opinion about which is preferrable.

@jeengbe jeengbe changed the title Inconsistent Naming: toHaveBeenCalledOnce vs toHaveBeenCalledExactlyOnceWith Inconsistent Naming: toHaveBeenCalledOnce vs. toHaveBeenCalledExactlyOnceWith Jan 11, 2025
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

1 participant