redistest

package
v0.0.0-...-85984c4 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

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

Variables

This section is empty.

Functions

func AuthCommandTest

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

func CommandTest

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

nolint: maintidx, gocyclo

func ConnectionCommandTest

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

nolint: maintidx, gocyclo

func ExecRedisBenchmark

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

func ExecYCSB

func ExecYCSB(t *testing.T)

func ExecYCSBWorkload

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

func GenericCommandTest

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

nolint: maintidx, gocyclo

func GenericTTLCommandTest

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

nolint: maintidx, gocyclo

func HashCommandTest

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

nolint: maintidx, gocyclo, dupl

func ListCommandTest

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

nolint: maintidx, gocyclo, dupl

func ServerCommandTest

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

nolint: maintidx, gocyclo

func SetCommandTest

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

nolint: maintidx, gocyclo, dupl

func StringCommandTest

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

nolint: maintidx, gocyclo, dupl

func ZSetCommandTest

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

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

type ClientOptions

type ClientOptions = goredis.Options

ClientOptions represents a client options for the Redis server.

func NewClientOptions

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