Skip to content

Commit

Permalink
Fix channel tests (opensearch-project#1507)
Browse files Browse the repository at this point in the history
* add ; to tests

Signed-off-by: Riya Saxena <[email protected]>

* fix channel tests in notifications

Signed-off-by: Riya Saxena <[email protected]>

* fix channel tests in notifications

Signed-off-by: Riya Saxena <[email protected]>

---------

Signed-off-by: Riya Saxena <[email protected]>
  • Loading branch information
riysaxen-amzn authored Aug 5, 2024
1 parent 77b4d19 commit 09bf9ce
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"config_type": "chime",
"is_enabled": true,
"chime": {
"url": "https://sample-chime-webhook"
"url": "https://hooks.chime.aws/incomingwebhooks/sample_chime_url?token=123456"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"config_type": "slack",
"is_enabled": true,
"slack": {
"url": "https://sample-slack-webhook"
"url": "https://hooks.slack.com/services/A123456/B1234567/A1B2C3D4E5F6G7H8I9J0K1L2"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ describe('Test create channels', () => {

cy.get('[placeholder="Enter channel name"]').type('Test slack channel');
cy.get('[data-test-subj="create-channel-slack-webhook-input"]').type(
'https://sample-slack-webhook'
'https://hooks.slack.com/services/A123456/B1234567/A1B2C3D4E5F6G7H8I9J0K1L2'
);
cy.wait(NOTIFICATIONS_DELAY);
cy.get('[data-test-subj="create-channel-send-test-message-button"]').click({
Expand All @@ -44,10 +44,12 @@ describe('Test create channels', () => {
cy.wait(NOTIFICATIONS_DELAY);
// This needs some time to appear as it will wait for backend call to timeout
cy.contains('test message.').should('exist');
cy.wait(NOTIFICATIONS_DELAY);

cy.get('[data-test-subj="create-channel-create-button"]').click({
force: true,
});
cy.wait(NOTIFICATIONS_DELAY);
cy.contains('successfully created.').should('exist');
});

Expand All @@ -62,11 +64,12 @@ describe('Test create channels', () => {
cy.wait(NOTIFICATIONS_DELAY);

cy.get('[data-test-subj="create-channel-chime-webhook-input"]').type(
'https://sample-chime-webhook'
'https://hooks.chime.aws/incomingwebhooks/sample_chime_url?token=123456'
);
cy.wait(NOTIFICATIONS_DELAY);

cy.get('[data-test-subj="create-channel-create-button"]').click();
cy.wait(NOTIFICATIONS_DELAY);
cy.contains('successfully created.').should('exist');
});

Expand Down

0 comments on commit 09bf9ce

Please sign in to comment.