Sha256: 0683795016e9fe997b63fdfc3056609bbdbf17c5ba21fb8033f93bbcd23003e5

Contents?: true

Size: 736 Bytes

Versions: 5

Compression:

Stored size: 736 Bytes

Contents

require 'zeus/rails'                   

# 1. Add the cucumber methods (below) to your custom plan (or take this file if
# you don't have an existing custom_plan).
#
# 2. Add the following line to the test_environment section of your zeus.json:
#
#   "cucumber_environment": {"cucumber": []}

class CucumberPlan < Zeus::Rails         
  def cucumber_environment
    require 'cucumber/rspec/disable_option_parser'
    require 'cucumber/cli/main'
    @cucumber_runtime = Cucumber::Runtime.new
  end

  def cucumber(argv=ARGV)
    cucumber_main = Cucumber::Cli::Main.new(argv.dup)
    had_failures = cucumber_main.execute!(@cucumber_runtime)
    exit_code = had_failures ? 1 : 0
    exit exit_code
  end
end

Zeus.plan = CucumberPlan.new

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
zeus-0.15.10 examples/custom_plan/cucumber_plan.rb
zeus-0.15.4 examples/custom_plan/cucumber_plan.rb
zeus-0.15.3 examples/custom_plan/cucumber_plan.rb
zeus-0.15.2 examples/custom_plan/cucumber_plan.rb
zeus-0.15.1 examples/custom_plan/cucumber_plan.rb