Add test cases with a question mark
The test framework used to treat them specially (but no longer does). Add these test cases as non-regression for how the test framework allows "?" and especially "??" (which I think in the very distant path needed special handling because the test data was embedded in a .c file, and thus ?? could be interpreted as the prefix of a trigraph). Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
parent
9a75131da1
commit
578613322a
2 changed files with 13 additions and 0 deletions
|
@ -74,6 +74,9 @@ printf_char2:"%c%c":DOUBLE_QUOTE_CHAR:SPACE_CHAR:"\" "
|
|||
printf "%c%c", COLON, SPACE
|
||||
printf_char2:"%c%c":COLON_CHAR:SPACE_CHAR:"\: "
|
||||
|
||||
printf "%c%c", QUESTION, SPACE
|
||||
printf_char2:"%c%c":QUESTION_CHAR:SPACE_CHAR:"? "
|
||||
|
||||
printf "%c%c", BACKSLASH, SPACE
|
||||
printf_char2:"%c%c":BACKSLASH_CHAR:SPACE_CHAR:"\\ "
|
||||
|
||||
|
@ -86,6 +89,12 @@ printf_char2:"%c%c":COLON_CHAR:COLON_CHAR:"\:\:"
|
|||
printf "%c%c", COLON, NEWLINE
|
||||
printf_char2:"%c%c":COLON_CHAR:NEWLINE_CHAR:"\:\n"
|
||||
|
||||
printf "%c%c", QUESTION, QUESTION
|
||||
printf_char2:"%c%c":QUESTION_CHAR:QUESTION_CHAR:"??"
|
||||
|
||||
printf "%c%c", QUESTION, NEWLINE
|
||||
printf_char2:"%c%c":QUESTION_CHAR:NEWLINE_CHAR:"?\n"
|
||||
|
||||
printf "%c%c", BACKSLASH, NEWLINE
|
||||
printf_char2:"%c%c":BACKSLASH_CHAR:NEWLINE_CHAR:"\\\n"
|
||||
|
||||
|
@ -95,6 +104,9 @@ printf_char2:"%c%c":BACKSLASH_CHAR:DOUBLE_QUOTE_CHAR:"\\\""
|
|||
printf "%c%c", BACKSLASH, COLON
|
||||
printf_char2:"%c%c":BACKSLASH_CHAR:COLON_CHAR:"\\\:"
|
||||
|
||||
printf "%c%c", BACKSLASH, QUESTION
|
||||
printf_char2:"%c%c":BACKSLASH_CHAR:QUESTION_CHAR:"\\?"
|
||||
|
||||
printf "%c%c", BACKSLASH, BACKSLASH
|
||||
printf_char2:"%c%c":BACKSLASH_CHAR:BACKSLASH_CHAR:"\\\\"
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#define SPACE_CHAR ' '
|
||||
#define DOUBLE_QUOTE_CHAR '"'
|
||||
#define COLON_CHAR ':'
|
||||
#define QUESTION_CHAR '?'
|
||||
#define BACKSLASH_CHAR '\\'
|
||||
#define LOWERCASE_N_CHAR 'n'
|
||||
/* END_HEADER */
|
||||
|
|
Loading…
Reference in a new issue