Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

InverseAsymmetricMatchers incorrectly extends base Jest Expect #703

Open
Woodz opened this issue Sep 19, 2024 · 0 comments
Open

InverseAsymmetricMatchers incorrectly extends base Jest Expect #703

Woodz opened this issue Sep 19, 2024 · 0 comments

Comments

@Woodz
Copy link

Woodz commented Sep 19, 2024

Within the base Jest namespace augmentation, the line
interface InverseAsymmetricMatchers extends Expect {}

says that InverseAsymmetricMatchers extends the augmented Expect interface (which combines base Jest Expect with jest-extended Expect). This means that code such as expect.not.anything() is valid, but this fails at runtime as anything is not implemented in either InverseAsymmetricMatchers.

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

No branches or pull requests

1 participant