summaryrefslogtreecommitdiffstats
path: root/test/ruby/test_regexp.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_regexp.rb')
-rw-r--r--test/ruby/test_regexp.rb7
1 files changed, 2 insertions, 5 deletions
diff --git a/test/ruby/test_regexp.rb b/test/ruby/test_regexp.rb
index 29783d415..17fe9fa45 100644
--- a/test/ruby/test_regexp.rb
+++ b/test/ruby/test_regexp.rb
@@ -123,6 +123,8 @@ class TestRegexp < Test::Unit::TestCase
r = /./
m = r.match("a")
assert_equal(r, m.regexp)
+ re = /foo/
+ assert_equal(re, re.match("foo").regexp)
end
def test_source
@@ -188,11 +190,6 @@ class TestRegexp < Test::Unit::TestCase
assert_equal(/foo/, m.dup.regexp)
end
- def test_match_regexp
- re = /foo/
- assert_equal(re, re.match("foo").regexp)
- end
-
def test_match_size
m = /(.)(.)(\d+)(\d)/.match("THX1138.")
assert_equal(5, m.size)