Documentation
¶
Overview ¶
Package test is a wrapper of testing that supply some useful functions for test.
Index ¶
- Variables
- func Recover(t testing.TB)
- func RecoverEq(t testing.TB, s string)
- type TB
- func DeepEq(t testing.TB, expect, got interface{}) TB
- func Eq(t testing.TB, expect, got interface{}) TB
- func False(t testing.TB, val bool) TB
- func NE(t testing.TB, expect, got interface{}) TB
- func NNil(t testing.TB, val interface{}) TB
- func Nil(t testing.TB, val interface{}) TB
- func True(t testing.TB, val bool) TB
- func Wrap(t testing.TB) TB
- func (t TB) DeepEq(expect, got interface{}) TB
- func (t TB) Eq(expect, got interface{}) TB
- func (t TB) False(val bool) TB
- func (t TB) NE(expect, got interface{}) TB
- func (t TB) NNil(val interface{}) TB
- func (t TB) Nil(val interface{}) TB
- func (t TB) Recover() TB
- func (t TB) RecoverEq(s string) TB
- func (t TB) True(val bool) TB
- type TestCase
- func (test *TestCase) Arg(args ...interface{}) *TestCase
- func (test *TestCase) Expect(expect ...interface{}) *TestCase
- func (test *TestCase) False() *TestCase
- func (test *TestCase) Nil() *TestCase
- func (test *TestCase) Run(t testing.TB, fn ...interface{}) *TestCase
- func (test *TestCase) True() *TestCase
Constants ¶
This section is empty.
Variables ¶
View Source
var NoCheck = struct{}{}
NoCheck means don't check this value
View Source
var NonNil = struct{}{}
NonNil means this value should not be nil
Functions ¶
Types ¶
type TB ¶
TB is a wrapper of testing.testing.TB
Click to show internal directories.
Click to hide internal directories.