Skip to content

Commit 94ecb36

Browse files
committed
Test version: 3.3.0
1 parent 9778377 commit 94ecb36

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

test/prism/location_test.rb

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,10 @@ def test_CallNode
174174

175175
assert_location(CallNode, "foo bar baz")
176176
assert_location(CallNode, "foo bar('baz')")
177+
178+
assert_location(CallNode, "-> { it }", 5...7, version: "3.3.0") do |node|
179+
node.body.body.first
180+
end
177181
end
178182

179183
def test_CallAndWriteNode
@@ -900,8 +904,8 @@ def test_all_tested
900904

901905
private
902906

903-
def assert_location(kind, source, expected = 0...source.length)
904-
result = Prism.parse(source)
907+
def assert_location(kind, source, expected = 0...source.length, **options)
908+
result = Prism.parse(source, **options)
905909
assert_equal [], result.comments
906910
assert_equal [], result.errors
907911

0 commit comments

Comments
 (0)