Add error conditions for quoted names to scanner regression test.

git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4234 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Mark M. Hoffman committed 2006-11-12 18:21:43 +00:00
1 parent 04cd960539
commit 68558575ad
3 files changed
+34

No files matched your search

+13
View File
@@ -0,0 +1,13 @@
chip "blah-*"
# keyword with two quoted names, no intermediate whitespace
label "in0""foo"
# missing closing quote before EOL
label "in1" "bar
# (correct label statement, just for separation)
label "in2" "baz"
# missing closing quote before immediate EOF
label "in3" "baz
+19
View File
@@ -0,0 +1,19 @@
1: CHIP
1: NAME: blah-*
2: EOL
4: LABEL
4: ERROR
5: EOL
7: LABEL
7: NAME: in1
7: ERROR
8: EOL
10: LABEL
10: NAME: in2
10: NAME: baz
11: EOL
13: LABEL
13: NAME: in3
13: ERROR
13: EOL
13: EOF
+2
View File
@@ -41,6 +41,8 @@ my @scenarios = (
desc => 'invalid, unquoted names' },
{ base => 'names-quoted', status => 0,
desc => 'normal, quoted names' },
{ base => 'names-quoted-errors', status => 0,
desc => 'invalid, quoted names' },
);
plan tests => ($#scenarios + 1) * 3;