Commit 5f3e401
test(e2e): fix TLS test retry with RequestAssert
The 'ApisixTls and Ingress with same certificate but different hosts'
test was consistently failing due to two compounding issues:
1. Control-plane / data-plane propagation delay: the control plane
confirms the api7.com SSL object, but APISIX data plane may not
have loaded it yet when the HTTPS request is made.
2. Non-retryable Eventually block: NewAPISIXHttpsClient uses
GinkgoT() as the httpexpect reporter. On TLS error, httpexpect
calls GinkgoT().Fatalf() -> runtime.Goexit(), which exits the
goroutine immediately. gomega's Eventually cannot retry because
the goroutine is gone.
Fix: replace the raw Eventually+httpexpect blocks with s.RequestAssert,
which already exists in the scaffold and uses ErrorReporter (stores
errors instead of calling FailNow). Transient TLS errors are now
returned as retryable errors, letting Eventually poll until the data
plane is fully ready.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 65b8f1d commit 5f3e401
4 files changed
Lines changed: 19 additions & 71 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
194 | 194 | | |
195 | 195 | | |
196 | 196 | | |
197 | | - | |
| 197 | + | |
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
| |||
222 | 222 | | |
223 | 223 | | |
224 | 224 | | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
230 | 225 | | |
231 | 226 | | |
232 | 227 | | |
233 | 228 | | |
234 | 229 | | |
235 | 230 | | |
| 231 | + | |
236 | 232 | | |
237 | 233 | | |
238 | 234 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
424 | 424 | | |
425 | 425 | | |
426 | 426 | | |
427 | | - | |
428 | | - | |
429 | | - | |
430 | | - | |
431 | | - | |
432 | | - | |
433 | | - | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
434 | 434 | | |
435 | 435 | | |
436 | | - | |
437 | | - | |
438 | | - | |
439 | | - | |
440 | | - | |
441 | | - | |
442 | | - | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
443 | 446 | | |
444 | 447 | | |
445 | 448 | | |
| |||
This file was deleted.
0 commit comments