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 PR: 42850



details:   https://anonhg.NetBSD.org/src/rev/0ef59c044f62
branches:  trunk
changeset: 754200:0ef59c044f62
user:      sjg <sjg%NetBSD.org@localhost>
date:      Fri Apr 23 15:43:28 2010 +0000

description:
PR: 42850
Reviewed by:

Reduced the "expected to exist" dirs in path to just
/ /bin and /tmp
and change the "not expected to exist" dir to something
even less likely.
Add a comment to suggest why.

diffstat:

 usr.bin/make/unit-tests/modmisc  |   6 ++++--
 usr.bin/make/unit-tests/test.exp |  14 +++++++-------
 2 files changed, 11 insertions(+), 9 deletions(-)

diffs (41 lines):

diff -r a7492617536f -r 0ef59c044f62 usr.bin/make/unit-tests/modmisc
--- a/usr.bin/make/unit-tests/modmisc   Fri Apr 23 15:38:46 2010 +0000
+++ b/usr.bin/make/unit-tests/modmisc   Fri Apr 23 15:43:28 2010 +0000
@@ -1,8 +1,10 @@
-# $Id: modmisc,v 1.5 2010/04/22 19:15:24 sjg Exp $
+# $Id: modmisc,v 1.6 2010/04/23 15:43:28 sjg Exp $
 #
 # miscellaneous modifier tests
 
-path=:/bin:/usr/bin::/:.:/user/bin:.
+# do not put any dirs in this list which exist on some
+# but not all target systems - an exists() check is below.
+path=:/bin:/tmp::/:.:/no/such/dir:.
 # strip cwd from path.
 MOD_NODOT=S/:/ /g:N.:ts:
 # and decorate, note that $'s need to be doubled. Also note that 
diff -r a7492617536f -r 0ef59c044f62 usr.bin/make/unit-tests/test.exp
--- a/usr.bin/make/unit-tests/test.exp  Fri Apr 23 15:38:46 2010 +0000
+++ b/usr.bin/make/unit-tests/test.exp  Fri Apr 23 15:43:28 2010 +0000
@@ -112,14 +112,14 @@
 LIB=e X_LIBS:M*/lib${LIB}.a is "/tmp/libe.a"
 LIB=e X_LIBS:M*/lib${LIB}.a:tu is "/TMP/LIBE.A"
 Mscanner=OK
-path=':/bin:/usr/bin::/:.:/user/bin:.'
-path='/bin:/usr/bin:/:/user/bin'
-path='/bin:/usr/bin:/:/user/bin'
-path='/bin':'/usr/bin':'/':'/user/bin'
-path='/bin':'/usr/bin':'/':'/user/bin'
+path=':/bin:/tmp::/:.:/no/such/dir:.'
+path='/bin:/tmp:/:/no/such/dir'
+path='/bin:/tmp:/:/no/such/dir'
+path='/bin':'/tmp':'/':'/no/such/dir'
+path='/bin':'/tmp':'/':'/no/such/dir'
 path_/usr/xbin=/opt/xbin/
-paths=/bin /usr/bin / /user/bin /opt/xbin
-PATHS=/BIN /USR/BIN / /USER/BIN /OPT/XBIN
+paths=/bin /tmp / /no/such/dir /opt/xbin
+PATHS=/BIN /TMP / /NO/SUCH/DIR /OPT/XBIN
 LIST      = one two three four five six seven eight nine ten
 LIST:O    = eight five four nine one seven six ten three two
 LIST:Ox   = Ok



Home | Main Index | Thread Index | Old Index