qaparser

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeCompress

func DeCompress(tarFile, dest string) error

解压 tar.gz

func NewStatuses

func NewStatuses(pass, skip, failed, err int) map[apistructs.TestStatus]int

func ParseInt

func ParseInt(i interface{}) (int, error)

func Register

func Register(p Parser, types ...types.TestParserType) error

Types

type Manager

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

func GetManager

func GetManager() *Manager

func (*Manager) GetParser

func (m *Manager) GetParser(t types.TestParserType) Parser

type Parser

type Parser interface {
	Parse(endpoint, ak, sk, bucket, objectName string) ([]*apistructs.TestSuite, error)
	Register()
}

type Suite

type Suite struct {
	*apistructs.TestSuite
}

func (*Suite) Aggregate

func (s *Suite) Aggregate()

Aggregate calculates result sums across all tests.

type Totals

type Totals struct {
	*apistructs.TestTotals
}

func (*Totals) Add

func (t *Totals) Add(total *apistructs.TestTotals) *Totals

func (*Totals) SetStatuses

func (t *Totals) SetStatuses(statuses map[apistructs.TestStatus]int) *Totals

type XmlNode

type XmlNode struct {
	XMLName xml.Name
	Attrs   map[string]string `xml:"-"`
	Content []byte            `xml:",innerxml"`
	Nodes   []XmlNode         `xml:",any"`
}

func NodeParse

func NodeParse(data []byte) ([]XmlNode, error)

parse unmarshalls the given XML data into a graph of nodes, and then returns a slice of all top-level nodes.

func (*XmlNode) Attr

func (n *XmlNode) Attr(name string) string

func (*XmlNode) UnmarshalXML

func (n *XmlNode) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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