mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
- Merge #968: Replace the obsolescent fgrep with grep -F in tests.
This commit is contained in:
commit
a2f0186427
11 changed files with 28 additions and 25 deletions
|
|
@ -1,3 +1,6 @@
|
||||||
|
27 November 2023: Yorgos
|
||||||
|
- Merge #968: Replace the obsolescent fgrep with grep -F in tests.
|
||||||
|
|
||||||
27 November 2023: Wouter
|
27 November 2023: Wouter
|
||||||
- Fix #964: config.h.in~ backup file in release tar balls.
|
- Fix #964: config.h.in~ backup file in release tar balls.
|
||||||
|
|
||||||
|
|
|
||||||
26
testdata/01-doc.tdir/01-doc.test
vendored
26
testdata/01-doc.tdir/01-doc.test
vendored
|
|
@ -24,21 +24,21 @@ fi
|
||||||
(cd $PRE; find . -name "*.h" -print) >hlist
|
(cd $PRE; find . -name "*.h" -print) >hlist
|
||||||
(cd $PRE; find . -name "*.c" -print) >>hlist
|
(cd $PRE; find . -name "*.c" -print) >>hlist
|
||||||
# filter out config.h
|
# filter out config.h
|
||||||
fgrep -v -e "config.h" hlist > ilist; mv ilist hlist
|
grep -F -v -e "config.h" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/configparser" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/configparser" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/configlexer" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/configlexer" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/configyyrename" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/configyyrename" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/locks.h" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/locks.h" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/storage/lookup3.c" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/storage/lookup3.c" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "ldns-src/" hlist > ilist; mv ilist hlist
|
grep -F -v -e "ldns-src/" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "libunbound/python/libunbound_wrap.c" hlist > ilist; mv ilist hlist
|
grep -F -v -e "libunbound/python/libunbound_wrap.c" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "pythonmod/interface.h" hlist > ilist; mv ilist hlist
|
grep -F -v -e "pythonmod/interface.h" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "dnstap" hlist > ilist; mv ilist hlist
|
grep -F -v -e "dnstap" hlist > ilist; mv ilist hlist
|
||||||
fgrep -v -e "util/siphash.c" hlist > ilist; mv ilist hlist
|
grep -F -v -e "util/siphash.c" hlist > ilist; mv ilist hlist
|
||||||
# filter out compat
|
# filter out compat
|
||||||
fgrep -v -e "compat/" hlist > ilist; mv ilist hlist
|
grep -F -v -e "compat/" hlist > ilist; mv ilist hlist
|
||||||
for h in `cat hlist`; do
|
for h in `cat hlist`; do
|
||||||
if fgrep "`basename $h`" $PRE/doc/html/files.html >/dev/null; then
|
if grep -F "`basename $h`" $PRE/doc/html/files.html >/dev/null; then
|
||||||
: # ok
|
: # ok
|
||||||
else
|
else
|
||||||
echo "Warning: $h has no documentation."
|
echo "Warning: $h has no documentation."
|
||||||
|
|
|
||||||
6
testdata/common.sh
vendored
6
testdata/common.sh
vendored
|
|
@ -169,7 +169,7 @@ wait_server_up () {
|
||||||
local WAIT_THRES=30
|
local WAIT_THRES=30
|
||||||
local try
|
local try
|
||||||
for (( try=0 ; try <= $MAX_UP_TRY ; try++ )) ; do
|
for (( try=0 ; try <= $MAX_UP_TRY ; try++ )) ; do
|
||||||
if test -f $1 && fgrep "$2" $1 >/dev/null; then
|
if test -f $1 && grep -F "$2" $1 >/dev/null; then
|
||||||
#echo "done on try $try"
|
#echo "done on try $try"
|
||||||
break;
|
break;
|
||||||
fi
|
fi
|
||||||
|
|
@ -220,11 +220,11 @@ wait_server_up_or_fail () {
|
||||||
local WAIT_THRES=30
|
local WAIT_THRES=30
|
||||||
local try
|
local try
|
||||||
for (( try=0 ; try <= $MAX_UP_TRY ; try++ )) ; do
|
for (( try=0 ; try <= $MAX_UP_TRY ; try++ )) ; do
|
||||||
if test -f $1 && fgrep "$2" $1 >/dev/null; then
|
if test -f $1 && grep -F "$2" $1 >/dev/null; then
|
||||||
echo "done on try $try"
|
echo "done on try $try"
|
||||||
break;
|
break;
|
||||||
fi
|
fi
|
||||||
if test -f $1 && fgrep "$3" $1 >/dev/null; then
|
if test -f $1 && grep -F "$3" $1 >/dev/null; then
|
||||||
echo "failed on try $try"
|
echo "failed on try $try"
|
||||||
break;
|
break;
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
4
testdata/fwd_ancil.tdir/fwd_ancil.post
vendored
4
testdata/fwd_ancil.tdir/fwd_ancil.post
vendored
|
|
@ -7,10 +7,10 @@
|
||||||
# do your teardown here
|
# do your teardown here
|
||||||
. ../common.sh
|
. ../common.sh
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
if fgrep "service stopped" unbound.log; then
|
if grep -F "service stopped" unbound.log; then
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
if fgrep "disable interface-automatic" unbound.log; then
|
if grep -F "disable interface-automatic" unbound.log; then
|
||||||
echo "skip test"
|
echo "skip test"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
2
testdata/fwd_ancil.tdir/fwd_ancil.pre
vendored
2
testdata/fwd_ancil.tdir/fwd_ancil.pre
vendored
|
|
@ -36,7 +36,7 @@ wait_ldns_testns_up fwd.log
|
||||||
# wait for unbound to come up
|
# wait for unbound to come up
|
||||||
# string 'Start of service' in log.
|
# string 'Start of service' in log.
|
||||||
wait_server_up_or_fail unbound.log "start of service" "disable interface-automatic"
|
wait_server_up_or_fail unbound.log "start of service" "disable interface-automatic"
|
||||||
if fgrep "disable interface-automatic" unbound.log; then
|
if grep -F "disable interface-automatic" unbound.log; then
|
||||||
skip_test "skip test"
|
skip_test "skip test"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
||||||
2
testdata/fwd_ancil.tdir/fwd_ancil.test
vendored
2
testdata/fwd_ancil.tdir/fwd_ancil.test
vendored
|
|
@ -7,7 +7,7 @@
|
||||||
PRE="../.."
|
PRE="../.."
|
||||||
. ../common.sh
|
. ../common.sh
|
||||||
|
|
||||||
if fgrep "disable interface-automatic" unbound.log; then
|
if grep -F "disable interface-automatic" unbound.log; then
|
||||||
echo "skip test"
|
echo "skip test"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
2
testdata/fwd_oneport.tdir/fwd_oneport.post
vendored
2
testdata/fwd_oneport.tdir/fwd_oneport.post
vendored
|
|
@ -9,7 +9,7 @@
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
|
|
||||||
# find all extra forked testns and kill them.
|
# find all extra forked testns and kill them.
|
||||||
pidlist=`fgrep "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
pidlist=`grep -F "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
||||||
for p in $pidlist; do
|
for p in $pidlist; do
|
||||||
kill_pid $p
|
kill_pid $p
|
||||||
done
|
done
|
||||||
|
|
|
||||||
2
testdata/fwd_three.tdir/fwd_three.post
vendored
2
testdata/fwd_three.tdir/fwd_three.post
vendored
|
|
@ -11,7 +11,7 @@
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
|
|
||||||
# find all extra forked testns and kill them.
|
# find all extra forked testns and kill them.
|
||||||
pidlist=`fgrep "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
pidlist=`grep -F "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
||||||
for p in $pidlist; do
|
for p in $pidlist; do
|
||||||
kill_pid $p
|
kill_pid $p
|
||||||
done
|
done
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
|
|
||||||
# find all extra forked testns and kill them.
|
# find all extra forked testns and kill them.
|
||||||
pidlist=`fgrep "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
pidlist=`grep -F "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
||||||
for p in $pidlist; do
|
for p in $pidlist; do
|
||||||
kill_pid $p
|
kill_pid $p
|
||||||
done
|
done
|
||||||
|
|
|
||||||
2
testdata/fwd_udptmout.tdir/fwd_udptmout.post
vendored
2
testdata/fwd_udptmout.tdir/fwd_udptmout.post
vendored
|
|
@ -10,7 +10,7 @@
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
|
|
||||||
# find all extra forked testns and kill them.
|
# find all extra forked testns and kill them.
|
||||||
pidlist=`fgrep "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
pidlist=`grep -F "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
||||||
for p in $pidlist; do
|
for p in $pidlist; do
|
||||||
kill_pid $p
|
kill_pid $p
|
||||||
done
|
done
|
||||||
|
|
|
||||||
2
testdata/fwd_waitudp.tdir/fwd_waitudp.post
vendored
2
testdata/fwd_waitudp.tdir/fwd_waitudp.post
vendored
|
|
@ -11,7 +11,7 @@
|
||||||
kill_pid $FWD_PID
|
kill_pid $FWD_PID
|
||||||
|
|
||||||
# find all extra forked testns and kill them.
|
# find all extra forked testns and kill them.
|
||||||
pidlist=`fgrep "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
pidlist=`grep -F "forked pid:" fwd.log | sed -e 's/forked pid: //'`
|
||||||
for p in $pidlist; do
|
for p in $pidlist; do
|
||||||
kill_pid $p
|
kill_pid $p
|
||||||
done
|
done
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue