Module: Bacon

Extended by:
PrettyOutput, SpecDoxOutput
Defined in:
lib/vendor/bacon.rb,
lib/ramaze/spec/helper/pretty_output.rb

Overview

Copyright © 2007, 2008 Christian Neukirchen <purl.org/net/chneukirchen>

Bacon is freely distributable under the terms of an MIT-style license. See COPYING or www.opensource.org/licenses/mit-license.php.

Defined Under Namespace

Modules: PrettyOutput, SpecDoxOutput, TapOutput, TestUnitOutput Classes: Context, Error

Constant Summary collapse

VERSION =
"0.9"
Counter =
Hash.new(0)
ErrorLog =
""
Shared =
Hash.new { |_, name|
  raise NameError, "no such context: #{name.inspect}"
}
RestrictName =
//
RestrictContext =
//

Constants included from PrettyOutput

PrettyOutput::NAME, PrettyOutput::RamazeLogger

Class Method Summary collapse

Methods included from SpecDoxOutput

handle_requirement, handle_specification, handle_summary

Methods included from PrettyOutput

general_error, handle_requirement, handle_specification, handle_summary

Class Method Details

.summary_on_exitObject



22
23
24
25
26
27
28
29
30
31
32
33
# File 'lib/vendor/bacon.rb', line 22

def self.summary_on_exit
  return  if Counter[:installed_summary] > 0
  at_exit {
    handle_summary
    if $!
      raise $!
    elsif Counter[:errors] + Counter[:failed] > 0
      exit 1
    end
  }
  Counter[:installed_summary] += 1
end