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

bug number

* test/ruby/test_syntax.rb (test_keyword_rest): give the bug number to assertions.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2012-03-16 08:38:13 +00:00
parent 19451891d8
commit a87f0aa071

View file

@ -81,13 +81,13 @@ class TestSyntax < Test::Unit::TestCase
def test_keyword_rest
bug5989 = '[ruby-core:42455]'
assert_valid_syntax("def kwrest_test(**a) a; end", __FILE__)
assert_valid_syntax("def kwrest_test2(**a, &b) end", __FILE__)
assert_valid_syntax("def kwrest_test(**a) a; end", __FILE__, bug5989)
assert_valid_syntax("def kwrest_test2(**a, &b) end", __FILE__, bug5989)
o = Object.new
def o.kw(**a) a end
assert_equal({}, o.kw)
assert_equal({foo: 1}, o.kw(foo: 1))
assert_equal({foo: 1, bar: 2}, o.kw(foo: 1, bar: 2))
assert_equal({}, o.kw, bug5989)
assert_equal({foo: 1}, o.kw(foo: 1), bug5989)
assert_equal({foo: 1, bar: 2}, o.kw(foo: 1, bar: 2), bug5989)
end
def test_warn_grouped_expression