Class: Test::Unit::TestSuiteAdapter
- Defined in:
- lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb
Instance Attribute Summary collapse
-
#example_group ⇒ Object
readonly
Returns the value of attribute example_group.
-
#examples ⇒ Object
(also: #tests)
readonly
Returns the value of attribute examples.
Instance Method Summary collapse
- #delete(example) ⇒ Object
- #empty? ⇒ Boolean
-
#initialize(example_group) ⇒ TestSuiteAdapter
constructor
A new instance of TestSuiteAdapter.
- #name ⇒ Object
- #run(*args) ⇒ Object
- #size ⇒ Object
Constructor Details
#initialize(example_group) ⇒ TestSuiteAdapter
Returns a new instance of TestSuiteAdapter.
6 7 8 9 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 6 def initialize(example_group) @example_group = example_group @examples = example_group.examples end |
Instance Attribute Details
#example_group ⇒ Object (readonly)
Returns the value of attribute example_group.
4 5 6 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 4 def example_group @example_group end |
#examples ⇒ Object (readonly) Also known as: tests
Returns the value of attribute examples.
4 5 6 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 4 def examples @examples end |
Instance Method Details
#delete(example) ⇒ Object
24 25 26 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 24 def delete(example) examples.delete example end |
#empty? ⇒ Boolean
28 29 30 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 28 def empty? examples.empty? end |
#name ⇒ Object
11 12 13 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 11 def name example_group.description end |
#run(*args) ⇒ Object
15 16 17 18 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 15 def run(*args) return true unless args.empty? example_group.run(Spec::Runner.) end |
#size ⇒ Object
20 21 22 |
# File 'lib/gems/rspec-1.1.12/lib/spec/interop/test/unit/testsuite_adapter.rb', line 20 def size example_group.number_of_examples end |