Class: Nestor::Mappers::Rails::Test::TestRunner
- Inherits:
-
Test::Unit::UI::Console::TestRunner
- Object
- Test::Unit::UI::Console::TestRunner
- Nestor::Mappers::Rails::Test::TestRunner
- Defined in:
- lib/nestor/mappers/rails/test/unit.rb
Overview
A helper class that allows me to get more information from the build.
This is something that definitely will change when Nestor is tested on Ruby 1.9.
Instance Attribute Summary collapse
-
#faults ⇒ Object
readonly
:nodoc:.
Instance Method Summary collapse
-
#passed? ⇒ Boolean
Returns pass/fail status.
-
#run(suite, output_level = NORMAL) ⇒ Object
This is a duck-typing method.
Instance Attribute Details
#faults ⇒ Object (readonly)
:nodoc:
250 251 252 |
# File 'lib/nestor/mappers/rails/test/unit.rb', line 250 def faults @faults end |
Instance Method Details
#passed? ⇒ Boolean
Returns pass/fail status.
261 262 263 |
# File 'lib/nestor/mappers/rails/test/unit.rb', line 261 def passed? @faults.empty? end |
#run(suite, output_level = NORMAL) ⇒ Object
This is a duck-typing method. Test::Unit’s design requiers a #run method, but it is implemented as a class method. I fake it here to allow me to pass an instance and have the actual TestRunner instance available afterwards.
255 256 257 258 |
# File 'lib/nestor/mappers/rails/test/unit.rb', line 255 def run(suite, output_level=NORMAL) @suite = suite.respond_to?(:suite) ? suite.suite : suite start end |