integration

package
v0.15.6 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2020 License: Apache-2.0 Imports: 35 Imported by: 0

Documentation

Overview

Package integration contains EN Server integration tests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Eventually

func Eventually(tb testing.TB, times uint64, interval time.Duration, f func() error)

Eventually retries the given function n times, sleeping 1s between each invocation. To mark an error as retryable, wrap it in retry.RetryableError. Non-retryable errors return immediately.

func IndexFilePath

func IndexFilePath(root string) string

IndexFilePath returns the filepath of index file under blob storage

func Seed added in v0.10.0

func Seed(tb testing.TB, ctx context.Context, db *database.DB, exportPeriod time.Duration) (*testutil.JWTConfig, string, string, string)

Types

type Client

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

Client provides Exposure Notifications API client to support integration testing.

func NewTestServer

func NewTestServer(tb testing.TB) (*serverenv.ServerEnv, *Client)

NewTestServer sets up mocked local servers for running tests

func (*Client) CleanupExports

func (c *Client) CleanupExports() error

func (*Client) CleanupExposures

func (c *Client) CleanupExposures() error

func (*Client) ExportBatches

func (c *Client) ExportBatches() error

func (*Client) PublishKeys

func (c *Client) PublishKeys(payload *verifyapi.Publish) (*verifyapi.PublishResponse, error)

func (*Client) RotateKeys added in v0.3.0

func (c *Client) RotateKeys() error

func (*Client) StartExportWorkers

func (c *Client) StartExportWorkers() error

Jump to

Keyboard shortcuts

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