Skip to content

Commit 4fe1d6e

Browse files
committed
Try fix connect tests in trunk env.
1 parent 3921ba6 commit 4fe1d6e

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

tests/cypress/e2e/connect.test.js

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,18 @@ describe('Admin can connect to "Mailchimp" Account', () => {
2323
cy.get('#mailchimp_sf_oauth_connect').click();
2424
cy.wait(6000);
2525

26-
cy.popup().find('input#username').clear().type(Cypress.env('MAILCHIMP_USERNAME'));
27-
cy.popup().find('input#password').clear().type(Cypress.env('MAILCHIMP_PASSWORD'));
28-
cy.popup().find('button[type="submit"]').click();
26+
cy.popup()
27+
.find('input#username')
28+
.clear()
29+
.type(Cypress.env('MAILCHIMP_USERNAME'), { force: true });
30+
cy.popup()
31+
.find('input#password')
32+
.clear()
33+
.type(Cypress.env('MAILCHIMP_PASSWORD'), { force: true });
34+
cy.popup().find('button[type="submit"]').click({ force: true });
2935
cy.wait(10000); // Not a best practice, but did not find a better way to handle this.
3036

31-
cy.popup().find('input#submitButton').click();
37+
cy.popup().find('input#submitButton').click({ force: true });
3238
cy.wait(10000); // Not a best practice, but did not find a better way to handle this.
3339

3440
cy.get('.mc-user h3').contains('Logged in as: ');

tests/cypress/support/commands.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable no-undef */
12
// ***********************************************
23
// This example commands.js shows you how to
34
// create various custom commands and overwrite
@@ -44,7 +45,6 @@ Cypress.Commands.add('capturePopup', () => {
4445
* Returns a wrapped body of a captured popup
4546
*/
4647
Cypress.Commands.add('popup', () => {
47-
console.log('state', state.popup);
4848
const popup = Cypress.$(state.popup.document);
4949
return cy.wrap(popup.contents().find('body'));
5050
});

0 commit comments

Comments
 (0)