Presubmit.Runner.Report (presubmit v0.2.2)

Copy Markdown View Source

Every rule's outcome for one change set.

Summary

Functions

Counts of results by kind.

:pass when no rule failed or errored, :error when any rule crashed, else :fail.

Whether any rule warned.

Types

t()

@type t() :: %Presubmit.Runner.Report{
  commit: Presubmit.Commit.t(),
  results: [Presubmit.Runner.Result.t()]
}

Functions

counts(report)

@spec counts(t()) :: %{
  pass: non_neg_integer(),
  fail: non_neg_integer(),
  warn: non_neg_integer(),
  skip: non_neg_integer(),
  error: non_neg_integer()
}

Counts of results by kind.

status(report)

@spec status(t()) :: :pass | :fail | :error

:pass when no rule failed or errored, :error when any rule crashed, else :fail.

warnings?(report)

@spec warnings?(t()) :: boolean()

Whether any rule warned.