summaryrefslogtreecommitdiff
path: root/test/win32ole/test_win32ole_method.rb
diff options
context:
space:
mode:
authorsuke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-06 12:38:49 +0000
committersuke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-06 12:38:49 +0000
commit696e6a9b7655c5dd32c4468c105e2a471f712cd6 (patch)
treedbd4b5fc2e27c72c4bf12028dd22f4032892fc71 /test/win32ole/test_win32ole_method.rb
parent0ca8c28e4d250e90e368a62fd2cc5edb2098cb90 (diff)
* ext/win32ole/win32ole.c (fole_s_connect, fole_initialize,
folevariant_initialize): check argument type of WIN32OLE.connect, WIN32OLE.new, WIN32OLE_VARIANT.new. * test/win32ole/test_win32ole.rb (test_s_new_exc, test_s_connect_exc): ditto. * test/win32ole/test_win32ole_variant.rb (test_s_new_exc): ditto. * test/win32ole/test_win32ole_method.rb: add assertion of WIN32OLE_METHOD.new. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20113 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/win32ole/test_win32ole_method.rb')
-rw-r--r--test/win32ole/test_win32ole_method.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/win32ole/test_win32ole_method.rb b/test/win32ole/test_win32ole_method.rb
index 161b10233f1..f2ed0c622cf 100644
--- a/test/win32ole/test_win32ole_method.rb
+++ b/test/win32ole/test_win32ole_method.rb
@@ -24,6 +24,9 @@ if defined?(WIN32OLE_METHOD)
def test_initialize
ole_type = WIN32OLE_TYPE.new("Microsoft Shell Controls And Automation", "Shell")
+ assert_raise(TypeError) {
+ WIN32OLE_METHOD.new(1, 2)
+ }
assert_raise(ArgumentError) {
method = WIN32OLE_METHOD.new("foo")
}