package setval_test

import (
	"testing"

	"github.com/redis/go-redis/internal/customvet/checks/setval"
	"golang.org/x/tools/go/analysis/analysistest"
)

func Test(t *testing.T) {
	testdata := analysistest.TestData()
	analysistest.Run(t, testdata, setval.Analyzer, "a")
}

Related articles

redis pubsub_test

package redis_test import ( "io" "net" "sync" "time" . "github.com/bsm/ginkgo/v2" . "github.com/bsm/gomega" "github.com/redis/go-redis/v9" ) var _ = Describe("PubSub", func() { var client *redis.Client BeforeEach(func() { opt := redisOpti

redis RELEASING

# Releasing 1. Run `release.sh` script which updates versions in go.mod files and pushes a new branch to GitHub: ```shell TAG=v1.0.0 ./scripts/release.sh ``` 2. Open a pull request and wait for the build to finish. 3. Merge the pull request and run `

redis main_test

package redis_test import ( "fmt" "net" "os" "os/exec" "path/filepath" "sync" "testing" "time" . "github.com/bsm/ginkgo/v2" . "github.com/bsm/gomega" "github.com/redis/go-redis/v9" ) const ( redisSecondaryPort = "6381" ) const ( ringSha

redis golangci lint

name: golangci-lint on: push: tags: - v* branches: - master - main - v9 pull_request: permissions: contents: read jobs: golangci: permissions: contents: read # for actions/checkout to fetch code

redis ring_test

package redis_test import ( "context" "crypto/rand" "fmt" "net" "strconv" "sync" "time" . "github.com/bsm/ginkgo/v2" . "github.com/bsm/gomega" "github.com/redis/go-redis/v9" ) var _ = Describe("Redis Ring", func() { const heartbeat = 100 *

redis bench_decode_test

package redis import ( "context" "fmt" "io" "net" "testing" "time" "github.com/redis/go-redis/v9/internal/proto" ) var ctx = context.TODO() type ClientStub struct { Cmdable resp []byte } var initHello = []byte("%1\r\n+proto\r\n:3\r\n") fun

redis tracing

package redisotel import ( "context" "fmt" "net" "runtime" "strings" "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/codes" semconv "go.opentelemetry.io/otel/semconv/v1.10.0" "go.opentelemetry.io/otel/trace" "github.com/redis/

redis conn_check_dummy

//go:build !linux && !darwin && !dragonfly && !freebsd && !netbsd && !openbsd && !solaris && !illumos // +build !linux,!darwin,!dragonfly,!freebsd,!netbsd,!openbsd,!solaris,!illumos package pool import "net" func connCheck(conn net.Conn) error { retu

redis rediscmd_test

package rediscmd import ( "testing" . "github.com/bsm/ginkgo/v2" . "github.com/bsm/gomega" ) func TestGinkgo(t *testing.T) { RegisterFailHandler(Fail) RunSpecs(t, "redisext") } var _ = Describe("AppendArg", func() { DescribeTable("...", func(

redis pool_single

package pool import "context" type SingleConnPool struct { pool Pooler cn *Conn stickyErr error } var _ Pooler = (*SingleConnPool)(nil) func NewSingleConnPool(pool Pooler, cn *Conn) *SingleConnPool { return &SingleConnPool{ pool: po