Module Protest::Utils::Summaries
In: lib/protest/utils/summaries.rb

Mixin that provides summaries for your text based test runs.

Methods

Public Instance methods

Call on +:end+ to print a list of failures (failed assertions) and errors (unrescued exceptions), including file and line number where the test failed, and a short backtrace.

It will not output anything if there weren‘t any failures or errors.

For example:

    on :end do |report|
      report.puts
      report.summarize_errors
    end

This relies on the public Report API, and on the presence of a puts method to write to whatever source you are writing your report.

Call on +:end+ to print a list of pending tests, including file and line number where the call to TestCase#pending+ was made.

It will not output anything if there weren‘t any pending tests.

For example:

    on :end do |report|
      report.puts
      report.summarize_pending_tests
    end

This relies on the public Report API, and on the presence of a puts method to write to whatever source you are writing your report.

Call on +:end+ to output the amount of tests (passed, pending, failed and errored), the amount of assertions, and the time elapsed.

For example:

    on :end do |report|
      report.puts
      report.summarize_test_totals
    end

This relies on the public Report API, and on the presence of a puts method to write to whatever source you are writing your report.

[Validate]