fix(examples): correct 'test:projects' script to use vitest directly #10683
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Update the
test:projects
script in thewith-vitest
example to use Vitest's projects feature directly.Currently, the
test:projects
script runsturbo run test
, which leverages Turborepo's package-level caching. However, given the script name and the example's hybrid approach documentation, it seems more appropriate for this command to usevitest run
directly to demonstrate Vitest's projects feature.Changes made:
package.json
to usevitest run
for thetest:projects
scripttest:projects
doesdocs/site/content/docs/guides/tools/vitest.mdx
to reflect the correct usageTesting Instructions
examples/with-vitest
directorypnpm install
pnpm --filter @repo/vitest-config build
pnpm test
- Should run tests using Turborepo (with caching)pnpm test:projects
- Should run tests using Vitest's projects feature directlypnpm test:projects:watch
- Should run tests in watch mode using Vitest's projects featuretest
andtest:projects
now have different behaviors as intended