From 31c94ffeb5f09d09ac2c86fc9e6614e38251a43d Mon Sep 17 00:00:00 2001 From: drbrain Date: Tue, 9 Jun 2009 21:38:59 +0000 Subject: Update to RubyGems 1.3.4 r2223 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23659 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/rubygems/test_gem_ext_ext_conf_builder.rb | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) (limited to 'test/rubygems/test_gem_ext_ext_conf_builder.rb') diff --git a/test/rubygems/test_gem_ext_ext_conf_builder.rb b/test/rubygems/test_gem_ext_ext_conf_builder.rb index d178c1f737..e815a6555f 100644 --- a/test/rubygems/test_gem_ext_ext_conf_builder.rb +++ b/test/rubygems/test_gem_ext_ext_conf_builder.rb @@ -14,6 +14,10 @@ class TestGemExtExtConfBuilder < RubyGemTestCase end def test_class_build + if vc_windows? && !nmake_found? + skip("test_class_build skipped - nmake not found") + end + File.open File.join(@ext, 'extconf.rb'), 'w' do |extconf| extconf.puts "require 'mkmf'\ncreate_makefile 'foo'" end @@ -46,6 +50,10 @@ class TestGemExtExtConfBuilder < RubyGemTestCase end def test_class_build_extconf_fail + 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 "have_library 'nonexistent' or abort 'need libnonexistent'" @@ -69,6 +77,10 @@ checking for main\(\) in .*?nonexistent/m, error.message) end def test_class_make + if vc_windows? && !nmake_found? + skip("test_class_make skipped - nmake not found") + end + output = [] makefile_path = File.join(@ext, 'Makefile') File.open makefile_path, 'w' do |makefile| @@ -82,14 +94,8 @@ checking for main\(\) in .*?nonexistent/m, error.message) Gem::Ext::ExtConfBuilder.make @ext, output end - case RUBY_PLATFORM - when /mswin/ then - assert_equal 'nmake', output[0] - assert_equal 'nmake install', output[2] - else - assert_equal 'make', output[0] - assert_equal 'make install', output[2] - end + assert_equal make_command, output[0] + assert_equal "#{make_command} install", output[2] edited_makefile = <<-EOF RUBYARCHDIR = #{@ext}$(target_prefix) -- cgit v1.2.3