Skip to content

Commit

Permalink
Use FRAMEWORKS constant from tasks/release to avoid duplication
Browse files Browse the repository at this point in the history
  • Loading branch information
arunagw committed Dec 17, 2015
1 parent d9d8fca commit cbed616
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions Rakefile
Expand Up @@ -10,16 +10,14 @@ task :build => "all:build"
desc "Release all gems to rubygems and create a tag"
task :release => "all:release"

PROJECTS = %w(activesupport activemodel actionpack actionview actionmailer activerecord railties activejob)

desc 'Run all tests by default'
task :default => %w(test test:isolated)

%w(test test:isolated package gem).each do |task_name|
desc "Run #{task_name} task for all projects"
task task_name do
errors = []
PROJECTS.each do |project|
FRAMEWORKS.each do |project|
system(%(cd #{project} && #{$0} #{task_name})) || errors << project
end
fail("Errors in #{errors.join(', ')}") unless errors.empty?
Expand All @@ -28,7 +26,7 @@ end

desc "Smoke-test all projects"
task :smoke do
(PROJECTS - %w(activerecord)).each do |project|
(FRAMEWORKS - %w(activerecord)).each do |project|
system %(cd #{project} && #{$0} test:isolated)
end
system %(cd activerecord && #{$0} sqlite3:isolated_test)
Expand Down

0 comments on commit cbed616

Please sign in to comment.