testutil

package
v0.0.0-...-eeee692 Latest Latest
Warning

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

Go to latest
Published: May 25, 2017 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestServerFromServiceContext

func NewTestServerFromServiceContext(port int, sc servicecontext.ServiceContext) (*httptest.Server, error)

NewTestServerFromServiceContext takes in a port and already constructed ServiceContext and creates an REST v2 API server. This is very useful when testing, especially when mocking out sections of the ServiceContext to make sure request occur as expected.

func NewTestServerFromSettings

func NewTestServerFromSettings(settings *evergreen.Settings) (*httptest.Server, error)

NewTestServerFromSettings takes an evergreen.Settings and creates a database backed REST v2 test server. It automatically starts the server on port 9191.

Types

This section is empty.

Jump to

Keyboard shortcuts

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