From eb18c5c166a158dfe15fffc60c073863c3c113f7 Mon Sep 17 00:00:00 2001 From: dv Date: Wed, 26 Apr 2023 10:14:21 +0000 Subject: [PATCH] regress: remove vmd path length tests. These add no value and we'd now that we don't artificially limit path lengths just be updating them to check PATH_MAX. --- regress/usr.sbin/vmd/config/Makefile | 19 +++---------------- .../config/vmd-fail-boot-name-too-long.conf | 6 ------ .../vmd/config/vmd-fail-boot-name-too-long.ok | 1 - .../config/vmd-fail-cdrom-name-too-long.conf | 6 ------ .../config/vmd-fail-cdrom-name-too-long.ok | 1 - .../config/vmd-fail-disk-path-too-long.conf | 6 ------ .../vmd/config/vmd-fail-disk-path-too-long.ok | 2 -- .../vmd/config/vmd-fail-vm-name-too-long.conf | 4 ---- .../vmd/config/vmd-fail-vm-name-too-long.ok | 1 - 9 files changed, 3 insertions(+), 43 deletions(-) delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.conf delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.ok delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.conf delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.ok delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.conf delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.ok delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.conf delete mode 100644 regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.ok diff --git a/regress/usr.sbin/vmd/config/Makefile b/regress/usr.sbin/vmd/config/Makefile index 1a769794958..d913840ca60 100644 --- a/regress/usr.sbin/vmd/config/Makefile +++ b/regress/usr.sbin/vmd/config/Makefile @@ -1,13 +1,11 @@ -# $OpenBSD: Makefile,v 1.10 2020/12/16 22:59:55 bluhm Exp $ +# $OpenBSD: Makefile,v 1.11 2023/04/26 10:14:21 dv Exp $ VMD ?= /usr/sbin/vmd VMD_PASS=boot-keyword memory-round memory-just-enough cdrom-keyword \ format-keyword -VMD_FAIL=kernel-keyword too-few-ram vm-name-too-long too-many-ifs \ - boot-name-too-long disk-path-too-long too-many-disks \ - switch-no-interface switch-no-add cdrom-name-too-long \ - bad-format missing-format +VMD_FAIL=kernel-keyword too-few-ram too-many-ifs too-many-disks \ + switch-no-interface switch-no-add bad-format missing-format .for n in ${VMD_PASS} REGRESS_TARGETS += run-pass-$n @@ -30,17 +28,6 @@ run-fail-bad-format run-fail-missing-format run-pass-format-keyword: foo.img foo.img disk0.img disk1.img disk2.img disk3.img disk4.img: touch $@ -PATH_LONG = some/relativepath/somewhere/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789 -BOOT_PATH_LONG = ${PATH_LONG}/bsd.rd -DISK_PATH_LONG = ${PATH_LONG}/bsd.img - -run-fail-boot-name-too-long: ${BOOT_PATH_LONG} -run-fail-disk-path-too-long: ${DISK_PATH_LONG} - -${BOOT_PATH_LONG} ${DISK_PATH_LONG}: - mkdir -p ${@:H} - touch $@ - clean: rm -f -- *.img rm -rf some diff --git a/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.conf b/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.conf deleted file mode 100644 index 209be7cf36f..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.conf +++ /dev/null @@ -1,6 +0,0 @@ -# $OpenBSD: vmd-fail-boot-name-too-long.conf,v 1.2 2018/10/22 16:45:24 bluhm Exp $ -# Fail on boot path (> 128) -ramdisk="some/relativepath/somewhere/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/bsd.rd" -vm "x" { - boot $ramdisk -} diff --git a/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.ok b/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.ok deleted file mode 100644 index 56cb73b98cf..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-boot-name-too-long.ok +++ /dev/null @@ -1 +0,0 @@ -5: kernel name too long diff --git a/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.conf b/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.conf deleted file mode 100644 index 70ad4e952aa..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.conf +++ /dev/null @@ -1,6 +0,0 @@ -# $OpenBSD: vmd-fail-cdrom-name-too-long.conf,v 1.1 2018/01/07 22:59:57 ccardenas Exp $ -# Fail on cdrom path (> 128) -iso="/some/absolutepath/somewhere/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/cd62.iso" -vm "x" { - cdrom $iso -} diff --git a/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.ok b/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.ok deleted file mode 100644 index e94f1e3ef8c..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-cdrom-name-too-long.ok +++ /dev/null @@ -1 +0,0 @@ -5: cdrom name too long diff --git a/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.conf b/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.conf deleted file mode 100644 index 32781ccd110..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.conf +++ /dev/null @@ -1,6 +0,0 @@ -# $OpenBSD: vmd-fail-disk-path-too-long.conf,v 1.2 2018/07/20 22:18:49 bluhm Exp $ -# Fail on disk path (> 128) -rdisk="some/relativepath/somewhere/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/bsd.img" -vm "x" { - disk $rdisk -} diff --git a/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.ok b/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.ok deleted file mode 100644 index 5df11e932b1..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-disk-path-too-long.ok +++ /dev/null @@ -1,2 +0,0 @@ -disk path too long -5: failed to parse disks: some/relativepath/somewhere/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/abcdefghijklmnopqrstuvwxyz0123456789/bsd.img diff --git a/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.conf b/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.conf deleted file mode 100644 index 3ee90ffa76a..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.conf +++ /dev/null @@ -1,4 +0,0 @@ -# $OpenBSD: vmd-fail-vm-name-too-long.conf,v 1.2 2019/03/04 21:36:21 bluhm Exp $ -# Fail on VM name (>= 64 chars) -vm "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ__" { -} diff --git a/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.ok b/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.ok deleted file mode 100644 index 1b99d3d7810..00000000000 --- a/regress/usr.sbin/vmd/config/vmd-fail-vm-name-too-long.ok +++ /dev/null @@ -1 +0,0 @@ -3: vm name too long -- 2.20.1