summaryrefslogtreecommitdiff
path: root/test/rubygems
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-04 04:53:57 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-04 04:53:57 +0000
commit57940c032366f25ff118bb5b6c305fe103431e29 (patch)
treeb1920739eef372663ddeb6e9202af66890df9411 /test/rubygems
parentea56a70eb81e8f7a859f854821481f1cfc18083d (diff)
* test/rubygems/test_gem.rb (TestGem#test_self_find_files): "."
is no longer included in $LOAD_PATH. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25224 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/rubygems')
-rw-r--r--test/rubygems/test_gem.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/rubygems/test_gem.rb b/test/rubygems/test_gem.rb
index ccdd2e3c08..e18004c4ea 100644
--- a/test/rubygems/test_gem.rb
+++ b/test/rubygems/test_gem.rb
@@ -266,6 +266,8 @@ class TestGem < RubyGemTestCase
def test_self_find_files
discover_path = File.join 'lib', 'foo', 'discover.rb'
+ cwd = File.expand_path('..', __FILE__)
+ $LOAD_PATH.unshift(cwd.dup)
foo1 = quick_gem 'foo', '1' do |s|
s.files << discover_path
@@ -289,12 +291,14 @@ class TestGem < RubyGemTestCase
Gem.searcher = nil
expected = [
- File.expand_path('foo/discover.rb', File.dirname(__FILE__)),
+ File.expand_path('../foo/discover.rb', __FILE__),
File.join(foo2.full_gem_path, discover_path),
File.join(foo1.full_gem_path, discover_path),
]
assert_equal expected, Gem.find_files('foo/discover')
+ ensure
+ assert_equal(cwd, $LOAD_PATH.shift)
end
def test_self_latest_load_paths