Component tests do not load with Vite 3 + HTTPs
See original GitHub issueCurrent behavior
When vite.config server.https
is set to true. Cypress component tests do not load. It’s stuck on “Your tests are loading” but without any error messages in console or in browser.
Desired behavior
Component tests should run successfully. Commenting out HTTPS in server.https and restarting Cypress allows the tests to pass.
Test code to reproduce
https://github.com/jnarowski/vite-3-vue-3-cypress
yarn install yarn cypress open
Click HelloWorld test and it will not run
Cypress Version
10.11.0
Node version
16.17.1
Operating System
Mac M1 Ventura
Debug Logs
https://gist.github.com/jnarowski/950ae8d3d4586472255a2a2052ee3ec0
Other
No response
Issue Analytics
- State:
- Created 10 months ago
- Reactions:1
- Comments:9 (3 by maintainers)
Top Results From Across the Web
Features | Vite
Rewrite the imports to valid URLs like /node_modules/.vite/deps/my-dep.js?v=f3sf2ebd so that the browser can import them properly. Dependencies are Strongly ...
Read more >Vite https on localhost - ssl - Stack Overflow
Easiest way is to use the vite-plugin-mkcert package. npm i vite-plugin-mkcert -D. vite.config.js import { defineConfig } from 'vite' import ...
Read more >Vitest | A blazing fast unit test framework powered by Vite
Jest Compatible. Expect, snapshot, coverage, and more - migrating from Jest is straightforward. Smart & instant watch mode.
Read more >Component Testing with Vite, Vue, and Cypress | Jessica Sachs
Cypress's component test runner interacts with your components as a user would, meaning you can debug using your favorite dev tools.
Read more >Upcoming Changes to Component Testing - Cypress
As part of Cypress 11, we are making some small changes to the mount API, the main way you render components. These changes...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
On my side updating the documentation should be enough for now.
Would the outcome of this ticket be documentation? I don’t think https support will land anytime soon: https://github.com/cypress-io/cypress/issues/3708