Sha256: 1c74086a06a4d5c2dfeb4a6be759e87c33d6c5ca8cde2749636b34865fa4e5c6

Contents?: true

Size: 1.46 KB

Versions: 4

Compression:

Stored size: 1.46 KB

Contents

begin
  require "rspec/core/rake_task"
  desc "Run RSpec code examples"
  RSpec::Core::RakeTask.new(:integration_test) do |t|
    # Glob pattern to match files.
    t.pattern = "spec/integration/**/test_*.rb"

    # By default, if there is a Gemfile, the generated command will include
    # 'bundle exec'. Set this to true to ignore the presence of a Gemfile, 
    # and not add 'bundle exec' to the command.
    t.skip_bundler = false

    # Name of Gemfile to use
    t.gemfile = "Gemfile"

    # Whether or not to fail Rake when an error occurs (typically when 
    # examples fail).
    t.fail_on_error = true

    # A message to print to stderr when there are failures.
    t.failure_message = nil

    # Use verbose output. If this is set to true, the task will print the
    # executed spec command to stdout.
    t.verbose = true

    # Use rcov for code coverage?
    t.rcov = false

    # Path to rcov.
    t.rcov_path = "rcov"

    # Command line options to pass to rcov. See 'rcov --help' about this
    t.rcov_opts = []

    # Command line options to pass to ruby. See 'ruby --help' about this 
    t.ruby_opts = []

    # Path to rspec
    t.rspec_path = "rspec"

    # Command line options to pass to rspec. See 'rspec --help' about this
    t.rspec_opts = ["--color", "--backtrace"]
  end
rescue LoadError => ex
  task :integration_test do
    abort 'rspec is not available. In order to run spec, you must: gem install rspec'
  end
ensure
  task :test => [:integration_test]
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
alf-0.10.1 tasks/integration_test.rake
viiite-0.1.0 tasks/integration_test.rake
alf-0.10.0 tasks/integration_test.rake
alf-0.9.3 tasks/integration_test.rake