forked from chamnap/liquid-rails
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
27 lines (23 loc) · 790 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
require 'bundler/gem_tasks'
require 'rspec/core'
require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:spec) do |spec|
spec.pattern = FileList['spec/**/*_spec.rb']
end
task default: 'spec:all'
namespace :spec do
%w(rails_42 rails_41 rails_40 rails_32).each do |gemfile|
desc "Run Tests against #{gemfile}"
task gemfile do
sh "BUNDLE_GEMFILE='gemfiles/#{gemfile}.gemfile' bundle --quiet"
sh "BUNDLE_GEMFILE='gemfiles/#{gemfile}.gemfile' bundle exec rake spec"
end
end
desc "Run Tests against rails versions"
task :all do
%w(rails_42 rails_41 rails_40 rails_32).each do |gemfile|
sh "BUNDLE_GEMFILE='gemfiles/#{gemfile}.gemfile' bundle --quiet"
sh "BUNDLE_GEMFILE='gemfiles/#{gemfile}.gemfile' bundle exec rake spec"
end
end
end