mirror of
https://github.com/redis/go-redis.git
synced 2025-12-02 06:22:31 +03:00
allow e2e tests to run longer
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"log"
|
||||
"os"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/redis/go-redis/v9"
|
||||
"github.com/redis/go-redis/v9/logging"
|
||||
@@ -12,6 +13,8 @@ import (
|
||||
// Global log collector
|
||||
var logCollector *TestLogCollector
|
||||
|
||||
const defaultTestTimeout = 30 * time.Minute
|
||||
|
||||
// Global fault injector client
|
||||
var faultInjector *FaultInjectorClient
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ func TestEndpointTypesPushNotifications(t *testing.T) {
|
||||
t.Skip("Scenario tests require E2E_SCENARIO_TESTS=true")
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 25*time.Minute)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
|
||||
defer cancel()
|
||||
|
||||
var dump = true
|
||||
|
||||
@@ -19,7 +19,7 @@ func TestPushNotifications(t *testing.T) {
|
||||
t.Skip("Scenario tests require E2E_SCENARIO_TESTS=true")
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 15*time.Minute)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
|
||||
defer cancel()
|
||||
|
||||
// Setup: Create fresh database and client factory for this test
|
||||
@@ -395,8 +395,9 @@ func TestPushNotifications(t *testing.T) {
|
||||
|
||||
p("Executing commands and collecting logs for analysis... This will take 30 seconds...")
|
||||
go commandsRunner.FireCommandsUntilStop(ctx)
|
||||
time.Sleep(30 * time.Second)
|
||||
time.Sleep(time.Minute)
|
||||
commandsRunner.Stop()
|
||||
time.Sleep(time.Minute)
|
||||
allLogsAnalysis := logCollector.GetAnalysis()
|
||||
trackerAnalysis := tracker.GetAnalysis()
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ func TestStressPushNotifications(t *testing.T) {
|
||||
t.Skip("[STRESS][SKIP] Scenario tests require E2E_SCENARIO_TESTS=true")
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 35*time.Minute)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 40*time.Minute)
|
||||
defer cancel()
|
||||
|
||||
// Setup: Create fresh database and client factory for this test
|
||||
|
||||
@@ -20,7 +20,7 @@ func ТestTLSConfigurationsPushNotifications(t *testing.T) {
|
||||
t.Skip("Scenario tests require E2E_SCENARIO_TESTS=true")
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 25*time.Minute)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
|
||||
defer cancel()
|
||||
|
||||
var dump = true
|
||||
|
||||
Reference in New Issue
Block a user