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

bug: CLI Jest -u argument is not passed #3828

Closed
duhem-s opened this issue Nov 17, 2022 · 5 comments
Closed

bug: CLI Jest -u argument is not passed #3828

duhem-s opened this issue Nov 17, 2022 · 5 comments
Assignees
Labels
Bug: Validated This PR or Issue is verified to be a bug within Stencil

Comments

@duhem-s
Copy link

duhem-s commented Nov 17, 2022

Stencil version:

 @stencil/core@2.13.0

Current behavior:
When I run the test script, I can not pass anymore the -u argument to update my snapshots.

Expected behavior:
Being able to update my snapshot using the CLI.

GitHub Reproduction Link:
https://github.com/duhem-s/stencil-cli

Other information:
Using the command npm run test -u with stencil@2.12.1 :
image

With stencil@2.13.0 :
image

@tanner-reits
Copy link
Member

Hey @duhem-s 👋

Thanks for reporting this issue and providing a reproduction! I hopped in and took a peek at the problem you encountered across a couple different versions of Stencil (2.12.1, 2.13.0, and 2.19.3 (latest)). Definitely some inconsistencies between the versions. So, I'll get this pulled into our backlog for us to take a look at!

In the meantime, if you're running Stencil 2.13.0, I was able to get the snapshots to update in the reproduction repo using the un-aliased Jest CLI flag:
npm run test -- --updateSnapshot

Hopefully that can keep you moving for now!

@tanner-reits tanner-reits removed their assignment Nov 17, 2022
@tanner-reits tanner-reits added Bug: Validated This PR or Issue is verified to be a bug within Stencil and removed triage labels Nov 17, 2022
@alicewriteswrongs alicewriteswrongs self-assigned this Nov 17, 2022
@rwaskiewicz
Copy link
Contributor

@duhem-s Can you do us a favor and let us know what versions of node and npm you're using? From your project's directory, run:

npm --version
node --version

Thanks!

@rwaskiewicz rwaskiewicz added the Awaiting Reply This PR or Issue needs a reply from the original reporter. label Dec 1, 2022
@duhem-s
Copy link
Author

duhem-s commented Dec 1, 2022

Hi @rwaskiewicz !

I'm using npm@6.14.17 and node@14.19.3

@ionitron-bot ionitron-bot bot removed the Awaiting Reply This PR or Issue needs a reply from the original reporter. label Dec 1, 2022
@alicewriteswrongs
Copy link
Contributor

Hey @duhem-s, we now have a PR which I believe fixes this problem (#4124). I just published a dev build with those changes which could be installed like so:

npm install @stencil/core@3.1.0-dev.1678201586.203c481

after installing it in your reproduction case I'm able to do

npm test -- -u

and the snapshots update!

Would you mind trying that out to confirm that it works for you as well?

@rwaskiewicz
Copy link
Contributor

The PR associated with this issue has landed and is included in today's v3.2.0 release. Should this issue reappear, please feel free to open a new issue. Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug: Validated This PR or Issue is verified to be a bug within Stencil
Projects
None yet
Development

No branches or pull requests

4 participants