-
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
feat(component-testing): changes to the driver and reporter preparing for runner-ct #14434
Conversation
runScript can now use promises instead of files. Thi test this new behavior
Thanks for taking the time to open a PR!
|
Test summaryRun details
View run in Cypress Dashboard ➡️ Flakiness
This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
I did not find where the tests for [EDIT] nevermind I found the integration tests |
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.
Mostly spec matcher suggestions. One question about why we're returning a value from a seemingly unaffected line of code
packages/reporter/cypress/integration/unit/runnables_store_spec.ts
Outdated
Show resolved
Hide resolved
packages/driver/cypress/integration/cypress/script_utils_spec.js
Outdated
Show resolved
Hide resolved
Co-authored-by: Jessica Sachs <jess@jessicasachs.io>
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.
Left some comments
packages/driver/cypress/integration/cypress/script_utils_spec.js
Outdated
Show resolved
Hide resolved
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 think this looks good
b4e150a
Except for the percy snapshot that was added, all tests seems to be passing and the coverage does not seem diminished. |
Reporter and Driver packages
changes necessary for runner-ct
driver
Since the specs are loaded using a dev-server, we need to be able to delegate the loading to webpack/vite/parcel.
To that effect, we allow to initialize
runScripts
indriver/src/cypress/scripts_utils.js
to accept promises instead of file paths.Also, there is a little fix on the script utils tests (it was not testing that eval was called).
reporter
To allow running of multiple specs files at once we need to add a history of runnables in the runnables store.
The runner-ct will allow to start & watch multiple specs at once so we will need to be able to run those through the reporter.
Accounting for this multi-spec mode means also having this
runMode
as a prop for the reporter component.closes CT-201