зеркало из https://github.com/github/ruby.git
[rubygems/rubygems] Fix Tempfile leaks
https://github.com/rubygems/rubygems/commit/f95d1a87ce
This commit is contained in:
Родитель
06195e7603
Коммит
e37bf46ed5
|
@ -199,6 +199,8 @@ class TestGemPackageTarReaderEntry < Gem::Package::TarTestCase
|
|||
expected = StringIO.new("")
|
||||
|
||||
assert_equal expected.read, zero_entry.read
|
||||
ensure
|
||||
close_util_entry(zero_entry) if zero_entry
|
||||
end
|
||||
|
||||
def test_zero_byte_file_readpartial
|
||||
|
@ -206,5 +208,7 @@ class TestGemPackageTarReaderEntry < Gem::Package::TarTestCase
|
|||
expected = StringIO.new("")
|
||||
|
||||
assert_equal expected.readpartial(0), zero_entry.readpartial(0)
|
||||
ensure
|
||||
close_util_entry(zero_entry) if zero_entry
|
||||
end
|
||||
end
|
||||
|
|
Загрузка…
Ссылка в новой задаче