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(nx-plugin): fix server tests and tsConfigPaths not being recognized #804

Merged

Conversation

jeremyhofer
Copy link
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • Other... Please describe:

Which package are you modifying?

  • vite-plugin-angular
  • vite-plugin-nitro
  • astro-angular
  • create-analog
  • router
  • platform
  • content
  • nx-plugin
  • trpc

What is the current behavior?

Currently tests created in the src/server directory within an analog application scaffolded inside a Nx monorepo are not recognized. Similarly, tsconfig paths are not respected, causing import issues.

Closes #801

What is the new behavior?

After conversation with @brandonroberts , making the exclude array in the tsconfig.json of the application an empty array fixes this as currently it is excluding all test files under src/server. An alternative is to override the excludes by setting an empty array in tsconfig.spec.json, but this only fixes the tests not being recognized, not the tsconfig paths issue.

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

[optional] What gif best describes this PR or how it makes you feel?

Copy link

netlify bot commented Dec 15, 2023

Deploy Preview for analog-blog ready!

Name Link
🔨 Latest commit 8fb009e
🔍 Latest deploy log https://app.netlify.com/sites/analog-blog/deploys/657cd45fe5b755000750e2ed
😎 Deploy Preview https://deploy-preview-804--analog-blog.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Dec 15, 2023

Deploy Preview for analog-docs ready!

Name Link
🔨 Latest commit 8fb009e
🔍 Latest deploy log https://app.netlify.com/sites/analog-docs/deploys/657cd45f4b0de60008e64c1a
😎 Deploy Preview https://deploy-preview-804--analog-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Dec 15, 2023

Deploy Preview for analog-app ready!

Name Link
🔨 Latest commit 8fb009e
🔍 Latest deploy log https://app.netlify.com/sites/analog-app/deploys/657cd45f74c1ec0008ad02a7
😎 Deploy Preview https://deploy-preview-804--analog-app.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@brandonroberts brandonroberts merged commit eda802b into analogjs:main Dec 16, 2023
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Nx monorepo - vitest fails to recognize tests in src/**/*.spec.ts files
2 participants