forked from sumoheavy/jira-ruby
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
32 lines (24 loc) · 752 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
require 'bundler/gem_tasks'
require 'rubygems'
require 'rspec/core/rake_task'
require 'rdoc/task'
Dir.glob('lib/tasks/*.rake').each { |r| import r }
task :default => [:test]
task :test => [:prepare, :spec]
desc 'Prepare and run rspec tests'
task :prepare do
rsa_key = File.expand_path('rsakey.pem')
unless File.exists?(rsa_key)
raise 'rsakey.pem does not exist, tests will fail. Run `rake jira:generate_public_cert` first'
end
end
desc 'Run RSpec tests'
#RSpec::Core::RakeTask.new(:spec)
RSpec::Core::RakeTask.new(:spec) do |task|
task.rspec_opts = ['--color', '--format', 'doc']
end
Rake::RDocTask.new(:doc) do |rd|
rd.main = 'README.rdoc'
rd.rdoc_dir = 'doc'
rd.rdoc_files.include('README.rdoc', 'lib/**/*.rb')
end