Files
opencloud/services/search/pkg
Jörn Friedrich Dreyer a7b21848cf test(search): wait for the first debouncer run instead of sleeping
"doesn't trigger twice simultaneously" slept 100ms and assumed the
first run had started by then. On a busy CI runner the 50ms debounce
timer can fire later. The second Debounce then only resets the pending
timer, both calls collapse into one run and the count never reaches 2:

  [FAILED] Timed out after 2.001s.
  Expected <int>: 1 to equal <int>: 2

The run now blocks on a channel until the test releases it. We wait
for the first run to start, check that the second debounce does not
start another run while it is in progress, then release it and expect
the second run.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2026-11-13 17:41:56 +01:00
..
2026-11-04 15:47:44 +01:00
2026-10-27 12:46:43 +01:00