Class: CommandUnit::Totaliser
- Inherits:
-
Object
- Object
- CommandUnit::Totaliser
- Defined in:
- lib/command-unit/totaliser.rb
Instance Attribute Summary collapse
-
#expectations_failed ⇒ Object
readonly
Returns the value of attribute expectations_failed.
-
#expectations_passed ⇒ Object
readonly
Returns the value of attribute expectations_passed.
-
#expectations_run ⇒ Object
readonly
Returns the value of attribute expectations_run.
-
#scenarios_failed ⇒ Object
readonly
Returns the value of attribute scenarios_failed.
-
#scenarios_passed ⇒ Object
readonly
Returns the value of attribute scenarios_passed.
-
#scenarios_run ⇒ Object
readonly
Returns the value of attribute scenarios_run.
-
#tests_failed ⇒ Object
readonly
Returns the value of attribute tests_failed.
-
#tests_passed ⇒ Object
readonly
Returns the value of attribute tests_passed.
-
#tests_run ⇒ Object
readonly
Returns the value of attribute tests_run.
Instance Method Summary collapse
- #expectation_fail ⇒ Object
- #expectation_pass ⇒ Object
- #expectation_run ⇒ Object
-
#initialize ⇒ Totaliser
constructor
A new instance of Totaliser.
- #scenario_fail ⇒ Object
- #scenario_pass ⇒ Object
- #scenario_run ⇒ Object
- #test_fail ⇒ Object
- #test_pass ⇒ Object
- #test_run ⇒ Object
Constructor Details
#initialize ⇒ Totaliser
Returns a new instance of Totaliser.
3 4 5 6 7 8 9 10 11 12 13 |
# File 'lib/command-unit/totaliser.rb', line 3 def initialize @scenarios_run = 0 @scenarios_passed = 0 @scenarios_failed = 0 @tests_run = 0 @tests_passed = 0 @tests_failed = 0 @expectations_run = 0 @expectations_passed = 0 @expectations_failed = 0 end |
Instance Attribute Details
#expectations_failed ⇒ Object (readonly)
Returns the value of attribute expectations_failed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def expectations_failed @expectations_failed end |
#expectations_passed ⇒ Object (readonly)
Returns the value of attribute expectations_passed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def expectations_passed @expectations_passed end |
#expectations_run ⇒ Object (readonly)
Returns the value of attribute expectations_run.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def expectations_run @expectations_run end |
#scenarios_failed ⇒ Object (readonly)
Returns the value of attribute scenarios_failed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def scenarios_failed @scenarios_failed end |
#scenarios_passed ⇒ Object (readonly)
Returns the value of attribute scenarios_passed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def scenarios_passed @scenarios_passed end |
#scenarios_run ⇒ Object (readonly)
Returns the value of attribute scenarios_run.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def scenarios_run @scenarios_run end |
#tests_failed ⇒ Object (readonly)
Returns the value of attribute tests_failed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def tests_failed @tests_failed end |
#tests_passed ⇒ Object (readonly)
Returns the value of attribute tests_passed.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def tests_passed @tests_passed end |
#tests_run ⇒ Object (readonly)
Returns the value of attribute tests_run.
51 52 53 |
# File 'lib/command-unit/totaliser.rb', line 51 def tests_run @tests_run end |
Instance Method Details
#expectation_fail ⇒ Object
47 48 49 |
# File 'lib/command-unit/totaliser.rb', line 47 def expectation_fail @expectations_failed += 1 end |
#expectation_pass ⇒ Object
43 44 45 |
# File 'lib/command-unit/totaliser.rb', line 43 def expectation_pass @expectations_passed += 1 end |
#expectation_run ⇒ Object
39 40 41 |
# File 'lib/command-unit/totaliser.rb', line 39 def expectation_run @expectations_run += 1 end |
#scenario_fail ⇒ Object
23 24 25 |
# File 'lib/command-unit/totaliser.rb', line 23 def scenario_fail @scenarios_failed += 1 end |
#scenario_pass ⇒ Object
19 20 21 |
# File 'lib/command-unit/totaliser.rb', line 19 def scenario_pass @scenarios_passed += 1 end |
#scenario_run ⇒ Object
15 16 17 |
# File 'lib/command-unit/totaliser.rb', line 15 def scenario_run @scenarios_run += 1 end |
#test_fail ⇒ Object
35 36 37 |
# File 'lib/command-unit/totaliser.rb', line 35 def test_fail @tests_failed += 1 end |
#test_pass ⇒ Object
31 32 33 |
# File 'lib/command-unit/totaliser.rb', line 31 def test_pass @tests_passed += 1 end |
#test_run ⇒ Object
27 28 29 |
# File 'lib/command-unit/totaliser.rb', line 27 def test_run @tests_run += 1 end |