Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Property ¶ added in v1.20.0
type Property struct { Name string `xml:"name,attr"` Value interface{} `xml:"value,attr"` }
Preperty is a named property that will be formatted as an XML tag.
type Result ¶ added in v1.20.0
type Result struct { XMLName xml.Name Type string `xml:"type,attr"` Message string `xml:",innerxml"` }
Result represents the final state of the test case.
type TestCase ¶
type TestCase struct { Name string `xml:"name,attr"` Time time.Time `xml:"time,attr"` SystemOut string `xml:"system-out"` Result *Result `xml:",omitempty"` }
TestCase contains information about an individual test case.
type TestSuite ¶
type TestSuite struct { Name string `xml:"name,attr"` Properties struct { Properties []Property `xml:"property"` } `xml:"properties,omitempty"` TestCases []TestCase `xml:"testcase,omitempty"` Tests int `xml:"tests,attr"` Skipped int `xml:"skipped,attr"` Failures int `xml:"failures,attr"` Errors int `xml:"errors,attr"` }
TestSuite contains for details about a test beyond the final status
func (*TestSuite) AddFailure ¶ added in v1.20.0
AddFailure adds a failed test case to the suite.
func (*TestSuite) AddProperty ¶ added in v1.20.0
AddProperty adds the property key/value to the test suite.
type TestSuites ¶
type TestSuites struct { XMLName xml.Name `xml:"testsuites"` // Component name: <testsuites> Name string `xml:"name,attr"` TestSuites []TestSuite `xml:"testsuite"` }
TestSuites is the top level object for amassing Xunit test results
func NewTestSuites ¶ added in v1.20.0
func NewTestSuites(name string, testSuites []TestSuite) TestSuites
NewTestSuites returns a new XUnit result from the given test suites.
Click to show internal directories.
Click to hide internal directories.