mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Add SimpleCov and Coveralls.io dependenices
Add rake tasks for travis, which include publishing coverage reports.
This commit is contained in:
parent
06deb8554f
commit
e42902a266
2 changed files with 19 additions and 0 deletions
5
Gemfile
5
Gemfile
|
@ -1,3 +1,8 @@
|
|||
source "https://rubygems.org"
|
||||
|
||||
group :development, :test do
|
||||
# This is here because gemspec doesn't support require: false
|
||||
gem 'coveralls', :require => false
|
||||
end
|
||||
|
||||
gemspec
|
||||
|
|
14
Rakefile
14
Rakefile
|
@ -47,11 +47,17 @@ end
|
|||
|
||||
GEM_NAME = "#{name}"
|
||||
task :default => :test
|
||||
task :travis => ['test:travis', 'coveralls_push_workaround']
|
||||
|
||||
require "tasks/test_task"
|
||||
Fog::Rake::TestTask.new
|
||||
|
||||
namespace :test do
|
||||
task :travis do
|
||||
[true].each do |mock|
|
||||
sh("export FOG_MOCK=#{mock} && bundle exec shindont")
|
||||
end
|
||||
end
|
||||
task :vsphere do
|
||||
[true].each do |mock|
|
||||
sh("export FOG_MOCK=#{mock} && bundle exec shindont tests/vsphere")
|
||||
|
@ -186,3 +192,11 @@ end
|
|||
|
||||
require "tasks/changelog_task"
|
||||
Fog::Rake::ChangelogTask.new
|
||||
|
||||
task :coveralls_push_workaround do
|
||||
if Gem::Version.new(RUBY_VERSION) > Gem::Version.new('1.9')
|
||||
require 'coveralls/rake/task'
|
||||
Coveralls::RakeTask.new
|
||||
Rake::Task["coveralls:push"].invoke
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue