diff --git a/memcache/memcache_test.go b/memcache/memcache_test.go index ea49abe..70ca120 100644 --- a/memcache/memcache_test.go +++ b/memcache/memcache_test.go @@ -8,7 +8,7 @@ import ( "time" cache "github.com/bartventer/gocache" - "github.com/bartventer/gocache/internal/cachetest" + "github.com/bartventer/gocache/drivertest" "github.com/bradfitz/gomemcache/memcache" "github.com/docker/docker/api/types/container" "github.com/stretchr/testify/assert" @@ -134,14 +134,14 @@ func (h *harness) Close() { // Cleanup is handled in setup function } -func (h *harness) Options() cachetest.Options { - return cachetest.Options{ +func (h *harness) Options() drivertest.Options { + return drivertest.Options{ PatternMatchingDisabled: true, // Memcached does not support pattern matching CloseIsNoop: true, // Cache can still be used after closing } } -func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { +func newHarness(ctx context.Context, t *testing.T) (drivertest.Harness, error) { cache := setupCache(t) return &harness{ cache: cache, @@ -149,5 +149,5 @@ func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { } func TestConformance(t *testing.T) { - cachetest.RunConformanceTests(t, newHarness) + drivertest.RunConformanceTests(t, newHarness) } diff --git a/redis/redis_test.go b/redis/redis_test.go index ce5f223..b36be5c 100644 --- a/redis/redis_test.go +++ b/redis/redis_test.go @@ -7,7 +7,7 @@ import ( "time" cache "github.com/bartventer/gocache" - "github.com/bartventer/gocache/internal/cachetest" + "github.com/bartventer/gocache/drivertest" "github.com/docker/docker/api/types/container" "github.com/redis/go-redis/v9" "github.com/stretchr/testify/assert" @@ -112,14 +112,14 @@ func (h *harness) Close() { // Cleanup is handled in setup function } -func (h *harness) Options() cachetest.Options { - return cachetest.Options{ +func (h *harness) Options() drivertest.Options { + return drivertest.Options{ PatternMatchingDisabled: false, CloseIsNoop: false, } } -func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { +func newHarness(ctx context.Context, t *testing.T) (drivertest.Harness, error) { cache := setupCache(t) return &harness{ cache: cache, @@ -127,5 +127,5 @@ func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { } func TestConformance(t *testing.T) { - cachetest.RunConformanceTests(t, newHarness) + drivertest.RunConformanceTests(t, newHarness) } diff --git a/rediscluster/rediscluster_test.go b/rediscluster/rediscluster_test.go index c05ab0e..df507b3 100644 --- a/rediscluster/rediscluster_test.go +++ b/rediscluster/rediscluster_test.go @@ -7,7 +7,7 @@ import ( "time" cache "github.com/bartventer/gocache" - "github.com/bartventer/gocache/internal/cachetest" + "github.com/bartventer/gocache/drivertest" "github.com/docker/docker/api/types/container" "github.com/docker/go-connections/nat" "github.com/redis/go-redis/v9" @@ -128,14 +128,14 @@ func (h *harness) Close() { // Cleanup is handled in setup function } -func (h *harness) Options() cachetest.Options { - return cachetest.Options{ +func (h *harness) Options() drivertest.Options { + return drivertest.Options{ PatternMatchingDisabled: false, CloseIsNoop: false, } } -func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { +func newHarness(ctx context.Context, t *testing.T) (drivertest.Harness, error) { cache := setupCache(t) return &harness{ cache: cache, @@ -143,5 +143,5 @@ func newHarness(ctx context.Context, t *testing.T) (cachetest.Harness, error) { } func TestConformance(t *testing.T) { - cachetest.RunConformanceTests(t, newHarness) + drivertest.RunConformanceTests(t, newHarness) }