Class: Command::CritiqueLoader

Inherits:
Spec::Runner::ExampleGroupRunner
  • Object
show all
Defined in:
lib/command-set/critic.rb

Instance Method Summary collapse

Constructor Details

#initialize(opts, command_set) ⇒ CritiqueLoader

Returns a new instance of CritiqueLoader.



32
33
34
35
# File 'lib/command-set/critic.rb', line 32

def initialize(opts, command_set)
  super(opts)
  @command_set_module = command_set
end

Instance Method Details

#load_files(files) ⇒ Object



37
38
39
40
41
# File 'lib/command-set/critic.rb', line 37

def load_files(files)
  set = CommandSet::new
  set.require_commands(@command_set_module)
  Critic.criticize(set)
end