class

Spectator::PendingResult

Inherits Spectator::Result / Reference / Object

Outcome that indicates running an example was pending. A pending result means the example is not ready to run yet. This can happen when the functionality to be tested is not implemented yet.

Constants

DEFAULT_REASON = "No reason given"

Constructors

new(reason : String = DEFAULT_REASON, location : Spectator::Location | Nil = nil, elapsed = Time::Span::ZERO, expectations = [] of Expectation)

Creates the result. elapsed is the length of time it took to run the example. A reason for the skip/pending result can be specified. If the pending result was triggered inside of an example, then location can be set.

Source

Instance methods

accept(visitor)

Calls the pending method on the visitor.

Source
accept(visitor, &)

Calls the pending method on the visitor.

Source
fail?

Indicates whether the example failed.

Source
location

Location the pending result was triggered from.

Source
location?

Location the pending result was triggered from.

Source
pass?

Indicates whether the example passed.

Source
reason

Reason the example was skipped or marked pending.

Source
to_json(json : JSON::Builder)

Creates a JSON object from the result information.

Source
to_s(io : IO) : Nil

One-word description of the result.

Source