mirror of
https://github.com/ruby/ruby.git
synced 2025-09-15 16:44:01 +02:00
Revert "Removed deprecated Dir.exists? and File.exists?"
This reverts commit 1a5205536f
.
This commit is contained in:
parent
1a5205536f
commit
4e01ab342a
3 changed files with 29 additions and 6 deletions
|
@ -961,17 +961,13 @@ $stderr = $stdout; raise "\x82\xa0"') do |outs, errs, status|
|
|||
end
|
||||
|
||||
def test_warn_deprecated_backwards_compatibility_category
|
||||
skip "no method to test"
|
||||
|
||||
warning = capture_warning_warn { }
|
||||
warning = capture_warning_warn { Dir.exists?("non-existent") }
|
||||
|
||||
assert_match(/deprecated/, warning[0])
|
||||
end
|
||||
|
||||
def test_warn_deprecated_category
|
||||
skip "no method to test"
|
||||
|
||||
warning = capture_warning_warn(category: true) { }
|
||||
warning = capture_warning_warn(category: true) { Dir.exists?("non-existent") }
|
||||
|
||||
assert_equal :deprecated, warning[0][1]
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue