Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/dev/cgd make this work when rawpart != d
details: https://anonhg.NetBSD.org/src/rev/8f0e76906535
branches: trunk
changeset: 760350:8f0e76906535
user: pooka <pooka%NetBSD.org@localhost>
date: Mon Jan 03 09:37:42 2011 +0000
description:
make this work when rawpart != d
diffstat:
tests/dev/cgd/t_cgd.sh | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
diffs (49 lines):
diff -r fa658a0a3dce -r 8f0e76906535 tests/dev/cgd/t_cgd.sh
--- a/tests/dev/cgd/t_cgd.sh Mon Jan 03 09:35:33 2011 +0000
+++ b/tests/dev/cgd/t_cgd.sh Mon Jan 03 09:37:42 2011 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: t_cgd.sh,v 1.4 2010/12/30 16:58:07 pooka Exp $
+# $NetBSD: t_cgd.sh,v 1.5 2011/01/03 09:37:42 pooka Exp $
#
# Copyright (c) 2010 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -25,6 +25,8 @@
# POSSIBILITY OF SUCH DAMAGE.
#
+rawpart=`sysctl -n kern.rawpartition | tr '01234' 'abcde'`
+rawcgd=/dev/rcgd0${rawpart}
cgdserver=\
"rump_server -lrumpvfs -lrumpkern_crypto -lrumpdev -lrumpdev_disk -lrumpdev_cgd"
@@ -45,10 +47,9 @@
export RUMP_SERVER=unix://csock
atf_check -s exit:0 sh -c "echo 12345 | \
rump.cgdconfig -p cgd0 /dev/dk ${d}/paramsfile"
- atf_check -s exit:0 -e ignore dd if=${d}/t_cgd rof=/dev/rcgd0d count=2
+ atf_check -s exit:0 -e ignore dd if=${d}/t_cgd rof=${rawcgd} count=2
atf_check -s exit:0 -e ignore dd if=${d}/t_cgd of=testfile count=2
- atf_check -s exit:0 -e ignore -o file:testfile \
- dd rif=/dev/rcgd0d count=2
+ atf_check -s exit:0 -e ignore -o file:testfile dd rif=${rawcgd} count=2
}
basic_cleanup()
@@ -75,7 +76,7 @@
export RUMP_SERVER=unix://csock
atf_check -s exit:0 sh -c "echo 12345 | \
rump.cgdconfig -p cgd0 /dev/dk ${d}/paramsfile"
- atf_check -s exit:0 -e ignore dd if=${d}/t_cgd rof=/dev/rcgd0d count=2
+ atf_check -s exit:0 -e ignore dd if=${d}/t_cgd rof=${rawcgd} count=2
# unconfig and reconfig cgd
atf_check -s exit:0 rump.cgdconfig -u cgd0
@@ -84,7 +85,7 @@
atf_check -s exit:0 -e ignore dd if=${d}/t_cgd of=testfile count=2
atf_check -s exit:0 -e ignore -o not-file:testfile \
- dd rif=/dev/rcgd0d count=2
+ dd rif=${rawcgd} count=2
}
wrongpass_cleanup()
Home |
Main Index |
Thread Index |
Old Index