mirror of
https://github.com/rest-client/rest-client.git
synced 2022-11-09 13:49:40 -05:00
1ef588bd62
SimpleCov runs when RSpec is run; there is no Rake task for it.
42 lines
989 B
Ruby
42 lines
989 B
Ruby
begin
|
|
# optionally load `rake build/install/release tasks'
|
|
require 'bundler/gem_tasks'
|
|
rescue LoadError
|
|
end
|
|
|
|
require "rspec/core/rake_task"
|
|
|
|
desc "Run all specs"
|
|
task :spec => ["spec:unit", "spec:integration"]
|
|
|
|
desc "Run unit specs"
|
|
RSpec::Core::RakeTask.new('spec:unit') do |t|
|
|
t.pattern = 'spec/*_spec.rb'
|
|
end
|
|
|
|
desc "Run integration specs"
|
|
RSpec::Core::RakeTask.new('spec:integration') do |t|
|
|
t.pattern = 'spec/integration/*_spec.rb'
|
|
end
|
|
|
|
desc "Print specdocs"
|
|
RSpec::Core::RakeTask.new(:doc) do |t|
|
|
t.rspec_opts = ["--format", "specdoc", "--dry-run"]
|
|
t.pattern = 'spec/*_spec.rb'
|
|
end
|
|
|
|
task :default => :spec
|
|
|
|
############################
|
|
|
|
require 'rdoc/task'
|
|
|
|
Rake::RDocTask.new do |t|
|
|
t.rdoc_dir = 'rdoc'
|
|
t.title = "rest-client, fetch RESTful resources effortlessly"
|
|
t.options << '--line-numbers' << '--inline-source' << '-A cattr_accessor=object'
|
|
t.options << '--charset' << 'utf-8'
|
|
t.rdoc_files.include('README.rdoc')
|
|
t.rdoc_files.include('lib/*.rb')
|
|
end
|
|
|