Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/make/unit-tests make(1): fix sh-dots test



details:   https://anonhg.NetBSD.org/src/rev/da7ff643f7cd
branches:  trunk
changeset: 937991:da7ff643f7cd
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sat Aug 29 19:35:38 2020 +0000

description:
make(1): fix sh-dots test

The exact output depends on the shell.  Some shells prefix the error
message with their name, some don't.

diffstat:

 usr.bin/make/unit-tests/Makefile    |  5 ++---
 usr.bin/make/unit-tests/sh-dots.exp |  2 +-
 2 files changed, 3 insertions(+), 4 deletions(-)

diffs (32 lines):

diff -r 72bf4607676c -r da7ff643f7cd usr.bin/make/unit-tests/Makefile
--- a/usr.bin/make/unit-tests/Makefile  Sat Aug 29 19:28:32 2020 +0000
+++ b/usr.bin/make/unit-tests/Makefile  Sat Aug 29 19:35:38 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.128 2020/08/29 19:07:32 rillig Exp $
+# $NetBSD: Makefile,v 1.129 2020/08/29 19:35:38 rillig Exp $
 #
 # Unit tests for make(1)
 #
@@ -352,9 +352,8 @@
 
 # Some tests need extra post-processing.
 SED_CMDS.opt-debug-g1= -e 's,${.CURDIR},CURDIR,'
-SED_CMDS.opt-debug-g1+=        -e 's,[/[a-z]*/share/mk,/.../share/mk,'
 SED_CMDS.opt-debug-g1+=        -e '/Global Variables:/,/Suffixes:/d'
-SED_CMDS.sh-dots+=     -e 's,^${.SHELL}: ,,' -e '/not found/s,command ,,'
+SED_CMDS.sh-dots=      -e 's,^.*\.\.\.:.*,<normalized: ...: not found>,'
 SED_CMDS.varmod-subst-regex+= \
                        -e 's,\(Regex compilation error:\).*,\1 (details omitted),'
 SED_CMDS.varmod-edge+= -e 's, line [0-9]*:, line omitted:,'
diff -r 72bf4607676c -r da7ff643f7cd usr.bin/make/unit-tests/sh-dots.exp
--- a/usr.bin/make/unit-tests/sh-dots.exp       Sat Aug 29 19:28:32 2020 +0000
+++ b/usr.bin/make/unit-tests/sh-dots.exp       Sat Aug 29 19:35:38 2020 +0000
@@ -6,7 +6,7 @@
 commented commented
 *** Error code 1 (ignored)
 ...    # Run the below commands later
-...: not found
+<normalized: ...: not found>
 commented delayed commented
 first delayed first
 repeated delayed repeated



Home | Main Index | Thread Index | Old Index