Class: Fried::Test::Autorun

Inherits:
Object
  • Object
show all
Defined in:
lib/fried/test/autorun.rb

Defined Under Namespace

Classes: Substitute

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeAutorun

Returns a new instance of Autorun.



18
19
20
# File 'lib/fried/test/autorun.rb', line 18

def initialize
  @execute = Noop
end

Instance Attribute Details

#executeObject

Returns the value of attribute execute.



16
17
18
# File 'lib/fried/test/autorun.rb', line 16

def execute
  @execute
end

Class Method Details

.buildObject



22
23
24
25
26
# File 'lib/fried/test/autorun.rb', line 22

def self.build
  new.tap do |instance|
    instance.execute = method(:require)
  end
end

.callObject



32
33
34
35
# File 'lib/fried/test/autorun.rb', line 32

def self.call
  instance = build
  instance.()
end

Instance Method Details

#callObject



28
29
30
# File 'lib/fried/test/autorun.rb', line 28

def call
  execute.("minitest/autorun")
end