In App.samplingNavigation.test.tsx, (#1035)
- replaced test for Reject button with the one used in the regular sampling test, which gets the button by role. This test appeared to be failing because formatting puts the name between the button elements with some whitespace. The way to look is with a regex
This commit is contained in:
parent
3adaf39371
commit
9f3b4ff0a9
1 changed files with 1 additions and 1 deletions
|
|
@ -229,7 +229,7 @@ describe("App - Sampling auto-navigation", () => {
|
|||
expect(screen.getByTestId("sampling-request")).toBeTruthy();
|
||||
});
|
||||
|
||||
fireEvent.click(screen.getByText("Reject"));
|
||||
fireEvent.click(screen.getByRole("button", { name: /Reject/i }));
|
||||
|
||||
await waitFor(() => {
|
||||
expect(reject).toHaveBeenCalled();
|
||||
|
|
|
|||
Loading…
Reference in a new issue