> job-tracker-ui@0.1.0 test > jest --runInBand application-workspace-overlay.test.tsx --testNamePattern=entering Answers|late previous Answers-entry node.exe : FAIL src/application-workspace-overlay.test.tsx At line:1 char:1 + & "C:\Program Files\nodejs/node.exe" "C:\Program Files\nodejs/node_mo ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (FAIL src/applic...verlay.test.tsx:String) [], RemoteException + FullyQualifiedErrorId : NativeCommandError ● entering Answers waits for a fresh coherent snapshot after sibling writes expect(element).not.toBeInTheDocument() expected document not to contain element, found 42|Saved answer|Saved recruiter message|7 instead 422 | mockedApi.get.mockReturnValueOnce(pending); 423 | fireEvent.click(screen.getByRole("tab", { name: "Answers & message draft" })); > 424 | expect(screen.queryByTestId("answer-props")).not.toBeInTheDocument(); | ^ 425 | await act(async () => { resolve({ data: { ...overview, revision: 8, applicationAnswerDraft: "Fresh answer", recruiterMessageDraft: "Fresh message" } }); await pending; }); 426 | expect(await screen.findByTestId("answer-props")).toHaveTextContent("42|Fresh answer|Fresh message|8"); 427 | expect(mockedApi.get.mock.calls.filter(([url]) => url === "/jobapplications/42/workspace")).toHaveLength(2); at Object.toBeInTheDocument (src/application-workspace-overlay.test.tsx:424:52) ● a late previous Answers-entry read cannot enable the current editor expect(element).not.toBeInTheDocument() expected document not to contain element, found 42|Saved answer|Saved recruiter message|7 instead 440 | await act(async () => { await router.navigate("/jobs/42?section=application&sub=answers"); }); 441 | await act(async () => { resolveOld({ data: { ...overview, revision: 8 } }); await oldRead; }); > 442 | expect(screen.queryByTestId("answer-props")).not.toBeInTheDocument(); | ^ 443 | await act(async () => { resolveNew({ data: { ...overview, revision: 9, applicationAnswerDraft: "Current answer" } }); await newRead; }); 444 | expect(await screen.findByTestId("answer-props")).toHaveTextContent("42|Current answer|Saved recruiter message|9"); 445 | }); at Object.toBeInTheDocument (src/application-workspace-overlay.test.tsx:442:52) Test Suites: 1 failed, 1 total Tests: 2 failed, 19 skipped, 21 total Snapshots: 0 total Time: 2.695 s, estimated 7 s Ran all test suites matching application-workspace-overlay.test.tsx with tests matching "entering Answers|late previous Answers-entry".