redis

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetTodayNumber(n int) (int, error)
}

func New

func New(client redis.Cmdable) Client

type TestGetTodayNumber

type TestGetTodayNumber struct{}

func (TestGetTodayNumber) FailBadResponse

func (TestGetTodayNumber) FailBadResponse(t *testing.T) (actual int, err error)

FailBadResponse because the response is bad.

func (TestGetTodayNumber) FailClientGet

func (TestGetTodayNumber) FailClientGet(t *testing.T) (actual int, err error)

FailClientGet because fail to Get.

func (TestGetTodayNumber) FailClientNil

func (TestGetTodayNumber) FailClientNil(t *testing.T) (actual int, err error)

FailClientNil because client is nil.

func (TestGetTodayNumber) Success

func (TestGetTodayNumber) Success(t *testing.T) (actual int, err error)

Success when everything is success.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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