fix two flaky test issues

This commit is contained in:
burnettk 2022-10-05 16:34:27 -04:00
parent 56e8efb76c
commit 35c7d247d6
2 changed files with 6 additions and 1 deletions

View File

@ -165,7 +165,8 @@ describe('process-instances', () => {
cy.getBySel(`process-instance-status-${processStatus}`).contains(
processStatus
);
cy.get('button[aria-label=Remove]').click();
// there should really only be one, but in CI there are sometimes more
cy.get('button[aria-label=Remove]:first').click();
}
});

View File

@ -47,6 +47,10 @@ Cypress.Commands.add('login', (selector, ...args) => {
Cypress.Commands.add('logout', (selector, ...args) => {
cy.getBySel('logout-button').click();
// otherwise we can click logout, quickly load the next page, and the javascript
// doesn't have time to actually sign you out
cy.contains('Sign in to your account');
});
Cypress.Commands.add('createGroup', (groupId, groupDisplayName) => {