summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorBen Hutchings <ben@decadent.org.uk>2018-07-27 14:13:52 +0800
committerBen Hutchings <benh@debian.org>2020-09-06 23:40:03 +0100
commit69240b147a807c0372322d9a203e445ad6c61197 (patch)
tree11356ec8e76928acc238e1fa1ae8bdda9848255b /debian
parent3dd298490b61c9bc163acbac8a56ed9568455bd9 (diff)
debian/tests: Add basic test for amd64 using busybox
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'debian')
-rwxr-xr-xdebian/tests/amd64-busybox19
-rw-r--r--debian/tests/control3
2 files changed, 22 insertions, 0 deletions
diff --git a/debian/tests/amd64-busybox b/debian/tests/amd64-busybox
new file mode 100755
index 0000000..1daf998
--- /dev/null
+++ b/debian/tests/amd64-busybox
@@ -0,0 +1,19 @@
+#!/bin/sh -e
+
+LOCALVERSION=-amd64
+. debian/tests/test-common
+
+cat >>"${CONFDIR}/initramfs.conf" <<EOF
+MODULES=most
+BUSYBOX=y
+FSTYPE=ext2
+EOF
+build_initramfs
+lsinitramfs "${INITRAMFS}" | grep -qw busybox
+
+build_rootfs_ext2
+
+run_qemu_amd64
+
+# Check that fsck ran
+grep -q "^/dev/${ROOTDISK_LINUX_NAME}: clean," "${OUTPUT}"
diff --git a/debian/tests/control b/debian/tests/control
index 3c20b12..a328e7f 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -4,3 +4,6 @@ Restrictions: superficial
Tests: amd64-klibc
Depends: @, qemu-system-x86, linux-image-amd64, klibc-utils, genext2fs
+
+Tests: amd64-busybox
+Depends: @, qemu-system-x86, linux-image-amd64, klibc-utils, busybox | busybox-initramfs, genext2fs