Documentation
¶
Index ¶
- func Bool(v bool) *bool
- func Int(v int) *int
- type AssertionResult
- type Command
- type DirectoryAssertion
- type DurationAssertion
- type Error
- type ErrorKind
- type Expectations
- type FileAssertion
- type FileExtension
- type FileSystemAssertion
- type Launcher
- func (l *Launcher) DryRun(plan TestPlan, opts ...RunOption) *TestExecutionReport
- func (l *Launcher) Execute(plan TestPlan, opts ...RunOption) *TestExecutionReport
- func (l *Launcher) ExecuteFile(path string, opts ...RunOption) (*TestExecutionReport, error)
- func (l *Launcher) ExecuteFileT(t testing.TB, path string, opts ...RunOption) *TestExecutionReport
- func (l *Launcher) ExecuteT(t testing.TB, plan TestPlan, opts ...RunOption) *TestExecutionReport
- func (l *Launcher) ListSpecs(plan TestPlan, opts ...RunOption) []string
- type OutputAssertion
- type OutputAssertions
- type OutputMatcher
- func Contains(substrings ...string) OutputMatcher
- func ContainsAnyOf(substrings ...string) OutputMatcher
- func ContainsExactLine(line string) OutputMatcher
- func Empty() OutputMatcher
- func EndsWith(suffix string) OutputMatcher
- func Equals(s string) OutputMatcher
- func HasLineCount(n int) OutputMatcher
- func HasLineCountAtLeast(n int) OutputMatcher
- func Matches(re string) OutputMatcher
- func NotContains(substrings ...string) OutputMatcher
- func NotMatches(re string) OutputMatcher
- func StartsWith(prefix string) OutputMatcher
- type PlanBuilder
- type Preconditions
- type ReportBlock
- func (r *ReportBlock) Duration() time.Duration
- func (r *ReportBlock) Entries() []ReportEntry
- func (r *ReportBlock) Failed() bool
- func (r *ReportBlock) Index() int
- func (r *ReportBlock) Phase() string
- func (r *ReportBlock) Skipped() bool
- func (r *ReportBlock) StartedAt() time.Time
- func (r *ReportBlock) TimedOut() bool
- func (r *ReportBlock) Total() int
- type ReportEntry
- type ReportEntryType
- type Reporter
- type RunOption
- type SkipCondition
- type Spec
- type SpecBuilder
- func (b *SpecBuilder) Build() Spec
- func (b *SpecBuilder) Command(cmd Command) *SpecBuilder
- func (b *SpecBuilder) Description(d string) *SpecBuilder
- func (b *SpecBuilder) ExpectStatus(code int) *SpecBuilder
- func (b *SpecBuilder) ExpectStatusGT(n int) *SpecBuilder
- func (b *SpecBuilder) ExpectStatusLT(n int) *SpecBuilder
- func (b *SpecBuilder) ExpectStderr(matchers ...OutputMatcher) *SpecBuilder
- func (b *SpecBuilder) ExpectStdout(matchers ...OutputMatcher) *SpecBuilder
- func (b *SpecBuilder) Retries(n int) *SpecBuilder
- func (b *SpecBuilder) RetryDelay(d string) *SpecBuilder
- func (b *SpecBuilder) Setup(cmds ...Command) *SpecBuilder
- func (b *SpecBuilder) Skip() *SpecBuilder
- func (b *SpecBuilder) Tags(tags ...string) *SpecBuilder
- func (b *SpecBuilder) Teardown(cmds ...Command) *SpecBuilder
- type StatusAssertion
- type TestExecutionReport
- func (r *TestExecutionReport) AllErrors() []error
- func (r *TestExecutionReport) Blocks() []*ReportBlock
- func (r *TestExecutionReport) FailWith(t *testing.T)
- func (r *TestExecutionReport) FailedSpecs() []string
- func (r *TestExecutionReport) Success() bool
- func (r *TestExecutionReport) Summary() string
- type TestPlan
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AssertionResult ¶
type AssertionResult struct {
// contains filtered or unexported fields
}
AssertionResult is the container of verification results.
func (*AssertionResult) Description ¶
func (r *AssertionResult) Description() string
Description is the textual representation of the assertion.
func (*AssertionResult) Errors ¶
func (r *AssertionResult) Errors() []error
Errors returns the errors list.
func (*AssertionResult) Success ¶
func (r *AssertionResult) Success() bool
Success returns if an assertion completed with no error.
type Command ¶
type Command struct {
WorkingDir string `yaml:"working_dir"`
// Cli is a shell command line. The system shell interprets it, so pipes,
// redirects, and globs work. Mutually exclusive with exe.
Cli string `yaml:"cli"`
// Exe is the path or name of the executable. The process is started
// directly without a shell. Mutually exclusive with cli.
Exe string `yaml:"exe"`
Env map[string]string `yaml:"env"`
// Extension is appended to Exe based on the runtime OS (e.g. ".exe" on Windows).
Extension FileExtension `yaml:"ext"`
// Args holds arguments passed directly to Exe. Only meaningful when Exe is set.
Args []string `yaml:"args"`
// Timeout is the maximum wall-clock time to wait; parsed by time.ParseDuration
// (e.g. "30s", "1m"). Zero or empty means no timeout.
Timeout string `yaml:"timeout"`
// Stdin is an inline string piped to the command's standard input.
Stdin string `yaml:"stdin"`
// StdinFile is a path to a file whose contents are piped to standard input.
StdinFile string `yaml:"stdin_file"`
}
Command represents the command under test.
Use either cli or exe+args — setting both is a configuration error.
cli runs the value through the system shell ($SHELL -c on Unix, cmd /C on Windows). Shell features such as pipes (|), redirects (>), globs (*), and variable expansion are available. Convenient for simple one-liners. Avoid when any part of the command line comes from untrusted input: shell injection is possible.
exe + args starts the process directly without a shell. Arguments are passed verbatim to the OS; no quoting, globbing, or expansion occurs. Prefer this form when shell features are not needed, especially with values that originate from user input or external data.
func Cmd ¶ added in v0.5.0
Cmd creates a Command that runs the given executable directly (no shell).
type DirectoryAssertion ¶
type DirectoryAssertion struct {
Path string `yaml:"path"`
// Exists defaults to true (nil): check that the directory exists.
// Set to false to assert the directory must not exist.
Exists *bool `yaml:"exists"`
EqualsTo string `yaml:"equals_to"`
ContainsAny []string `yaml:"contains_any"`
ContainsAll []string `yaml:"contains_all"`
ContainsExactly []string `yaml:"contains_exactly"`
}
DirectoryAssertion is an assertion on a given directory.
type DurationAssertion ¶ added in v0.5.0
DurationAssertion asserts that the command's wall-clock execution time is within the specified bounds. Both fields accept any string accepted by time.ParseDuration (e.g. "2s", "500ms", "1m30s").
type Error ¶ added in v0.4.0
Error is a structured error that carries a kind for programmatic classification. It wraps the underlying cause so errors.As / errors.Is work through the chain.
type ErrorKind ¶ added in v0.4.0
type ErrorKind int
ErrorKind categorises an Error so consumers can distinguish failure modes.
const ( // KindAssertionFailure means an assertion's condition was not met. KindAssertionFailure ErrorKind = iota // KindInfrastructure means a system-level operation failed (file I/O, path resolution). KindInfrastructure // KindConfiguration means the test plan itself is invalid (YAML, unknown fields, wrong field usage). KindConfiguration )
type Expectations ¶
type Expectations struct {
StatusAssertion StatusAssertion `yaml:"status"`
OutputAssertions OutputAssertions `yaml:"output"`
FileSystemAssertions []FileSystemAssertion `yaml:"fs"`
DurationAssertion DurationAssertion `yaml:"duration"`
}
Expectations is the aggregate of the final assertions on the command executed.
type FileAssertion ¶
type FileAssertion struct {
Path string `yaml:"path"`
Extension FileExtension `yaml:"ext"`
// Exists defaults to true (nil): check that the file exists.
// Set to false to assert the file must not exist.
Exists *bool `yaml:"exists"`
EqualsTo string `yaml:"equals_to"`
TextEqualsTo string `yaml:"text_equals_to"`
ContainsAny []string `yaml:"contains_any"`
ContainsAll []string `yaml:"contains_all"`
ContainsMatching string `yaml:"contains_matching"`
}
FileAssertion is an assertion on a given file.
type FileExtension ¶
FileExtension is added as suffix to file assertions' path and command's exe values based on runtime.GOOS
type FileSystemAssertion ¶
type FileSystemAssertion struct {
File string `yaml:"file"`
Extension FileExtension `yaml:"ext"`
Directory string `yaml:"directory"`
// Exists defaults to true when omitted (nil): the assertion checks the path exists.
// Set explicitly to false to assert the path must not exist.
Exists *bool `yaml:"exists"`
EqualsTo string `yaml:"equals_to"`
// Only for files
TextEqualsTo string `yaml:"text_equals_to"`
ContainsAny []string `yaml:"contains_any"`
ContainsAll []string `yaml:"contains_all"`
ContainsExactly []string `yaml:"contains_exactly"`
ContainsMatching string `yaml:"contains_matching"`
}
FileSystemAssertion is an assertion on files and directories.
type Launcher ¶
type Launcher struct {
// contains filtered or unexported fields
}
Launcher checks the results respect expectations.
func NewLauncher ¶
func NewLauncher() *Launcher
NewLauncher creates a default implementation for Launcher.
func (*Launcher) DryRun ¶ added in v0.5.0
func (l *Launcher) DryRun(plan TestPlan, opts ...RunOption) *TestExecutionReport
DryRun validates the plan structure and reports which specs would run or be skipped, without executing any commands or touching the filesystem. The returned report uses InfoType entries for specs that would run and SkippedType entries for those that would not. Config errors produce ErrorType entries just as they do in Execute.
func (*Launcher) Execute ¶
func (l *Launcher) Execute(plan TestPlan, opts ...RunOption) *TestExecutionReport
Execute runs all specs in plan and returns a report of the results. The report is never nil; spec-level failures are recorded inside it and do not cause an error return. Pass RunOption values (WithTags, SkipTags, FailFast) to control which specs run. For use in Go tests prefer ExecuteT, which forwards spec failures to t.Errorf.
func (*Launcher) ExecuteFile ¶
func (l *Launcher) ExecuteFile(path string, opts ...RunOption) (*TestExecutionReport, error)
ExecuteFile loads a test plan from path and runs it. Returns a non-nil error when the file cannot be read or parsed; spec-level failures are recorded in the report and do not cause an error return.
func (*Launcher) ExecuteFileT ¶ added in v0.5.0
ExecuteFileT loads the YAML plan at path, runs all specs, and integrates with Go's testing.TB: load and parse errors call t.Fatalf (stopping the test immediately); each spec failure calls t.Errorf. The returned report is never nil. Pass RunOption values (WithTags, SkipTags, FailFast) to filter specs. It is the idiomatic single-line form for Go tests:
qac.NewLauncher().ExecuteFileT(t, "plan.yaml")
func (*Launcher) ExecuteT ¶ added in v0.5.0
ExecuteT runs plan and integrates with Go's testing.TB: each spec failure calls t.Errorf. The returned report is never nil. Pass RunOption values (WithTags, SkipTags, FailFast) to filter specs. It is the idiomatic single-line form when constructing plans in Go:
qac.NewLauncher().ExecuteT(t, plan)
type OutputAssertion ¶
type OutputAssertion struct {
EqualsTo string `yaml:"equals_to"`
EqualsToFile string `yaml:"equals_to_file"`
// output is trimmed
StartsWith string `yaml:"starts_with"`
// output is trimmed
EndsWith string `yaml:"ends_with"`
IsEmpty *bool `yaml:"is_empty"`
ContainsAny []string `yaml:"contains_any"`
ContainsAll []string `yaml:"contains_all"`
ContainsNone []string `yaml:"contains_none"`
// ContainsLine requires at least one line to equal the given string exactly (after trimming).
ContainsLine string `yaml:"contains_line"`
// LineCount requires the output to have exactly N non-empty lines.
LineCount *int `yaml:"line_count"`
// LineCountGte requires the output to have at least N non-empty lines.
LineCountGte *int `yaml:"line_count_gte"`
// Matches requires the entire trimmed output to match the regular expression.
Matches string `yaml:"matches"`
// NotMatches requires the entire trimmed output NOT to match the regular expression.
NotMatches string `yaml:"not_matches"`
// contains filtered or unexported fields
}
OutputAssertion is an assertion on the output of a command: namely standard output and standard error.
type OutputAssertions ¶
type OutputAssertions struct {
Stdout OutputAssertion `yaml:"stdout"`
Stderr OutputAssertion `yaml:"stderr"`
}
OutputAssertions is the aggregate of stdout and stderr assertions.
type OutputMatcher ¶ added in v0.5.0
type OutputMatcher func(*OutputAssertion)
OutputMatcher is a function that configures an OutputAssertion. Use the constructor functions (Contains, Equals, Empty, etc.) to create matchers.
func Contains ¶ added in v0.5.0
func Contains(substrings ...string) OutputMatcher
Contains requires the output to contain all of the given substrings.
func ContainsAnyOf ¶ added in v0.5.0
func ContainsAnyOf(substrings ...string) OutputMatcher
ContainsAnyOf requires the output to contain at least one of the given substrings.
func ContainsExactLine ¶ added in v0.5.0
func ContainsExactLine(line string) OutputMatcher
ContainsExactLine requires at least one line to equal the given string exactly (after trimming).
func EndsWith ¶ added in v0.5.0
func EndsWith(suffix string) OutputMatcher
EndsWith requires the output to end with the given suffix (after trimming).
func Equals ¶ added in v0.5.0
func Equals(s string) OutputMatcher
Equals requires the output to equal the given string exactly (after trimming).
func HasLineCount ¶ added in v0.5.0
func HasLineCount(n int) OutputMatcher
HasLineCount requires the output to have exactly n non-empty lines.
func HasLineCountAtLeast ¶ added in v0.5.0
func HasLineCountAtLeast(n int) OutputMatcher
HasLineCountAtLeast requires the output to have at least n non-empty lines.
func Matches ¶ added in v0.5.0
func Matches(re string) OutputMatcher
Matches requires the entire trimmed output to match the given regular expression.
func NotContains ¶ added in v0.5.0
func NotContains(substrings ...string) OutputMatcher
NotContains requires the output to contain none of the given substrings.
func NotMatches ¶ added in v0.5.0
func NotMatches(re string) OutputMatcher
NotMatches requires the entire trimmed output NOT to match the given regular expression.
func StartsWith ¶ added in v0.5.0
func StartsWith(prefix string) OutputMatcher
StartsWith requires the output to start with the given prefix (after trimming).
type PlanBuilder ¶ added in v0.5.0
type PlanBuilder struct {
// contains filtered or unexported fields
}
PlanBuilder is a fluent builder for TestPlan.
func (*PlanBuilder) Build ¶ added in v0.5.0
func (b *PlanBuilder) Build() TestPlan
Build returns the constructed TestPlan value.
func (*PlanBuilder) Setup ¶ added in v0.5.0
func (b *PlanBuilder) Setup(cmds ...Command) *PlanBuilder
Setup appends plan-level setup commands.
func (*PlanBuilder) Spec ¶ added in v0.5.0
func (b *PlanBuilder) Spec(name string, spec interface{}) *PlanBuilder
Spec adds a spec to the plan under the given name. The spec argument may be a *SpecBuilder (Build() is called automatically) or a Spec value directly.
func (*PlanBuilder) Teardown ¶ added in v0.5.0
func (b *PlanBuilder) Teardown(cmds ...Command) *PlanBuilder
Teardown appends plan-level teardown commands.
func (*PlanBuilder) Var ¶ added in v0.5.0
func (b *PlanBuilder) Var(key, value string) *PlanBuilder
Var sets a plan-level variable.
type Preconditions ¶
type Preconditions struct {
FileSystemAssertions []FileSystemAssertion `yaml:"fs"`
}
Preconditions represents the minimal requirements for a plan or a single spec to start.
type ReportBlock ¶
type ReportBlock struct {
// contains filtered or unexported fields
}
ReportBlock is an aggregate of report entries classified on the phase.
func (*ReportBlock) Duration ¶ added in v0.4.0
func (r *ReportBlock) Duration() time.Duration
Duration returns how long this block took to execute.
func (*ReportBlock) Entries ¶
func (r *ReportBlock) Entries() []ReportEntry
Entries returns the entries of a block.
func (*ReportBlock) Failed ¶ added in v0.5.0
func (r *ReportBlock) Failed() bool
Failed returns true if this block contains at least one error or timeout entry.
func (*ReportBlock) Index ¶ added in v0.4.0
func (r *ReportBlock) Index() int
Index returns the 1-based ordinal of this spec in the execution order (0 for non-spec blocks).
func (*ReportBlock) Phase ¶
func (r *ReportBlock) Phase() string
Phase returns the phase of a block.
func (*ReportBlock) Skipped ¶ added in v0.5.0
func (r *ReportBlock) Skipped() bool
Skipped returns true if this spec block was skipped (by skip field, skip_if, or tag filter).
func (*ReportBlock) StartedAt ¶ added in v0.4.0
func (r *ReportBlock) StartedAt() time.Time
StartedAt returns when execution of this block started.
func (*ReportBlock) TimedOut ¶ added in v0.5.0
func (r *ReportBlock) TimedOut() bool
TimedOut returns true if the command in this block exceeded its configured timeout.
func (*ReportBlock) Total ¶ added in v0.4.0
func (r *ReportBlock) Total() int
Total returns the total number of specs in the plan (0 for non-spec blocks).
type ReportEntry ¶
type ReportEntry struct {
// contains filtered or unexported fields
}
ReportEntry is a single unit of information in a report.
func (*ReportEntry) Description ¶
func (r *ReportEntry) Description() string
Description is the textual representation of a report entry.
func (*ReportEntry) Errors ¶
func (r *ReportEntry) Errors() []error
Errors returns the errors list in a report entry.
func (*ReportEntry) Kind ¶
func (r *ReportEntry) Kind() ReportEntryType
Kind returns the type of a report entry: error, info, success, skipped...
type ReportEntryType ¶
type ReportEntryType int8
ReportEntryType represents the type of a report entry.
const ( // ErrorType is report entry error ErrorType ReportEntryType // InfoType is report entry info InfoType // SuccessType is report entry success SuccessType // SkippedType means the spec was not executed because preconditions were not met SkippedType // TimedOutType means the command exceeded its configured timeout TimedOutType )
func (ReportEntryType) String ¶ added in v0.5.0
func (t ReportEntryType) String() string
String returns a human-readable name for the entry type.
type Reporter ¶
type Reporter interface {
Publish(report *TestExecutionReport) error
}
Reporter is the interface for components publishing the report.
func NewConsoleReporter ¶
func NewConsoleReporter() Reporter
NewConsoleReporter returns a Reporter implementation writing to the stdout.
func NewTestLogsReporter ¶
NewTestLogsReporter returns a Reporter implementation using the testing log.
type RunOption ¶ added in v0.5.0
type RunOption func(*runConfig)
RunOption configures a single Execute or ExecuteFile call.
func FailFast ¶ added in v0.5.0
func FailFast() RunOption
FailFast stops execution after the first spec failure. Subsequent specs are not run; plan-level teardown still executes.
type SkipCondition ¶ added in v0.5.0
type SkipCondition struct {
// EnvSet skips the spec when the named environment variable is defined (regardless of its value).
EnvSet string `yaml:"env_set"`
// EnvValue skips the spec when any named variable equals its specified value.
EnvValue map[string]string `yaml:"env_value"`
}
SkipCondition holds the conditions under which a spec is skipped.
type Spec ¶
type Spec struct {
Description string `yaml:"description"`
Tags []string `yaml:"tags"`
Skip bool `yaml:"skip"`
SkipIf SkipCondition `yaml:"skip_if"`
// Retries is the number of additional attempts after the first failure.
// Zero (default) means no retry.
Retries int `yaml:"retries"`
RetryDelay string `yaml:"retry_delay"`
Setup []Command `yaml:"setup"`
Teardown []Command `yaml:"teardown"`
Preconditions Preconditions `yaml:"preconditions"`
Command Command `yaml:"command"`
Expectations Expectations `yaml:"expectations"`
// contains filtered or unexported fields
}
Spec is the single test.
type SpecBuilder ¶ added in v0.5.0
type SpecBuilder struct {
// contains filtered or unexported fields
}
SpecBuilder is a fluent builder for Spec.
func (*SpecBuilder) Build ¶ added in v0.5.0
func (b *SpecBuilder) Build() Spec
Build returns the constructed Spec value.
func (*SpecBuilder) Command ¶ added in v0.5.0
func (b *SpecBuilder) Command(cmd Command) *SpecBuilder
Command sets the command under test.
func (*SpecBuilder) Description ¶ added in v0.5.0
func (b *SpecBuilder) Description(d string) *SpecBuilder
Description sets the human-readable description for the spec.
func (*SpecBuilder) ExpectStatus ¶ added in v0.5.0
func (b *SpecBuilder) ExpectStatus(code int) *SpecBuilder
ExpectStatus asserts the command exits with the given status code.
func (*SpecBuilder) ExpectStatusGT ¶ added in v0.5.0
func (b *SpecBuilder) ExpectStatusGT(n int) *SpecBuilder
ExpectStatusGT asserts the exit status is greater than n.
func (*SpecBuilder) ExpectStatusLT ¶ added in v0.5.0
func (b *SpecBuilder) ExpectStatusLT(n int) *SpecBuilder
ExpectStatusLT asserts the exit status is less than n.
func (*SpecBuilder) ExpectStderr ¶ added in v0.5.0
func (b *SpecBuilder) ExpectStderr(matchers ...OutputMatcher) *SpecBuilder
ExpectStderr adds one or more matchers on the command's standard error.
func (*SpecBuilder) ExpectStdout ¶ added in v0.5.0
func (b *SpecBuilder) ExpectStdout(matchers ...OutputMatcher) *SpecBuilder
ExpectStdout adds one or more matchers on the command's standard output.
func (*SpecBuilder) Retries ¶ added in v0.5.0
func (b *SpecBuilder) Retries(n int) *SpecBuilder
Retries sets the number of additional attempts after the first failure.
func (*SpecBuilder) RetryDelay ¶ added in v0.5.0
func (b *SpecBuilder) RetryDelay(d string) *SpecBuilder
RetryDelay sets the delay between retries (e.g. "1s", "500ms").
func (*SpecBuilder) Setup ¶ added in v0.5.0
func (b *SpecBuilder) Setup(cmds ...Command) *SpecBuilder
Setup appends setup commands that run before this spec.
func (*SpecBuilder) Skip ¶ added in v0.5.0
func (b *SpecBuilder) Skip() *SpecBuilder
Skip marks this spec so it is always skipped.
func (*SpecBuilder) Tags ¶ added in v0.5.0
func (b *SpecBuilder) Tags(tags ...string) *SpecBuilder
Tags sets the tags for the spec.
func (*SpecBuilder) Teardown ¶ added in v0.5.0
func (b *SpecBuilder) Teardown(cmds ...Command) *SpecBuilder
Teardown appends teardown commands that run after this spec.
type StatusAssertion ¶
type StatusAssertion struct {
EqualsTo *int `yaml:"equals_to"`
GreaterThan *int `yaml:"greater_than"`
LessThan *int `yaml:"less_than"`
}
StatusAssertion represents an assertion on the status code returned from a command.
type TestExecutionReport ¶
type TestExecutionReport struct {
// contains filtered or unexported fields
}
TestExecutionReport is the full report on a test execution
func (*TestExecutionReport) AllErrors ¶
func (r *TestExecutionReport) AllErrors() []error
AllErrors returns all errors in a report, without considering blocks or phases.
func (*TestExecutionReport) Blocks ¶
func (r *TestExecutionReport) Blocks() []*ReportBlock
Blocks returns the blocks list in a full report.
func (*TestExecutionReport) FailWith ¶ added in v0.5.0
func (r *TestExecutionReport) FailWith(t *testing.T)
FailWith calls t.Errorf for every error in the report, prefixed with the block phase so failures are easy to locate. It is the idiomatic one-liner to fail a Go test when a qac plan has errors:
report.FailWith(t)
func (*TestExecutionReport) FailedSpecs ¶ added in v0.5.0
func (r *TestExecutionReport) FailedSpecs() []string
FailedSpecs returns the phase names of spec blocks that failed.
func (*TestExecutionReport) Success ¶ added in v0.5.0
func (r *TestExecutionReport) Success() bool
Success returns true when no block recorded an error or timeout.
func (*TestExecutionReport) Summary ¶ added in v0.5.0
func (r *TestExecutionReport) Summary() string
Summary returns a one-line human-readable description of the execution result, e.g. "3/5 specs passed" or "5/5 specs passed (2 skipped)".
type TestPlan ¶
type TestPlan struct {
Include []string `yaml:"include"`
Vars map[string]string `yaml:"vars"`
Setup []Command `yaml:"setup"`
Teardown []Command `yaml:"teardown"`
Preconditions Preconditions `yaml:"preconditions"`
Specs map[string]Spec `yaml:"specs"`
// contains filtered or unexported fields
}
TestPlan represents the full set of tests on a program.