forked from minitest/minitest-rails
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathRakefile
36 lines (31 loc) · 774 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
33
34
35
36
require "bundler"
require "bundler/setup"
require "bundler/gem_tasks"
require "rdoc/task"
RDoc::Task.new do |rdoc|
rdoc.main = "README.md"
rdoc.title = "minitest-rails"
rdoc.rdoc_files.include "README.md", "lib/**/*.rb"
rdoc.rdoc_dir = "doc"
end
require "rubocop/rake_task"
RuboCop::RakeTask.new
require "rake/testtask"
desc "Run tests."
Rake::TestTask.new do |t|
t.libs << "test"
t.test_files = FileList["test/**/test_*.rb"]
t.warning = false
t.verbose = false
end
namespace :test do
desc "Run tests for all Rails versions"
task "all" do
Dir.glob("gemfiles/*.gemfile").each do |gemfile|
Bundler.with_clean_env do
sh "bundle --gemfile=#{gemfile} && bundle exec rake test"
end
end
end
end
task default: %i[test rubocop]