ruby-changes:60897
From: Nobuyoshi <ko1@a...>
Date: Sat, 25 Apr 2020 02:51:17 +0900 (JST)
Subject: [ruby-changes:60897] ae235db25d (master): [ruby/rdoc] Should teardown in reverse order of setup
https://git.ruby-lang.org/ruby.git/commit/?id=ae235db25d From ae235db25d6d6437862d4823d053d42702d1a07a Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Sat, 25 Apr 2020 00:19:01 +0900 Subject: [ruby/rdoc] Should teardown in reverse order of setup https://github.com/ruby/rdoc/commit/00fb4dd2a3 diff --git a/test/rdoc/test_rdoc_parser_changelog.rb b/test/rdoc/test_rdoc_parser_changelog.rb index cb64062..d93cb7d 100644 --- a/test/rdoc/test_rdoc_parser_changelog.rb +++ b/test/rdoc/test_rdoc_parser_changelog.rb @@ -14,6 +14,8 @@ class TestRDocParserChangeLog < RDoc::TestCase https://github.com/ruby/ruby/blob/trunk/test/rdoc/test_rdoc_parser_changelog.rb#L14 def teardown @tempfile.close! + + super end def test_class_can_parse diff --git a/test/rdoc/test_rdoc_ri_driver.rb b/test/rdoc/test_rdoc_ri_driver.rb index 1a8ac3d..e623233 100644 --- a/test/rdoc/test_rdoc_ri_driver.rb +++ b/test/rdoc/test_rdoc_ri_driver.rb @@ -33,11 +33,11 @@ class TestRDocRIDriver < RDoc::TestCase https://github.com/ruby/ruby/blob/trunk/test/rdoc/test_rdoc_ri_driver.rb#L33 end def teardown - super - ENV['HOME'] = @orig_home ENV['RI'] = @orig_ri FileUtils.rm_rf @tmpdir + + super end DUMMY_PAGER = ":;\n" diff --git a/test/rdoc/test_rdoc_ri_paths.rb b/test/rdoc/test_rdoc_ri_paths.rb index 726922d..78e1a04 100644 --- a/test/rdoc/test_rdoc_ri_paths.rb +++ b/test/rdoc/test_rdoc_ri_paths.rb @@ -36,12 +36,12 @@ class TestRDocRIPaths < RDoc::TestCase https://github.com/ruby/ruby/blob/trunk/test/rdoc/test_rdoc_ri_paths.rb#L36 end def teardown - super - Gem.use_paths(*@orig_gem_path) Gem::Specification.reset FileUtils.rm_rf @tempdir ENV.replace(@orig_env) + + super end def test_class_each -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/