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

TypeError: environment.teardown is not a function #10159

Closed
acanimal opened this issue Jun 11, 2020 · 3 comments
Closed

TypeError: environment.teardown is not a function #10159

acanimal opened this issue Jun 11, 2020 · 3 comments

Comments

@acanimal
Copy link

Hi, I'm using jest on a node project and TypeError: environment.teardown is not a function appears appear after upgrading from jest@24.9.0 to jest@26.1.0 (yarn)

I search and found this #6393 but none of the solutions (like deleting yarn.lock, node_modules, yarn and reinstalling everyting) works for me.

After some tries it seems like the jest-environment-node package is not installed. Once manually installed all seems to work again.

Is this the right solution? Any help?

hyochan pushed a commit to dooboolab-community/hackatalk that referenced this issue Jun 27, 2020
@hyochan
Copy link

hyochan commented Jun 29, 2020

We've managed to fix this by installing jest-environment-node explicitly. Thanks @acanimal .

@SimenB
Copy link
Member

SimenB commented Jun 29, 2020

You don't have to explicitly install it although it's a good practice so you don't have to rely on hoisting - you probably have some config (preset?) with a dep on an older version or some such.


This issue does not follow the issue template asking for a minimal reproduction, so closing

@SimenB SimenB closed this as completed Jun 29, 2020
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 11, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants