Sha256: cab54a6bed4548fc4c7ba7d09f98b888f2ab82fd8cd6595d6128a4b7d9fdc412

Contents?: true

Size: 464 Bytes

Versions: 14

Compression:

Stored size: 464 Bytes

Contents

#!/usr/bin/env ruby

require_relative '../lib/knapsack'

runner = ARGV[0]
arguments = ARGV[1]

MAP = {
  'rspec' => Knapsack::Runners::RSpecRunner,
  'cucumber' => Knapsack::Runners::CucumberRunner,
  'minitest' => Knapsack::Runners::MinitestRunner,
}

runner_class = MAP[runner]

if runner_class
  runner_class.run(arguments)
else
  raise 'Undefined runner. Please provide runner name and optional arguments, for instance: knapsack rspec "--color --profile"'
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
knapsack-1.10.0 bin/knapsack
knapsack-1.9.0 bin/knapsack
knapsack-1.8.0 bin/knapsack
knapsack-1.7.0 bin/knapsack
knapsack-1.6.1 bin/knapsack
knapsack-1.6.0 bin/knapsack
knapsack-1.5.1 bin/knapsack
knapsack-1.5.0 bin/knapsack
knapsack-1.4.1 bin/knapsack
knapsack-1.4.0 bin/knapsack
knapsack-1.3.4 bin/knapsack
knapsack-1.3.3 bin/knapsack
knapsack-1.3.1 bin/knapsack
knapsack-1.3.0 bin/knapsack