mirror of
https://github.com/hibiken/asynq.git
synced 2025-09-19 05:17:30 +08:00
Fix benchmark tests
This commit is contained in:
@@ -16,11 +16,17 @@ import (
|
||||
// This file defines test helper functions used by
|
||||
// other test files.
|
||||
|
||||
// redis used for package testing.
|
||||
const (
|
||||
redisAddr = "localhost:6379"
|
||||
redisDB = 14
|
||||
)
|
||||
|
||||
func setup(tb testing.TB) *redis.Client {
|
||||
tb.Helper()
|
||||
r := redis.NewClient(&redis.Options{
|
||||
Addr: "localhost:6379",
|
||||
DB: 14,
|
||||
Addr: redisAddr,
|
||||
DB: redisDB,
|
||||
})
|
||||
// Start each test with a clean slate.
|
||||
h.FlushDB(tb, r)
|
||||
|
Reference in New Issue
Block a user