-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
[Component Testing] New test code is not being bundled using NextJS 11.1 and Webpack 5 #17920
Comments
Is this fixed by restarting Cypress? If so, it's possible this PR will fix it. |
It does seem related, but in my case it only was fixed when I deleted the .next folder |
Interesting work around. I am not sure I can look at this immediately. I wonder if @ZachJW34 has any ideas? Some kind of Next or Webpack 5 caching? Did you try using the latest version of our webpack-dev-server package (released 5 days ago?) |
@lmiller1990 I applied my fix in #17950 to this project and it fixed this issue. After disabling the loader cache, I did have to delete the @drj17 after #17950 is merged and you've updated to the new version, this should no longer be an issue (note that you will probably have to delete the
Make sure to delete the |
This was released as @cypress/webpack-dev-server-v1.8.1 on 2022-02-08. |
Current behavior
When creating a new
*.spec.{tsx, jsx}
file in the specified component folder, these tests cannot be run.Similarly, if you delete a spec file the compiler will complain that the file
{file}.spec.tsx
cannot be found.The only work around I've found is to manually delete the .next folder so that it actually bundles the code when I run
cypress open-ct
.Desired behavior
No response
Test code to reproduce
yarn install && yarn cypress open-ct
cypress/pages/index.spec.jsx
file.next
folder, re-runyarn cypress open-ct
, tests now show show up.Cypress Version
8.3.1
Other
package.json
plugins/index.js
cypress.json:
The text was updated successfully, but these errors were encountered: