Skip to content

Commit

Permalink
Fix random timing related Cypress test failures (huh).
Browse files Browse the repository at this point in the history
  • Loading branch information
knadh committed Oct 20, 2024
1 parent 29aa977 commit 13222b5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions frontend/cypress/e2e/campaigns.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ describe('Campaigns', () => {
});

it('Deletes campaign', () => {
cy.wait(1000);
// Delete all visible lists.
cy.get('tbody tr').each(() => {
cy.get('tbody a[data-cy=btn-delete]').first().click();
Expand Down
2 changes: 1 addition & 1 deletion frontend/cypress/support/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Cypress.Commands.add('resetDB', () => {
// table against the given IDs, asserting the expected order of sort.
Cypress.Commands.add('sortTable', (theadSelector, ordIDs) => {
cy.get(theadSelector).click();
cy.wait(100);
cy.wait(250);
cy.get('tbody td[data-id]').each(($el, index) => {
expect(ordIDs[index]).to.equal(parseInt($el.attr('data-id')));
});
Expand Down

0 comments on commit 13222b5

Please sign in to comment.