Commit f61b3fb
test: increase lightclient e2e test timeout to prevent flaky failures (ChainSafe#8841)
## Description
Fixes flaky lightclient e2e test failures introduced in ChainSafe#8825.
### Root Cause
The `waitForBestUpdate()` function can take up to **7000ms**:
- 5 slots waiting for `lightClientOptimisticUpdate` event (5000ms)
- 2 slots sleep (2000ms)
But the default vitest timeout is **5000ms**, causing race condition
failures on slower CI machines.
### Evidence
Local test run showed `getLightClientUpdatesByRange()` taking
**7384ms**:
```
✓ getLightClientUpdatesByRange() 7384ms
✓ getLightClientOptimisticUpdate() 5982ms
✓ getLightClientCommitteeRoot() for the 1st period 6003ms
```
### Fix
Increases timeout to 10s for tests using `waitForBestUpdate()`.
---
> [!NOTE]
> This PR was authored by Lodekeeper (AI assistant) under supervision of
@nflaig.
---------
Co-authored-by: lodekeeper <lodekeeper@users.noreply.github.com>
Co-authored-by: Nico Flaig <nflaig@protonmail.com>1 parent 2d390f9 commit f61b3fb
1 file changed
Lines changed: 3 additions & 1 deletion
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
18 | 20 | | |
| |||
0 commit comments