Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Consolidate drill through e2e tests (#83959)

Nemanja Glumacdff065df353c
diff --git a/e2e/test/scenarios/visualizations/drillthroughs/chart_drill.cy.spec.js b/e2e/test/scenarios/visualizations/drillthroughs/chart_drill.cy.spec.js
index 4f55263e165..34ad6912564 100644
--- a/e2e/test/scenarios/visualizations/drillthroughs/chart_drill.cy.spec.js
+++ b/e2e/test/scenarios/visualizations/drillthroughs/chart_drill.cy.spec.js
@@ -13,7 +13,7 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
cy.signInAsAdmin();
});
- it("should allow brush date filter", () => {
+ it("should show chart drills and allow brush date filter on a line chart", () => {
H.createQuestion(
{
name: "Brush Date Temporal Filter",
@@ -41,6 +41,33 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
.and("contain.text", "January 2026");
});
+ cy.log("Chart drills");
+ H.cartesianChartCircle().eq(2).click();
+ H.popover().within(() => {
+ cy.findByText("See these Orders").should("be.visible");
+
+ cy.findByText("See this month by week").should("be.visible");
+
+ cy.findByText("Break out by…").should("be.visible");
+ cy.findByText("Automatic insights…").should("be.visible");
+
+ cy.findByText(">").should("be.visible");
+ cy.findByText("<").should("be.visible");
+ cy.findByText("=").should("be.visible");
+ cy.findByText("≠").should("be.visible");
+ });
+
+ cy.findByTestId("timeseries-chrome").within(() => {
+ cy.findByText("View").should("be.visible");
+ cy.findByText("All time").should("be.visible");
+ cy.findByText("by").should("be.visible");
+ cy.findByText("Month").should("be.visible");
+ });
+
+ cy.realPress("Escape");
+ H.popover({ skipVisibilityCheck: true }).should("not.exist");
+ H.echartsTriggerBlur();
+
cy.wait(100); // wait to avoid grabbing the svg before the chart redraws
cy.log("Zoom-in on the left side, which corresponds to July 2025");
cy.findByTestId("query-visualization-root") // drag across to filter
@@ -99,31 +126,41 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
.trigger("mousemove", 420, 200)
.trigger("mouseup", 420, 200);
- cy.wait("@dataset");
+ cy.wait("@dataset").its("response.body.error").should("not.exist");
- // Once the issue gets fixed, figure out the positive assertion for the "month-of-year" granularity
if (granularity === "month") {
cy.findByTestId("qb-filters-panel")
.findByText(
"Created At: Month is Sep 1, 2025, 12:00 AM – Feb 1, 2026, 12:00 AM",
)
.should("exist");
+ } else {
+ cy.findByTestId("qb-filters-panel")
+ .findByText(/^Created At: Month of year is between .+ and .+$/)
+ .should("exist");
+ cy.findByTestId("qb-filters-panel").should("not.contain", "Unknown");
}
H.cartesianChartCircle();
});
});
- it("should correctly drill through on a card with multiple series (metabase#11442)", () => {
- H.createQuestion({
- name: "11442_Q1",
+ it("should drill through combined cards with one or more added series (metabase#11442, metabase#13457)", () => {
+ // Series colors come from a hash of the question names.
+ const ordersByYear = (name, filter) => ({
+ name,
query: {
"source-table": ORDERS_ID,
aggregation: [["count"]],
breakout: [["field", ORDERS.CREATED_AT, { "temporal-unit": "year" }]],
+ filter,
},
display: "line",
- }).then(({ body: { id: Q1_ID } }) => {
+ });
+
+ H.createQuestion(
+ ordersByYear("11442_Q1", [">", ["field", ORDERS.TOTAL, null], 50]),
+ ).then(({ body: { id: Q1_11442_ID } }) => {
H.createQuestion({
name: "11442_Q2",
query: {
@@ -132,111 +169,89 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
breakout: [
["field", PRODUCTS.CREATED_AT, { "temporal-unit": "year" }],
],
+ filter: [">", ["field", PRODUCTS.PRICE, null], 20],
},
display: "line",
- }).then(({ body: { id: Q2_ID } }) => {
- H.createDashboard({ name: "11442D" }).then(
- ({ body: { id: DASHBOARD_ID } }) => {
- cy.log("Add the first question to the dashboard");
-
- H.addOrUpdateDashboardCard({
- card_id: Q1_ID,
- dashboard_id: DASHBOARD_ID,
- card: {
- size_x: 21,
- size_y: 12,
- // Add additional series combining it with the second question
- series: [
- {
- id: Q2_ID,
- model: "card",
- },
+ }).then(({ body: { id: Q2_11442_ID } }) => {
+ H.createQuestion(ordersByYear("13457_Q1")).then(
+ ({ body: { id: Q1_13457_ID } }) => {
+ H.createQuestion({
+ name: "13457_Q2",
+ query: {
+ "source-table": ORDERS_ID,
+ aggregation: [
+ ["avg", ["field", ORDERS.DISCOUNT, null]],
+ ["avg", ["field", ORDERS.QUANTITY, null]],
+ ],
+ breakout: [
+ ["field", ORDERS.CREATED_AT, { "temporal-unit": "year" }],
],
},
+ display: "line",
+ }).then(({ body: { id: Q2_13457_ID } }) => {
+ H.createDashboard().then(({ body: { id: DASHBOARD_ID } }) => {
+ H.updateDashboardCards({
+ dashboard_id: DASHBOARD_ID,
+ cards: [
+ {
+ card_id: Q1_11442_ID,
+ col: 0,
+ size_x: 12,
+ size_y: 10,
+ series: [{ id: Q2_11442_ID, model: "card" }],
+ },
+ {
+ card_id: Q1_13457_ID,
+ col: 12,
+ size_x: 12,
+ size_y: 10,
+ series: [{ id: Q2_13457_ID, model: "card" }],
+ },
+ ],
+ });
+
+ H.visitDashboard(DASHBOARD_ID);
+ });
});
-
- H.visitDashboard(DASHBOARD_ID);
-
- cy.log("The first series line");
- H.cartesianChartCircleWithColor("#509EE3").eq(0).click();
- cy.findByText("See this year by quarter");
- cy.findByText("See these Orders");
-
- // Click anywhere else to close the first action panel
- cy.findByText("11442D").click();
-
- // Second line from the second question
- cy.log("The second series line");
- H.cartesianChartCircleWithColor("#98D9D9").eq(0).click();
- cy.findByText("See this year by quarter");
- cy.findByText("See these Products");
},
);
});
});
- });
-
- it("should allow drill-through on combined cards with different amount of series (metabase#13457)", () => {
- H.createQuestion({
- name: "13457_Q1",
- query: {
- "source-table": ORDERS_ID,
- aggregation: [["count"]],
- breakout: [["field", ORDERS.CREATED_AT, { "temporal-unit": "year" }]],
- },
- display: "line",
- }).then(({ body: { id: Q1_ID } }) => {
- H.createQuestion({
- name: "13457_Q2",
- query: {
- "source-table": ORDERS_ID,
- aggregation: [
- ["avg", ["field", ORDERS.DISCOUNT, null]],
- ["avg", ["field", ORDERS.QUANTITY, null]],
- ],
- breakout: [["field", ORDERS.CREATED_AT, { "temporal-unit": "year" }]],
- },
- display: "line",
- }).then(({ body: { id: Q2_ID } }) => {
- H.createDashboard({ name: "13457D" }).then(
- ({ body: { id: DASHBOARD_ID } }) => {
- cy.log("Add the first question to the dashboard");
-
- H.addOrUpdateDashboardCard({
- card_id: Q1_ID,
- dashboard_id: DASHBOARD_ID,
- card: {
- size_x: 21,
- size_y: 12,
- // Add additional series combining it with the second question
- series: [
- {
- id: Q2_ID,
- model: "card",
- },
- ],
- },
- });
-
- H.visitDashboard(DASHBOARD_ID);
- cy.log("The first series line");
- H.cartesianChartCircleWithColor("#509EE3").eq(0).click();
- cy.findByText("See this year by quarter");
- cy.findByText("See these Orders");
+ cy.log("metabase#11442: one added series");
+ assertSeriesDrills({
+ cardIndex: 0,
+ color: "#509EE3",
+ underlyingRecords: "See these Orders",
+ });
+ assertSeriesDrills({
+ cardIndex: 0,
+ color: "#98D9D9",
+ underlyingRecords: "See these Products",
+ });
- // Click anywhere else to close the first action panel
- cy.findByText("13457D").click();
+ cy.log("metabase#13457: the added card has more series than the first");
+ assertSeriesDrills({
+ cardIndex: 1,
+ color: "#509EE3",
+ underlyingRecords: "See these Orders",
+ });
+ assertSeriesDrills({
+ cardIndex: 1,
+ color: "#EF8C8C",
+ underlyingRecords: "See these Orders",
+ });
- // Second line from the second question
- cy.log("The third series line");
- H.cartesianChartCircleWithColor("#EF8C8C").eq(0).click();
- cy.findByText("See this year by quarter");
- cy.findByText("See these Orders");
- },
- );
- });
+ cy.log(
+ "metabase#11442: underlying records of an added series keep only its own filters",
+ );
+ H.getDashboardCard(0).within(() => {
+ H.cartesianChartCircleWithColor("#98D9D9").eq(0).click();
});
+ H.popover().findByText("See these Products").click();
+ cy.findByTestId("qb-filters-panel")
+ .should("contain", "Price is greater than 20")
+ .and("not.contain", "Total");
});
it("should drill through a nested query", () => {
@@ -278,21 +293,19 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
cy.contains("Dominique Leffler");
});
- it("should drill through a with date filter (metabase#12496)", () => {
- H.createQuestion({
- name: "Orders by Created At: Week",
- query: {
- "source-table": ORDERS_ID,
- aggregation: [["count"]],
- breakout: [["field", ORDERS.CREATED_AT, { "temporal-unit": "week" }]],
+ it("should drill through to a date range filter (metabase#12496)", () => {
+ H.createQuestion(
+ {
+ name: "Orders by Created At: Week",
+ query: {
+ "source-table": ORDERS_ID,
+ aggregation: [["count"]],
+ breakout: [["field", ORDERS.CREATED_AT, { "temporal-unit": "week" }]],
+ },
+ display: "line",
},
- display: "line",
- });
-
- cy.visit("/collection/root");
- cy.findAllByTestId("collection-entry-name")
- .contains("Orders by Created At: Week")
- .click();
+ { visitQuestion: true },
+ );
H.echartsContainer().contains("January 2028");
// drill into a recent week
@@ -304,10 +317,7 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
H.assertQueryBuilderRowCount(127);
cy.log("Filter should show the range between two dates");
- // Now click on the filter widget to see if the proper parameters got passed in
- cy.findByTestId("filter-pill")
- .contains(/^Created At: Week is .*–/)
- .click(); // en-dash to detect date range
+ cy.findByTestId("filter-pill").contains(/^Created At: Week is .*–/); // en-dash to detect date range
});
it("should drill-through on filtered aggregated results (metabase#13504)", () => {
@@ -448,9 +458,10 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
cy.findByTestId("more-charts-toggle").click();
cy.icon("line").click();
});
- cy.findByText(
- "Cannot read properties of undefined (reading 'name')",
- ).should("not.exist");
+ cy.findByTestId("visualization-root")
+ .should("have.attr", "data-viz-ui-name", "Line")
+ .and("not.contain", "Something’s gone wrong")
+ .and("not.contain", "Cannot read properties of undefined");
});
});
@@ -713,9 +724,6 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
});
it("should result in a correct query result", () => {
- cy.log("Assert that the URL is correct");
- cy.url().should("include", "/question#");
-
cy.log("Assert on the correct product category: Widget");
cy.findByTestId("qb-filters-panel").findByText("Category is Widget");
@@ -724,6 +732,10 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
"Showing 54 rows",
);
+ cy.log("Assert that the drill result is an unsaved question");
+ cy.location("pathname").should("eq", "/question");
+ cy.location("hash").should("not.be.empty");
+
cy.findByTestId("visualization-root")
.should("contain", "Widget")
.and("not.contain", "Gizmo")
@@ -731,50 +743,6 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
});
});
- it("should display proper drills on chart click for line chart", () => {
- H.createQuestion(
- {
- name: "Line chart drills",
- query: {
- "source-table": ORDERS_ID,
- aggregation: [["count"]],
- breakout: [
- [
- "field",
- PRODUCTS.CREATED_AT,
- { "source-field": ORDERS.PRODUCT_ID, "temporal-unit": "month" },
- ],
- ["field", PRODUCTS.CATEGORY, { "source-field": ORDERS.PRODUCT_ID }],
- ],
- },
- display: "line",
- },
- { visitQuestion: true },
- );
-
- H.cartesianChartCircle().eq(2).click();
- H.popover().within(() => {
- cy.findByText("See these Orders").should("be.visible");
-
- cy.findByText("See this month by week").should("be.visible");
-
- cy.findByText("Break out by…").should("be.visible");
- cy.findByText("Automatic insights…").should("be.visible");
-
- cy.findByText(">").should("be.visible");
- cy.findByText("<").should("be.visible");
- cy.findByText("=").should("be.visible");
- cy.findByText("≠").should("be.visible");
- });
-
- cy.findByTestId("timeseries-chrome").within(() => {
- cy.findByText("View").should("be.visible");
- cy.findByText("All time").should("be.visible");
- cy.findByText("by").should("be.visible");
- cy.findByText("Month").should("be.visible");
- });
- });
-
it("should display proper drills on chart click for bar chart", () => {
H.createQuestion(
{
@@ -859,8 +827,6 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
describe("chart click actions analytics", () => {
beforeEach(() => {
H.resetSnowplow();
- H.restore();
- cy.signInAsAdmin();
H.enableTracking();
});
@@ -946,3 +912,15 @@ describe("scenarios > visualizations > drillthroughs > chart drill", () => {
});
});
});
+
+function assertSeriesDrills({ cardIndex, color, underlyingRecords }) {
+ H.getDashboardCard(cardIndex).within(() => {
+ H.cartesianChartCircleWithColor(color).eq(0).click();
+ });
+ H.popover().within(() => {
+ cy.findByText("See this year by quarter").should("be.visible");
+ cy.findByText(underlyingRecords).should("be.visible");
+ });
+ cy.realPress("Escape");
+ H.popover({ skipVisibilityCheck: true }).should("not.exist");
+}
diff --git a/e2e/test/scenarios/visualizations/drillthroughs/column_extract_drill.cy.spec.js b/e2e/test/scenarios/visualizations/drillthroughs/column_extract_drill.cy.spec.js
index 26c6cceedaf..fa04a0cd331 100644
--- a/e2e/test/scenarios/visualizations/drillthroughs/column_extract_drill.cy.spec.js
+++ b/e2e/test/scenarios/visualizations/drillthroughs/column_extract_drill.cy.spec.js
@@ -21,16 +21,7 @@ describe("extract action", { viewportWidth: 1600 }, () => {
});
describe("date columns", () => {
- describe("should add a new column after the selected column", () => {
- it("ad-hoc question", () => {
- H.openOrdersTable();
- extractColumnAndCheck({
- column: "Created At",
- option: "Year",
- extraction: "Extract day, month…",
- });
- });
-
+ describe("should add the new column as the last column", () => {
it("saved question without viz settings", () => {
H.visitQuestion(ORDERS_QUESTION_ID);
extractColumnAndCheck({
@@ -87,25 +78,6 @@ describe("extract action", { viewportWidth: 1600 }, () => {
});
});
- it("should be able to modify the expression in the notebook editor", () => {
- H.openOrdersTable({ limit: 1 });
- extractColumnAndCheck({
- column: "Created At",
- option: "Year",
- value: "2,028",
- extraction: "Extract day, month…",
- });
- H.openNotebook();
- H.getNotebookStep("expression").findByText("Year").click();
- H.enterCustomColumnDetails({
- formula: "year([Created At]) + 2",
- format: true,
- });
- H.popover().button("Update").should("not.be.disabled").click();
- H.visualize();
- cy.findByRole("gridcell", { name: "2,030" }).should("be.visible");
- });
-
it("should use current user locale for string expressions", () => {
cy.request("GET", "/api/user/current").then(({ body: user }) => {
cy.request("PUT", `/api/user/${user.id}`, { locale: "en-ZZ" });
@@ -123,9 +95,6 @@ describe("extract action", { viewportWidth: 1600 }, () => {
describe("url columns", () => {
beforeEach(() => {
- H.restore();
- cy.signInAsAdmin();
-
// Make the Email column a URL column for these tests, to avoid having to create a new model
cy.request("PUT", `/api/field/${PEOPLE.EMAIL}`, {
semantic_type: "type/URL",
@@ -258,7 +227,7 @@ describe("extract action", { viewportWidth: 1600 }, () => {
H.expectNoBadSnowplowEvents();
});
- it("should create a snowplow event for the column extraction action", () => {
+ it("should create a snowplow event for the column extraction action and allow editing the expression in the notebook editor", () => {
H.openOrdersTable({ limit: 1 });
cy.wait(1);
@@ -275,5 +244,16 @@ describe("extract action", { viewportWidth: 1600 }, () => {
custom_expressions_used: ["get-year"],
database_id: SAMPLE_DB_ID,
});
+
+ cy.log("Modify the expression in the notebook editor");
+ H.openNotebook();
+ H.getNotebookStep("expression").findByText("Year").click();
+ H.enterCustomColumnDetails({
+ formula: "year([Created At]) + 2",
+ format: true,
+ });
+ H.popover().button("Update").should("not.be.disabled").click();
+ H.visualize();
+ cy.findByRole("gridcell", { name: "2,030" }).should("be.visible");
});
});
diff --git a/e2e/test/scenarios/visualizations/drillthroughs/combine-column.cy.spec.ts b/e2e/test/scenarios/visualizations/drillthroughs/combine-column.cy.spec.ts
index ee6d85c7595..443201207fa 100644
--- a/e2e/test/scenarios/visualizations/drillthroughs/combine-column.cy.spec.ts
+++ b/e2e/test/scenarios/visualizations/drillthroughs/combine-column.cy.spec.ts
@@ -15,7 +15,7 @@ describe("scenarios > visualizations > drillthroughs > table_drills > combine co
H.expectNoBadSnowplowEvents();
});
- it("should be possible to combine columns from the a table header", () => {
+ it("should be possible to combine columns from a table header and handle duplicate column names", () => {
H.createQuestion(
{
query: {
@@ -85,23 +85,8 @@ describe("scenarios > visualizations > drillthroughs > table_drills > combine co
custom_expressions_used: ["concat"],
database_id: SAMPLE_DB_ID,
});
- });
-
- it("should handle duplicate column names", () => {
- H.createQuestion(
- {
- query: {
- "source-table": PEOPLE_ID,
- fields: [
- ["field", PEOPLE.ID, { "base-type": "type/Number" }],
- ["field", PEOPLE.EMAIL, { "base-type": "type/Text" }],
- ],
- limit: 3,
- },
- },
- { visitQuestion: true },
- );
+ cy.log("Duplicate column names");
// first combine (email + ID)
H.tableHeaderClick("Email");
H.popover().findByText("Combine columns").click();
@@ -112,11 +97,9 @@ describe("scenarios > visualizations > drillthroughs > table_drills > combine co
H.popover().findByText("Combine columns").click();
H.popover().findByText("Done").click();
- cy.findAllByTestId("header-cell")
- .contains("Combined Email, ID")
- .should("exist");
- cy.findAllByTestId("header-cell")
- .contains("Combined Email, ID_2")
- .should("exist");
+ cy.findByTestId("table-header").within(() => {
+ cy.findByText("Combined Email, ID").should("be.visible");
+ cy.findByText("Combined Email, ID_2").should("be.visible");
+ });
});
});
diff --git a/e2e/test/scenarios/visualizations/drillthroughs/dash_drill.cy.spec.js b/e2e/test/scenarios/visualizations/drillthroughs/dash_drill.cy.spec.js
index 7bc4bb37896..12eac6822d0 100644
--- a/e2e/test/scenarios/visualizations/drillthroughs/dash_drill.cy.spec.js
+++ b/e2e/test/scenarios/visualizations/drillthroughs/dash_drill.cy.spec.js
@@ -19,31 +19,6 @@ describe("scenarios > visualizations > drillthroughs > dash_drill", () => {
cy.signInAsAdmin();
});
- describe("from a scalar card", () => {
- const DASHBOARD_NAME = "Scalar Dash";
-
- beforeEach(() => {
- // Convert the second question to a scalar (Orders, summarized by count)
- cy.request("PUT", `/api/card/${Q2.id}`, {
- display: "scalar",
- });
-
- addCardToNewDashboard(DASHBOARD_NAME, Q2.id);
-
- // eslint-disable-next-line metabase/no-unscoped-text-selectors -- deprecated usage
- cy.findByText(DASHBOARD_NAME);
- clickScalarCardTitle(Q2.name);
- });
-
- it("should result in a correct query result", () => {
- cy.log("Assert that the url is correct");
- cy.location("pathname").should("eq", `/question/${Q2.expectedPath}`);
-
- // eslint-disable-next-line metabase/no-unscoped-text-selectors -- deprecated usage
- cy.contains("18,760");
- });
- });
-
describe("from a scalar with active filter applied", () => {
const DASHBOARD_NAME = "Scalar w Filter Dash";
@@ -80,7 +55,7 @@ describe("scenarios > visualizations > drillthroughs > dash_drill", () => {
});
});
- describe("from a dashcard multiscalar legend", () => {
+ describe("from a line chart with two breakouts", () => {
const DASHBOARD_NAME = "Multiscalar Dash";
const CARD_NAME = "Multiscalar Question";
@@ -189,7 +164,7 @@ describe("scenarios > visualizations > drillthroughs > dash_drill", () => {
cy.findByTestId("qb-filters-panel")
.findByText("Product → Category is Doohickey")
.should("be.visible");
- H.queryBuilderMain().findByText("177").should("be.visible"); // Doohickeys for 2025
+ H.tableInteractive().findByText("177").should("be.visible"); // Doohickeys for 2025
});
});
});
diff --git a/e2e/test/scenarios/visualizations/drillthroughs/table_drills.cy.spec.js b/e2e/test/scenarios/visualizations/drillthroughs/table_drills.cy.spec.js
index bb20b27976c..586e1f5107f 100644
--- a/e2e/test/scenarios/visualizations/drillthroughs/table_drills.cy.spec.js
+++ b/e2e/test/scenarios/visualizations/drillthroughs/table_drills.cy.spec.js
@@ -27,6 +27,10 @@ describe("scenarios > visualizations > drillthroughs > table_drills", () => {
});
});
H.openReviewsTable({ limit: 3 });
+ H.tableInteractive().should("be.visible");
+ cy.findByTestId("development-watermark").should(
+ devMode ? "exist" : "not.exist",
+ );
// FK cell drills
cy.get(".test-Table-FK").findByText("1").first().click();
@@ -253,7 +257,8 @@ describe("scenarios > visualizations > drillthroughs > table_drills", () => {
.should("be.visible");
}
- it("should allow category pivot drills on single-stage queries (metabase#52236)", () => {
+ it("should allow category and timeseries pivot drills on single-stage queries (metabase#52236)", () => {
+ cy.log("Category pivot drill");
pivotDrillTest({
query: queryWithJoin,
drillCellText: "4,939",
@@ -261,9 +266,8 @@ describe("scenarios > visualizations > drillthroughs > table_drills", () => {
filterText: "Products → Category is Gadget",
resultText: "Barrows-Johns",
});
- });
- it("should allow timeseries pivot drills on single-stage queries (metabase#52236)", () => {
+ cy.log("Timeseries pivot drill");
pivotDrillTest({
query: queryWithJoin,
drillCellText: "3,976",
@@ -362,7 +366,7 @@ describe("scenarios > visualizations > drillthroughs > table_drills", () => {
{ visitQuestion: true },
);
- // FK cell drills
+ // Numeric cell drills
cy.get("[data-testid=cell-data]").filter(":contains(1)").eq(1).click();
H.popover().within(() => {
cy.findByText("Filter by this value").should("be.visible");
@@ -495,44 +499,6 @@ describe("scenarios > visualizations > drillthroughs > table_drills", () => {
cy.findByText("Filter by this column").should("be.visible");
});
});
-
- it("should display proper drills on cell click for query aggregated by date", () => {
- H.createNativeQuestion(
- {
- name: "table_drills",
- native: {
- query: `
- SELECT
- DATE_TRUNC('month', REVIEWS.CREATED_AT) AS "Created At",
- COUNT(*) AS "count"
- FROM
- REVIEWS
- GROUP BY
- DATE_TRUNC('month', REVIEWS.CREATED_AT)
- LIMIT
- 10
- `,
- },
- },
- { visitQuestion: true },
- );
-
- cy.get("[data-testid=cell-data]").contains("June").first().click();
- H.popover().within(() => {
- cy.findByText("Before").should("be.visible");
- cy.findByText("After").should("be.visible");
- cy.findByText("On").should("be.visible");
- cy.findByText("Not on").should("be.visible");
- });
-
- cy.get("[data-testid=cell-data]").contains("4").first().click();
- H.popover().within(() => {
- cy.findByText(">").should("be.visible");
- cy.findByText("<").should("be.visible");
- cy.findByText("=").should("be.visible");
- cy.findByText("≠").should("be.visible");
- });
- });
});
});
@@ -632,8 +598,6 @@ describe("Issue 40061", () => {
H.popover().findByText("Extract day, month…").click();
H.popover().findByText("Year").click();
cy.findByTestId("table-header").findByText("Year").should("exist");
- cy.findByTestId("question-row-count")
- .findByText("Showing 1,421 rows")
- .should("exist");
+ H.tableInteractiveBody().findAllByText("2,025").should("not.be.empty");
});
});