diff options
-rw-r--r-- | test/ruby/test_complex.rb | 2 | ||||
-rw-r--r-- | test/ruby/test_rational.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/test/ruby/test_complex.rb b/test/ruby/test_complex.rb index 6706b5b39f..f6d65de6de 100644 --- a/test/ruby/test_complex.rb +++ b/test/ruby/test_complex.rb @@ -7,7 +7,7 @@ class Complex_Test < Test::Unit::TestCase def setup @rational = defined?(Rational) if @rational - @keiju = Rational.instance_variable_get('@RCS_ID') + @keiju = Rational.instance_variables.include?(:@RCS_ID) end seps = [File::SEPARATOR, File::ALT_SEPARATOR].compact.map{|x| Regexp.escape(x)}.join("|") @unify = $".grep(/(?:^|#{seps})mathn(?:\.(?:rb|so))?/).size != 0 diff --git a/test/ruby/test_rational.rb b/test/ruby/test_rational.rb index 705f712bd3..02d8bd61ed 100644 --- a/test/ruby/test_rational.rb +++ b/test/ruby/test_rational.rb @@ -7,7 +7,7 @@ class Rational_Test < Test::Unit::TestCase def setup @complex = defined?(Complex) if @complex - @keiju = Complex.instance_variable_get('@RCS_ID') + @keiju = Complex.instance_variables.include?(:@RCS_ID) end seps = [File::SEPARATOR, File::ALT_SEPARATOR].compact.map{|x| Regexp.escape(x)}.join("|") @unify = $".grep(/(?:^|#{seps})mathn(?:\.(?:rb|so))?/).size != 0 |