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,4 +1,5 @@
|
|||||||
require_relative 'test_base'
|
require_relative 'test_base'
|
||||||
|
require_relative '../ruby/envutil'
|
||||||
|
|
||||||
module DL
|
module DL
|
||||||
class TestHandle < TestBase
|
class TestHandle < TestBase
|
||||||
@ -158,9 +159,11 @@ module DL
|
|||||||
# interface, below, should be used, since getpid() is a function and not a
|
# interface, below, should be used, since getpid() is a function and not a
|
||||||
# data object.)
|
# data object.)
|
||||||
# --- FreeBSD 8.0 dlsym(3)
|
# --- FreeBSD 8.0 dlsym(3)
|
||||||
|
out, err = capture_io do
|
||||||
require 'objspace'
|
require 'objspace'
|
||||||
handle = DL::Handle::NEXT
|
print DL::Handle::NEXT.inspect
|
||||||
assert_not_nil handle['Init_objspace']
|
end
|
||||||
|
assert_match(/\A#<DL::Handle:0x[0-9a-f]+>\z/, out + err)
|
||||||
end
|
end
|
||||||
end unless /mswin|mingw/ =~ RUBY_PLATFORM
|
end unless /mswin|mingw/ =~ RUBY_PLATFORM
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user