test: add parentheses to method calls on assignment RHS

Preparation for future grammar simplification that may
require parentheses for method calls with arguments on
the right-hand side of assignments.

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Yukihiro "Matz" Matsumoto
2026-01-26 08:58:08 +09:00
parent 9123ef46eb
commit 32a27216bb
5 changed files with 20 additions and 20 deletions
+1 -1
View File
@@ -46,7 +46,7 @@ assert('NameError', '15.2.31') do
raise NameError.new
end
e = NameError.new "msg", "name"
e = NameError.new("msg", "name")
assert_equal "msg", e.message
assert_equal "name", e.name
end
+1 -1
View File
@@ -9,7 +9,7 @@ assert('NoMethodError', '15.2.32') do
end
assert('NoMethodError#args', '15.2.32.2.1') do
a = NoMethodError.new 'test', :test, [1, 2]
a = NoMethodError.new('test', :test, [1, 2])
assert_equal [1, 2], a.args
assert_nothing_raised do