package
module
Version:
v0.0.0-...-82e2b9b
Opens a new window with list of versions in this module.
Published: Jul 23, 2020
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 7
Opens a new window with list of known importers.
Documentation
¶
-
func Equals(t Tester, expected, actual interface{}, msg ...interface{}) bool
-
func Error(t Tester, err error, msg ...interface{}) bool
-
func False(t Tester, condition bool, msg ...interface{}) bool
-
func Fatal(t Tester, condition bool, msg ...interface{})
-
func FatalError(t Tester, err error, msg ...interface{})
-
func HasPrefix(t Tester, s, p string, msg ...interface{}) bool
-
func HasSuffix(t Tester, s, suffix string, msg ...interface{}) bool
-
func Len(t Tester, expected int, value interface{}, msg ...interface{}) bool
-
func Nil(t Tester, value interface{}, msg ...interface{}) bool
-
func NoError(t Tester, err error, msg ...interface{}) bool
-
func NotEquals(t Tester, expected, actual interface{}, msg ...interface{}) bool
-
func NotNil(t Tester, value interface{}, msg ...interface{}) bool
-
func Panic(t Tester, f func(), msg ...interface{}) (ret bool)
-
func True(t Tester, condition bool, msg ...interface{}) bool
-
func Type(t Tester, expected, value interface{}, msg ...interface{}) bool
-
type Tester
func Equals(t Tester, expected, actual interface{}, msg ...interface{}) bool
Equals checks that expected and actual are equal.
Error checks if err is not nil.
False checks that a condition is false.
func Fatal(t Tester, condition bool, msg ...interface{})
Fatal checks that a condition is true or marks the test as failed and stop
it's execution.
func FatalError(t Tester, err error, msg ...interface{})
FatalError checks that a error is nil or marks the test as failed and stop
it's execution.
HasPrefix checks that the string contains the given prefix.
HasSuffix checks that the string ends with the given suffix.
func Len(t Tester, expected int, value interface{}, msg ...interface{}) bool
Len checks that the application of len() to value match the expected value.
func Nil(t Tester, value interface{}, msg ...interface{}) bool
Nil checks that the value is nil.
NoError checks if err nil.
func NotEquals(t Tester, expected, actual interface{}, msg ...interface{}) bool
NotEquals checks that expected and actual are not equal.
func NotNil(t Tester, value interface{}, msg ...interface{}) bool
NotNil checks that the value is not nil.
func Panic(t Tester, f func(), msg ...interface{}) (ret bool)
Panic checks that the passed function panics.
True checks that a condition is true.
func Type(t Tester, expected, value interface{}, msg ...interface{}) bool
Type checks that the value matches the type of expected.
type Tester interface {
Errorf(format string, args ...interface{})
Fatalf(format string, args ...interface{})
Helper()
}
Tester is an interface that testing.T implements, It has the methods used
in the implementation of this package.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.