]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
testsuite: reformat and clang-format off args[]
authorEmil Velikov <emil.l.velikov@gmail.com>
Sun, 8 Sep 2024 10:38:12 +0000 (11:38 +0100)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Mon, 9 Sep 2024 04:39:19 +0000 (23:39 -0500)
Reformat a bunch of the args blocks and freeze them as-is. The remaining
instances clang-format handles correctly. The format is:

  progname,
  '--list', 'of', '--arguments',
  'modname',
  NULL

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/118
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
testsuite/test-depmod.c
testsuite/test-modinfo.c
testsuite/test-modprobe.c

index 89e763ba08d88a0e9a4ebb7c4be270ad1ab49ce5..478dda04f8459b1e7170d9eb29dd8b9167ea5296 100644 (file)
@@ -49,9 +49,11 @@ static noreturn int depmod_modules_outdir(const struct test *t)
 {
        const char *progname = TOOLS_DIR "/depmod";
        const char *const args[] = {
+               // clang-format off
                progname,
                "--outdir", MODULES_OUTDIR_ROOTFS "/outdir/",
                NULL,
+               // clang-format on
        };
 
        test_spawn_prog(progname, args);
index 8b7c050ec9a0c4f4845969865cf16734132463b2..c886b5417304615c354d63dff09d0d896e192fe5 100644 (file)
@@ -89,9 +89,12 @@ DEFINE_TEST(test_modinfo_signature,
 static noreturn int test_modinfo_external(const struct test *t)
 {
        const char *const args[] = {
-               progname, "-F", "filename",
+               // clang-format off
+               progname,
+               "-F", "filename",
                "mod-simple",
                NULL,
+               // clang-format on
        };
        test_spawn_prog(progname, args);
        exit(EXIT_FAILURE);
index 39c19014aa99fbf417145714fd3018fb67aeb32b..414c8cd8653b21335e1a1ae6cf32d4241fcd3fae 100644 (file)
@@ -57,14 +57,16 @@ DEFINE_TEST(modprobe_show_depends2,
                .out = TESTSUITE_ROOTFS "test-modprobe/show-depends/correct-mod-simple.txt",
        });
 
-
 static noreturn int modprobe_show_alias_to_none(const struct test *t)
 {
        const char *progname = TOOLS_DIR "/modprobe";
        const char *const args[] = {
+               // clang-format off
                progname,
-               "--show-depends", "--ignore-install", "--quiet", "mod-simple",
+               "--show-depends", "--ignore-install", "--quiet",
+               "mod-simple",
                NULL,
+               // clang-format on
        };
 
        test_spawn_prog(progname, args);
@@ -82,14 +84,16 @@ DEFINE_TEST(modprobe_show_alias_to_none,
        .modules_loaded = "",
        );
 
-
 static noreturn int modprobe_show_exports(const struct test *t)
 {
        const char *progname = TOOLS_DIR "/modprobe";
        const char *const args[] = {
+               // clang-format off
                progname,
-               "--show-exports", "--quiet", "/mod-loop-a.ko",
+               "--show-exports", "--quiet",
+               "/mod-loop-a.ko",
                NULL,
+               // clang-format on
        };
 
        test_spawn_prog(progname, args);