mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Run another process to avoid failure when objspace is already loaded
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
9709448474
commit
40bae2f67c
1 changed files with 6 additions and 3 deletions
|
@ -1,4 +1,5 @@
|
|||
require_relative 'test_base'
|
||||
require_relative '../ruby/envutil'
|
||||
|
||||
module DL
|
||||
class TestHandle < TestBase
|
||||
|
@ -158,9 +159,11 @@ module DL
|
|||
# interface, below, should be used, since getpid() is a function and not a
|
||||
# data object.)
|
||||
# --- FreeBSD 8.0 dlsym(3)
|
||||
require 'objspace'
|
||||
handle = DL::Handle::NEXT
|
||||
assert_not_nil handle['Init_objspace']
|
||||
out, err = capture_io do
|
||||
require 'objspace'
|
||||
print DL::Handle::NEXT.inspect
|
||||
end
|
||||
assert_match(/\A#<DL::Handle:0x[0-9a-f]+>\z/, out + err)
|
||||
end
|
||||
end unless /mswin|mingw/ =~ RUBY_PLATFORM
|
||||
|
||||
|
|
Loading…
Reference in a new issue