Removed deprecated Dir.exists? and File.exists?

This commit is contained in:
Nobuyoshi Nakada 2020-11-30 23:33:20 +09:00
parent 9e94cd18fc
commit 1a5205536f
No known key found for this signature in database
GPG key ID: 7CD2805BFA3770C6
3 changed files with 6 additions and 29 deletions

View file

@ -961,13 +961,17 @@ $stderr = $stdout; raise "\x82\xa0"') do |outs, errs, status|
end
def test_warn_deprecated_backwards_compatibility_category
warning = capture_warning_warn { Dir.exists?("non-existent") }
skip "no method to test"
warning = capture_warning_warn { }
assert_match(/deprecated/, warning[0])
end
def test_warn_deprecated_category
warning = capture_warning_warn(category: true) { Dir.exists?("non-existent") }
skip "no method to test"
warning = capture_warning_warn(category: true) { }
assert_equal :deprecated, warning[0][1]
end