mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[rubygems/rubygems] Check not having load system features also for successful runs
4807bd19a5
This commit is contained in:
parent
d49ee9e2c3
commit
b2b473707f
1 changed files with 3 additions and 9 deletions
|
@ -24,12 +24,6 @@ class RubygemsVersionManager
|
||||||
|
|
||||||
def assert_system_features_not_loaded!
|
def assert_system_features_not_loaded!
|
||||||
at_exit do
|
at_exit do
|
||||||
errors = if $!.nil?
|
|
||||||
""
|
|
||||||
else
|
|
||||||
all_commands_output
|
|
||||||
end
|
|
||||||
|
|
||||||
rubylibdir = RbConfig::CONFIG["rubylibdir"]
|
rubylibdir = RbConfig::CONFIG["rubylibdir"]
|
||||||
|
|
||||||
rubygems_path = rubylibdir + "/rubygems"
|
rubygems_path = rubylibdir + "/rubygems"
|
||||||
|
@ -43,11 +37,11 @@ class RubygemsVersionManager
|
||||||
(loaded_feature.start_with?(bundler_path) && !bundler_exemptions.any? {|bundler_exemption| loaded_feature.start_with?(bundler_exemption) })
|
(loaded_feature.start_with?(bundler_path) && !bundler_exemptions.any? {|bundler_exemption| loaded_feature.start_with?(bundler_exemption) })
|
||||||
end
|
end
|
||||||
|
|
||||||
if bad_loaded_features.any?
|
errors = if bad_loaded_features.any?
|
||||||
errors += "the following features were incorrectly loaded:\n#{bad_loaded_features.join("\n")}"
|
all_commands_output + "the following features were incorrectly loaded:\n#{bad_loaded_features.join("\n")}"
|
||||||
end
|
end
|
||||||
|
|
||||||
raise errors unless errors.empty?
|
raise errors if errors
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue