-
Notifications
You must be signed in to change notification settings - Fork 344
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
Switch TPv2 E2E tests to Cypress #7894
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #7894 +/- ##
=============================================
+ Coverage 28.84% 74.35% +45.50%
=============================================
Files 602 117 -485
Lines 77445 5374 -72071
Branches 90 880 +790
=============================================
- Hits 22342 3996 -18346
+ Misses 53012 1310 -51702
+ Partials 2091 68 -2023
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Also ran npm audit fix
1d9b149
to
f232748
Compare
This is making the TPv2 RPM fail to build From the PR of #7922:
|
that's interesting. It shouldn't be attempting to compile or run the e2e tests to build the RPM. |
This reverts commit d8e78de.
Reverted due to breaking tests in 4b6af89, please re-PR with tests fixed |
Reverting something experimental because it affects the ability to build distributables for something that isn't distributed (because it's experimental) seems a bit extreme. |
If we don't want it to affect the default builds, then
But because it is included in |
That should definitely never have been true. That's a bug in
Also should never have been true, but additionally: why is a test that depends on and explicitly uses something not run when that thing changes? Two bugs in the GHAs. |
AFAIAC, the bug that lead to the revert is that TPv2 is included in the CDN-in-a-Box CI GHA workflow but its paths don't trigger it. If the CDN-in-a-Box CI GHA had failed (due to the breaking changes in #7894), it would not have gotten merged and would not need to be reverted. |
This PR switches the TPv2 E2E testing suite from NightwatchJS to Cypress.
"Why?", you may ask. Because it took me all of two days to replicate all of our test suite in Cypress - that's how easy it is to use. For comparison: I have never even once been able to get the Nightwatch tests to run on my machine. With Cypress, the typings are provided by the library itself, testing on Chrome and Firefox took exactly zero time and effort to figure out, and the tests actually just do the things I want them to do without me having to spend countless hours needling them with the correct set of
await
s and chained commands. Which is why most all of our tests do little more than check for the presence of some DOM elements. Maybe with Cypress, we could fix that.tl;dr: Nightwatch is extremely hard to use and Cypress is extremely easy.
Which Traffic Control components are affected by this PR?
What is the best way to verify this PR?
Run the end-to-end tests. Which doesn't take very long and can be depended upon to actually work.
PR submission checklist