E2E openLibrary and openLayers should not be indeterminate
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3550965. --> Reported by: [jessebaker](https://www.drupal.org/user/3546546) Related to !206 >>> <h3 id="overview">Overview</h3> <p>For ease of DX our e2e tests (both CY and PW) have helpfunctions to open the various primary panels (library, layers etc).</p> <p>To make those helpers easier to use, they are made in such a way that you can call them no matter the current state of the DOM and they should muddle through and end up with the requested panel open.</p> <p>The issue is that it means those functions are somewhat indeterminate. As Cypress's docs describe here <a href="https://docs.cypress.io/app/guides/conditional-testing">https://docs.cypress.io/app/guides/conditional-testing</a> conditional testing is really an anti-pattern and that's essentially what we are doing here (in a round about way)</p> <h3 id="proposed-resolution">Proposed resolution</h3> <p>Update those helpers to be more picky. If I tell a test to open the library panel but the library panel is already open, then my test is wrong and I should be forced to correct it. </p> <h3 id="ui-changes">User interface changes</h3>
issue