Class: Fried::Test::Activate
- Inherits:
-
Object
- Object
- Fried::Test::Activate
- Defined in:
- lib/fried/test/activate.rb
Instance Attribute Summary collapse
-
#target ⇒ Object
Returns the value of attribute target.
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ void
-
#initialize ⇒ Activate
constructor
A new instance of Activate.
Constructor Details
#initialize ⇒ Activate
Returns a new instance of Activate.
8 9 10 |
# File 'lib/fried/test/activate.rb', line 8 def initialize @target = nil end |
Instance Attribute Details
#target ⇒ Object
Returns the value of attribute target.
6 7 8 |
# File 'lib/fried/test/activate.rb', line 6 def target @target end |
Class Method Details
.build ⇒ Object
12 13 14 15 16 |
# File 'lib/fried/test/activate.rb', line 12 def self.build new.tap do |instance| instance.target = Module end end |
.call ⇒ Object
27 28 29 30 |
# File 'lib/fried/test/activate.rb', line 27 def self.call instance = build instance.() end |
Instance Method Details
#call ⇒ void
This method returns an undefined value.
19 20 21 22 23 24 25 |
# File 'lib/fried/test/activate.rb', line 19 def call return if target.nil? target.class_eval do include Minitest::Spec::DSL end end |