1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Use \A and \z instead of ^ and $

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60358 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kazu 2017-10-22 09:16:54 +00:00
parent 208d2a95f5
commit dfee14d34c

View file

@ -146,7 +146,7 @@ end
def test_alphanumeric
65.times do |n|
an = @it.alphanumeric(n)
assert_match(/^[0-9a-zA-Z]*$/, an)
assert_match(/\A[0-9a-zA-Z]*\z/, an)
assert_equal(n, an.length)
end
end