Sha256: 5bb686866df70db93218ff660e8e71386a53e0f539659355a3026a5dd2b6cbf8

Contents?: true

Size: 1.02 KB

Versions: 21

Compression:

Stored size: 1.02 KB

Contents

Feature: Custom Formatter

  Scenario: my own formatter
    Given a file named "features/f.feature" with:
      """
      Feature: I'll use my own
        because I'm worth it
        Scenario: just print me
          Given this step works
      """
    And a file named "features/step_definitions/steps.rb" with:
      """
      Given /^this step works$/ do
      end
      """
    And a file named "features/support/ze/formator.rb" with:
      """
      module Ze
        class Formator
          def initialize(step_mother, io, options)
            @step_mother = step_mother
            @io = io
          end

          def before_feature(feature)
            @io.puts feature.short_name.upcase
          end

          def scenario_name(keyword, name, file_colon_line, source_indent)
            @io.puts "  #{name.upcase}"
          end
        end
      end
      """
    When I run `cucumber features/f.feature --format Ze::Formator`
    Then it should pass with exactly:
      """
      I'LL USE MY OWN
        JUST PRINT ME

      """

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
cucumber-1.3.20 features/custom_formatter.feature
cucumber-1.3.19 features/custom_formatter.feature
cucumber-1.3.18 features/custom_formatter.feature
cucumber-1.3.17 features/custom_formatter.feature
cucumber-1.3.16 features/custom_formatter.feature
cucumber-1.3.15 features/custom_formatter.feature
cucumber-1.3.14 features/custom_formatter.feature
cucumber-1.3.13 features/custom_formatter.feature
cucumber-1.3.12 features/custom_formatter.feature
cucumber-1.3.11 features/custom_formatter.feature
cucumber-1.3.10 features/custom_formatter.feature
cucumber-1.3.9 features/custom_formatter.feature
cucumber-1.3.8 features/custom_formatter.feature
cucumber-1.3.7 features/custom_formatter.feature
cucumber-1.3.6 features/custom_formatter.feature
cucumber-1.3.5 features/custom_formatter.feature
cucumber-1.3.4 features/custom_formatter.feature
cucumber-1.3.3 features/custom_formatter.feature
cucumber-1.3.2 features/custom_formatter.feature
cucumber-1.3.1 features/custom_formatter.feature