Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Kind represents the type definition of this config. Kind = "playwright-cucumberjs" // APIVersion represents the supported config version. APIVersion = "v1alpha" )
Config descriptors.
Functions ¶
func FilterSuites ¶
FilterSuites filters out suites in the project that don't match the given suite name.
func SetDefaults ¶
func SetDefaults(p *Project)
SetDefaults applies config defaults in case the user has left them blank.
Types ¶
type Options ¶
type Options struct { Config string `yaml:"config,omitempty" json:"config"` // Name is a regular expression for selecting scenario names. Name string `yaml:"name,omitempty" json:"name"` Paths []string `yaml:"paths,omitempty" json:"paths"` ExcludedTestFiles []string `yaml:"excludedTestFiles,omitempty" json:"excludedTestFiles"` Backtrace bool `yaml:"backtrace,omitempty" json:"backtrace"` Require []string `yaml:"require,omitempty" json:"require"` Import []string `yaml:"import,omitempty" json:"import"` Tags []string `yaml:"tags,omitempty" json:"tags"` Format []string `yaml:"format,omitempty" json:"format"` FormatOptions map[string]string `yaml:"formatOptions,omitempty" json:"formatOptions"` Parallel int `yaml:"parallel,omitempty" json:"parallel"` }
Options represents cucumber settings
type Playwright ¶
type Playwright struct { // Version represents the playwright framework version. Version string `yaml:"version,omitempty" json:"version"` }
Playwright represents the playwright setting
type Project ¶
type Project struct { config.TypeDef `yaml:",inline" mapstructure:",squash"` DryRun bool `yaml:"-" json:"-"` ShowConsoleLog bool `yaml:"showConsoleLog" json:"-"` ConfigFilePath string `yaml:"-" json:"-"` CLIFlags map[string]interface{} `yaml:"-" json:"-"` Sauce config.SauceConfig `yaml:"sauce,omitempty" json:"sauce"` // 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"` BeforeExec []string `yaml:"beforeExec,omitempty" json:"beforeExec"` Playwright Playwright `yaml:"playwright,omitempty" json:"playwright"` Npm config.Npm `yaml:"npm,omitempty" json:"npm"` RootDir string `yaml:"rootDir,omitempty" json:"rootDir"` RunnerVersion string `yaml:"runnerVersion,omitempty" json:"runnerVersion"` Artifacts config.Artifacts `yaml:"artifacts,omitempty" json:"artifacts"` Reporters config.Reporters `yaml:"reporters,omitempty" json:"-"` Defaults config.Defaults `yaml:"defaults,omitempty" json:"defaults"` Env map[string]string `yaml:"env,omitempty" json:"env"` Notifications config.Notifications `yaml:"notifications,omitempty" json:"-"` }
Project represents cucumber sauce config
func (*Project) FilterFailedTests ¶ added in v0.138.0
func (p *Project) FilterFailedTests(suiteName string, report saucereport.SauceReport) error
FilterFailedTests takes the failed specs in the report and sets them as a test filter in the suite. The test filter remains unchanged if the report does not contain any failed tests.
type Suite ¶
type Suite struct { Name string `yaml:"name,omitempty" json:"name"` BrowserName string `yaml:"browserName,omitempty" json:"browserName"` BrowserVersion string `yaml:"browserVersion,omitempty" json:"browserVersion"` PlatformName string `yaml:"platformName,omitempty" json:"platformName"` Env map[string]string `yaml:"env,omitempty" json:"env"` Shard string `yaml:"shard,omitempty" json:"shard"` Mode string `yaml:"mode,omitemty" json:"mode"` Timeout time.Duration `yaml:"timeout,omitempty" json:"timeout"` ScreenResolution string `yaml:"screenResolution,omitempty" json:"screenResolution"` PreExec []string `yaml:"preExec,omitempty" json:"preExec"` Options Options `yaml:"options,omitempty" json:"options"` PassThreshold int `yaml:"passThreshold,omitempty" json:"-"` SmartRetry config.SmartRetry `yaml:"smartRetry,omitempty" json:"-"` }
Suite represents the playwright-cucumberjs test suite configuration.
func SortByHistory ¶
func SortByHistory(suites []Suite, history insights.JobHistory) []Suite
SortByHistory sorts the suites in the order of job history
Click to show internal directories.
Click to hide internal directories.