1
0
Fork 0

Merge branch v3.3 into v3.4

This commit is contained in:
kevinpollet 2025-04-18 11:38:04 +02:00
commit 9c1902c62e
No known key found for this signature in database
GPG key ID: 0C9A5DDD1B292453
54 changed files with 1060 additions and 636 deletions

View file

@ -282,11 +282,7 @@ func TestInMemoryRateLimit(t *testing.T) {
end := start.Add(test.loadDuration)
ticker := time.NewTicker(loadPeriod)
defer ticker.Stop()
for {
if time.Now().After(end) {
break
}
for !time.Now().After(end) {
req := testhelpers.MustNewRequest(http.MethodGet, "http://localhost", nil)
req.RemoteAddr = "127.0.0.1:1234"
w := httptest.NewRecorder()
@ -496,11 +492,7 @@ func TestRedisRateLimit(t *testing.T) {
end := start.Add(test.loadDuration)
ticker := time.NewTicker(loadPeriod)
defer ticker.Stop()
for {
if time.Now().After(end) {
break
}
for !time.Now().After(end) {
req := testhelpers.MustNewRequest(http.MethodGet, "http://localhost", nil)
req.RemoteAddr = "127.0.0." + strconv.Itoa(randPort) + ":" + strconv.Itoa(randPort)
w := httptest.NewRecorder()