Commit 3e6cd06
Gabi
fix: serve tests wait for TCP socket before fetching
The serve start/stop tests polled for the ready-file (confirming the
port was bound) but then immediately called fetch() without waiting
for the server to accept connections. On slow CI runners (Node 18/20),
the socket wasn't ready yet, causing flaky ECONNREFUSED failures.
Both tests now use the existing waitForHttpServer() helper to confirm
the server accepts connections before making requests.1 parent f348e16 commit 3e6cd06
1 file changed
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
750 | 750 | | |
751 | 751 | | |
752 | 752 | | |
753 | | - | |
| 753 | + | |
| 754 | + | |
754 | 755 | | |
755 | 756 | | |
756 | 757 | | |
757 | 758 | | |
758 | 759 | | |
759 | 760 | | |
760 | | - | |
| 761 | + | |
| 762 | + | |
761 | 763 | | |
762 | 764 | | |
763 | 765 | | |
| |||
785 | 787 | | |
786 | 788 | | |
787 | 789 | | |
| 790 | + | |
788 | 791 | | |
| 792 | + | |
789 | 793 | | |
790 | 794 | | |
791 | 795 | | |
| |||
0 commit comments