- Notifications
You must be signed in to change notification settings - Fork1k
Commit6fb4cc6
authored
fix: add retry logic to OAuth2 metadata tests to avoid race conditions (#19813)
This PR adds a readiness wait to OAuth2 metadata endpoint tests to avoid rare races with server startup. Instead of immediately making HTTP requests, the tests now use `testutil.Eventually` to retry the requests until they succeed, with a short interval between attempts. This helps prevent flaky tests that might fail due to timing issues during server initialization.Fixes:coder/internal#9961 parent98213d7 commit6fb4cc6
2 files changed
+45
-26
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2 | 2 |
| |
3 | 3 |
| |
4 | 4 |
| |
5 |
| - | |
6 |
| - | |
7 | 5 |
| |
8 | 6 |
| |
9 | 7 |
| |
| |||
23 | 21 |
| |
24 | 22 |
| |
25 | 23 |
| |
26 |
| - | |
| 24 | + | |
| 25 | + | |
27 | 26 |
| |
28 |
| - | |
29 |
| - | |
30 |
| - | |
31 |
| - | |
32 |
| - | |
33 |
| - | |
34 |
| - | |
35 |
| - | |
36 |
| - | |
37 | 27 |
| |
38 |
| - | |
39 |
| - | |
| 28 | + | |
40 | 29 |
| |
41 | 30 |
| |
42 | 31 |
| |
| |||
57 | 46 |
| |
58 | 47 |
| |
59 | 48 |
| |
60 |
| - | |
| 49 | + | |
| 50 | + | |
61 | 51 |
| |
62 |
| - | |
63 |
| - | |
64 |
| - | |
65 |
| - | |
66 |
| - | |
67 |
| - | |
68 |
| - | |
69 |
| - | |
70 |
| - | |
71 | 52 |
| |
72 |
| - | |
73 |
| - | |
| 53 | + | |
74 | 54 |
| |
75 | 55 |
| |
76 | 56 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + |
0 commit comments
Comments
(0)