Skip to content

Commit

Permalink
t
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTallJerry committed Mar 4, 2024
1 parent 6dacbc5 commit 4db8966
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions demo/src/__tests__/MemoryModels.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,12 @@ describe("MemoryModelsUserInput", () => {
// wait until the button is enabled to click
expect(reapplyBtn).toHaveProperty("disabled", false);
fireEvent.click(reapplyBtn);
});

await waitFor(() => {
// once from reapplyBtn onChange, once from MemoryModelsTextInput handleTextFieldChange
// if put within the same waitFor block as fireEvent.click(reapplyBtn), this test always passes
// even with the wrong expect
expect(setTextDataMock).toHaveBeenNthCalledWith(
2,
fileString
Expand Down

0 comments on commit 4db8966

Please sign in to comment.