Add error test case for unterminated strings in the config file

This commit is contained in:
Thomas Jensen 2021-02-14 14:15:33 +01:00
parent ac8617b383
commit beb8696a79
No known key found for this signature in database
GPG Key ID: A4ACEE270D0FB7DB
2 changed files with 35 additions and 0 deletions

View File

@ -0,0 +1,24 @@
BOX testbox1
escaped "aaa\"bbb\\\"ccc#" # the string aaa"bbb\"ccc#
errored "aaa\\"bbb" # unterminated!
sample
#
# regular comments used in Perl, Shell scripts, etc.
#
ends
shapes {
w ("#")
}
elastic (
w
)
padding {
left 1
}
END testbox1

View File

@ -0,0 +1,11 @@
:ARGS
-f 120_parser_unterminated_string.cfg
:INPUT
foo
:OUTPUT-FILTER
:EXPECTED-ERROR 1
boxes: 120_parser_unterminated_string.cfg: line 4: Unterminated String -- " # unterminated!
boxes: 120_parser_unterminated_string.cfg: line 4: syntax error
boxes: 120_parser_unterminated_string.cfg: line 4: skipping to next design
boxes: 120_parser_unterminated_string.cfg: line 25: no valid designs found
:EOF