Sha256: e6dc73b1decbd5c1d0cce017b32cfd00415efe172fc3e3fbb92bddaefcbf8a54

Contents?: true

Size: 535 Bytes

Versions: 3

Compression:

Stored size: 535 Bytes

Contents

require 'cucumber/formatter/ansicolor'

module Cucumber
  class CleanupFormatter
    include Cucumber::Formatter::ANSIColor

    def initialize(step_mother, path_or_io, options)
      @step_mother = step_mother
    end

    def after_features(features)
      defs = @step_mother.unmatched_step_definitions

      if !defs.empty?
        $stdout.puts yellow("The following steps are unused:")
        $stdout.puts

        defs.each do |step|
          $stdout.puts yellow(step.file_colon_line)
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cuke-pack-0.0.3 lib/cucumber/cleanup_formatter.rb
cuke-pack-0.0.2 lib/cucumber/cleanup_formatter.rb
cuke-pack-0.0.1 lib/cucumber/cleanup_formatter.rb