summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/ripper/test_parser_events.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ripper/test_parser_events.rb b/test/ripper/test_parser_events.rb
index d28328da9d..3025025fa8 100644
--- a/test/ripper/test_parser_events.rb
+++ b/test/ripper/test_parser_events.rb
@@ -152,6 +152,12 @@ class TestRipper::ParserEvents < Test::Unit::TestCase
assert_equal true, thru_arg_ambiguous
end
+ def test_operator_ambiguous
+ thru_operator_ambiguous = false
+ parse('a=1; a //', :on_operator_ambiguous) {thru_operator_ambiguous = true}
+ assert_equal true, thru_operator_ambiguous
+ end
+
def test_array # array literal
assert_equal '[array([1,2,3])]', parse('[1,2,3]')
end