зеркало из https://github.com/github/ruby.git
test-bundled-gems.rb: show failed gems at last
This commit is contained in:
Родитель
d3c685f0b5
Коммит
2a99fea89e
|
@ -8,6 +8,7 @@ rake = File.realpath("../../.bundle/bin/rake", __FILE__)
|
||||||
gem_dir = File.realpath('../../gems', __FILE__)
|
gem_dir = File.realpath('../../gems', __FILE__)
|
||||||
exit_code = 0
|
exit_code = 0
|
||||||
ruby = ENV['RUBY'] || RbConfig.ruby
|
ruby = ENV['RUBY'] || RbConfig.ruby
|
||||||
|
failed = []
|
||||||
File.foreach("#{gem_dir}/bundled_gems") do |line|
|
File.foreach("#{gem_dir}/bundled_gems") do |line|
|
||||||
next if /^\s*(?:#|$)/ =~ line
|
next if /^\s*(?:#|$)/ =~ line
|
||||||
gem = line.split.first
|
gem = line.split.first
|
||||||
|
@ -44,9 +45,11 @@ File.foreach("#{gem_dir}/bundled_gems") do |line|
|
||||||
if allowed_failures.include?(gem)
|
if allowed_failures.include?(gem)
|
||||||
puts "Ignoring test failures for #{gem} due to \$TEST_BUNDLED_GEMS_ALLOW_FAILURES"
|
puts "Ignoring test failures for #{gem} due to \$TEST_BUNDLED_GEMS_ALLOW_FAILURES"
|
||||||
else
|
else
|
||||||
|
failed << gem
|
||||||
exit_code = $?.exitstatus
|
exit_code = $?.exitstatus
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
puts "Failed gems: #{failed.join(', ')}" unless failed.empty?
|
||||||
exit exit_code
|
exit exit_code
|
||||||
|
|
Загрузка…
Ссылка в новой задаче