From 7f8afd2235375a26eaeb2afc5cfe3c095a03ca8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20de=20la=20Pe=C3=B1a?= Date: Mon, 28 Apr 2025 10:14:48 +0200 Subject: [PATCH] fix: use test helper --- redis/redis_test.go | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/redis/redis_test.go b/redis/redis_test.go index 745cf478..466c4b3e 100644 --- a/redis/redis_test.go +++ b/redis/redis_test.go @@ -331,7 +331,9 @@ func Test_Redis_Initialize_WithHostPort(t *testing.T) { } func Test_Redis_Initialize_WithURL_TLS_Verify(t *testing.T) { - testFn := func(secureURL bool, mtlsDisabled bool) { + testFn := func(t *testing.T, secureURL bool, mtlsDisabled bool) { + t.Helper() + testStore := newTestStore(t, withTLS(secureURL, mtlsDisabled)) defer testStore.Close() @@ -356,19 +358,19 @@ func Test_Redis_Initialize_WithURL_TLS_Verify(t *testing.T) { } t.Run("insecure-url/mtls-disabled", func(t *testing.T) { - testFn(false, true) + testFn(t, false, true) }) t.Run("insecure-url/mtls-enabled", func(t *testing.T) { - testFn(false, false) + testFn(t, false, false) }) t.Run("secure-url/mtls-disabled", func(t *testing.T) { - testFn(true, true) + testFn(t, true, true) }) t.Run("secure-url/mtls-enabled", func(t *testing.T) { - testFn(true, false) + testFn(t, true, false) }) }