summaryrefslogtreecommitdiff
path: root/test/rubygems/test_gem_indexer.rb
diff options
context:
space:
mode:
authorTomas Volf <tomas.volf@showmax.com>2022-06-24 09:21:47 +0200
committergit <svn-admin@ruby-lang.org>2022-06-26 11:15:43 +0900
commit56809537a46417d4c0f93de9ea9fc9a623ea83f1 (patch)
tree23332bc22898a2284231074f4d44b85af24bef23 /test/rubygems/test_gem_indexer.rb
parentf159bbd17da88a7f456e0ec7fbf7890135d456a3 (diff)
[rubygems/rubygems] Clean up temporary directory after generate_index --update
While generate_index did clean up temporary directory, when running with --update flag, that did not happen and the temporary directory was left behind. This commit fixes that and modifies tests in order to make sure this is not reintroduced later on. Fixes #5635. https://github.com/rubygems/rubygems/commit/9fa34dc329
Diffstat (limited to 'test/rubygems/test_gem_indexer.rb')
-rw-r--r--test/rubygems/test_gem_indexer.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/rubygems/test_gem_indexer.rb b/test/rubygems/test_gem_indexer.rb
index 6653f29adf..24afae5fcc 100644
--- a/test/rubygems/test_gem_indexer.rb
+++ b/test/rubygems/test_gem_indexer.rb
@@ -103,6 +103,8 @@ class TestGemIndexer < Gem::TestCase
assert_indexed @indexerdir, "latest_specs.#{@marshal_version}"
assert_indexed @indexerdir, "latest_specs.#{@marshal_version}.gz"
+
+ refute_directory_exists @indexer.directory
end
def test_generate_index_modern
@@ -342,6 +344,8 @@ class TestGemIndexer < Gem::TestCase
assert_includes pre_specs_index, @d2_1_a_tuple
refute_includes pre_specs_index, @d2_1_tuple
+
+ refute_directory_exists @indexer.directory
end
end