[rubygems/rubygems] Fix leaked tempfiles
Fix up https://github.com/rubygems/rubygems/pull/6882 https://github.com/rubygems/rubygems/commit/525b94a89f
This commit is contained in:
parent
795587386c
commit
70ce3c8947
@ -216,6 +216,8 @@ class TestGemPackageTarReaderEntry < Gem::Package::TarTestCase
|
|||||||
corrupt_entry.rewind
|
corrupt_entry.rewind
|
||||||
|
|
||||||
assert_nil corrupt_entry.read(100), "IO.read with len should return nil as per IO.read docs"
|
assert_nil corrupt_entry.read(100), "IO.read with len should return nil as per IO.read docs"
|
||||||
|
ensure
|
||||||
|
close_util_entry(corrupt_entry) if corrupt_entry
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_readpartial_corrupted_tar
|
def test_readpartial_corrupted_tar
|
||||||
@ -228,6 +230,8 @@ class TestGemPackageTarReaderEntry < Gem::Package::TarTestCase
|
|||||||
assert_raise EOFError do
|
assert_raise EOFError do
|
||||||
corrupt_entry.readpartial(100)
|
corrupt_entry.readpartial(100)
|
||||||
end
|
end
|
||||||
|
ensure
|
||||||
|
close_util_entry(corrupt_entry) if corrupt_entry
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_rewind
|
def test_rewind
|
||||||
|
Loading…
x
Reference in New Issue
Block a user