We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents e86296d + 59ac47e commit f7b0740Copy full SHA for f7b0740
test/stdlib/FileTest_test.rb
@@ -5,12 +5,11 @@ class FileTestSingletonTest < Test::Unit::TestCase
5
6
testing "singleton(::FileTest)"
7
8
-
9
- def with_path_io(path: __FILE__, io: default=File.open(File.expand_path(__FILE__)), &block)
10
- with_path(path, &block)
11
- with_io(io, &block)
12
- ensure
13
- io.close if default
+ def with_path_io(&block)
+ with_path(__FILE__, &block)
+ File.open(File.expand_path(__FILE__)) do |io|
+ with_io(io, &block)
+ end
14
end
15
16
def test_blockdev?
0 commit comments