diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2020-04-25 00:19:01 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2020-04-25 02:49:35 +0900 |
commit | ae235db25d6d6437862d4823d053d42702d1a07a (patch) | |
tree | ea6bf0e55c9f951e000fbc5a9f2b2db8690a2858 /test/rdoc | |
parent | cf5b3d6798509631b7b4dd72ff3d5dedc68c0d25 (diff) | |
download | ruby-ae235db25d6d6437862d4823d053d42702d1a07a.tar.gz |
[ruby/rdoc] Should teardown in reverse order of setup
https://github.com/ruby/rdoc/commit/00fb4dd2a3
Diffstat (limited to 'test/rdoc')
-rw-r--r-- | test/rdoc/test_rdoc_parser_changelog.rb | 2 | ||||
-rw-r--r-- | test/rdoc/test_rdoc_ri_driver.rb | 4 | ||||
-rw-r--r-- | test/rdoc/test_rdoc_ri_paths.rb | 4 |
3 files changed, 6 insertions, 4 deletions
diff --git a/test/rdoc/test_rdoc_parser_changelog.rb b/test/rdoc/test_rdoc_parser_changelog.rb index cb6406259c..d93cb7deca 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 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 1a8ac3dde5..e62323338b 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 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 726922daf0..78e1a04f73 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 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 |