You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test(frontend): venue picker test can fail on a page 2 request with no answer #432
A component test in venue-picker.test.tsx failed once in a full pnpm test run, on a change that does not touch it:
FAIL src/examples/venues/components/venue-picker.test.tsx > finds a venue by a search on the Server, and keeps the pick when the search goes
Error: No answer for these requests: GET /api/v1/venues?pageNumber=2&pageSize=10. Answer them with commands.answerRequests.
renderPicker answers this request, so the test's own answers are not the fault.
The previous test can end with the list open, so its load-more row can send the page 2 request late. beforeEach in src/test/browser-setup.ts unmounts the page, clears the answers, and drains the unanswered list. Then the next test sets its answers. A request that reaches the dev server after the clear and before those answers gets no answer, and it counts against the next test.
To reproduce
Run pnpm test in frontend/ many times on a loaded machine, and look for the error above. A pause between the clear in beforeEach and the answers of renderPicker may make the failure more frequent. This has not been tried.
Activity