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

[E2E] Fix the flake in nested questions test (#25736)

parent 85e5f3aa
Branches
Tags
No related merge requests found
......@@ -61,7 +61,7 @@ describe("scenarios > question > nested", () => {
{ loadBaseQuestionMetadata: true },
);
cy.contains("Count").click();
openHeaderCellContextMenu("Count");
cy.contains("Distribution").click();
cy.wait("@dataset");
cy.contains("Count by Count: Auto binned");
......@@ -70,7 +70,7 @@ describe("scenarios > question > nested", () => {
// Go back to the nested question and make sure Sum over time works
cy.findByText("Nested GUI").click();
cy.contains("Count").click();
openHeaderCellContextMenu("Count");
cy.contains("Sum over time").click();
cy.contains("Sum of Count");
cy.findByText("137");
......@@ -93,7 +93,7 @@ describe("scenarios > question > nested", () => {
{ loadBaseQuestionMetadata: true },
);
cy.contains("COUNT").click();
openHeaderCellContextMenu("COUNT");
cy.contains("Distribution").click();
cy.wait("@dataset");
cy.contains("Count by COUNT: Auto binned");
......@@ -101,7 +101,7 @@ describe("scenarios > question > nested", () => {
cy.findByText("Nested SQL").click();
cy.contains("COUNT").click();
openHeaderCellContextMenu("COUNT");
cy.contains("Sum over time").click();
cy.wait("@dataset");
cy.contains("Sum of COUNT");
......@@ -599,3 +599,7 @@ function visitNestedQueryAdHoc(id) {
},
});
}
function openHeaderCellContextMenu(cell) {
cy.findAllByTestId("header-cell").should("be.visible").contains(cell).click();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment