Sha256: df6a2b438004e159a043d910f486018cf1811b706d8df5dda4d3c820dddbbf64

Contents?: true

Size: 1.2 KB

Versions: 3

Compression:

Stored size: 1.2 KB

Contents

@spawn @wip-jruby
Feature: Raketask

  In order to use cucumber's rake task
  As a Cuker
  I do not want to see rake's backtraces when it fails
  Also I want to get zero exit status code on failures
  And non-zero exit status code when it pases

  Background:
    Given the standard step definitions
    Given a file named "features/passing_and_failing.feature" with:
      """
      Feature: Sample

        Scenario: Passing
          Given this step passes

        Scenario: Failing
          Given this step raises an error
      """
    Given a file named "Rakefile" with:
      """
        require 'cucumber/rake/task'

        SAMPLE_FEATURE_FILE = 'features/passing_and_failing.feature'

        Cucumber::Rake::Task.new(:pass) do |t|
          t.cucumber_opts = "#{SAMPLE_FEATURE_FILE}:3"
        end

        Cucumber::Rake::Task.new(:fail) do |t|
          t.cucumber_opts = "#{SAMPLE_FEATURE_FILE}:6"
        end
      """

  @todo-windows
  Scenario: Passing feature
    When I run `bundle exec rake pass`
    Then the exit status should be 0

  @todo-windows
  Scenario: Failing feature
    When I run `bundle exec rake fail`
    Then the exit status should be 1
    But the output should not contain "rake aborted!"

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cucumber-3.0.1 features/docs/raketask.feature
cucumber-3.0.0 features/docs/raketask.feature
cucumber-3.0.0.pre.2 features/docs/raketask.feature