Skip to content
Snippets Groups Projects
Unverified Commit 7577ebeb authored by Nemanja Glumac's avatar Nemanja Glumac Committed by GitHub
Browse files

[E2E] Re-enable monitoring permissions test (#36050)

* Unskip previously quarantined test

* Improve test readability
parent c06f6d0d
No related branches found
No related tags found
No related merge requests found
......@@ -9,6 +9,7 @@ import {
setTokenFeatures,
setupSMTP,
sidebar,
popover,
} from "e2e/support/helpers";
import { USERS } from "e2e/support/cypress_data";
......@@ -133,36 +134,41 @@ describeEE("scenarios > admin > permissions > application", () => {
cy.signInAsNormalUser();
});
// Adding this test to quarantine. When it was failing was making all the subsequents to fail.
// More details can be found on the Thread https://metaboat.slack.com/archives/CKZEMT1MJ/p1649272824618149
it.skip("allows accessing tools, audit, and troubleshooting for non-admins", () => {
it("allows accessing tools, audit, and troubleshooting for non-admins", () => {
cy.visit("/");
cy.icon("gear").click();
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("Admin settings").click();
popover().findByText("Admin settings").click();
// Tools smoke test
cy.url().should("include", "/admin/tools/errors");
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("Questions that errored when last run");
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("broken_question");
// Audit smoke test
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("Audit").click();
cy.url().should("include", "/admin/audit/members/overview");
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("All members").click();
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText(getFullName(admin));
// Troubleshooting smoke test
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("Troubleshooting").click();
// eslint-disable-next-line no-unscoped-text-selectors -- deprecated usage
cy.findByText("Diagnostic Info");
cy.log("Tools smoke test");
cy.location("pathname").should("eq", "/admin/tools/errors");
cy.findByRole("heading", {
name: "Questions that errored when last run",
});
cy.findAllByRole("cell").should("contain", "broken_question");
cy.log("Audit smoke test");
cy.findByRole("navigation")
.findByRole("link", { name: "Audit" })
.click();
cy.location("pathname").should("eq", "/admin/audit/members/overview");
cy.findByRole("heading", {
name: "Team members",
});
cy.findByRole("radiogroup").contains("Audit log").click();
cy.location("pathname").should("eq", "/admin/audit/members/log");
cy.findAllByRole("cell")
.should("contain", "broken_question")
.and("contain", getFullName(admin));
cy.log("Troubleshooting smoke test");
cy.findByRole("navigation")
.findByRole("link", { name: "Troubleshooting" })
.click();
cy.location("pathname").should("eq", "/admin/troubleshooting/help");
cy.get("main")
.should("contain", "Help")
.and("contain", "Diagnostic Info");
});
});
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment