testsuite

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2019 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Run = suite.Run

Alias suite.Run so suite doesn't have to be imported

Functions

This section is empty.

Types

type TestSuite

type TestSuite struct {
	suite.Suite
}

func (*TestSuite) Contains

func (s *TestSuite) Contains(container interface{}, thingToFind interface{}, msgAndArgs ...interface{})

Contains uses Require by default, because this is usually checked before indexing a map. Using Assert would result in a key not in bounds panic, so Require is a better default.

func (*TestSuite) Len

func (s *TestSuite) Len(object interface{}, length int, msgAndArgs ...interface{})

Len uses Require by default, because this is usually checked before indexing an array. Using Assert would result in a out of bounds panic, so Require is a better default.

func (*TestSuite) NoError

func (s *TestSuite) NoError(err error, msgAndArgs ...interface{})

NoError uses Require by default, because you almost always want an instant failure if an error occurs.

func (*TestSuite) NotNil

func (s *TestSuite) NotNil(object interface{}, msgAndArgs ...interface{})

NotNil uses Require by default, because this is usually checked before accessing attributes. Using Assert would then result in a nil dereference panic, so Require is a better default.

Jump to

Keyboard shortcuts

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