Skip to content
Browse files

Check RUBY_PLATFORM for mingw in addition to mswin

  • Loading branch information...
1 parent 8013ecc commit f36dfe1b404c0e6428e9c185ac023ee317dc47aa @snaury snaury committed Oct 24, 2009
Showing with 2 additions and 2 deletions.
  1. +1 −1 bin/post-setup.rb
  2. +1 −1 test/test-exitcode.rb
View
2 bin/post-setup.rb
@@ -3,7 +3,7 @@
# $Id: post-setup.rb,v 1.1 2006/04/27 01:25:21 yuya Exp $
#==============================================================================#
-if /mswin32/ =~ RUBY_PLATFORM
+if /mswin|mingw/ =~ RUBY_PLATFORM
File.open("exerb.bat", "w") { |file|
file.puts(%|@echo off|)
file.puts(%|"%~dp0ruby" -x "%~f0" %*|)
View
2 test/test-exitcode.rb
@@ -15,7 +15,7 @@ def name
end
def test_exitcode
- if RUBY_PLATFORM.include?('mswin32')
+ if /mswin|mingw/ =~ RUBY_PLATFORM
assert_equal("10\n", execute_cmd("#{@name}\\#{@name}.exe || if errorlevel 10 echo 10"))
else
assert_equal("10\n", execute_cmd("#{@name}/#{@name}.exe || echo $?"))

0 comments on commit f36dfe1

Please sign in to comment.
Something went wrong with that request. Please try again.