diff --git a/e2e/test/scenarios/visualizations/reproductions/25415-custom-column-drill-through.cy.spec.js b/e2e/test/scenarios/visualizations/reproductions/25415-custom-column-drill-through.cy.spec.js new file mode 100644 index 0000000000000000000000000000000000000000..06a69364fbcd7d166c4532d7d3c07d8c8d5b75ec --- /dev/null +++ b/e2e/test/scenarios/visualizations/reproductions/25415-custom-column-drill-through.cy.spec.js @@ -0,0 +1,52 @@ +import { popover, restore } from "e2e/support/helpers"; +import { SAMPLE_DATABASE } from "e2e/support/cypress_sample_database"; + +const { ORDERS, ORDERS_ID } = SAMPLE_DATABASE; + +describe.skip("issue 25415", () => { + beforeEach(() => { + restore(); + cy.signInAsAdmin(); + }); + + it("should allow to drill-through aggregated query with a custom column on top level (metabase#25415)", () => { + cy.createQuestion( + { + name: "Aggregated query with custom column", + display: "line", + query: { + "source-query": { + "source-table": ORDERS_ID, + aggregation: [["count"]], + breakout: [["field", ORDERS.PRODUCT_ID, null]], + limit: 2, + }, + expressions: { + "test custom": [ + "*", + [ + "field", + "count", + { + "base-type": "type/Integer", + }, + ], + 2, + ], + }, + }, + }, + { visitQuestion: true }, + ); + + cy.get(".dc-tooltip-list").get(".dot").first().click({ force: true }); + + popover().findByText("See these Orders").click(); + + // filter gets applied + cy.findByTestId("qb-filters-panel").should("contain", "Product ID is 1"); + + // there is a table with data + cy.findByTestId("TableInteractive-root").should("exist"); + }); +});