зеркало из https://github.com/github/ruby.git
[rubygems/rubygems] Check if failed with the expected error
https://github.com/rubygems/rubygems/commit/3f22e9df8d
This commit is contained in:
Родитель
e345970707
Коммит
92ab2dac22
|
@ -333,9 +333,15 @@ install:
|
|||
f.puts "RbConfig::CONFIG['platform'] = 'fake_platform'"
|
||||
end
|
||||
|
||||
stdout, stderr = capture_subprocess_io do
|
||||
system(Gem.ruby, "-rmkmf", "-e", "exit MakeMakefile::RbConfig::CONFIG['host_os'] == 'fake_os'",
|
||||
"--", "--target-rbconfig=#{fake_rbconfig}")
|
||||
pend "This version of mkmf does not support --target-rbconfig" unless $?.success?
|
||||
end
|
||||
unless $?.success?
|
||||
assert_include(stderr, "uninitialized constant MakeMakefile::RbConfig")
|
||||
pend "This version of mkmf does not support --target-rbconfig"
|
||||
end
|
||||
assert_empty(stdout)
|
||||
|
||||
@spec.extensions << "extconf.rb"
|
||||
@builder = Gem::Ext::Builder.new @spec, "", Gem::TargetRbConfig.from_path(fake_rbconfig)
|
||||
|
|
Загрузка…
Ссылка в новой задаче