From 27e895478253fbb454d38d0dc7789dde5471bfea Mon Sep 17 00:00:00 2001 From: Gerard Snaauw Date: Wed, 18 Dec 2024 15:42:27 +0100 Subject: [PATCH] remove useless test --- storage/session_memcached_test.go | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/storage/session_memcached_test.go b/storage/session_memcached_test.go index 577f71543..b5ce5964e 100644 --- a/storage/session_memcached_test.go +++ b/storage/session_memcached_test.go @@ -30,12 +30,6 @@ import ( "github.com/stretchr/testify/require" ) -func TestNewMemcachedSessionDatabase(t *testing.T) { - db := memcachedTestDatabase(t) - - assert.NotNil(t, db) -} - func TestNewMemcachedSessionDatabase_GetStore(t *testing.T) { db := memcachedTestDatabase(t) @@ -177,6 +171,10 @@ func memcachedTestServer(t *testing.T) *minimemcached.MiniMemcached { t.Fatal(err) } t.Cleanup(func() { + // Note on DATA RACE + // minimemcached.Run creates a new go routine to listen for new connections. + // In certain cases the new go routine may be created after/simultaneous with this cleanup resulting in a data race / nil pointer dereference. + // Mostly happens on CI during really short tests. m.Close() }) return m