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

#14193 Repro: Custom column is dropped after removing filter (that comes after...

#14193 Repro: Custom column is dropped after removing filter (that comes after aggregation) [ci skip] (#14197)
parent c41641cd
No related branches found
No related tags found
No related merge requests found
......@@ -334,4 +334,46 @@ describe("scenarios > question > custom columns", () => {
cy.get(".Visualization .dot").should("have.length.of.at.least", 8);
});
});
it.skip("should not be dropped if filter is changed after aggregation (metaabase#14193)", () => {
const CC_NAME = "Double the fun";
cy.request("POST", "/api/card", {
name: "14193",
dataset_query: {
type: "query",
query: {
"source-query": {
"source-table": ORDERS_ID,
filter: [">", ["field-id", ORDERS.SUBTOTAL], 0],
aggregation: [["sum", ["field-id", ORDERS.TOTAL]]],
breakout: [
["datetime-field", ["field-id", ORDERS.CREATED_AT], "year"],
],
},
expressions: {
[CC_NAME]: ["*", ["field-literal", "sum", "type/Float"], 2],
},
},
database: 1,
},
display: "table",
visualization_settings: {},
}).then(({ body: { id: QUESTION_ID } }) => {
cy.visit(`/question/${QUESTION_ID}`);
// Test displays collapsed filter - click on number 1 to expand and show the filter name
cy.get(".Icon-filter")
.parent()
.contains("1")
.click();
cy.findByText(/Subtotal is greater than 0/i)
.parent()
.find(".Icon-close")
.click();
cy.findByText(CC_NAME);
});
});
});
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