From 829177b50921ae6f8852c0e9ec1369f5dbd09246 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Wed, 2 Dec 2020 15:36:35 +0900 Subject: [PATCH] Remove deprecated DBM#index --- stdlib/dbm/0/dbm.rbs | 2 -- test/stdlib/DBM_test.rb | 6 ------ 2 files changed, 8 deletions(-) diff --git a/stdlib/dbm/0/dbm.rbs b/stdlib/dbm/0/dbm.rbs index 78c5517e2..3dc588d3a 100644 --- a/stdlib/dbm/0/dbm.rbs +++ b/stdlib/dbm/0/dbm.rbs @@ -138,8 +138,6 @@ class DBM # def include?: (String) -> bool - def index: (untyped) -> (String | NilClass) - # Returns a Hash (not a DBM database) created by using each value in the # database as a key, with the corresponding key as its value. # diff --git a/test/stdlib/DBM_test.rb b/test/stdlib/DBM_test.rb index 023d762c2..c7bc42aed 100644 --- a/test/stdlib/DBM_test.rb +++ b/test/stdlib/DBM_test.rb @@ -80,12 +80,6 @@ def test_invert assert_send_type "() -> Hash[untyped, String]", @dbm, :invert end - def test_index - @dbm["key3"] = 1 - assert_send_type "(untyped) -> (String | NilClass)", @dbm, :index, "key1" - assert_send_type "(untyped) -> (String | NilClass)", @dbm, :index, "keaaaay1" - end - def test_key @dbm["key_key"] = 1 assert_send_type "(untyped) -> (String | NilClass)", @dbm, :key, "key_key"