Documentation
¶
Overview ¶
Package tap13 implements a parser for the Test Anything Protocol (TAP) version 13 specification.
The full protocol specification can be found at the following URL:
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Results ¶
type Results struct {
ExpectedTests int
TotalTests int
PassedTests int
FailedTests int
SkippedTests int
TodoTests int
TapVersion int
BailOut bool
BailOutReason string
FoundTapData bool
Tests []Test
Lines []string
Explanation []string
}
Results encapsulates the result of the entire test run. If a plan was given in the input TAP, the ExpectedTests will be greater than or equal to zero. The input lines are preserved in the Lines field. Any diagnostics given before the output of a test run is preserved in the Explanation. The Tests field contains a Test struct for each test that was run, in the order that it appeared in the TAP output.
func Parse ¶
Parse interprets the specified lines as output lines from a program that generate TAP output, and returns a corresponding Results structure containing the test results based on its interpretation.
type Test ¶
type Test struct {
TestNumber int
Passed bool
Failed bool
Skipped bool
Todo bool
Description string
DirectiveText string
Diagnostics []string
YamlBytes []byte
}
Test encapsulates the result of a specific test, including a description and diagnostics (if supplied). The TestNumber field is undefined if the TAP output does not include test numbers. Diagnostics are supplied with trimmed whitespace, and blank lines removed.