mirror of
https://github.com/Sea-Haven-Industries/shoc-frontend-new.git
synced 2026-09-30 09:13:11 +00:00
fix(work-orders): avoid Array.at in advanced search wiring test
Keep the public-interface assertion compatible with the project's TypeScript lib target.
This commit is contained in:
parent
ea747af854
commit
ba4f3ca96d
1 changed files with 2 additions and 1 deletions
|
|
@ -177,7 +177,8 @@ describe("WorkOrders Advanced Search page wiring (SH-121)", () => {
|
|||
fireEvent.click(within(sheet).getByRole("button", { name: /apply filters/i }));
|
||||
|
||||
expect(applyAdvancedFilters).toHaveBeenCalled();
|
||||
const applied = applyAdvancedFilters.mock.calls.at(-1)?.[0] as typeof EMPTY_ADVANCED_FILTERS;
|
||||
const appliedCalls = applyAdvancedFilters.mock.calls;
|
||||
const applied = appliedCalls[appliedCalls.length - 1]?.[0] as typeof EMPTY_ADVANCED_FILTERS;
|
||||
expect(applied.severities.has(1)).toBe(true);
|
||||
expect(applied.hasUplift).toBe(true);
|
||||
expect(applied.upliftStatuses.has("pending")).toBe(true);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue