Sha256: 39b36a652dccadc03d0851c358e9e03f1efc2f614b80f8fe730eea11b71aeaa6

Contents?: true

Size: 771 Bytes

Versions: 6

Compression:

Stored size: 771 Bytes

Contents

require_relative '../../lib/reek'
require_relative '../../lib/reek/cli/application'
require 'aruba/cucumber'
require 'active_support/core_ext/string/strip'

begin
  require 'pry-byebug'
rescue LoadError # rubocop:disable Lint/HandleExceptions
end

#
# Provides runner methods used in the cucumber steps.
#
class ReekWorld
  def reek(args)
    run_simple("reek --no-color #{args}", false)
  end

  def reek_with_pipe(stdin, args)
    run "reek --no-color #{args}"
    type(stdin)
    close_input
  end

  def rake(name, task_def)
    header = <<-EOS.strip_heredoc
      require 'reek/rake/task'

    EOS
    write_file 'Rakefile', header + task_def
    run_simple("rake #{name}", false)
  end
end

World do
  ReekWorld.new
end

Before do
  @aruba_timeout_seconds = 30
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
reek-3.4.1 features/support/env.rb
reek-3.4.0 features/support/env.rb
reek-3.3.1 features/support/env.rb
reek-3.3.0 features/support/env.rb
reek-3.2.1 features/support/env.rb
reek-3.2 features/support/env.rb