Documentation
¶
Overview ¶
Package smarttest implements the smart_test tool.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Params ¶
type Params struct {
//nolint:lll
Dir string `json:"dir" jsonschema:"The absolute directory path to test in. Required. Relative paths are rejected."`
//nolint:lll
Packages string `json:"packages,omitempty" jsonschema:"Packages to test (default: ./...)"`
//nolint:lll
Level string `` /* 244-byte string literal not displayed */
//nolint:lll
Run string `json:"run,omitempty" jsonschema:"Regex pattern to filter specific tests or benchmark functions (maps to -run or -bench)."`
}
Params defines the input parameters for smart_test.
type Runner ¶
type Runner interface {
Run(ctx context.Context, dir, name string, args ...string) error
RunWithOutput(ctx context.Context, dir, name string, args ...string) (string, error)
LookPath(file string) (string, error)
}
Runner defines the interface for running CLI commands.
var CommandRunner Runner = &stdRunner{}
CommandRunner is used for executing CLI commands during testing or runtime.
Click to show internal directories.
Click to hide internal directories.