Class: Crew::Tester::DSL
- Inherits:
-
Object
- Object
- Crew::Tester::DSL
- Defined in:
- lib/crew/tester/dsl.rb
Instance Method Summary collapse
- #context(name, &blk) ⇒ Object
- #hints(*hints) ⇒ Object
-
#initialize(tester) ⇒ DSL
constructor
A new instance of DSL.
- #load(&blk) ⇒ Object
- #prepare(name, &blk) ⇒ Object
Constructor Details
#initialize(tester) ⇒ DSL
Returns a new instance of DSL.
4 5 6 |
# File 'lib/crew/tester/dsl.rb', line 4 def initialize(tester) @tester = tester end |
Instance Method Details
#context(name, &blk) ⇒ Object
12 13 14 |
# File 'lib/crew/tester/dsl.rb', line 12 def context(name, &blk) @tester.context(name, &blk) end |
#hints(*hints) ⇒ Object
16 17 18 |
# File 'lib/crew/tester/dsl.rb', line 16 def hints(*hints) @tester.hints = hints end |
#load(&blk) ⇒ Object
8 9 10 |
# File 'lib/crew/tester/dsl.rb', line 8 def load(&blk) instance_eval(&blk) end |
#prepare(name, &blk) ⇒ Object
20 21 22 |
# File 'lib/crew/tester/dsl.rb', line 20 def prepare(name, &blk) @tester.add_preparer(name, &blk) end |