(
sort: MultiSortReturn["sort"],
dataKey: string,
eventModifier = "",
defaultSortDirection: SortDirectionType = "ASC"
)
| 4 | |
| 5 | describe("createMultiSort", () => { |
| 6 | function simulate( |
| 7 | sort: MultiSortReturn["sort"], |
| 8 | dataKey: string, |
| 9 | eventModifier = "", |
| 10 | defaultSortDirection: SortDirectionType = "ASC" |
| 11 | ) { |
| 12 | sort({ |
| 13 | defaultSortDirection, |
| 14 | event: { |
| 15 | ctrlKey: eventModifier === "control", |
| 16 | metaKey: eventModifier === "meta", |
| 17 | shiftKey: eventModifier === "shift" |
| 18 | }, |
| 19 | sortBy: dataKey |
| 20 | }); |
| 21 | } |
| 22 | |
| 23 | it("errors if the user did not specify a sort callback", () => { |
| 24 | expect(createMultiSort).toThrow(); |
no test coverage detected