diff --git a/background_test.go b/background_test.go index 03e32e8..2acebbc 100644 --- a/background_test.go +++ b/background_test.go @@ -8,7 +8,6 @@ import ( "testing" "time" - "github.com/go-redis/redis/v7" "github.com/google/go-cmp/cmp" "go.uber.org/goleak" ) @@ -18,10 +17,10 @@ func TestBackground(t *testing.T) { ignoreOpt := goleak.IgnoreTopFunction("github.com/go-redis/redis/v7/internal/pool.(*ConnPool).reaper") defer goleak.VerifyNoLeaks(t, ignoreOpt) - r := redis.NewClient(&redis.Options{ + r := &RedisClientOpt{ Addr: "localhost:6379", DB: 15, - }) + } client := NewClient(r) bg := NewBackground(r, &Config{ Concurrency: 10, diff --git a/client_test.go b/client_test.go index 73c9190..7024f5d 100644 --- a/client_test.go +++ b/client_test.go @@ -15,7 +15,10 @@ import ( func TestClient(t *testing.T) { r := setup(t) - client := NewClient(r) + client := NewClient(&RedisClientOpt{ + Addr: "localhost:6379", + DB: 14, + }) task := NewTask("send_email", map[string]interface{}{"to": "customer@gmail.com", "from": "merchant@example.com"})