report

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 15, 2020 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Assert

type Assert struct {
	Index   int    `json:"index"`
	Passed  bool   `json:"passed"`
	Message string `json:"message"`
}

Assert contains the test result from an assert.

type Report

type Report struct {
	Chart   string `json:"chart"`
	Version string `json:"version"`
	Date    string `json:"date"`
	Score   Score  `json:"score"`
	Tests   []Test `json:"tests"`
}

Report contains the overall test report.

func NewReport

func NewReport() Report

NewReport returns a new instance of Report.

type Score

type Score struct {
	Passed  int `json:"passed"`
	Failed  int `json:"failed"`
	Skipped int `json:"skipped"`
	Total   int `json:"total"`
}

Score contains numeric results.

type Test

type Test struct {
	Name    string   `json:"name"`
	Summary string   `json:"summary"`
	Skipped bool     `json:"skipped"`
	Asserts []Assert `json:"asserts"`
	Score   Score    `json:"score"`
}

Test contains test information and results.

func NewTest

func NewTest() Test

NewTest returns a new instance of Test.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL