sequence

package
v0.0.14 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package sequence provides the sequencer that runs tests from a YAML description.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Monitor     bool           `yaml:"monitor"`
	Common      []KeyValuePair `yaml:"common"`
	Definitions []Definition   `yaml:"definitions"`
	Executions  []string       `yaml:"executions"`
}

Config is the overall representation of the complete YAML document

func (*Config) Validate

func (c *Config) Validate() error

Validate validates the sequence

type Definition

type Definition struct {
	Name       string         `yaml:"name"`
	RunnerType string         `yaml:"type"`
	BHCA       int            `yaml:"bhca"`
	Max        int            `yaml:"max"`
	Iterations int            `yaml:"iterations"`
	Test       string         `yaml:"test"`
	Next       []string       `yaml:"next"`
	Params     []KeyValuePair `yaml:"params"`
	Reports    Reports        `yaml:"reports"`
}

Definition represents the runner definitions within the YAML

type KeyValuePair

type KeyValuePair struct {
	Key   string      `yaml:"key"`
	Value interface{} `yanml:"value"`
}

KeyValuePair represents a key/value/env triplet in the YAML

type Reports

type Reports struct {
	CSV string `yaml:"csv"`
	TXT string `yaml:"txt"`
	SVG string `yaml:"svg"`
}

Reports represents the reports subsection of the YAML definition

type Sequence

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

Sequence is used to read and execute a YAML sequence

func NewSequence

func NewSequence(r io.Reader) (*Sequence, error)

NewSequence creates a new sequence from a reader

func NewSequenceFromFile

func NewSequenceFromFile(filename string) (*Sequence, error)

NewSequenceFromFile creates a new sequence from an OS file

func (*Sequence) Execute

func (s *Sequence) Execute()

Execute will execute the sequence

Jump to

Keyboard shortcuts

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