printer

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2023 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ColorFatal   = color.New(color.FgRed, color.Bold)
	ColorFailure = color.New(color.FgRed, color.Bold)
	ColorWarning = color.New(color.FgYellow, color.Bold)
	ColorSuccess = color.New()
	ColorStart   = color.New()
	ColorRunning = color.New(color.Faint)
	ColorLog     = color.New(color.Faint)
	Colors       = func(v string) *color.Color {
		switch v {
		case "pass":
			return ColorSuccess
		case "inconc":
			return ColorWarning
		case "none":
			return ColorWarning
		case "done":
			return color.New()
		default:
			return ColorFailure
		}
	}

	ErrCommandFailed = fmt.Errorf("command failed")
)

Functions

This section is empty.

Types

type ConsolePrinter

type ConsolePrinter struct {
}

func NewConsolePrinter

func NewConsolePrinter() *ConsolePrinter

func (*ConsolePrinter) Print

func (p *ConsolePrinter) Print(ev control.Event)

type JSONPrinter

type JSONPrinter struct {
}

func NewJSONPrinter

func NewJSONPrinter() *JSONPrinter

func (*JSONPrinter) Print

func (p *JSONPrinter) Print(ev control.Event)

type PlainPrinter

type PlainPrinter struct{}

func NewPlainPrinter

func NewPlainPrinter() *PlainPrinter

func (*PlainPrinter) Print

func (p *PlainPrinter) Print(ev control.Event)

type Printer

type Printer interface {
	Print(ev control.Event)
}

type TAPPrinter

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

func NewTAPPrinter

func NewTAPPrinter() *TAPPrinter

func (*TAPPrinter) Close

func (p *TAPPrinter) Close() error

func (*TAPPrinter) Print

func (p *TAPPrinter) Print(ev control.Event)

Jump to

Keyboard shortcuts

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