aboutsummaryrefslogtreecommitdiffstats
path: root/test/rubygems/test_gem_ext_ext_conf_builder.rb
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-01-24 02:38:57 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-01-24 02:38:57 +0000
commit5d438215365e1a5dc3da7172a511a335aa58a5b4 (patch)
tree72ac80942856be3a5370dea6458f3b6dfce671e4 /test/rubygems/test_gem_ext_ext_conf_builder.rb
parent6219b68fb53a77a221f615d47dde83fea0a7e7c8 (diff)
downloadruby-5d438215365e1a5dc3da7172a511a335aa58a5b4.tar.gz
Update Rubygems 2.6.10
* https://github.com/rubygems/rubygems/commit/2ee5bf9fd3bd7649d3e244bc40107ff32070ef47 * https://github.com/rubygems/rubygems/commit/be510dd4097e65c6a256a6e173d6b724a3a96472 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/rubygems/test_gem_ext_ext_conf_builder.rb')
-rw-r--r--test/rubygems/test_gem_ext_ext_conf_builder.rb23
1 files changed, 23 insertions, 0 deletions
diff --git a/test/rubygems/test_gem_ext_ext_conf_builder.rb b/test/rubygems/test_gem_ext_ext_conf_builder.rb
index f5d10fae50..b43ebf00d9 100644
--- a/test/rubygems/test_gem_ext_ext_conf_builder.rb
+++ b/test/rubygems/test_gem_ext_ext_conf_builder.rb
@@ -111,6 +111,29 @@ class TestGemExtExtConfBuilder < Gem::TestCase
assert_match(/^#{Gem.ruby}.* extconf.rb/, output[1])
assert_match(File.join(@dest_path, 'mkmf.log'), output[4])
+ assert_includes(output, "To see why this extension failed to compile, please check the mkmf.log which can be found here:\n")
+
+ assert_path_exists File.join @dest_path, 'mkmf.log'
+ end
+
+ def test_class_build_extconf_success_without_warning
+ if vc_windows? && !nmake_found?
+ skip("test_class_build_extconf_fail skipped - nmake not found")
+ end
+
+ File.open File.join(@ext, 'extconf.rb'), 'w' do |extconf|
+ extconf.puts "require 'mkmf'"
+ extconf.puts "File.open('mkmf.log', 'w'){|f| f.write('a')}"
+ extconf.puts "create_makefile 'foo'"
+ end
+
+ output = []
+
+ Dir.chdir @ext do
+ Gem::Ext::ExtConfBuilder.build 'extconf.rb', nil, @dest_path, output
+ end
+
+ refute_includes(output, "To see why this extension failed to compile, please check the mkmf.log which can be found here:\n")
assert_path_exists File.join @dest_path, 'mkmf.log'
end