diff --git a/frontend/test/metabase/scenarios/question/reproductions/18589-numeric-binning-in-joins.cy.spec.js b/frontend/test/metabase/scenarios/question/reproductions/18589-numeric-binning-in-joins.cy.spec.js new file mode 100644 index 0000000000000000000000000000000000000000..720876f983f4d1456326548dccb6bc622fbf71f4 --- /dev/null +++ b/frontend/test/metabase/scenarios/question/reproductions/18589-numeric-binning-in-joins.cy.spec.js @@ -0,0 +1,44 @@ +import { + restore, + openOrdersTable, + getNotebookStep, + popover, +} from "__support__/e2e/cypress"; + +describe("issue 18589", () => { + beforeEach(() => { + restore(); + cy.signInAsAdmin(); + cy.intercept("POST", "/api/dataset").as("dataset"); + }); + + it.skip("should not bin numeric fields in join condition by default (metabase#18589)", () => { + openOrdersTable({ mode: "notebook" }); + + joinTable("Reviews"); + selectFromDropdown("Quantity"); + selectFromDropdown("Rating"); + + cy.findByText("Summarize").click(); + selectFromDropdown("Count of rows"); + + getNotebookStep("summarize").within(() => { + cy.icon("play").click(); + cy.wait("@dataset"); + cy.findByText("2.860.368"); + }); + }); +}); + +function joinTable(table) { + cy.findByText("Join data").click(); + popover() + .findByText(table) + .click(); +} + +function selectFromDropdown(option, clickOpts) { + popover() + .findByText(option) + .click(clickOpts); +}