From ec788b94ae40da127520b261d092689135ea0357 Mon Sep 17 00:00:00 2001 From: Visa Hankala Date: Thu, 12 Mar 2020 15:40:40 +0000 Subject: Add a regression test for vnd(4). --- regress/sys/dev/Makefile | 3 ++- regress/sys/dev/vnd/Makefile | 27 +++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 regress/sys/dev/vnd/Makefile (limited to 'regress/sys') diff --git a/regress/sys/dev/Makefile b/regress/sys/dev/Makefile index c771b1f5e71..48b73f2a241 100644 --- a/regress/sys/dev/Makefile +++ b/regress/sys/dev/Makefile @@ -1,7 +1,8 @@ -# $OpenBSD: Makefile,v 1.7 2019/03/18 22:12:40 claudio Exp $ +# $OpenBSD: Makefile,v 1.8 2020/03/12 15:40:39 visa Exp $ SUBDIR+= fdesc SUBDIR+= kcov +SUBDIR+= vnd #SUBDIR+= wscons .include diff --git a/regress/sys/dev/vnd/Makefile b/regress/sys/dev/vnd/Makefile new file mode 100644 index 00000000000..5c1bf6cc32d --- /dev/null +++ b/regress/sys/dev/vnd/Makefile @@ -0,0 +1,27 @@ +# $OpenBSD: Makefile,v 1.1 2020/03/12 15:40:39 visa Exp $ + +REGRESS_SETUP= setup +REGRESS_CLEANUP= cleanup +REGRESS_TARGETS= + +setup: + mkdir -p /mnt/regress-vnd + +cleanup: unconfig + -rmdir /mnt/regress-vnd 2>/dev/null || true + +unconfig: + -vnconfig -u vnd0 2>/dev/null || true + -umount -f /mnt/regress-vnd 2>/dev/null || true + +REGRESS_TARGETS+= run-regress-async-mount +run-regress-async-mount: unconfig + mount_mfs -s1M -oasync swap /mnt/regress-vnd + dd if=/dev/zero of=/mnt/regress-vnd/disk.img count=1024 + vnconfig vnd0 /mnt/regress-vnd/disk.img + echo 'e 0\nC\n\n64\n960\nw\nq\n' | fdisk -e vnd0 + newfs -t msdos vnd0i + +REGRESS_ROOT_TARGETS= ${REGRESS_TARGETS} + +.include -- cgit v1.2.3