diff options
author | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-04-30 23:37:54 +0000 |
---|---|---|
committer | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-04-30 23:37:54 +0000 |
commit | 9154b19baeef87742e2f854bce091f98fdd00809 (patch) | |
tree | aa370a84f07e24001a1382af7ab318a90314a867 /test/win32ole/test_win32ole_variant_m.rb | |
parent | 5c1ae872f40be7c33033cf2b45d7c8a929860a7f (diff) | |
download | ruby-9154b19baeef87742e2f854bce091f98fdd00809.tar.gz |
ole_param_ole_type should return "unknown type" string when ITypeInfo::GetFuncDesc failed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10121 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/win32ole/test_win32ole_variant_m.rb')
-rw-r--r-- | test/win32ole/test_win32ole_variant_m.rb | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/test/win32ole/test_win32ole_variant_m.rb b/test/win32ole/test_win32ole_variant_m.rb new file mode 100644 index 0000000000..1271526db9 --- /dev/null +++ b/test/win32ole/test_win32ole_variant_m.rb @@ -0,0 +1,36 @@ +# You need RubyUnit and MS Excel and MSI to run this test script + +begin + require 'win32ole' +rescue LoadError +end + +require "test/unit" + +if defined?(WIN32OLE::VARIANT) + class TestWin32OLE_VARIANT < Test::Unit::TestCase + include WIN32OLE::VARIANT + def test_variant + assert_equal(2, VT_I2) + assert_equal(3, VT_I4) + assert_equal(4, VT_R4) + assert_equal(5, VT_R8) + assert_equal(6, VT_CY) + assert_equal(7, VT_DATE) + assert_equal(8, VT_BSTR) + assert_equal(9, VT_DISPATCH) + assert_equal(10, VT_ERROR) + assert_equal(11, VT_BOOL) + assert_equal(12, VT_VARIANT) + assert_equal(13, VT_UNKNOWN) + assert_equal(16, VT_I1) + assert_equal(17, VT_UI1) + assert_equal(18, VT_UI2) + assert_equal(19, VT_UI4) + assert_equal(22, VT_INT) + assert_equal(23, VT_UINT) + assert_equal(0x2000, VT_ARRAY) + assert_equal(0x4000, VT_BYREF) + end + end +end |