blocky/redis/redis_suite_test.go

26 lines
417 B
Go
Raw Normal View History

package redis
import (
"context"
"testing"
"github.com/0xERR0R/blocky/log"
"github.com/go-redis/redis/v8"
2022-03-03 11:27:27 +01:00
. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
)
func init() {
log.Silence()
redis.SetLogger(NoLogs{})
}
func TestRedisClient(t *testing.T) {
RegisterFailHandler(Fail)
RunSpecs(t, "Redis Suite")
}
type NoLogs struct{}
2023-05-08 18:09:53 +02:00
func (l NoLogs) Printf(context.Context, string, ...interface{}) {}