From b407ad375588f19f2d65160beacee9277213da63 Mon Sep 17 00:00:00 2001 From: Peter Kurfer Date: Sat, 6 Aug 2022 18:38:31 +0200 Subject: [PATCH] fix: increase testcontainer creation timeout --- protocols/redis/container_test.go | 2 +- protocols/sql/container_test.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/protocols/redis/container_test.go b/protocols/redis/container_test.go index a055ba7..f992418 100644 --- a/protocols/redis/container_test.go +++ b/protocols/redis/container_test.go @@ -15,7 +15,7 @@ func PrepareRedisContainer(tb testing.TB) *config.Server { tb.Helper() const redisPort = "6379/tcp" - ctx, cancel := context.WithTimeout(context.Background(), 1*time.Minute) + ctx, cancel := context.WithTimeout(context.Background(), 5*time.Minute) tb.Cleanup(cancel) container, err := testcontainers.GenericContainer(ctx, testcontainers.GenericContainerRequest{ diff --git a/protocols/sql/container_test.go b/protocols/sql/container_test.go index 72c5e6e..3baa379 100644 --- a/protocols/sql/container_test.go +++ b/protocols/sql/container_test.go @@ -26,7 +26,7 @@ func PreparePostgresContainer(tb testing.TB) (name string, cfg *config.Server) { const postgresPort = "5432/tcp" - ctx, cancel := context.WithTimeout(context.Background(), 1*time.Minute) + ctx, cancel := context.WithTimeout(context.Background(), 5*time.Minute) tb.Cleanup(cancel) container, err := testcontainers.GenericContainer(ctx, testcontainers.GenericContainerRequest{ @@ -77,7 +77,7 @@ func PrepareMariaDBContainer(tb testing.TB) (name string, cfg *config.Server) { const mysqlPort = "3306/tcp" - ctx, cancel := context.WithTimeout(context.Background(), 1*time.Minute) + ctx, cancel := context.WithTimeout(context.Background(), 5*time.Minute) tb.Cleanup(cancel) container, err := testcontainers.GenericContainer(ctx, testcontainers.GenericContainerRequest{