Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CancelAction ¶
func CancelAction() *github.CheckRunAction
CancelAction is an action that can be taken to cancel a pending check run.
func IgnoreAction ¶
func IgnoreAction() *github.CheckRunAction
IgnoreAction is an action that can be taken to ignore a fail outcome, marking it as passing.
func RecomputeAction ¶
func RecomputeAction() *github.CheckRunAction
RecomputeAction is an action that can be taken to trigger a recompute of the diff, against the latest master run's results.
Types ¶
type BeforeAndAfter ¶
type BeforeAndAfter map[string]TestBeforeAndAfter
BeforeAndAfter summarizes counts for pass/total before and after, across a particular path (could be a folder, could be a test).
func (BeforeAndAfter) Add ¶
func (bna BeforeAndAfter) Add(p string, before, after shared.TestSummary)
Add the given before/after counts to the totals.
type CheckState ¶
type CheckState struct { HostName string // The host (e.g. wpt.fyi) TestRun *shared.TestRun // The (completed) TestRun, if applicable. Product shared.ProductSpec HeadSHA string DetailsURL *url.URL // The current status. Can be one of "queued", "in_progress", or "completed". Default: "queued". (Optional.) Status string // Can be one of "success", "failure", "neutral", "cancelled", "timed_out", or "action_required". // (Optional. Required if you provide a status of "completed".) Conclusion *string Actions []github.CheckRunAction PRNumbers []int }
CheckState represents all the status fields for updating a check.
func (CheckState) FileIssueURL ¶
func (c CheckState) FileIssueURL() *url.URL
FileIssueURL returns a URL for filing an issue in wpt.fyi repo about checks.
func (CheckState) GetCheckState ¶
func (c CheckState) GetCheckState() CheckState
GetCheckState returns the info in the CheckState struct. It's a dumb placeholder since we can't define fields on interfaces.
func (CheckState) Name ¶
func (c CheckState) Name() string
Name returns the check run's name, based on the product.
func (CheckState) Title ¶
func (c CheckState) Title() string
Title returns the check run's title, based on the product.
type Completed ¶
type Completed struct { CheckState ResultsComparison Results BeforeAndAfter More int }
Completed is the struct for completed.md.
func (Completed) GetActions ¶
func (c Completed) GetActions() []*github.CheckRunAction
GetActions returns the actions that can be taken by the user.
func (Completed) GetCheckState ¶
func (c Completed) GetCheckState() CheckState
GetCheckState returns the info needed to update a check.
func (Completed) GetSummary ¶
GetSummary executes the template for the data.
type Pending ¶
type Pending struct { CheckState RunsURL string // URL for the list of test runs }
Pending is the struct for pending.md.
func (Pending) GetActions ¶
func (p Pending) GetActions() []*github.CheckRunAction
GetActions returns the actions that can be taken by the user.
func (Pending) GetCheckState ¶
func (p Pending) GetCheckState() CheckState
GetCheckState returns the info needed to update a check.
func (Pending) GetSummary ¶
GetSummary executes the template for the data.
type Regressed ¶
type Regressed struct { CheckState ResultsComparison Regressions BeforeAndAfter More int }
Regressed is the struct for regressed.md.
func (Regressed) GetActions ¶
func (r Regressed) GetActions() []*github.CheckRunAction
GetActions returns the actions that can be taken by the user.
func (Regressed) GetCheckState ¶
func (r Regressed) GetCheckState() CheckState
GetCheckState returns the info needed to update a check.
func (Regressed) GetSummary ¶
GetSummary executes the template for the data.
type ResultsComparison ¶
type ResultsComparison struct { BaseRun shared.TestRun HeadRun shared.TestRun MasterDiffURL string DiffURL string // URL for the diff-view of the results HostURL string // Host environment URL, e.g. "https://wpt.fyi" }
ResultsComparison is all the fields shared across summaries that involve a result comparison.
type Summary ¶
type Summary interface { // GetCheckState returns the info needed to update a check. GetCheckState() CheckState // GetActions returns the actions that can be taken by the user. GetActions() []*github.CheckRunAction // GetSummary compiles the summary markdown template. GetSummary() (string, error) }
Summary is the generic interface of a summary template data type.