aboutsummaryrefslogtreecommitdiffstats
path: root/test/uri
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-01-05 02:57:21 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-01-05 02:57:21 +0000
commit87fe4480919baaa9f0a37b9444912bae98220395 (patch)
tree009041b5d33be9702204ffd0ec83a079021a5ef8 /test/uri
parent4157d6f2f3b49a809da95acd9cce8ed677a072b8 (diff)
downloadruby-87fe4480919baaa9f0a37b9444912bae98220395.tar.gz
* lib/uri/common.rb (URI::Parser#initialize_regexp):
use \A \z instead of ^ $. [Bug #5843] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34214 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/uri')
-rw-r--r--test/uri/test_generic.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/uri/test_generic.rb b/test/uri/test_generic.rb
index cfd92e7b26..2c9bdd00fa 100644
--- a/test/uri/test_generic.rb
+++ b/test/uri/test_generic.rb
@@ -692,6 +692,7 @@ class URI::TestGeneric < Test::Unit::TestCase
uri = URI.parse('http://example.com')
assert_raise(URI::InvalidURIError) { uri.password = 'bar' }
+ assert_raise(URI::InvalidComponentError) { uri.query = "foo\nbar" }
uri.userinfo = 'foo:bar'
assert_equal('http://foo:bar@example.com', uri.to_s)
assert_raise(URI::InvalidURIError) { uri.registry = 'bar' }