Commit 54eeb5e
test(eval): pin BatchSpanProcessor's schedule delay to avoid test flakiness
Copilot review comment: ExecutionSpanProcessor is a real BatchSpanProcessor
with its own background worker thread, which auto-flushes every 5s by
default (or when its queue fills). Tests asserting "not yet exported at
this exact moment" could in principle flake if that worker thread woke up
and exported on its own between a span ending and the assertion running.
Push the processor's schedule delay to 1 hour right after construction so
only the explicit force_flush() calls in these tests ever export anything,
removing the wall-clock dependency entirely rather than relying on the
worker thread simply not winning the race in practice.
Co-Authored-By: Claude Sonnet 5 <[email protected]>1 parent 7552722 commit 54eeb5e
1 file changed
Lines changed: 11 additions & 0 deletions
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
54 | 65 | | |
55 | 66 | | |
56 | 67 | | |
| |||
0 commit comments