Background
While working on #2084 (Cypress/Behat coverage for the "remember my choice" epic), the pre-existing it.only(...) in tests/e2e/cypress/integration/skeune/wayf/wayf.general.spec.js was removed to allow other tests in the file to run again.
Running the full file exposed 20 failures (not the ~12 previously assumed). #2084 fixes the subset that is well-understood and cheap:
- A test missing its own
cy.visit() (breaks under Cypress's default testIsolation: true, which resets to a blank page between tests).
- Raw connected/disconnected IdP count assertions that don't account for
WayfController's addDiscoveries query param defaulting to true (which injects 2 fixed synthetic "discovery" IdPs into every render).
The remaining failures are left re-.skip()'d (with a comment pointing at this issue) because they look like a distinct, deeper problem needing dedicated investigation:
- Visibility assertions tied to the
wayf__idpList--cutoffMet CSS class (Should show no connected IdPs when cutoff point is configured, Should show no disconnected IdPs when the flag is false) — the element has the expected class but isn't actually hidden, suggesting either the CSS rule is missing/stale in the built theme assets for this test environment, or the class/behaviour contract has drifted.
search__submit / search__reset visually-hidden class toggling not happening as expected when typing in the search field (Should show no results when no IdPs are found, Should be able to search for an idp).
data-weight attribute assertions (6 tests) — findWeight.js / checkFullMatch.js / checkPartialMatch.js scoring constants (215/82/100/60/8/7) don't match any currently-rendered element; could be legitimate algorithm drift since these tests were written, unrelated to the discovery-idp noise.
.remainingIdps__defaultIdp banner not found / not toggling correctly in several tests (Check if the defaultIdp is present, Should reset the search text..., Should hide/show the IdP link when search term is provided).
No console/JS errors were observed during a quick browser check, which weakens the "broken build" theory somewhat, but this needs a proper investigation with fresh eyes — likely tracing whether the built CSS/JS actually matches current source for the container used to run these tests, and re-verifying the weight-scoring constants against current fixture data.
Task
Investigate and fix (or intentionally rewrite) the remaining suppressed test cases in wayf.general.spec.js, removing the .skip() added in #2084 once each is understood and passing for the right reason.
Background
While working on #2084 (Cypress/Behat coverage for the "remember my choice" epic), the pre-existing
it.only(...)intests/e2e/cypress/integration/skeune/wayf/wayf.general.spec.jswas removed to allow other tests in the file to run again.Running the full file exposed 20 failures (not the ~12 previously assumed). #2084 fixes the subset that is well-understood and cheap:
cy.visit()(breaks under Cypress's defaulttestIsolation: true, which resets to a blank page between tests).WayfController'saddDiscoveriesquery param defaulting totrue(which injects 2 fixed synthetic "discovery" IdPs into every render).The remaining failures are left re-
.skip()'d (with a comment pointing at this issue) because they look like a distinct, deeper problem needing dedicated investigation:wayf__idpList--cutoffMetCSS class (Should show no connected IdPs when cutoff point is configured,Should show no disconnected IdPs when the flag is false) — the element has the expected class but isn't actually hidden, suggesting either the CSS rule is missing/stale in the built theme assets for this test environment, or the class/behaviour contract has drifted.search__submit/search__resetvisually-hidden class toggling not happening as expected when typing in the search field (Should show no results when no IdPs are found,Should be able to search for an idp).data-weightattribute assertions (6 tests) —findWeight.js/checkFullMatch.js/checkPartialMatch.jsscoring constants (215/82/100/60/8/7) don't match any currently-rendered element; could be legitimate algorithm drift since these tests were written, unrelated to the discovery-idp noise..remainingIdps__defaultIdpbanner not found / not toggling correctly in several tests (Check if the defaultIdp is present,Should reset the search text...,Should hide/show the IdP link when search term is provided).No console/JS errors were observed during a quick browser check, which weakens the "broken build" theory somewhat, but this needs a proper investigation with fresh eyes — likely tracing whether the built CSS/JS actually matches current source for the container used to run these tests, and re-verifying the weight-scoring constants against current fixture data.
Task
Investigate and fix (or intentionally rewrite) the remaining suppressed test cases in
wayf.general.spec.js, removing the.skip()added in #2084 once each is understood and passing for the right reason.