diff options
| author | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-01-07 08:56:04 +0000 |
|---|---|---|
| committer | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-01-07 08:56:04 +0000 |
| commit | a278e914cdb6e92e84a3531d599b5661f59a25a1 (patch) | |
| tree | e1c7c7a918920e23db2ab3f946df97f504275e50 /test/win32ole | |
| parent | 009596eeda00170c67fa820c2b78525cffe08a91 (diff) | |
| download | ruby-a278e914cdb6e92e84a3531d599b5661f59a25a1.tar.gz ruby-a278e914cdb6e92e84a3531d599b5661f59a25a1.tar.xz ruby-a278e914cdb6e92e84a3531d599b5661f59a25a1.zip | |
add some test. update comment for rdoc.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11507 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/win32ole')
| -rw-r--r-- | test/win32ole/test_win32ole.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/win32ole/test_win32ole.rb b/test/win32ole/test_win32ole.rb index f1bdb2c20..df7a9abfd 100644 --- a/test/win32ole/test_win32ole.rb +++ b/test/win32ole/test_win32ole.rb @@ -40,5 +40,19 @@ if defined?(WIN32OLE) name = folder.getDetailsOf({"vItem" => item, :iColumn => 0}) assert_equal(item.name, name) end + + def test_bracket + dict = WIN32OLE.new('Scripting.Dictionary') + dict.add("foo", "FOO") + assert_equal("FOO", dict.item("foo")) + assert_equal("FOO", dict["foo"]) + end + + def test_bracket_equal + dict = WIN32OLE.new('Scripting.Dictionary') + dict.add("foo", "FOO") + dict["foo"] = "BAR" + assert_equal("BAR", dict["foo"]) + end end end |
