testing

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MockMinimumVersion is the minimum acceptable version for finance-mock.
	// It's here so that if the library depends on new endpoints or features
	// added in a more recent version of finance-mock, we can show people a
	// better error message instead of the test suite crashing with a bunch of
	// confusing 404 errors or the like.
	MockMinimumVersion = "0.0.5"
	TestServerAddr     = "localhost"

	// Symbols for testing asset classes.
	TestEquitySymbol     = "AAPL"
	TestETFSymbol        = "SPY"
	TestFutureSymbol     = "O=F"
	TestIndexSymbol      = "^GSPC"
	TestOptionSymbol     = "AMD180720C00003000"
	TestMutualFundSymbol = "INPSX"
	TestForexPairSymbol  = "USDGBP=X"
	TestCryptoPairSymbol = "BTC-USD"
	TestStraddleSymbol   = "AMD"
)

This file should contain any testing helpers that should be commonly available across all tests in the finance package.

Variables

This section is empty.

Functions

func SetMarket

func SetMarket(state finance.MarketState)

SetMarket sets the test server to the state/session specified.

Types

This section is empty.

Jump to

Keyboard shortcuts

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