]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
test: remove test module
authorJo Zzsi <jozzsicsataban@gmail.com>
Thu, 31 Jul 2025 11:21:44 +0000 (07:21 -0400)
committerLaszlo <laszlo.gombos@gmail.com>
Sat, 9 Aug 2025 18:53:51 +0000 (14:53 -0400)
test module can be simplified down to just a configuration file instead
as it no longer has its own additional scripts files that would
require a module.

This commit is an additional step to reinforce testing in a similar configuration
as actual end-user configuration.

dracut.conf.d/test/test.conf
modules.d/70test [deleted symlink]
test/TEST-70-ISCSI/test.sh
test/TEST-82-DRACUT-CPIO/test.sh
test/modules.d/70test/module-setup.sh [deleted file]

index e5bf3e7acae421b6f4ef438d88b08a1382960e7a..daf598242af2c4bbba8a12bcf4b67c69c5c4a6ec 100644 (file)
@@ -1,4 +1,4 @@
-add_dracutmodules+=" test "
+add_dracutmodules+=" base debug qemu watchdog kernel-modules "
 # do not strip
 do_strip="no"
 do_hardlink="no"
@@ -10,3 +10,6 @@ kernel_cmdline=" rd.retry=10 rd.timeout=120 rd.info rd.shell=0 "
 
 # test the dlopen dependencies support
 add_dlopen_features+=" libsystemd-shared-*.so:fido2 "
+
+# testsuite assumes ext4 for convenience
+add_drivers+=" ext4 "
diff --git a/modules.d/70test b/modules.d/70test
deleted file mode 120000 (symlink)
index fecae4c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-../test/modules.d/70test
\ No newline at end of file
index cbcee91cb3c9d7b9a0ba185d556c16f90df45a5b..a1bd034f4b7a0ca7745a3f490f1c455b27fd7638 100755 (executable)
@@ -210,7 +210,8 @@ test_setup() {
 
     # Make server's dracut image
     "$DRACUT" \
-        -a "test network-legacy" \
+        -a "network-legacy" \
+        --add-confdir test \
         -d "piix ide-gd_mod ata_piix ext4 sd_mod drbg virtio_net virtio_pci virtio_scsi" \
         -i "./server.link" "/etc/systemd/network/01-server.link" \
         -i ./wait-if-server.sh /lib/dracut/hooks/pre-mount/99-wait-if-server.sh \
index e90366231765b164d97e89578b8eff9acb41d138..c07ac1cf640a0cf812642577ed4124ae6284e237 100755 (executable)
@@ -29,7 +29,7 @@ EOF
 
     test_dracut \
         --no-kernel --drivers "" \
-        --modules "test" \
+        --add-confdir "test" \
         "${dracut_cpio_params[@]}" \
         --include "$tdir/init.sh" /lib/dracut/hooks/emergency/00-init.sh \
         --install "poweroff" \
diff --git a/test/modules.d/70test/module-setup.sh b/test/modules.d/70test/module-setup.sh
deleted file mode 100755 (executable)
index 23d707c..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/bash
-
-check() {
-    # Only include the module if another module requires it
-    return 255
-}
-
-depends() {
-    echo "base debug qemu watchdog kernel-modules"
-}
-
-# testsuite assumes ext4 for convenience
-installkernel() {
-    hostonly='' instmods \
-        ext4
-}