Help us shape the future of Go! Take the 2026 Go Developer Survey

streamer

package
v0.1.104 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2026 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CSVStreamer

type CSVStreamer struct {
	// contains filtered or unexported fields
}

func NewCSVStreamer

func NewCSVStreamer(writer io.Writer, quiet bool) *CSVStreamer

func (*CSVStreamer) StreamFinalSummary

func (c *CSVStreamer) StreamFinalSummary(summaries []TestSummary) error

func (*CSVStreamer) StreamSummary

func (c *CSVStreamer) StreamSummary(summary TestSummary) error

func (*CSVStreamer) StreamTestExecution

func (c *CSVStreamer) StreamTestExecution(exec TestExecution) error

type CompactStreamer

type CompactStreamer struct {
	// contains filtered or unexported fields
}

func NewCompactStreamer

func NewCompactStreamer(writer io.Writer, quiet bool) *CompactStreamer

func (*CompactStreamer) StreamFinalSummary

func (c *CompactStreamer) StreamFinalSummary(summaries []TestSummary) error

func (*CompactStreamer) StreamSummary

func (c *CompactStreamer) StreamSummary(summary TestSummary) error

func (*CompactStreamer) StreamTestExecution

func (c *CompactStreamer) StreamTestExecution(exec TestExecution) error

type HTMLStreamer

type HTMLStreamer struct {
	// contains filtered or unexported fields
}

func NewHTMLStreamer

func NewHTMLStreamer(writer io.Writer, quiet bool) *HTMLStreamer

func (*HTMLStreamer) StreamFinalSummary

func (h *HTMLStreamer) StreamFinalSummary(summaries []TestSummary) error

func (*HTMLStreamer) StreamSummary

func (h *HTMLStreamer) StreamSummary(summary TestSummary) error

func (*HTMLStreamer) StreamTestExecution

func (h *HTMLStreamer) StreamTestExecution(exec TestExecution) error

type JSONStreamer

type JSONStreamer struct {
	// contains filtered or unexported fields
}

func NewJSONStreamer

func NewJSONStreamer(writer io.Writer) *JSONStreamer

func (*JSONStreamer) StreamFinalSummary

func (j *JSONStreamer) StreamFinalSummary(summaries []TestSummary) error

func (*JSONStreamer) StreamSummary

func (j *JSONStreamer) StreamSummary(summary TestSummary) error

func (*JSONStreamer) StreamTestExecution

func (j *JSONStreamer) StreamTestExecution(exec TestExecution) error

type MarkdownStreamer

type MarkdownStreamer struct {
	// contains filtered or unexported fields
}

func NewMarkdownStreamer

func NewMarkdownStreamer(writer io.Writer, quiet bool) *MarkdownStreamer

func (*MarkdownStreamer) StreamFinalSummary

func (m *MarkdownStreamer) StreamFinalSummary(summaries []TestSummary) error

func (*MarkdownStreamer) StreamSummary

func (m *MarkdownStreamer) StreamSummary(summary TestSummary) error

func (*MarkdownStreamer) StreamTestExecution

func (m *MarkdownStreamer) StreamTestExecution(exec TestExecution) error

type OutputStreamer

type OutputStreamer interface {
	StreamTestExecution(exec TestExecution) error
	StreamSummary(summary TestSummary) error
	StreamFinalSummary(summaries []TestSummary) error
}

type TestExecution

type TestExecution struct {
	TestName  string        `json:"test_name"`
	Method    string        `json:"method"`
	Args      []any         `json:"args"`
	Result    any           `json:"result,omitempty"`
	Error     string        `json:"error,omitempty"`
	Status    string        `json:"status"` // "pass" or "fail"
	Duration  time.Duration `json:"duration"`
	Timestamp time.Time     `json:"timestamp"`
}

Individual test execution result - streamed immediately

type TestSummary

type TestSummary struct {
	TestName      string        `json:"test_name"`
	Method        string        `json:"method"`
	TestsRan      int           `json:"tests_ran"`
	TestsPassed   int           `json:"tests_passed"`
	TestsFailed   int           `json:"tests_failed"`
	SuccessRate   float64       `json:"success_rate"`
	TotalDuration time.Duration `json:"total_duration"`
}

Summary stats - no individual data stored

Jump to

Keyboard shortcuts

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