xcuitest

package
v0.63.4 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Kind represents the type definition of this config.
	Kind = "xcuitest"

	// APIVersion represents the supported config version.
	APIVersion = "v1alpha"
)

Config descriptors.

Functions

func FilterSuites added in v0.53.0

func FilterSuites(p *Project, suiteName string) error

FilterSuites filters out suites in the project that don't match the given suite name.

func SetDefaults added in v0.51.1

func SetDefaults(p *Project)

SetDefaults applies config defaults in case the user has left them blank.

func Validate

func Validate(p Project) error

Validate validates basic configuration of the project and returns an error if any of the settings contain illegal values. This is not an exhaustive operation and further validation should be performed both in the client and/or server side depending on the workflow that is executed.

Types

type Project

type Project struct {
	config.TypeDef `yaml:",inline" mapstructure:",squash"`
	Defaults       config.Defaults        `yaml:"defaults,omitempty" json:"defaults"`
	ConfigFilePath string                 `yaml:"-" json:"-"`
	DryRun         bool                   `yaml:"-" json:"-"`
	CLIFlags       map[string]interface{} `yaml:"-" json:"-"`
	Sauce          config.SauceConfig     `yaml:"sauce,omitempty" json:"sauce"`
	Xcuitest       Xcuitest               `yaml:"xcuitest,omitempty" json:"xcuitest"`
	// Suite is only used as a workaround to parse adhoc suites that are created via CLI args.
	Suite     Suite            `yaml:"suite,omitempty" json:"-"`
	Suites    []Suite          `yaml:"suites,omitempty" json:"suites"`
	Artifacts config.Artifacts `yaml:"artifacts,omitempty" json:"artifacts"`
	Reporters config.Reporters `yaml:"reporters,omitempty" json:"-"`
}

Project represents the xcuitest project configuration.

func FromFile

func FromFile(cfgPath string) (Project, error)

FromFile creates a new xcuitest Project based on the filepath cfgPath.

type Suite

type Suite struct {
	Name        string          `yaml:"name,omitempty" json:"name"`
	Timeout     time.Duration   `yaml:"timeout,omitempty" json:"timeout"`
	Devices     []config.Device `yaml:"devices,omitempty" json:"devices"`
	TestOptions TestOptions     `yaml:"testOptions,omitempty" json:"testOptions"`
}

Suite represents the xcuitest test suite configuration.

type TestOptions

type TestOptions struct {
	NotClass []string `yaml:"notClass,omitempty" json:"notClass"`
	Class    []string `yaml:"class,omitempty" json:"class"`
}

TestOptions represents the xcuitest test filter options configuration.

type Xcuitest

type Xcuitest struct {
	App       string   `yaml:"app,omitempty" json:"app"`
	TestApp   string   `yaml:"testApp,omitempty" json:"testApp"`
	OtherApps []string `yaml:"otherApps,omitempty" json:"otherApps"`
}

Xcuitest represents xcuitest apps configuration.

Jump to

Keyboard shortcuts

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