-
Notifications
You must be signed in to change notification settings - Fork 497
feat: update to Cypress 10 #108
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I chose to explicitly specify specPattern
everywhere, for:
- Make the convention clearer for newcomers;
- Besides the default pattern, I also allowed
*.spec.*
so that it's easier for users from the old projects to migrate.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides the default pattern, I also allowed .spec. so that it's easier for users from the old projects to migrate.
I believe this is okay for now. I worry about tsconfig files that have global types, but this is a convo for another day.
...ed to empty the `lib` option
@JessicaSachs
I pushed the templates to https://github.com/vuejs/create-vue-templates/tree/preview-cy-10
A basic example: https://github.com/vuejs/create-vue-templates/tree/preview-cy-10/cypress
Use with Vitest: https://github.com/vuejs/create-vue-templates/tree/preview-cy-10/vitest-cypress
Basic example, but in TypeScript: https://github.com/vuejs/create-vue-templates/tree/preview-cy-10/typescript-cypress
Use with Vitest, in TypeScript: https://github.com/vuejs/create-vue-templates/tree/preview-cy-10/typescript-vitest-cypress
(Reminder: In create-vue
templates, the project must be built before running test:e2e
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This configuration is not automatically migrated by the Cypress, is not mentioned in the migration guide, and is not included in the create-vue
template snapshots, so we might need to remind the user somewhere else.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really prefer not using __tests__
but it's a conversation topic for another time.
.spec.
will conflict with Vitest, Mocha, and Jest types I believe, which is why we chose .cy.
but it's okay, you're right about the struggle people may have with migration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They will not in our case because of the usage of solution-style tsconfigs.
But yeah, people who are not familiar enough with TypeScript will find this troublesome. So I've changed the default pattern.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently --e2e
and --component
flags are always passed to skip the "Choose testing type" screen.
This is because the commands are test:e2e
and test:unit
, we expect users to know what types of tests they are looking for.
No description provided.