-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Cannot run vitest using examples/with-vitest
with astro 5.0.3
#12662
Comments
I can confirm the issue and yes this is related to the closed one. Vitest has reverted its support for Vite 6 in I tried to use "pnpm": {
"overrides": {
"@vitest/coverage-v8>vite": "6.0.2",
"@vitest/mocker>vite": "6.0.2",
"vitest>vite": "6.0.2"
}
} If you use "overrides": {
"vite": "6.0.2"
} However, I don't know if we should update the example in the meantime since this should be temporary... According to a Vitest issue (vitest-dev/vitest#6992), Vite 6 will only be supported from Vitest 3 expected in January. |
I can confirm that the npm override worked for me. Thanks! |
Had the same problem. Ii'm using yarn, so solved it by setting
|
The workaround works for me as well! 👍
I understand. What would you say to adding a note to the migration page? The workaround might be a little hard to find for others in an issue. |
I'll keep this open to make it easier for people to find, but this is an issue which needs to be fixed upstream in Vitest. In the meantime, the overrides are the best approach. |
note: had to install vite 6.0.3 to allow the override. see the issue here: withastro/astro#12662
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
Hi there!
Running
npm run test run
fails withUnknown Error: [object object]
. I also ran this using node v20.18.0 but the result is the same.The code is using the Stackblitz link found on the example README.md
There is an issue that is probably related: #12384
What's the expected result?
I would expect the tests to run. :)
Link to Minimal Reproducible Example
https://stackblitz.com/github/withastro/astro/tree/latest/examples/with-vitest?file=README.md
Participation
The text was updated successfully, but these errors were encountered: