summaryrefslogtreecommitdiff
path: root/test/psych/helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/psych/helper.rb')
-rw-r--r--test/psych/helper.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/psych/helper.rb b/test/psych/helper.rb
index 11b2216..0111e11 100644
--- a/test/psych/helper.rb
+++ b/test/psych/helper.rb
@@ -5,7 +5,13 @@ require 'date'
require 'psych'
module Psych
- class TestCase < MiniTest::Unit::TestCase
+ superclass = if defined?(Minitest::Test)
+ Minitest::Test
+ else
+ MiniTest::Unit::TestCase
+ end
+
+ class TestCase < superclass
def self.suppress_warning
verbose, $VERBOSE = $VERBOSE, nil
yield