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

vitest run -u does not work as usual with [email protected] #7496

Closed
6 tasks done
blephy opened this issue Feb 14, 2025 · 1 comment
Closed
6 tasks done

vitest run -u does not work as usual with [email protected] #7496

blephy opened this issue Feb 14, 2025 · 1 comment

Comments

@blephy
Copy link

blephy commented Feb 14, 2025

Describe the bug

Hi,

-u option or --update does not work anymore with pnpm v10, it is not updating snapshots when using -- to pass command.

Reproduction

{
   "test": "vitest",
   "test:ci": "vitest run --coverage.enabled --hideSkippedTests",
   "test:update": "pnpm test -- --update"
}

pnpm test:update are not updating snapshot

But this still work :

{
   "test": "vitest",
   "test:ci": "vitest run --coverage.enabled --hideSkippedTests",
   "test:update": "pnpm test --update"
}

pnpm test:update are updating snapshot

System Info

System:
    OS: macOS 15.1.1
    CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
    Memory: 897.85 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.14.0 - ~/.nvm/versions/node/v22.14.0/bin/node
    npm: 10.9.2 - ~/.nvm/versions/node/v22.14.0/bin/npm
    pnpm: 10.4.0 - ~/.nvm/versions/node/v22.14.0/bin/pnpm
  Browsers:
    Chrome: 133.0.6943.55
    Safari: 18.1.1
  npmPackages:
    @vitest/coverage-v8: 3.0.5 => 3.0.5
    @vitest/eslint-plugin: 1.1.31 => 1.1.31
    vitest: 3.0.5 => 3.0.5

Used Package Manager

[email protected]

Validations

@blephy blephy changed the title vitest run -u does not work anymore vitest run -u does not work as usual with [email protected] Feb 14, 2025
@hi-ogawa
Copy link
Contributor

I heard pnpm 10 has some breaking change with pnpm test to work same as pnpm run test https://github.com/pnpm/pnpm/releases/tag/v10.0.0. It looks like you don't need -- for pnpm test. If you have questions regarding this change, please check with pnpm side.

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

2 participants