diff options
| author | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-11-11 11:02:15 +0000 |
|---|---|---|
| committer | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-11-11 11:02:15 +0000 |
| commit | 54162f91bdb7d30f9c4fed1956081f8b3b78f087 (patch) | |
| tree | 03a8d8e0b7a184856bfb7f004d33ba949f114407 /test | |
| parent | 2a333424b7317c9410e08b24c273b3fbc76f5bf9 (diff) | |
| download | ruby-54162f91bdb7d30f9c4fed1956081f8b3b78f087.tar.gz ruby-54162f91bdb7d30f9c4fed1956081f8b3b78f087.tar.xz ruby-54162f91bdb7d30f9c4fed1956081f8b3b78f087.zip | |
merges r20170 from trunk into ruby_1_9-1.
* test/sdbm/test_sdbm.rb (TestSDBM#test_index): Reflect the method
name change from #index to #key and remove a duplicated test
method.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@20204 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
| -rw-r--r-- | test/sdbm/test_sdbm.rb | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/test/sdbm/test_sdbm.rb b/test/sdbm/test_sdbm.rb index b7e849830..b94e198e9 100644 --- a/test/sdbm/test_sdbm.rb +++ b/test/sdbm/test_sdbm.rb @@ -199,9 +199,9 @@ class TestSDBM < Test::Unit::TestCase } end - def test_index + def test_key assert_equal('bar', @sdbm['foo'] = 'bar') - assert_equal('foo', @sdbm.index('bar')) + assert_equal('foo', @sdbm.key('bar')) assert_nil(@sdbm['bar']) end @@ -277,7 +277,7 @@ class TestSDBM < Test::Unit::TestCase n = 0 ret = @sdbm.each_value {|val| - assert_not_nil(key = @sdbm.index(val)) + assert_not_nil(key = @sdbm.key(val)) assert_not_nil(i = keys.index(key)) assert_equal(val, values[i]) @@ -530,12 +530,6 @@ class TestSDBM < Test::Unit::TestCase @sdbm = SDBM.new(@path) end - def test_index - assert_equal(nil, @sdbm.index("foo")) - @sdbm["bar"] = "foo" - assert_equal("bar", @sdbm.index("foo")) - end - def test_readonly @sdbm["bar"] = "baz" @sdbm.close |
