Skip to content
Snippets Groups Projects
Unverified Commit 473ae3b6 authored by Alexander Polyankin's avatar Alexander Polyankin Committed by GitHub
Browse files

Add a repro for "Cannot create another filter value if it starts with the same...

Add a repro for "Cannot create another filter value if it starts with the same value as an existing value" (#45837)
parent 143f2757
No related branches found
No related tags found
No related merge requests found
......@@ -881,6 +881,22 @@ describe("StringFilterValuePicker", () => {
expect(onChange).toHaveBeenLastCalledWith([]);
});
it("should allow to add multiple values that extend each other (metabase#21915)", async () => {
const { onChange, onFocus, onBlur } = await setupStringPicker({
query,
stageIndex,
column,
values: ["a"],
});
await userEvent.type(screen.getByLabelText("Filter value"), "ab,abc");
await userEvent.tab();
expect(onFocus).toHaveBeenCalled();
expect(onChange).toHaveBeenLastCalledWith(["a", "ab", "abc"]);
expect(onBlur).toHaveBeenCalled();
});
});
});
......
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