Skip to content

fix(js): do not generate explicit vitest task config for a js library unless adding plugin is disabled#29606

Merged
leosvelperez merged 1 commit intomasterfrom
js/fix-lib-vitest-inferred-task
Jan 13, 2025
Merged

fix(js): do not generate explicit vitest task config for a js library unless adding plugin is disabled#29606
leosvelperez merged 1 commit intomasterfrom
js/fix-lib-vitest-inferred-task

Conversation

@leosvelperez
Copy link
Copy Markdown
Member

@leosvelperez leosvelperez commented Jan 13, 2025

Current Behavior

Generating a js library with any bundler other than vite and with the vitest test runner results in an explicit test task in the project configuration.

Expected Behavior

Generating a js library with any bundler other than vite and with the vitest test runner should not generate an explicit test task in the project configuration. The test task should be inferred.

Related Issue(s)

Fixes #

@leosvelperez leosvelperez self-assigned this Jan 13, 2025
@leosvelperez leosvelperez requested a review from a team as a code owner January 13, 2025 15:51
@leosvelperez leosvelperez requested a review from jaysoo January 13, 2025 15:51
@vercel
Copy link
Copy Markdown

vercel Bot commented Jan 13, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Updated (UTC)
nx-dev ⬜️ Ignored (Inspect) Visit Preview Jan 13, 2025 3:53pm

@nx-cloud
Copy link
Copy Markdown
Contributor

nx-cloud Bot commented Jan 13, 2025

View your CI Pipeline Execution ↗ for commit 5884886.

Command Status Duration Result
nx affected --targets=lint,test,build,e2e,e2e-c... ✅ Succeeded 37m 1s View ↗
nx run-many -t check-imports check-commit check... ✅ Succeeded 1m 6s View ↗
nx-cloud record -- nx-cloud conformance:check ✅ Succeeded 1s View ↗
nx-cloud record -- nx format:check --base=dc2c9... ✅ Succeeded 19s View ↗
nx-cloud record -- nx sync:check ✅ Succeeded 17s View ↗
nx documentation --no-dte ✅ Succeeded 43s View ↗

☁️ Nx Cloud last updated this comment at 2025-01-13 16:35:12 UTC

@leosvelperez leosvelperez merged commit a352c81 into master Jan 13, 2025
@leosvelperez leosvelperez deleted the js/fix-lib-vitest-inferred-task branch January 13, 2025 16:37
FrozenPandaz pushed a commit that referenced this pull request Jan 15, 2025
… unless adding plugin is disabled (#29606)

<!-- Please make sure you have read the submission guidelines before
posting an PR -->
<!--
https://github.com/nrwl/nx/blob/master/CONTRIBUTING.md#-submitting-a-pr
-->

<!-- Please make sure that your commit message follows our format -->
<!-- Example: `fix(nx): must begin with lowercase` -->

<!-- If this is a particularly complex change or feature addition, you
can request a dedicated Nx release for this pull request branch. Mention
someone from the Nx team or the `@nrwl/nx-pipelines-reviewers` and they
will confirm if the PR warrants its own release for testing purposes,
and generate it for you if appropriate. -->

## Current Behavior
<!-- This is the behavior we have today -->

Generating a js library with any bundler other than `vite` and with the
`vitest` test runner results in an explicit `test` task in the project
configuration.

## Expected Behavior
<!-- This is the behavior we should expect with the changes in this PR
-->

Generating a js library with any bundler other than `vite` and with the
`vitest` test runner should not generate an explicit `test` task in the
project configuration. The `test` task should be inferred.

## Related Issue(s)
<!-- Please link the issue being fixed so it gets closed when this is
merged. -->

Fixes #

(cherry picked from commit a352c81)
@github-actions
Copy link
Copy Markdown
Contributor

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jan 19, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants