check that sed selects a non zero range of lines
This commit is contained in:
@@ -6,14 +6,13 @@
|
|||||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
|
||||||
# $Id: clean.sh,v 1.8 2011/08/03 23:47:48 tbox Exp $
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Clean up after cache cleaner tests.
|
# Clean up after cache cleaner tests.
|
||||||
#
|
#
|
||||||
|
|
||||||
rm -f dig.out.ns2
|
rm -f dig.out.ns2
|
||||||
rm -f dig.out.expire
|
rm -f dig.out.expire
|
||||||
|
rm -f sed.out.*
|
||||||
rm -f */named.memstats
|
rm -f */named.memstats
|
||||||
rm -f */named.run
|
rm -f */named.run
|
||||||
rm -f ns2/named_dump.db.*
|
rm -f ns2/named_dump.db.*
|
||||||
|
|||||||
@@ -6,8 +6,6 @@
|
|||||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
|
||||||
# $Id: tests.sh,v 1.10 2011/09/01 05:28:14 marka Exp $
|
|
||||||
|
|
||||||
SYSTEMTESTTOP=..
|
SYSTEMTESTTOP=..
|
||||||
. $SYSTEMTESTTOP/conf.sh
|
. $SYSTEMTESTTOP/conf.sh
|
||||||
|
|
||||||
@@ -221,11 +219,19 @@ ret=0
|
|||||||
load_cache
|
load_cache
|
||||||
dump_cache
|
dump_cache
|
||||||
mv ns2/named_dump.db.$n ns2/named_dump.db.$n.a
|
mv ns2/named_dump.db.$n ns2/named_dump.db.$n.a
|
||||||
sed -n '/plain success\/timeout/,/Unassociated entries/p' ns2/named_dump.db.$n.a | grep 'ns.flushtest.example' > /dev/null 2>&1 || ret=1
|
sed -n '/plain success\/timeout/,/Unassociated entries/p' \
|
||||||
|
ns2/named_dump.db.$n.a > sed.out.$n.a
|
||||||
|
grep 'plain success/timeout' sed.out.$n.a > /dev/null 2>&1 || ret=1
|
||||||
|
grep 'Unassociated entries' sed.out.$n.a > /dev/null 2>&1 || ret=1
|
||||||
|
grep 'ns.flushtest.example' sed.out.$n.a > /dev/null 2>&1 || ret=1
|
||||||
$RNDC $RNDCOPTS flushtree flushtest.example || ret=1
|
$RNDC $RNDCOPTS flushtree flushtest.example || ret=1
|
||||||
dump_cache
|
dump_cache
|
||||||
mv ns2/named_dump.db.$n ns2/named_dump.db.$n.b
|
mv ns2/named_dump.db.$n ns2/named_dump.db.$n.b
|
||||||
sed -n '/plain success\/timeout/,/Unassociated entries/p' ns2/named_dump.db.$n.b | grep 'ns.flushtest.example' > /dev/null 2>&1 && ret=1
|
sed -n '/plain success\/timeout/,/Unassociated entries/p' \
|
||||||
|
ns2/named_dump.db.$n.b > sed.out.$n.b
|
||||||
|
grep 'plain success/timeout' sed.out.$n.b > /dev/null 2>&1 || ret=1
|
||||||
|
grep 'Unassociated entries' sed.out.$n.b > /dev/null 2>&1 || ret=1
|
||||||
|
grep 'ns.flushtest.example' sed.out.$n.b > /dev/null 2>&1 && ret=1
|
||||||
if [ $ret != 0 ]; then echo "I:failed"; fi
|
if [ $ret != 0 ]; then echo "I:failed"; fi
|
||||||
status=`expr $status + $ret`
|
status=`expr $status + $ret`
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user