Class: Grntest::WorkerResult
- Inherits:
-
BaseResult
- Object
- BaseResult
- Grntest::WorkerResult
- Defined in:
- lib/grntest/worker.rb
Instance Attribute Summary collapse
-
#failed_tests ⇒ Object
readonly
Returns the value of attribute failed_tests.
-
#n_leaked_tests ⇒ Object
readonly
Returns the value of attribute n_leaked_tests.
-
#n_not_checked_tests ⇒ Object
readonly
Returns the value of attribute n_not_checked_tests.
-
#n_omitted_tests ⇒ Object
readonly
Returns the value of attribute n_omitted_tests.
-
#n_passed_tests ⇒ Object
readonly
Returns the value of attribute n_passed_tests.
-
#n_tests ⇒ Object
readonly
Returns the value of attribute n_tests.
Attributes inherited from BaseResult
#cpu_elapsed_time, #real_elapsed_time
Instance Method Summary collapse
- #cancel_test_failure(name) ⇒ Object
-
#initialize ⇒ WorkerResult
constructor
A new instance of WorkerResult.
- #n_failed_tests ⇒ Object
- #on_test_failure(name) ⇒ Object
- #on_test_finish ⇒ Object
- #on_test_leak(name) ⇒ Object
- #on_test_no_check ⇒ Object
- #on_test_omission ⇒ Object
- #on_test_success ⇒ Object
Methods inherited from BaseResult
Constructor Details
#initialize ⇒ WorkerResult
Returns a new instance of WorkerResult.
24 25 26 27 28 29 30 31 32 |
# File 'lib/grntest/worker.rb', line 24 def initialize super @n_tests = 0 @n_passed_tests = 0 @n_leaked_tests = 0 @n_omitted_tests = 0 @n_not_checked_tests = 0 @failed_tests = [] end |
Instance Attribute Details
#failed_tests ⇒ Object (readonly)
Returns the value of attribute failed_tests.
23 24 25 |
# File 'lib/grntest/worker.rb', line 23 def failed_tests @failed_tests end |
#n_leaked_tests ⇒ Object (readonly)
Returns the value of attribute n_leaked_tests.
21 22 23 |
# File 'lib/grntest/worker.rb', line 21 def n_leaked_tests @n_leaked_tests end |
#n_not_checked_tests ⇒ Object (readonly)
Returns the value of attribute n_not_checked_tests.
22 23 24 |
# File 'lib/grntest/worker.rb', line 22 def n_not_checked_tests @n_not_checked_tests end |
#n_omitted_tests ⇒ Object (readonly)
Returns the value of attribute n_omitted_tests.
22 23 24 |
# File 'lib/grntest/worker.rb', line 22 def n_omitted_tests @n_omitted_tests end |
#n_passed_tests ⇒ Object (readonly)
Returns the value of attribute n_passed_tests.
21 22 23 |
# File 'lib/grntest/worker.rb', line 21 def n_passed_tests @n_passed_tests end |
#n_tests ⇒ Object (readonly)
Returns the value of attribute n_tests.
21 22 23 |
# File 'lib/grntest/worker.rb', line 21 def n_tests @n_tests end |
Instance Method Details
#cancel_test_failure(name) ⇒ Object
50 51 52 |
# File 'lib/grntest/worker.rb', line 50 def cancel_test_failure(name) @failed_tests.delete(name) end |
#n_failed_tests ⇒ Object
34 35 36 |
# File 'lib/grntest/worker.rb', line 34 def n_failed_tests @failed_tests.size end |
#on_test_failure(name) ⇒ Object
46 47 48 |
# File 'lib/grntest/worker.rb', line 46 def on_test_failure(name) @failed_tests << name end |
#on_test_finish ⇒ Object
38 39 40 |
# File 'lib/grntest/worker.rb', line 38 def on_test_finish @n_tests += 1 end |
#on_test_leak(name) ⇒ Object
54 55 56 |
# File 'lib/grntest/worker.rb', line 54 def on_test_leak(name) @n_leaked_tests += 1 end |
#on_test_no_check ⇒ Object
62 63 64 |
# File 'lib/grntest/worker.rb', line 62 def on_test_no_check @n_not_checked_tests += 1 end |
#on_test_omission ⇒ Object
58 59 60 |
# File 'lib/grntest/worker.rb', line 58 def on_test_omission @n_omitted_tests += 1 end |
#on_test_success ⇒ Object
42 43 44 |
# File 'lib/grntest/worker.rb', line 42 def on_test_success @n_passed_tests += 1 end |