Fix failing tests and remove sleep statement for GitHub Actions (#1432)

This commit is contained in:
Kaan Kabalak
2022-01-21 15:21:28 -08:00
committed by GitHub
parent 5f281518fc
commit a778a1eaf9
2 changed files with 14 additions and 16 deletions

View File

@@ -58,7 +58,7 @@ jobs:
- name: Start Console, front-end app and initialize users/policies
run: |
(./console server && sleep 180) & (make initialize-permissions && sleep 180)
(./console server) & (make initialize-permissions)
- name: Run TestCafe Tests
uses: DevExpress/testcafe-action@latest

View File

@@ -60,22 +60,20 @@ test("Start Diagnostic button can be clicked", async (t) => {
.click(elements.startDiagnosticButton);
});
// TODO: Fix test failing sporadically on GitHub Actions
test("Download button exists after Diagnostic is completed", async (t) => {
const downloadExists = elements.downloadButton.exists;
await t
.navigateTo("http://localhost:9090/support/diagnostics")
.click(elements.startDiagnosticButton)
.expect(downloadExists).ok();
});
// test("Download button exists after Diagnostic is completed", async (t) => {
// const downloadExists = elements.downloadButton.exists;
// await t
// .navigateTo("http://localhost:9090/support/diagnostics")
// .click(elements.startDiagnosticButton)
// .expect(downloadExists).ok();
// });
// test("Download button is clickable after Diagnostic is completed", async (t) => {
// await t
// .navigateTo("http://localhost:9090/support/diagnostics")
// .click(elements.startDiagnosticButton)
// .click(elements.downloadButton);
// });
test("Download button is clickable after Diagnostic is completed", async (t) => {
await t
.navigateTo("http://localhost:9090/support/diagnostics")
.click(elements.startDiagnosticButton)
.click(elements.downloadButton);
});
test("Start New Diagnostic button exists after Diagnostic is completed", async (t) => {
const startNewDiagnosticButtonExists =