mock

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: May 10, 2024 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GraphqlResponseGetterStub

type GraphqlResponseGetterStub struct {
	GetCalled func(ctx context.Context, url string, query string, variables string) ([]byte, error)
}

GraphqlResponseGetterStub -

func (*GraphqlResponseGetterStub) Query

func (stub *GraphqlResponseGetterStub) Query(ctx context.Context, url string, query string, variables string) ([]byte, error)

Query -

type HttpResponseGetterStub

type HttpResponseGetterStub struct {
	GetCalled func(ctx context.Context, url string, response interface{}) error
}

HttpResponseGetterStub -

func (*HttpResponseGetterStub) Get

func (stub *HttpResponseGetterStub) Get(ctx context.Context, url string, response interface{}) error

Get -

type PriceFetcherStub

type PriceFetcherStub struct {
	NameCalled       func() string
	FetchPriceCalled func(ctx context.Context, base string, quote string) (float64, error)
	AddPairCalled    func(base, quote string)
}

PriceFetcherStub -

func (*PriceFetcherStub) AddPair

func (stub *PriceFetcherStub) AddPair(base, quote string)

AddPair -

func (*PriceFetcherStub) FetchPrice

func (stub *PriceFetcherStub) FetchPrice(ctx context.Context, base string, quote string) (float64, error)

FetchPrice -

func (*PriceFetcherStub) IsInterfaceNil

func (stub *PriceFetcherStub) IsInterfaceNil() bool

IsInterfaceNil -

func (*PriceFetcherStub) Name

func (stub *PriceFetcherStub) Name() string

Name -

type PriceNotifeeStub

type PriceNotifeeStub struct {
	PriceChangedCalled func(ctx context.Context, args []*aggregator.ArgsPriceChanged) error
}

PriceNotifeeStub -

func (*PriceNotifeeStub) IsInterfaceNil

func (stub *PriceNotifeeStub) IsInterfaceNil() bool

IsInterfaceNil -

func (*PriceNotifeeStub) PriceChanged

func (stub *PriceNotifeeStub) PriceChanged(ctx context.Context, args []*aggregator.ArgsPriceChanged) error

PriceChanged -

Jump to

Keyboard shortcuts

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