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

fix(nextjs): schema type for unitTestRunner for library #26824

Merged

Conversation

Demianeen
Copy link
Contributor

@Demianeen Demianeen commented Jul 4, 2024

Current Behavior

The docs say that you can use vitest as a unitTestRunner option. It also worked when I tested with the following command:

nx g @nx/next:library shared --dir=modules/shared --style none --dry-run --projectNameAndRootFormat as-provided --component false --unitTestRunner vitest

But types say otherwise:
CleanShot 2024-07-04 at 16 24 44@2x

Expected Behavior

Types will allow 'vitest' option for a unitTestRunner

Related Issue(s)

none

@Demianeen Demianeen requested a review from a team as a code owner July 4, 2024 15:28
@Demianeen Demianeen requested a review from xiongemi July 4, 2024 15:28
Copy link

vercel bot commented Jul 4, 2024

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 Aug 20, 2024 2:40pm

@Demianeen
Copy link
Contributor Author

Demianeen commented Jul 5, 2024 via email

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@xiongemi xiongemi changed the title fix(next): schema type for unitTestRunner fix(nextjs): schema type for unitTestRunner Aug 20, 2024
@xiongemi xiongemi changed the title fix(nextjs): schema type for unitTestRunner fix(nextjs): schema type for unitTestRunner for library Aug 20, 2024
@xiongemi xiongemi force-pushed the fix/invalid-schema-type-next-generator branch from 9703dfe to 68bd481 Compare August 20, 2024 14:37
@xiongemi xiongemi merged commit 73f12a3 into nrwl:master Aug 21, 2024
6 checks passed
FrozenPandaz pushed a commit that referenced this pull request Aug 21, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
## Current Behavior
The [docs](https://nx.dev/nx-api/next/generators/library#unittestrunner)
say that you can use vitest as a unitTestRunner option. It also worked
when I tested with the following command:
```sh
nx g @nx/next:library shared --dir=modules/shared --style none --dry-run --projectNameAndRootFormat as-provided --component false --unitTestRunner vitest
```

But types say otherwise:
![CleanShot 2024-07-04 at 16 24
44@2x](https://github.com/nrwl/nx/assets/51330172/13a2d0ca-6950-413b-ac80-5d33cd64a714)

## Expected Behavior
Types will allow 'vitest' option for a unitTestRunner

## Related Issue(s)
none

Co-authored-by: Emily Xiong <xiongemi@gmail.com>
(cherry picked from commit 73f12a3)
Copy link

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 Aug 28, 2024
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.

None yet

3 participants