mocks

package
v0.0.0-...-c280501 Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterInterface

type ClusterInterface struct {
	mock.Mock
}

ClusterInterface is an autogenerated mock type for the ClusterInterface type

func (*ClusterInterface) GetConnByAddr

func (_m *ClusterInterface) GetConnByAddr(addr string) (redis.Conn, bool, error)

GetConnByAddr provides a mock function with given fields: addr

func (*ClusterInterface) GetMasterFromSlaveIP

func (_m *ClusterInterface) GetMasterFromSlaveIP(slaveIP string) (string, error)

GetMasterFromSlaveIP provides a mock function with given fields: slaveIP

func (*ClusterInterface) GetMasterIPs

func (_m *ClusterInterface) GetMasterIPs() []string

GetMasterIPs provides a mock function with given fields:

func (*ClusterInterface) GetNodeIPBySlot

func (_m *ClusterInterface) GetNodeIPBySlot(slot int, readOnly bool) (string, error)

GetNodeIPBySlot provides a mock function with given fields: slot, readOnly

func (*ClusterInterface) GetSlaveIPs

func (_m *ClusterInterface) GetSlaveIPs() []string

GetSlaveIPs provides a mock function with given fields:

func (*ClusterInterface) HandleError

func (_m *ClusterInterface) HandleError(err error)

HandleError provides a mock function with given fields: err

func (*ClusterInterface) Slot

func (_m *ClusterInterface) Slot(key string) int

Slot provides a mock function with given fields: key

type Conn

type Conn struct {
	mock.Mock
}

Conn is an autogenerated mock type for the Conn type

func (*Conn) Close

func (_m *Conn) Close() error

Close provides a mock function with given fields:

func (*Conn) Do

func (_m *Conn) Do(commandName string, args ...interface{}) (interface{}, error)

Do provides a mock function with given fields: commandName, args

func (*Conn) Err

func (_m *Conn) Err() error

Err provides a mock function with given fields:

func (*Conn) Flush

func (_m *Conn) Flush() error

Flush provides a mock function with given fields:

func (*Conn) Receive

func (_m *Conn) Receive() (interface{}, error)

Receive provides a mock function with given fields:

func (*Conn) Send

func (_m *Conn) Send(commandName string, args ...interface{}) error

Send provides a mock function with given fields: commandName, args

type ConnWithTimeout

type ConnWithTimeout struct {
	mock.Mock
}

ConnWithTimeout is an autogenerated mock type for the ConnWithTimeout type

func (*ConnWithTimeout) Close

func (_m *ConnWithTimeout) Close() error

Close provides a mock function with given fields:

func (*ConnWithTimeout) Do

func (_m *ConnWithTimeout) Do(commandName string, args ...interface{}) (interface{}, error)

Do provides a mock function with given fields: commandName, args

func (*ConnWithTimeout) DoWithTimeout

func (_m *ConnWithTimeout) DoWithTimeout(timeout time.Duration, commandName string, args ...interface{}) (interface{}, error)

DoWithTimeout provides a mock function with given fields: timeout, commandName, args

func (*ConnWithTimeout) Err

func (_m *ConnWithTimeout) Err() error

Err provides a mock function with given fields:

func (*ConnWithTimeout) Flush

func (_m *ConnWithTimeout) Flush() error

Flush provides a mock function with given fields:

func (*ConnWithTimeout) Receive

func (_m *ConnWithTimeout) Receive() (interface{}, error)

Receive provides a mock function with given fields:

func (*ConnWithTimeout) ReceiveWithTimeout

func (_m *ConnWithTimeout) ReceiveWithTimeout(timeout time.Duration) (interface{}, error)

ReceiveWithTimeout provides a mock function with given fields: timeout

func (*ConnWithTimeout) Send

func (_m *ConnWithTimeout) Send(commandName string, args ...interface{}) error

Send provides a mock function with given fields: commandName, args

type RedisClient

type RedisClient struct {
	mock.Mock
}

RedisClient is an autogenerated mock type for the RedisClient type

func (*RedisClient) GetConn

func (_m *RedisClient) GetConn(host string) (redis.Conn, bool, error)

GetConn provides a mock function with given fields: host

func (*RedisClient) GetConnWithTimeout

func (_m *RedisClient) GetConnWithTimeout(host string) (redis.ConnWithTimeout, bool, error)

GetConnWithTimeout provides a mock function with given fields: host

func (*RedisClient) GetHosts

func (_m *RedisClient) GetHosts() ([]string, []string)

GetHosts provides a mock function with given fields:

func (*RedisClient) GetMasterFromSlaveIP

func (_m *RedisClient) GetMasterFromSlaveIP(slaveIP string) (string, error)

GetMasterFromSlaveIP provides a mock function with given fields: slaveIP

func (*RedisClient) GetMaxConn

func (_m *RedisClient) GetMaxConn() int

GetMaxConn provides a mock function with given fields:

func (*RedisClient) GetNodeIPByKey

func (_m *RedisClient) GetNodeIPByKey(key string, readOnly bool) (string, error)

GetNodeIPByKey provides a mock function with given fields: key, readOnly

func (*RedisClient) HandleError

func (_m *RedisClient) HandleError(err error)

HandleError provides a mock function with given fields: err

type RedisPipeline

type RedisPipeline struct {
	mock.Mock
}

RedisPipeline is an autogenerated mock type for the RedisPipeline type

func (*RedisPipeline) NewSession

NewSession provides a mock function with given fields: ctx

type RedisPipelineSession

type RedisPipelineSession struct {
	mock.Mock
}

RedisPipelineSession is an autogenerated mock type for the RedisPipelineSession type

func (*RedisPipelineSession) Execute

Execute provides a mock function with given fields:

func (*RedisPipelineSession) PushCommand

func (_m *RedisPipelineSession) PushCommand(command string, args ...interface{}) redispipeline.RedisPipelineSession

PushCommand provides a mock function with given fields: command, args

func (*RedisPipelineSession) PushCommandReadOnly

func (_m *RedisPipelineSession) PushCommandReadOnly(command string, args ...interface{}) redispipeline.RedisPipelineSession

PushCommandReadOnly provides a mock function with given fields: command, args

Jump to

Keyboard shortcuts

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