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

Support jest.testEnvironment in package.json #8880

Closed
yuki-93 opened this issue Apr 22, 2020 · 4 comments
Closed

Support jest.testEnvironment in package.json #8880

yuki-93 opened this issue Apr 22, 2020 · 4 comments

Comments

@yuki-93
Copy link

yuki-93 commented Apr 22, 2020

Hey guys,

use case: The user accesses my site with a query param in the URL for filling a questionnaire. I have a class in my project which is for the backend communication. This class fetches the correct param from window.location.search and adds it to the request.

I now want to test this class and method, but manipulation of window.location is not so easy with current jsdom versions. According to this issue and comment in jest-repo jestjs/jest#5124 (comment) there is a npm package which does the magic with jsdom.reconfigure.

I tried this so setup in my project, but got the error message from CRA the "testEnvironment" is not yet supported. I can either npm run eject or open an issue, to might support this jest config option.

Is there a reason, why not supporting all jest config options or a way, which I can use the given config? Thanks for your help.

@stale
Copy link

stale bot commented May 22, 2020

This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs.

@stale stale bot added the stale label May 22, 2020
@yuki-93
Copy link
Author

yuki-93 commented May 22, 2020

Hey guys, are here any updates?

@stale stale bot removed the stale label May 22, 2020
@stale
Copy link

stale bot commented Jun 21, 2020

This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs.

@stale stale bot added the stale label Jun 21, 2020
@stale
Copy link

stale bot commented Jun 26, 2020

This issue has been automatically closed because it has not had any recent activity. If you have a question or comment, please open a new issue.

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

No branches or pull requests

1 participant