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

Test globals not defined in node test environment. #9556

Closed
lwhiteley opened this issue Feb 11, 2020 · 2 comments
Closed

Test globals not defined in node test environment. #9556

lwhiteley opened this issue Feb 11, 2020 · 2 comments

Comments

@lwhiteley
Copy link

lwhiteley commented Feb 11, 2020

🐛 Bug Report

Test globals not defined in node test environment.
https://jestjs.io/docs/en/api

To Reproduce

Steps to reproduce the behavior:
When using config

  "jest": {
    "testEnvironment": "node"
  }

then the test globals are not defined.

when i remove the config or jus put "testEnvironment": "jsdom" then the tests receive globals

Expected behavior

Globals should be defined in node testEnvironment

envinfo

 System:
    OS: macOS 10.15.3
    CPU: (4) x64 Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
  Binaries:
    Node: 10.13.0 - ~/.nvm/versions/node/v10.13.0/bin/node
    Yarn: 1.21.1 - ~/.nvm/versions/node/v10.13.0/bin/yarn
    npm: 6.13.7 - ~/.nvm/versions/node/v10.13.0/bin/npm
  npmPackages:
    jest: ^25.1.0 => 25.1.0
@SimenB
Copy link
Member

SimenB commented Feb 11, 2020

Duplicate of #9538. You need to update your node version

@SimenB SimenB closed this as completed Feb 11, 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

2 participants