Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/lib/libcurses tests/libcurses: require keywords to be ...



details:   https://anonhg.NetBSD.org/src/rev/0090164af0ce
branches:  trunk
changeset: 951929:0090164af0ce
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Feb 07 19:49:32 2021 +0000

description:
tests/libcurses: require keywords to be lowercase, except for OK and ERR

There is no need to write the keywords in upper case or mixed case.  The
only case where a keyword did not have the canonical form yet was a
single lowercase 'ok' in the test case 'innstr'.

diffstat:

 tests/lib/libcurses/director/testlang_conf.l |  32 ++++++++++++++--------------
 tests/lib/libcurses/tests/innstr             |   2 +-
 2 files changed, 17 insertions(+), 17 deletions(-)

diffs (62 lines):

diff -r 4f829e3fa816 -r 0090164af0ce tests/lib/libcurses/director/testlang_conf.l
--- a/tests/lib/libcurses/director/testlang_conf.l      Sun Feb 07 19:44:34 2021 +0000
+++ b/tests/lib/libcurses/director/testlang_conf.l      Sun Feb 07 19:49:32 2021 +0000
@@ -1,5 +1,5 @@
 %{
-/*     $NetBSD: testlang_conf.l,v 1.12 2021/02/07 17:32:55 rillig Exp $        */
+/*     $NetBSD: testlang_conf.l,v 1.13 2021/02/07 19:49:32 rillig Exp $        */
 
 /*-
  * Copyright 2009 Brett Lymn <blymn%NetBSD.org@localhost>
@@ -138,25 +138,25 @@
 STRING         [0-9a-z!#-&(-^ \t%._\\]+
 numeric                [-0-9]+
 PCHAR           (\\.|[^ \t\n])
-ASSIGN         [aA][sS][sS][iI][gG][nN]
-CALL2          [cC][aA][lL][lL]2
-CALL3          [cC][aA][lL][lL]3
-CALL4          [cC][aA][lL][lL]4
-CALL           [cC][aA][lL][lL]
-CHECK          [cC][hH][eE][cC][kK]
-DELAY          [dD][eE][lL][aA][yY]
-INPUT          [iI][nN][pP][uU][tT]
-NOINPUT                [nN][oO][iI][nN][pP][uU][tT]
-OK_RET         [oO][kK]
-ERR_RET                [eE][rR][rR]
-COMPARE                [cC][oO][mM][pP][aA][rR][eE]
-COMPAREND      [cC][oO][mM][pP][aA][rR][eE][Nn][Dd]
+ASSIGN         assign
+CALL2          call2
+CALL3          call3
+CALL4          call4
+CALL           call
+CHECK          check
+DELAY          delay
+INPUT          input
+NOINPUT                noinput
+OK_RET         OK
+ERR_RET                ERR
+COMPARE                compare
+COMPAREND      comparend
 FILENAME       [A-Za-z0-9.][A-Za-z0-9./_-]+
 VARNAME                [A-Za-z][A-Za-z0-9_-]+
 NULL_RET       NULL
 NON_NULL       NON_NULL
-CCHAR          [cC][cC][hH][aA][rR]
-WCHAR          [wW][cC][hH][aA][rR]
+CCHAR          cchar
+WCHAR          wchar
 BYTE           BYTE
 OR             \|
 LPAREN         \(
diff -r 4f829e3fa816 -r 0090164af0ce tests/lib/libcurses/tests/innstr
--- a/tests/lib/libcurses/tests/innstr  Sun Feb 07 19:44:34 2021 +0000
+++ b/tests/lib/libcurses/tests/innstr  Sun Feb 07 19:49:32 2021 +0000
@@ -3,6 +3,6 @@
 call2 5 "cdefg" innstr 6
 call OK move 0 76
 call OK addstr "123"
-call ok move 0 75
+call OK move 0 75
 call2 5 " 123 " innstr 10
 call2 OK " 123 " instr



Home | Main Index | Thread Index | Old Index