Module Name: src
Committed By: ozaki-r
Date: Sun Mar 13 05:46:20 UTC 2016
Modified Files:
src/tests/net/net: t_ipv6address.sh
Log Message:
Add more debugging code
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/tests/net/net/t_ipv6address.sh
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/tests/net/net/t_ipv6address.sh
diff -u src/tests/net/net/t_ipv6address.sh:1.4 src/tests/net/net/t_ipv6address.sh:1.5
--- src/tests/net/net/t_ipv6address.sh:1.4 Sat Mar 12 06:15:31 2016
+++ src/tests/net/net/t_ipv6address.sh Sun Mar 13 05:46:20 2016
@@ -1,4 +1,4 @@
-# $NetBSD: t_ipv6address.sh,v 1.4 2016/03/12 06:15:31 ozaki-r Exp $
+# $NetBSD: t_ipv6address.sh,v 1.5 2016/03/13 05:46:20 ozaki-r Exp $
#
# Copyright (c) 2015 Internet Initiative Japan Inc.
# All rights reserved.
@@ -164,6 +164,8 @@ cleanup_bus()
{
local tmp_rump_server=$RUMP_SERVER
+ $DEBUG && dump_bus
+
export RUMP_SERVER=${SOCKSRC}
atf_check -s exit:0 rump.ifconfig shmif0 down
atf_check -s exit:0 rump.ifconfig shmif0 -linkstr
@@ -185,8 +187,6 @@ cleanup_bus()
atf_check -s exit:0 rump.ifconfig shmif1 -linkstr
unset RUMP_SERVER
- $DEBUG && dump_bus
-
atf_check -s exit:0 rm ${BUSSRC}
atf_check -s exit:0 rm ${BUSDST}
atf_check -s exit:0 rm ${BUS1}
@@ -225,6 +225,21 @@ dump_bus()
shmif_dumpbus -p - ${BUS2} 2>/dev/null| tcpdump -n -e -r -
}
+dump()
+{
+
+ export RUMP_SERVER=${SOCKSRC}
+ rump.ndp -n -a
+ rump.netstat -nr -f inet6
+ export RUMP_SERVER=${SOCKDST}
+ rump.ndp -n -a
+ rump.netstat -nr -f inet6
+ export RUMP_SERVER=${SOCKFWD}
+ rump.ndp -n -a
+ rump.netstat -nr -f inet6
+ unset RUMP_SERVER
+}
+
linklocal_head()
{
atf_set "descr" "Test for bassically function of the IPv6 linklocal address"
@@ -280,6 +295,8 @@ linklocal_body()
atf_check -s exit:0 -o ignore rump.ifconfig -w 10
$DEBUG && rump.ifconfig shmif0
+ $DEBUG && dump
+
atf_check -s exit:0 -o match:"0.0% packet loss" \
rump.ping6 -c 1 -X $TIMEOUT -n -S ${src_if0_lladdr}%shmif0 ${IP6FWD0}
unset RUMP_SERVER
@@ -322,6 +339,7 @@ linklocal_body()
linklocal_cleanup()
{
+ $DEBUG && dump
$DEBUG && dump_bus
cleanup_rump_servers
}