redistest

package
v1.5.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 12, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LocalHost   = "localhost"
	DefaultPort = 6379
)

Variables

This section is empty.

Functions

func AuthCommandTest added in v1.4.0

func AuthCommandTest(t *testing.T, server *Server)

func CommandTest added in v1.2.1

func CommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo

func ConnectionCommandTest added in v1.2.1

func ConnectionCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo

func ExecRedisBenchmark added in v1.2.0

func ExecRedisBenchmark(t *testing.T, param string)

func ExecYCSB added in v1.0.0

func ExecYCSB(t *testing.T)

func ExecYCSBWorkload added in v1.0.0

func ExecYCSBWorkload(t *testing.T, workload string)

func GenericCommandTest added in v1.2.1

func GenericCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo

func GenericTTLCommandTest added in v1.4.0

func GenericTTLCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo

func HashCommandTest added in v1.2.1

func HashCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo, dupl

func ListCommandTest added in v1.2.1

func ListCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo, dupl

func ServerCommandTest added in v1.2.1

func ServerCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo

func SetCommandTest added in v1.2.1

func SetCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo, dupl

func StringCommandTest added in v1.2.1

func StringCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo, dupl

func ZSetCommandTest added in v1.2.1

func ZSetCommandTest(t *testing.T, client *Client)

nolint: maintidx, gocyclo, dupl

Types

type Client

type Client struct {
	*goredis.Client
}

Client represents a client for the Redis server.

func NewClient

func NewClient() *Client

NewClient returns a client instance.

func (*Client) Close

func (client *Client) Close() error

Close closes the current connection with the specified host.

func (*Client) Open

func (client *Client) Open(host string) error

Open opens a connection with the specified host.

func (*Client) OpenWith added in v1.4.0

func (client *Client) OpenWith(host string, port int, opts *ClientOptions) error

type ClientOptions added in v1.4.0

type ClientOptions = goredis.Options

ClientOptions represents a client options for the Redis server.

func NewClientOptions added in v1.4.0

func NewClientOptions() ClientOptions

NewClientOptions returns a default client options. nolint: exhaustivestruct

type Server

type Server struct {
	*server.Server
}

Server represents an example server.

func NewServer

func NewServer() *Server

NewServer returns an example server instance.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL