reporters

package
v1.22.2 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2021 License: Apache-2.0 Imports: 13 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DetailsReporter added in v1.18.0

type DetailsReporter struct {
	Writer io.Writer
}

DetailsReporter is a ginkgo reporter which dumps information regarding the tests which is difficult to get via an AST app. This allows us to leverage the existing ginkgo logic to walk the tests and such while then following up with an custom app which leverages AST to generate conformance documentation.

func NewDetailsReporterFile added in v1.18.0

func NewDetailsReporterFile(filename string) *DetailsReporter

NewDetailsReporterFile returns a reporter which will create the file given and dump the specs to it as they complete.

func NewDetailsReporterWithWriter added in v1.18.0

func NewDetailsReporterWithWriter(w io.Writer) *DetailsReporter

NewDetailsReporterWithWriter returns a reporter which will write the SpecSummary objects as tests complete to the given writer.

func (*DetailsReporter) AfterSuiteDidRun added in v1.18.0

func (reporter *DetailsReporter) AfterSuiteDidRun(setupSummary *types.SetupSummary)

AfterSuiteDidRun is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*DetailsReporter) BeforeSuiteDidRun added in v1.18.0

func (reporter *DetailsReporter) BeforeSuiteDidRun(setupSummary *types.SetupSummary)

BeforeSuiteDidRun is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*DetailsReporter) SpecDidComplete added in v1.18.0

func (reporter *DetailsReporter) SpecDidComplete(specSummary *types.SpecSummary)

SpecDidComplete is invoked by Ginkgo each time a spec is completed (including skipped specs).

func (*DetailsReporter) SpecSuiteDidEnd added in v1.18.0

func (reporter *DetailsReporter) SpecSuiteDidEnd(summary *types.SuiteSummary)

SpecSuiteDidEnd is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*DetailsReporter) SpecSuiteWillBegin added in v1.18.0

func (reporter *DetailsReporter) SpecSuiteWillBegin(cfg config.GinkgoConfigType, summary *types.SuiteSummary)

SpecSuiteWillBegin is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*DetailsReporter) SpecWillRun added in v1.18.0

func (reporter *DetailsReporter) SpecWillRun(specSummary *types.SpecSummary)

SpecWillRun is implemented as a noop to satisfy the reporter interface for ginkgo.

type ProgressReporter

type ProgressReporter struct {
	LastMsg string `json:"msg"`

	TestsTotal     int `json:"total"`
	TestsCompleted int `json:"completed"`
	TestsSkipped   int `json:"skipped"`
	TestsFailed    int `json:"failed"`

	Failures []string `json:"failures,omitempty"`
	// contains filtered or unexported fields
}

ProgressReporter is a ginkgo reporter which tracks the total number of tests to be run/passed/failed/skipped. As new tests are completed it updates the values and prints them to stdout and optionally, sends the updates to the configured URL.

func NewProgressReporter

func NewProgressReporter(progressReportURL string) *ProgressReporter

NewProgressReporter returns a progress reporter which posts updates to the given URL.

func (*ProgressReporter) AfterSuiteDidRun

func (reporter *ProgressReporter) AfterSuiteDidRun(setupSummary *types.SetupSummary)

AfterSuiteDidRun is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*ProgressReporter) BeforeSuiteDidRun

func (reporter *ProgressReporter) BeforeSuiteDidRun(setupSummary *types.SetupSummary)

BeforeSuiteDidRun is implemented as a noop to satisfy the reporter interface for ginkgo.

func (*ProgressReporter) SpecDidComplete

func (reporter *ProgressReporter) SpecDidComplete(specSummary *types.SpecSummary)

SpecDidComplete is invoked by Ginkgo each time a spec is completed (including skipped specs).

func (*ProgressReporter) SpecSuiteDidEnd

func (reporter *ProgressReporter) SpecSuiteDidEnd(summary *types.SuiteSummary)

SpecSuiteDidEnd is the last method invoked by Ginkgo after all the specs are run.

func (*ProgressReporter) SpecSuiteWillBegin

func (reporter *ProgressReporter) SpecSuiteWillBegin(cfg config.GinkgoConfigType, summary *types.SuiteSummary)

SpecSuiteWillBegin is invoked by ginkgo when the suite is about to start and is the first point in which we can antipate the number of tests which will be run.

func (*ProgressReporter) SpecWillRun

func (reporter *ProgressReporter) SpecWillRun(specSummary *types.SpecSummary)

SpecWillRun is implemented as a noop to satisfy the reporter interface for ginkgo.

Jump to

Keyboard shortcuts

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