results

package
v1.0.0-beta Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NoMetrics = Metrics{}

Functions

This section is empty.

Types

type Metrics

type Metrics struct {
	TestCase     *model.TestCase `json:"-"`
	ResponseTime time.Duration   `json:"response_time"` // Http Response Time
	ResponseSize int             `json:"response_size"` // Size of the HTTP Response body
}

func NewMetrics

func NewMetrics(testCase *model.TestCase, responseTime time.Duration, responseSize int) Metrics

func NewMetricsFromRestyResponse

func NewMetricsFromRestyResponse(testCase *model.TestCase, response *resty.Response) Metrics

type TestCase

type TestCase struct {
	Id      string  `json:"id"`
	Pass    bool    `json:"pass"`
	Metrics Metrics `json:"metrics"`
	Fail    string  `json:"fail,omitempty"`
}

TestCase result for a run

func NewTestCaseFail

func NewTestCaseFail(id string, metrics Metrics, err error) TestCase

NewTestCaseFail returns a failed test

func NewTestCaseResult

func NewTestCaseResult(id string, pass bool, metrics Metrics, err error) TestCase

NewTestCaseResult return a new TestCase instance

Jump to

Keyboard shortcuts

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