diff options
| author | pooka <pooka@NetBSD.org> | 2011-02-04 19:44:00 +0000 |
|---|---|---|
| committer | pooka <pooka@NetBSD.org> | 2011-02-04 19:44:00 +0000 |
| commit | dfc77447cd50f0d7c6cd4a8497ba74b8ff8418bd (patch) | |
| tree | 76dd1917c32c7b6c5a9b526ef5694f1bfbc1c738 /tests/dev | |
| parent | 275ff3e9c55d347f5a9f3a95e913d968f774afbc (diff) | |
convert tests from oldstyle dd rif/rof to newstyle dd | rump.dd
Diffstat (limited to 'tests/dev')
| -rw-r--r-- | tests/dev/cgd/t_cgd.sh | 13 | ||||
| -rw-r--r-- | tests/dev/md/t_md.sh | 8 | ||||
| -rw-r--r-- | tests/dev/raidframe/t_raid.sh | 14 |
3 files changed, 22 insertions, 13 deletions
diff --git a/tests/dev/cgd/t_cgd.sh b/tests/dev/cgd/t_cgd.sh index cb937e59220..c7dd97b82fb 100644 --- a/tests/dev/cgd/t_cgd.sh +++ b/tests/dev/cgd/t_cgd.sh @@ -1,4 +1,4 @@ -# $NetBSD: t_cgd.sh,v 1.5 2011/01/03 09:37:42 pooka Exp $ +# $NetBSD: t_cgd.sh,v 1.6 2011/02/04 19:44:00 pooka Exp $ # # Copyright (c) 2010 The NetBSD Foundation, Inc. # All rights reserved. @@ -47,9 +47,11 @@ basic_body() 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=${rawcgd} count=2 + atf_check -s exit:0 -e ignore sh -c \ + "dd if=${d}/t_cgd count=2 | rump.dd of=${rawcgd}" 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=${rawcgd} count=2 + atf_check -s exit:0 -e ignore -o file:testfile \ + rump.dd if=${rawcgd} count=2 } basic_cleanup() @@ -76,7 +78,8 @@ wrongpass_body() 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=${rawcgd} count=2 + atf_check -s exit:0 -e ignore sh -c \ + "dd if=${d}/t_cgd | rump.dd of=${rawcgd} count=2" # unconfig and reconfig cgd atf_check -s exit:0 rump.cgdconfig -u cgd0 @@ -85,7 +88,7 @@ wrongpass_body() 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=${rawcgd} count=2 + rump.dd if=${rawcgd} count=2 } wrongpass_cleanup() diff --git a/tests/dev/md/t_md.sh b/tests/dev/md/t_md.sh index a43dd32879f..62408349a7f 100644 --- a/tests/dev/md/t_md.sh +++ b/tests/dev/md/t_md.sh @@ -1,4 +1,4 @@ -# $NetBSD: t_md.sh,v 1.5 2011/01/03 09:39:46 pooka Exp $ +# $NetBSD: t_md.sh,v 1.6 2011/02/04 19:44:00 pooka Exp $ # # Copyright (c) 2010 The NetBSD Foundation, Inc. # All rights reserved. @@ -45,8 +45,10 @@ basic_body() atf_check -s exit:0 $(atf_get_srcdir)/h_mdserv ${rawmd} export RUMP_SERVER=unix://commsock - atf_check -s exit:0 -e ignore dd if=/bin/ls rof=${rawmd} seek=100 count=10 - atf_check -s exit:0 -e ignore dd of=testfile rif=${rawmd} skip=100 count=10 + atf_check -s exit:0 -e ignore sh -c \ + "dd if=/bin/ls count=10 | rump.dd of=${rawmd} seek=100" + atf_check -s exit:0 -e ignore sh -c \ + "rump.dd if=${rawmd} skip=100 count=10 | dd of=testfile" atf_check -s exit:0 -e ignore -o file:testfile dd if=/bin/ls count=10 } diff --git a/tests/dev/raidframe/t_raid.sh b/tests/dev/raidframe/t_raid.sh index b455ef83ba8..e805ef1c439 100644 --- a/tests/dev/raidframe/t_raid.sh +++ b/tests/dev/raidframe/t_raid.sh @@ -1,4 +1,4 @@ -# $NetBSD: t_raid.sh,v 1.5 2010/12/30 16:58:07 pooka Exp $ +# $NetBSD: t_raid.sh,v 1.6 2011/02/04 19:44:00 pooka Exp $ # # Copyright (c) 2010 The NetBSD Foundation, Inc. # All rights reserved. @@ -98,7 +98,8 @@ raid1_compfail_body() # put some data there atf_check -s exit:0 -e ignore \ dd if=$(atf_get_srcdir)/t_raid of=testfile count=4 - atf_check -s exit:0 -e ignore dd if=testfile rof=${rawraid} conv=sync + atf_check -s exit:0 -e ignore sh -c \ + "dd if=testfile | rump.dd of=${rawraid} conv=sync" # restart server with failed component rump.halt @@ -111,7 +112,8 @@ raid1_compfail_body() atf_check -s exit:0 rump.raidctl -c raid.conf raid0 # check if we we get what we wrote - atf_check -s exit:0 -o file:testfile -e ignore dd rif=${rawraid} count=4 + atf_check -s exit:0 -o file:testfile -e ignore \ + rump.dd if=${rawraid} count=4 } raid1_compfail_cleanup() @@ -183,7 +185,8 @@ raid5_compfail_body() # put some data there atf_check -s exit:0 -e ignore \ dd if=$(atf_get_srcdir)/t_raid of=testfile count=4 - atf_check -s exit:0 -e ignore dd if=testfile rof=${rawraid} conv=sync + atf_check -s exit:0 -e ignore sh -c \ + "dd if=testfile | rump.dd of=${rawraid} conv=sync" # restart server with failed component rump.halt @@ -197,7 +200,8 @@ raid5_compfail_body() atf_check -s exit:0 rump.raidctl -c raid.conf raid0 # check if we we get what we wrote - atf_check -s exit:0 -o file:testfile -e ignore dd rif=${rawraid} count=4 + atf_check -s exit:0 -o file:testfile -e ignore \ + rump.dd if=${rawraid} count=4 } raid5_compfail_cleanup() |
