Module: XSpec::DSL
- Included in:
- Context
- Defined in:
- lib/xspec/dsl.rb
Instance Method Summary collapse
- #describe(*args, &block) ⇒ Object
- #it(*args, &block) ⇒ Object
- #it_behaves_like_a(context) ⇒ Object
- #let(*args, &block) ⇒ Object
- #shared_context(*args, &block) ⇒ Object
Instance Method Details
#describe(*args, &block) ⇒ Object
10 11 12 |
# File 'lib/xspec/dsl.rb', line 10 def describe(*args, &block) __xspec_context.add_child_context(*args, &block) end |
#it(*args, &block) ⇒ Object
6 7 8 |
# File 'lib/xspec/dsl.rb', line 6 def it(*args, &block) __xspec_context.add_unit_of_work(*args, &block) end |
#it_behaves_like_a(context) ⇒ Object
22 23 24 |
# File 'lib/xspec/dsl.rb', line 22 def it_behaves_like_a(context) __xspec_context.copy_into_tree(context) end |
#let(*args, &block) ⇒ Object
14 15 16 |
# File 'lib/xspec/dsl.rb', line 14 def let(*args, &block) __xspec_context.add_memoized_method(*args, &block) end |
#shared_context(*args, &block) ⇒ Object
18 19 20 |
# File 'lib/xspec/dsl.rb', line 18 def shared_context(*args, &block) __xspec_context.create_shared_context(*args, &block) end |