# `Mutare.Result`
[🔗](https://github.com/foxbenjaminfox/mutare/blob/v0.2.1/lib/mutare/result.ex#L1)

The outcome of running the suite against one mutant.

# `status`

```elixir
@type status() ::
  :killed
  | :survived
  | :no_coverage
  | :timeout
  | :atom_exhausted
  | :ignored
  | :poisoned
  | :harness_error
```

# `t`

```elixir
@type t() :: %Mutare.Result{
  duration_ms: non_neg_integer() | nil,
  exit_status: non_neg_integer() | nil,
  output: String.t() | nil,
  site: Mutare.Site.t(),
  status: status()
}
```

# `kill?`

```elixir
@spec kill?(status()) :: boolean()
```

Returns whether `status` counts as a killed mutant.

`:killed`, `:timeout`, and `:atom_exhausted` count as kills.

## Examples

    iex> Mutare.Result.kill?(:killed)
    true
    iex> Mutare.Result.kill?(:survived)
    false

# `ran?`

```elixir
@spec ran?(status()) :: boolean()
```

Returns whether a mutant launched a test run.

`:no_coverage`, `:ignored`, and `:poisoned` never start a test run.
`:harness_error` does start one and is included here.

## Examples

    iex> Mutare.Result.ran?(:harness_error)
    true
    iex> Mutare.Result.ran?(:ignored)
    false

# `scored?`

```elixir
@spec scored?(status()) :: boolean()
```

Returns whether `status` counts in the mutation-score denominator.

`:no_coverage`, `:ignored`, `:poisoned`, and `:harness_error` are excluded
because they do not produce a test-suite verdict for the mutation.

## Examples

    iex> Enum.filter(Mutare.Result.Status.names(), &Mutare.Result.scored?/1)
    [:killed, :timeout, :atom_exhausted, :survived]

---

*Consult [api-reference.md](api-reference.md) for complete listing*
