ruby-changes:25499
From: usa <ko1@a...>
Date: Thu, 8 Nov 2012 14:52:18 +0900 (JST)
Subject: [ruby-changes:25499] usa:r37556 (ruby_1_9_3): merge revision(s) 36641: [Backport #7295]
usa 2012-11-08 14:52:04 +0900 (Thu, 08 Nov 2012) New Revision: 37556 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=37556 Log: merge revision(s) 36641: [Backport #7295] * test/win32ole/test_win32ole_variant.rb: setting WIN32OLE.locale to pass some assertion. Thanks to Hiroshi Shirosaki. [ruby-core:46873][Bug #6814] Modified directories: branches/ruby_1_9_3/ Modified files: branches/ruby_1_9_3/ChangeLog branches/ruby_1_9_3/test/win32ole/test_win32ole_variant.rb branches/ruby_1_9_3/version.h Index: ruby_1_9_3/ChangeLog =================================================================== --- ruby_1_9_3/ChangeLog (revision 37555) +++ ruby_1_9_3/ChangeLog (revision 37556) @@ -1,3 +1,9 @@ +Thu Nov 8 14:50:02 2012 Masaki Suketa <masaki.suketa@n...> + + * test/win32ole/test_win32ole_variant.rb: setting WIN32OLE.locale + to pass some assertion. Thanks to Hiroshi Shirosaki. + [ruby-core:46873][Bug #6814] + Thu Nov 8 14:46:17 2012 Masaki Suketa <masaki.suketa@n...> * test/win32ole/test_win32ole.rb (test_s_codepage_changed): Index: ruby_1_9_3/version.h =================================================================== --- ruby_1_9_3/version.h (revision 37555) +++ ruby_1_9_3/version.h (revision 37556) @@ -1,5 +1,5 @@ #define RUBY_VERSION "1.9.3" -#define RUBY_PATCHLEVEL 312 +#define RUBY_PATCHLEVEL 313 #define RUBY_RELEASE_DATE "2012-11-08" #define RUBY_RELEASE_YEAR 2012 Index: ruby_1_9_3/test/win32ole/test_win32ole_variant.rb =================================================================== --- ruby_1_9_3/test/win32ole/test_win32ole_variant.rb (revision 37555) +++ ruby_1_9_3/test/win32ole/test_win32ole_variant.rb (revision 37556) @@ -12,7 +12,15 @@ if defined?(WIN32OLE_VARIANT) class TestWIN32OLE_VARIANT < Test::Unit::TestCase + def setup + @orglocale = WIN32OLE.locale + WIN32OLE.locale = 0x0409 # set locale US-Eng + end + def teardown + WIN32OLE.locale = @orglocale + end + def test_s_new obj = WIN32OLE_VARIANT.new('foo') assert_instance_of(WIN32OLE_VARIANT, obj) @@ -395,18 +403,14 @@ def test_conversion_str2cy begin - begin - WIN32OLE.locale = 0x0411 # set locale Japanese - rescue WIN32OLERuntimeError - STDERR.puts("\n#{__FILE__}:#{__LINE__}:#{self.class.name}.test_conversion_str2cy is skipped(Japanese locale is not installed)") - end - if WIN32OLE.locale == 0x0411 - obj = WIN32OLE_VARIANT.new("\\10,000", WIN32OLE::VARIANT::VT_CY) - assert_equal("10000", obj.value) - end - ensure - WIN32OLE.locale = WIN32OLE::LOCALE_SYSTEM_DEFAULT + WIN32OLE.locale = 0x0411 # set locale Japanese + rescue WIN32OLERuntimeError + skip("Japanese locale is not installed") end + if WIN32OLE.locale == 0x0411 + obj = WIN32OLE_VARIANT.new("\\10,000", WIN32OLE::VARIANT::VT_CY) + assert_equal("10000", obj.value) + end end def test_create_vt_array Property changes on: ruby_1_9_3 ___________________________________________________________________ Modified: svn:mergeinfo Merged /trunk:r36641 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/