mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Fixed RbConfig spec for multiarch
This commit is contained in:
parent
7072e0324e
commit
8c80922c82
1 changed files with 7 additions and 6 deletions
|
@ -39,12 +39,13 @@ describe 'RbConfig::CONFIG' do
|
|||
|
||||
guard -> {RbConfig::TOPDIR} do
|
||||
it "libdir/LIBRUBY_SO is the path to libruby and it exists if and only if ENABLE_SHARED" do
|
||||
if RbConfig::CONFIG['ENABLE_SHARED'] == 'yes'
|
||||
libdir = RbConfig::CONFIG['libdir']
|
||||
File.should.exist?("#{libdir}/#{RbConfig::CONFIG['LIBRUBY_SO']}")
|
||||
elsif RbConfig::CONFIG['ENABLE_SHARED'] == 'no'
|
||||
libdir = RbConfig::CONFIG['libdir']
|
||||
File.should_not.exist?("#{libdir}/#{RbConfig::CONFIG['LIBRUBY_SO']}")
|
||||
libdir = RbConfig::CONFIG[RbConfig::CONFIG['libdirname'] || 'libdir']
|
||||
libruby_so = "#{libdir}/#{RbConfig::CONFIG['LIBRUBY_SO']}"
|
||||
case RbConfig::CONFIG['ENABLE_SHARED']
|
||||
when 'yes'
|
||||
File.should.exist?(libruby_so)
|
||||
when 'no'
|
||||
File.should_not.exist?(libruby_so)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue