class Spec::Runner::Formatter::BaseFormatter
Baseclass for formatters that implements all required methods as no-ops.
def add_example_group(example_group)
+example_group+ is the example_group.
This method is invoked at the beginning of the execution of each example_group.
def add_example_group(example_group) @example_group = example_group end
def close
def close end
def dump_failure(counter, failure)
of the associated example. +failure+ is a Failure object, which contains detailed
This method is invoked for each failed example after all examples have run. +counter+ is the sequence number
Dumps detailed information about an example failure.
def dump_failure(counter, failure) end
def dump_pending
def dump_pending end
def dump_summary(duration, example_count, failure_count, pending_count)
def dump_summary(duration, example_count, failure_count, pending_count) end
def example_failed(example, counter, failure)
sequence number of the failure (starting at 1) and +failure+ is the associated
inside it (such as a failed should or other exception). +counter+ is the
This method is invoked when an +example+ fails, i.e. an exception occurred
def example_failed(example, counter, failure) end
def example_passed(example)
def example_passed(example) end
def example_pending(example, message)
+message+ is the message from the ExamplePendingError, if it exists, or the
been provided a block), or when an ExamplePendingError is raised.
This method is invoked when an example is not yet implemented (i.e. has not
def example_pending(example, message) end
def example_started(example)
def example_started(example) end
def initialize(options, where)
def initialize(options, where) @options = options @where = where end
def start(example_count)
This method will only be invoked once, and the next one to be invoked
formatters that need to provide progress on feedback (graphical ones)
they have all been collected. This can be useful for special
This method is invoked before any examples are run, right after
def start(example_count) end
def start_dump
This method is invoked after all of the examples have executed. The next method
def start_dump end