Files
gitea-axi/test/e2e/search.test.ts
alexion c2c5f1728c
All checks were successful
CI / test (pull_request) Successful in 45s
CI / test (push) Successful in 46s
test: poll for indexer consistency in search e2e (task 0016)
Gitea's issue/PR search endpoint is backed by an asynchronous, eventually-
consistent indexer (bleve by default), so a PR opened moments earlier in the
e2e `beforeAll` was not yet searchable when `search prs` ran, and the live
assertion saw zero matches. Both live-search tests now poll the search via
`expect.poll` until the freshly-created content is indexed before asserting on
the exact locator-schema output. Record the eventual-consistency behaviour as
a project gotcha.
2026-07-14 10:09:51 -04:00

3.6 KiB