Module: Splot
- Defined in:
- lib/splot.rb,
lib/splot/config.rb,
lib/splot/runner.rb,
lib/splot/command.rb,
lib/splot/version.rb,
lib/splot/corresponding_file.rb
Defined Under Namespace
Modules: Config
Classes: Command, CorrespondingFile, CucumberCommand, RSpecCommand, Runner, TestUnitCommand
Constant Summary
collapse
- RunnerNotFoundError =
Class.new StandardError
- VERSION =
"0.5.4"
Class Method Summary
collapse
Class Method Details
.command(params = {}) ⇒ Object
14
15
16
17
18
19
20
21
22
|
# File 'lib/splot.rb', line 14
def self.command(params = {})
new_file = CorrespondingFile.fetch params[:file]
unless new_file == params[:file]
params[:file] = new_file
params.delete(:line)
end
params.update Config.read_config params.delete(:config_file)
Command.for(params[:file]).new(params).command
end
|
.exec_command_from_argv ⇒ Object
24
25
26
27
28
29
30
|
# File 'lib/splot.rb', line 24
def self.exec_command_from_argv
command = Runner.new.tap(&:parse).command
Kernel.exec command
rescue RunnerNotFoundError => e
warn "Warning: #{e}; will not run any test"
exit 2
end
|