]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
testsuite: Rename test-user
authorLucas De Marchi <lucas.de.marchi@gmail.com>
Fri, 16 Aug 2024 04:17:11 +0000 (23:17 -0500)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Fri, 16 Aug 2024 21:47:33 +0000 (16:47 -0500)
First version of the patches implementing weakdep called them "user
dep", hence the name of the test. That doesn't make sense anymore after
the rename.  Rename the test accordingly.

Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/75
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
17 files changed:
Makefile.am
testsuite/.gitignore
testsuite/rootfs-pristine/test-weakdep/correct-weakdep.txt [moved from testsuite/rootfs-pristine/test-user/correct-weakdep.txt with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/etc/modprobe.d/dumb-weakdep.conf [moved from testsuite/rootfs-pristine/test-user/etc/modprobe.d/dumb-weakdep.conf with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.alias [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.alias with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.alias.bin [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.alias.bin with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.builtin.alias.bin [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.builtin.alias.bin with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.builtin.bin [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.builtin.bin with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.dep [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.dep with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.dep.bin [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.dep.bin with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.devname [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.devname with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.softdep [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.softdep with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.symbols [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.symbols with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.symbols.bin [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.symbols.bin with 100% similarity]
testsuite/rootfs-pristine/test-weakdep/lib/modules/4.4.4/modules.weakdep [moved from testsuite/rootfs-pristine/test-user/lib/modules/4.4.4/modules.weakdep with 100% similarity]
testsuite/setup-rootfs.sh
testsuite/test-weakdep.c [moved from testsuite/test-user.c with 76% similarity]

index fc1d8f2669bd9ad28e80a07f3b91509080a28761..ceb3f8d8715a494ed581a937c6d207251947c867 100644 (file)
@@ -276,7 +276,7 @@ TESTSUITE = \
        testsuite/test-modinfo testsuite/test-util testsuite/test-new-module \
        testsuite/test-modprobe testsuite/test-blacklist \
        testsuite/test-dependencies testsuite/test-depmod \
-       testsuite/test-list testsuite/test-user
+       testsuite/test-list testsuite/test-weakdep
 
 check_PROGRAMS = $(TESTSUITE)
 TESTS = $(TESTSUITE)
@@ -319,8 +319,8 @@ testsuite_test_depmod_LDADD = $(TESTSUITE_LDADD)
 testsuite_test_depmod_CPPFLAGS = $(TESTSUITE_CPPFLAGS)
 testsuite_test_list_LDADD = $(TESTSUITE_LDADD)
 testsuite_test_list_CPPFLAGS = $(TESTSUITE_CPPFLAGS)
-testsuite_test_user_LDADD = $(TESTSUITE_LDADD)
-testsuite_test_user_CPPFLAGS = $(TESTSUITE_CPPFLAGS)
+testsuite_test_weakdep_LDADD = $(TESTSUITE_LDADD)
+testsuite_test_weakdep_CPPFLAGS = $(TESTSUITE_CPPFLAGS)
 
 testsuite-distclean:
        $(RM) -r $(ROOTFS)
index 56d628e0a46c5a73751ba052cc436b47e700e28c..ce51cc20610f36de7c38270c35cd8dc7bee6beb6 100644 (file)
@@ -18,7 +18,7 @@
 /test-modprobe
 /test-hash
 /test-list
-/test-user
+/test-weakdep
 /rootfs
 /stamp-rootfs
 /test-scratchbuf.log
@@ -53,5 +53,5 @@
 /test-testsuite.trs
 /test-list.log
 /test-list.trs
-/test-user.log
-/test-user.trs
+/test-weakdep.log
+/test-weakdep.trs
index f57ef19766ac50c841b30a44fceb00f1016d6bf3..31b32df9625e81e31828f15548ce26984aed578c 100755 (executable)
@@ -108,10 +108,10 @@ map=(
     ["test-modinfo/mod-simple-sha256.ko"]="mod-simple.ko"
     ["test-modinfo/mod-simple-pkcs7.ko"]="mod-simple.ko"
     ["test-modinfo/external/lib/modules/external/mod-simple.ko"]="mod-simple.ko"
-    ["test-user$MODULE_DIRECTORY/4.4.4/kernel/mod-loop-a.ko"]="mod-loop-a.ko"
-    ["test-user$MODULE_DIRECTORY/4.4.4/kernel/mod-loop-b.ko"]="mod-loop-b.ko"
-    ["test-user$MODULE_DIRECTORY/4.4.4/kernel/mod-simple.ko"]="mod-simple.ko"
-    ["test-user$MODULE_DIRECTORY/4.4.4/kernel/mod-weakdep.ko"]="mod-weakdep.ko"
+    ["test-weakdep$MODULE_DIRECTORY/4.4.4/kernel/mod-loop-a.ko"]="mod-loop-a.ko"
+    ["test-weakdep$MODULE_DIRECTORY/4.4.4/kernel/mod-loop-b.ko"]="mod-loop-b.ko"
+    ["test-weakdep$MODULE_DIRECTORY/4.4.4/kernel/mod-simple.ko"]="mod-simple.ko"
+    ["test-weakdep$MODULE_DIRECTORY/4.4.4/kernel/mod-weakdep.ko"]="mod-weakdep.ko"
 )
 
 gzip_array=(
similarity index 76%
rename from testsuite/test-user.c
rename to testsuite/test-weakdep.c
index 0db48c3aca641489fd258cf1addc151b6307a04e..3a69e184c4f95746936d9f5cc686bbdf1721834d 100644 (file)
 
 #include "testsuite.h"
 
-#define TEST_USER_ROOTFS TESTSUITE_ROOTFS "test-user/"
-#define TEST_USER_KERNEL_DIR TEST_USER_ROOTFS MODULE_DIRECTORY "/4.4.4/"
+#define TEST_WEAKDEP_ROOTFS TESTSUITE_ROOTFS "test-weakdep/"
+#define TEST_WEAKDEP_KERNEL_DIR TEST_WEAKDEP_ROOTFS MODULE_DIRECTORY "/4.4.4/"
 
-static const char *const test_user_config_paths[] = {
-       TEST_USER_ROOTFS "etc/modprobe.d",
+static const char *const test_weakdep_config_paths[] = {
+       TEST_WEAKDEP_ROOTFS "etc/modprobe.d",
        NULL
 };
 
@@ -29,13 +29,13 @@ static const char *const mod_name[] = {
        NULL
 };
 
-static int test_user_weakdep(const struct test *t)
+static int test_weakdep(const struct test *t)
 {
        struct kmod_ctx *ctx;
        int mod_name_index = 0;
        int err;
 
-       ctx = kmod_new(TEST_USER_KERNEL_DIR, test_user_config_paths);
+       ctx = kmod_new(TEST_WEAKDEP_KERNEL_DIR, test_weakdep_config_paths);
        if (ctx == NULL)
                exit(EXIT_FAILURE);
 
@@ -83,16 +83,16 @@ static int test_user_weakdep(const struct test *t)
 
        return EXIT_SUCCESS;
 }
-DEFINE_TEST(test_user_weakdep,
-       .description = "check if modprobe breaks weakdep2",
+DEFINE_TEST(test_weakdep,
+       .description = "check if modprobe breaks weakdep",
        .config = {
                [TC_UNAME_R] = "4.4.4",
-               [TC_ROOTFS] = TESTSUITE_ROOTFS "test-user",
+               [TC_ROOTFS] = TESTSUITE_ROOTFS "test-weakdep",
                [TC_INIT_MODULE_RETCODES] = "",
        },
        .need_spawn = true,
        .output = {
-               .out = TESTSUITE_ROOTFS "test-user/correct-weakdep.txt",
+               .out = TESTSUITE_ROOTFS "test-weakdep/correct-weakdep.txt",
        });
 
 TESTSUITE_MAIN();