diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-10 09:04:00 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-10 09:04:00 +0000 |
commit | ef2c94bc39ef1619c2c25b7eb9acaf2d4cb5bba0 (patch) | |
tree | 10341aa3691c8fc0f2e0911461ffbc4b1f819451 /test | |
parent | 2c490bea5b4eb31ae20386bc88d46d2ff432f407 (diff) |
Revert r55357 because of test failures.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@55365 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/rubygems/test_require.rb | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/test/rubygems/test_require.rb b/test/rubygems/test_require.rb index 8aa9aac38c..dec5285d21 100644 --- a/test/rubygems/test_require.rb +++ b/test/rubygems/test_require.rb @@ -49,36 +49,6 @@ class TestGemRequire < Gem::TestCase end end - # Providing -I on the commandline should always beat gems - def test_dash_i_beats_gems - a1 = new_spec "a", "1", {"b" => "= 1"}, "lib/test_gem_require_a.rb" - b1 = new_spec "b", "1", {"c" => "> 0"}, "lib/b/c.rb" - c1 = new_spec "c", "1", nil, "lib/c/c.rb" - c2 = new_spec "c", "2", nil, "lib/c/c.rb" - - install_specs c1, c2, b1, a1 - - dir = Dir.mktmpdir - dash_i_arg = File.join Dir.mktmpdir, 'lib' - - c_rb = File.join dash_i_arg, 'b', 'c.rb' - - FileUtils.mkdir_p File.dirname c_rb - File.open(c_rb, 'w') { |f| f.write "class Object; HELLO = 'world' end" } - - lp = $LOAD_PATH.dup - - # Pretend to provide a commandline argument that overrides a file in gem b - $LOAD_PATH.unshift dash_i_arg - - assert_require 'test_gem_require_a' - assert_require 'b/c' # this should be required from -I - assert_equal "world", ::Object::HELLO - ensure - $LOAD_PATH.replace lp - Object.send :remove_const, :HELLO if Object.const_defined? :HELLO - end - def test_concurrent_require Object.const_set :FILE_ENTERED_LATCH, Latch.new(2) Object.const_set :FILE_EXIT_LATCH, Latch.new(1) |