Class: Object
- Inherits:
- BasicObject
- Defined in:
- lib/riot.rb
Overview
A little bit of monkey-patch so we can have context available anywhere.
Instance Method Summary collapse
-
#context(description, context_class = Riot::Context, &definition) ⇒ Context
(also: #describe)
Defining
contextin Object itself lets us define a rootcontextin any file.
Instance Method Details
#context(description, context_class = Riot::Context, &definition) ⇒ Context Also known as: describe
Defining context in Object itself lets us define a root context in any file. Any context defined within a context is already handled by Riot::Context#context.
141 142 143 |
# File 'lib/riot.rb', line 141 def context(description, context_class = Riot::Context, &definition) Riot.context(description, context_class, &definition) end |