From 9ac817ae7820d6cc6a7658997a63584daea1a296 Mon Sep 17 00:00:00 2001 From: Carson McDonald Date: Mon, 28 Apr 2014 14:22:55 -0400 Subject: Add tests for multiline comment parsing --- test/t/syntax.rb | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/test/t/syntax.rb b/test/t/syntax.rb index 159b36574..0bb3fa389 100644 --- a/test/t/syntax.rb +++ b/test/t/syntax.rb @@ -293,3 +293,19 @@ end assert('optional block argument in the rhs default expressions') do assert_nil(Proc.new {|foo = foo| foo}.call) end + +assert('multiline comments work correctly') do +=begin +this is a comment with nothing after begin and end +=end +=begin this is a comment +this is a comment with extra after =begin +=end +=begin +this is a comment that has =end with spaces after it +=end +=begin this is a comment +this is a comment that has extra after =begin and =end with spaces after it +=end + true +end -- cgit v1.2.3