Documentation
¶
Index ¶
- Constants
- func AddInitializer(initFunc InitializerFunc)
- func Debug(format string, args ...any)
- func Debugf(format string, args ...any)
- func Depth(depth int) debugObj
- func Info(format string, args ...any)
- func Infof(format string, args ...any)
- func InitializeTest(c4t ContextForTests, test Test)
- func SetDebugOutput(output bool)
- func Warn(format string, args ...any)
- func Warnf(format string, args ...any)
- type Context
- type ContextForTestArgs
- type ContextForTests
- type InitializerFunc
- type Test
- type TestCommon
- type TestSetter
Constants ¶
View Source
const (
DisableDebugInfoVar = "DISABLE_DEBUG_INFO"
)
Variables ¶
This section is empty.
Functions ¶
func AddInitializer ¶
func AddInitializer(initFunc InitializerFunc)
func InitializeTest ¶
func InitializeTest(c4t ContextForTests, test Test)
func SetDebugOutput ¶
func SetDebugOutput(output bool)
Types ¶
type ContextForTestArgs ¶
type ContextForTestArgs struct {
T *testing.T
Context context.Context
Test Test
Common *TestCommon
Recorder *httptest.ResponseRecorder
}
type ContextForTests ¶
type ContextForTests interface {
context.Context
testing.TB
Depth() int
IncrDepth() ContextForTests
DecrDepth() ContextForTests
Debugf(format string, args ...any) ContextForTests
Debug(args ...any) ContextForTests
SetTest(Test)
Reset(*testing.T) ContextForTests
SetTestingT(*testing.T)
TestingT() *testing.T
Run(string, func(t *testing.T)) bool
SetContext(Context)
Context() Context
Test() Test
Warnf(string, ...any) ContextForTests
Warn(args ...any) ContextForTests
Common() *TestCommon
Update(ContextForTestArgs)
Recorder() *httptest.ResponseRecorder
ConfigFilepath() string
}
func NewContextForTests ¶
func NewContextForTests(t *testing.T) ContextForTests
type InitializerFunc ¶
type InitializerFunc func(ContextForTests)
type Test ¶
type Test interface {
Common() *TestCommon
}
type TestCommon ¶
type TestCommon struct {
Name string
Reason string
Status int
Output string
LogOut []string
T *testing.T
}
func NewTestCommon ¶
func NewTestCommon(c4t ContextForTests) *TestCommon
func (*TestCommon) Common ¶
func (c *TestCommon) Common() *TestCommon
type TestSetter ¶
type TestSetter interface {
SetTest(Test)
}
Click to show internal directories.
Click to hide internal directories.