aboutsummaryrefslogtreecommitdiffstats
path: root/test/ruby/test_regexp.rb
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-18 15:56:38 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-18 15:56:38 +0000
commit93ad576b0511ee435c01bd92e31d625d29c2c22e (patch)
treecf39c49b1154844807aa3649ef40b34f27c948d1 /test/ruby/test_regexp.rb
parentf9e00ba03f9269cbbe4cdf51590a38eb877a85e8 (diff)
downloadruby-93ad576b0511ee435c01bd92e31d625d29c2c22e.tar.gz
* re.c (rb_reg_inspect): don't raise for uninitialized Regexp.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_regexp.rb')
-rw-r--r--test/ruby/test_regexp.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/ruby/test_regexp.rb b/test/ruby/test_regexp.rb
index bce362e34f..ad222c5483 100644
--- a/test/ruby/test_regexp.rb
+++ b/test/ruby/test_regexp.rb
@@ -686,7 +686,7 @@ class TestRegexp < Test::Unit::TestCase
assert_nil(~Regexp.allocate)
assert_raise(TypeError) { Regexp.allocate.match("") }
assert_raise(TypeError) { Regexp.allocate.to_s }
- assert_raise(TypeError) { Regexp.allocate.inspect }
+ assert_match(/^#<Regexp:.*>$/, Regexp.allocate.inspect)
assert_raise(TypeError) { Regexp.allocate.source }
assert_raise(TypeError) { Regexp.allocate.casefold? }
assert_raise(TypeError) { Regexp.allocate.options }