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): clean up test output of opt...



details:   https://anonhg.NetBSD.org/src/rev/536b69b1d578
branches:  trunk
changeset: 957740:536b69b1d578
user:      rillig <rillig%NetBSD.org@localhost>
date:      Wed Dec 09 08:20:56 2020 +0000

description:
make(1): clean up test output of opt-jobs-no-action

diffstat:

 usr.bin/make/unit-tests/opt-jobs-no-action.exp |   3 ++-
 usr.bin/make/unit-tests/opt-jobs-no-action.mk  |  13 ++++++++-----
 2 files changed, 10 insertions(+), 6 deletions(-)

diffs (53 lines):

diff -r e1dcbd98aadb -r 536b69b1d578 usr.bin/make/unit-tests/opt-jobs-no-action.exp
--- a/usr.bin/make/unit-tests/opt-jobs-no-action.exp    Wed Dec 09 08:18:35 2020 +0000
+++ b/usr.bin/make/unit-tests/opt-jobs-no-action.exp    Wed Dec 09 08:20:56 2020 +0000
@@ -1,3 +1,4 @@
+begin explain
 # .echoOff
 # .errOnOrEcho
 echo "false regular"
@@ -12,7 +13,7 @@
 false ignore-errors
 echo run despite the -n option
 run despite the -n option
-echo
+end explain
 
 begin combined
 
diff -r e1dcbd98aadb -r 536b69b1d578 usr.bin/make/unit-tests/opt-jobs-no-action.mk
--- a/usr.bin/make/unit-tests/opt-jobs-no-action.mk     Wed Dec 09 08:18:35 2020 +0000
+++ b/usr.bin/make/unit-tests/opt-jobs-no-action.mk     Wed Dec 09 08:20:56 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: opt-jobs-no-action.mk,v 1.6 2020/12/09 08:18:35 rillig Exp $
+# $NetBSD: opt-jobs-no-action.mk,v 1.7 2020/12/09 08:20:56 rillig Exp $
 #
 # Tests for the combination of the options -j and -n, which prints the
 # commands instead of actually running them.
@@ -34,11 +34,13 @@
        ignore="\# .errOffOrExecIgnore\n""%s\n" \
        errout="\# .errExit\n""{ %s \n} || exit $$?\n"
 
-all: documented combined
-.ORDER: documented combined
+all: explained combined
+.ORDER: explained combined
 
 # Explain the most basic cases in detail.
-documented: .PHONY
+explained: .PHONY
+       @+echo hide-from-output 'begin explain'
+
        # The following command is regular, it is printed twice:
        # - first using the template shell.errOnOrEcho,
        # - then using the template shell.errExit.
@@ -59,7 +61,8 @@
        # '!silent' in Compat_RunCommand.
        +echo run despite the -n option
 
-       @+echo
+       @+echo hide-from-output 'end explain'
+       @+echo hide-from-output
 
 
 # Test all combinations of the 3 RunFlags.



Home | Main Index | Thread Index | Old Index