Class: Oktest::BaseReporter
Constant Summary
collapse
- LABELS =
{ :PASS=>'pass', :FAIL=>'Fail', :ERROR=>'ERROR', :SKIP=>'Skip', :TODO=>'TODO' }
- CHARS =
{ :PASS=>'.', :FAIL=>'f', :ERROR=>'E', :SKIP=>'s', :TODO=>'t' }
Instance Attribute Summary collapse
Instance Method Summary
collapse
Methods inherited from Reporter
#order_policy
Constructor Details
Returns a new instance of BaseReporter.
1796
1797
1798
1799
|
# File 'lib/oktest.rb', line 1796
def initialize()
@exceptions = []
@counts = {}
end
|
Instance Attribute Details
#counts ⇒ Object
Returns the value of attribute counts.
1801
1802
1803
|
# File 'lib/oktest.rb', line 1801
def counts
@counts
end
|
Instance Method Details
#enter_all(runner) ⇒ Object
1803
1804
1805
1806
1807
|
# File 'lib/oktest.rb', line 1803
def enter_all(runner)
reset_counts()
@start_at = Time.now
end
|
#enter_scope(scope) ⇒ Object
1815
1816
|
# File 'lib/oktest.rb', line 1815
def enter_scope(scope)
end
|
#enter_spec(spec, depth) ⇒ Object
1827
1828
|
# File 'lib/oktest.rb', line 1827
def enter_spec(spec, depth)
end
|
#enter_topic(topic, depth) ⇒ Object
1821
1822
|
# File 'lib/oktest.rb', line 1821
def enter_topic(topic, depth)
end
|
#exit_all(runner) ⇒ Object
1809
1810
1811
1812
1813
|
# File 'lib/oktest.rb', line 1809
def exit_all(runner)
elapsed = Time.now - @start_at
puts (elapsed)
end
|
#exit_scope(scope) ⇒ Object
1818
1819
|
# File 'lib/oktest.rb', line 1818
def exit_scope(scope)
end
|
#exit_spec(spec, depth, status, exc, parent) ⇒ Object
1830
1831
1832
1833
1834
1835
|
# File 'lib/oktest.rb', line 1830
def exit_spec(spec, depth, status, exc, parent)
@counts[status] += 1
@exceptions << [spec, status, exc, parent] if status == :FAIL || status == :ERROR
end
|
#exit_topic(topic, depth) ⇒ Object
1824
1825
|
# File 'lib/oktest.rb', line 1824
def exit_topic(topic, depth)
end
|