diff options
Diffstat (limited to 'test/testutil.rb')
-rw-r--r-- | test/testutil.rb | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/test/testutil.rb b/test/testutil.rb index 83f4906..92aafcc 100644 --- a/test/testutil.rb +++ b/test/testutil.rb @@ -9,16 +9,12 @@ require 'test/unit/testcase' -def _ruby_ver_str # :nodoc: - return /\d+\.\d+/.match(RUBY_VERSION)[0] -end - def ruby18? # :nodoc: - _ruby_ver_str() == "1.8" + RUBY_VERSION =~ /\A1.8/ end def ruby19? # :nodoc: - _ruby_ver_str() > "1.8" + RUBY_VERSION =~ /\A1.9/ end |