get

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2019 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Downloader

type Downloader interface {
	Download(module coordinates.SerialModule) error
}

func New

func New(
	proxyClient zips.ProxyClient,
	upstreamClient zips.UpstreamClient,
	resolver upstream.Resolver,
	store store.ZipStore,
	index store.Index,
	emitter stats.Sender,
) Downloader

type DownloaderMock

type DownloaderMock struct {
	DownloadMock mDownloaderMockDownload
	// contains filtered or unexported fields
}

DownloaderMock implements Downloader

func NewDownloaderMock

func NewDownloaderMock(t minimock.Tester) *DownloaderMock

NewDownloaderMock returns a mock for Downloader

func (*DownloaderMock) Download

func (mmDownload *DownloaderMock) Download(module coordinates.SerialModule) (err error)

Download implements Downloader

func (*DownloaderMock) DownloadAfterCounter

func (mmDownload *DownloaderMock) DownloadAfterCounter() uint64

DownloadAfterCounter returns a count of finished DownloaderMock.Download invocations

func (*DownloaderMock) DownloadBeforeCounter

func (mmDownload *DownloaderMock) DownloadBeforeCounter() uint64

DownloadBeforeCounter returns a count of DownloaderMock.Download invocations

func (*DownloaderMock) MinimockDownloadDone

func (m *DownloaderMock) MinimockDownloadDone() bool

MinimockDownloadDone returns true if the count of the Download invocations corresponds the number of defined expectations

func (*DownloaderMock) MinimockDownloadInspect

func (m *DownloaderMock) MinimockDownloadInspect()

MinimockDownloadInspect logs each unmet expectation

func (*DownloaderMock) MinimockFinish

func (m *DownloaderMock) MinimockFinish()

MinimockFinish checks that all mocked methods have been called the expected number of times

func (*DownloaderMock) MinimockWait

func (m *DownloaderMock) MinimockWait(timeout mm_time.Duration)

MinimockWait waits for all mocked methods to be called the expected number of times

type DownloaderMockDownloadExpectation

type DownloaderMockDownloadExpectation struct {
	Counter uint64
	// contains filtered or unexported fields
}

DownloaderMockDownloadExpectation specifies expectation struct of the Downloader.Download

func (*DownloaderMockDownloadExpectation) Then

Then sets up Downloader.Download return parameters for the expectation previously defined by the When method

type DownloaderMockDownloadParams

type DownloaderMockDownloadParams struct {
	// contains filtered or unexported fields
}

DownloaderMockDownloadParams contains parameters of the Downloader.Download

type DownloaderMockDownloadResults

type DownloaderMockDownloadResults struct {
	// contains filtered or unexported fields
}

DownloaderMockDownloadResults contains results of the Downloader.Download

type Ranges

type Ranges = coordinates.RangeIDs

Range is an alias of coordinates.RangeIDs for brevity.

type RegistryAPI

type RegistryAPI interface {
	ModulesNeeded(Ranges) ([]coordinates.SerialModule, error)
}

RegistryAPI is used to issue API request from the registry

func NewRegistryAPI

func NewRegistryAPI(
	registryClient registry.Client,
	index store.Index,
) RegistryAPI

Jump to

Keyboard shortcuts

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