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

When running jest script through npm, the snapshot summary help message is missing -- #5414

Closed
yjcxy12 opened this issue Jan 29, 2018 · 3 comments

Comments

@yjcxy12
Copy link

yjcxy12 commented Jan 29, 2018

Do you want to request a feature or report a bug?
Report a bug

What is the current behavior?
When running jest through npm script, the Snapshot Summary report outputs wrong help message. e.g. run `npm run test:react -u` to remove it. rather than run `npm run test:react -- -u` to remove it.

If the current behavior is a bug, please provide the steps to reproduce and
either a repl.it demo through https://repl.it/languages/jest or a minimal
repository on GitHub that we can yarn install and yarn test.

  • make a snapshot
  • run test
  • remove original component
  • run test again

What is the expected behavior?
It should output run `npm run test:react -- -u

Please provide your exact Jest configuration and mention your Jest, node,
yarn/npm version and operating system.

Using npm@5 node@8 Macbook OSX

Additional info
Suspect https://github.com/facebook/jest/blob/master/packages/jest-cli/src/reporters/summary_reporter.js#L147 is the line to fix. Only checking isYarn.

@rickhanlonii
Copy link
Member

Nice find @yjcxy12

This is probably a dupe of #2517

@SimenB
Copy link
Member

SimenB commented Jan 29, 2018

Should have been fixed in #5376.

@SimenB SimenB closed this as completed Jan 29, 2018
@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 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants