From bfc2cbc69abc7866de6f03489c63dc27ca89847c Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Tue, 2 Apr 2013 22:24:52 +0200 Subject: [PATCH] t/201-config-parser: add test for quotes in comments --- testcases/t/201-config-parser.t | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/testcases/t/201-config-parser.t b/testcases/t/201-config-parser.t index 6a49ff78..151103d7 100644 --- a/testcases/t/201-config-parser.t +++ b/testcases/t/201-config-parser.t @@ -448,6 +448,21 @@ is(parser_calls($config), $expected, 'errors dont harm subsequent statements'); +################################################################################ +# Regression: semicolons end comments, but shouldn’t +################################################################################ + +$config = <<'EOT'; +# "foo" client.focused #4c7899 #285577 #ffffff #2e9ef4 +EOT + +$expected = <<'EOT'; + +EOT + +is(parser_calls($config), + $expected, + 'semicolon does not end a comment line'); ################################################################################ # Error message with 2+2 lines of context -- 2.39.5