Documentation
¶
Overview ¶
Package allure provides allure formatter for godog.
Index ¶
Constants ¶
const ( Broken = Status("broken") Passed = Status("passed") Failed = Status("failed") Skipped = Status("skipped") Unknown = Status("unknown") )
Available statuses.
Variables ¶
This section is empty.
Functions ¶
func RegisterFormatter ¶
func RegisterFormatter()
RegisterFormatter adds allure to available formatters.
Types ¶
type Attachment ¶
type Attachment struct {
Name string `json:"name"`
Source string `json:"source"`
Type string `json:"type"`
}
Attachment can be attached.
func NewAttachment ¶
func NewAttachment(name string, mimeType string, resultsPath string, content []byte) (*Attachment, error)
NewAttachment creates and stores attachment.
type Container ¶
type Container struct {
UUID string `json:"uuid,omitempty"`
Name string `json:"name"`
Children []string `json:"children"`
Start TimestampMs `json:"start,omitempty"`
Stop TimestampMs `json:"stop,omitempty"`
}
Container lists all results.
type Executor ¶
type Executor struct {
Name string `json:"name,omitempty" example:"Jenkins"`
// Type may be one of [github, gitlab, teamcity, bamboo, jenkins] or a custom one.
Type string `json:"type,omitempty" example:"jenkins"`
URL string `json:"url,omitempty" example:"url"`
BuildOrder int `json:"buildOrder,omitempty" example:"13"`
BuildName string `json:"buildName,omitempty" example:"allure-report_deploy#13"`
BuildURL string `json:"buildUrl,omitempty" example:"http://example.org/build#13"`
ReportURL string `json:"reportUrl,omitempty" example:"http://example.org/build#13/AllureReport"`
ReportName string `json:"reportName,omitempty" example:"Demo allure report"`
}
Executor describes execution context.
type Link ¶
type Link struct {
Name string `json:"name,omitempty"`
Type LinkType `json:"type,omitempty"`
URL string `json:"url,omitempty"`
}
Link references additional resources.
type Result ¶
type Result struct {
UUID string `json:"uuid,omitempty"`
HistoryID string `json:"historyId,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
Status Status `json:"status,omitempty"`
StatusDetails *StatusDetails `json:"statusDetails,omitempty"`
Stage string `json:"stage,omitempty"` // "finished"
Steps []Step `json:"steps,omitempty"`
Attachments []Attachment `json:"attachments,omitempty"`
Parameters []Parameter `json:"parameters,omitempty"`
Start TimestampMs `json:"start,omitempty"`
Stop TimestampMs `json:"stop,omitempty"`
Children []string `json:"children,omitempty"`
FullName string `json:"fullName,omitempty"`
Labels []Label `json:"labels,omitempty"`
Links []Link `json:"links,omitempty"`
}
Result is the top level report object for a test.
18 known properties: "start", "descriptionHtml", "parameters", "name", "historyId", "statusDetails", "status", "links", "fullName", "uuid", "description", "testCaseId", "stage", "labels", "stop", "steps", "rerunOf", "attachments".
type StatusDetails ¶
type StatusDetails struct {
Known bool `json:"known,omitempty"`
Muted bool `json:"muted,omitempty"`
Flaky bool `json:"flaky,omitempty"`
Message string `json:"message,omitempty"`
Trace string `json:"trace,omitempty"`
}
StatusDetails provides additional information on status.
type Step ¶
type Step struct {
Name string `json:"name,omitempty"`
Status Status `json:"status,omitempty"`
StatusDetails *StatusDetails `json:"statusDetails,omitempty"`
Stage string `json:"stage"`
ChildrenSteps []Step `json:"steps"`
Attachments []Attachment `json:"attachments"`
Parameters []Parameter `json:"parameters"`
Start TimestampMs `json:"start"`
Stop TimestampMs `json:"stop"`
}
Step is a part of scenario result.