]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/helper/test-path-utils.c
Sync with 2.42.2
[thirdparty/git.git] / t / helper / test-path-utils.c
index 70396fa38454e86d661b9a4857e3ef463ee40f63..023ed2e1a7835c9a8029cc8a96fd3df2a55f1dd0 100644 (file)
@@ -7,6 +7,7 @@
 #include "string-list.h"
 #include "trace.h"
 #include "utf8.h"
+#include "copy.h"
 
 /*
  * A "string_list_each_func_t" function that normalizes an entry from
@@ -500,6 +501,16 @@ int cmd__path_utils(int argc, const char **argv)
                return !!res;
        }
 
+       if (argc == 4 && !strcmp(argv[1], "do_files_match")) {
+               int ret = do_files_match(argv[2], argv[3]);
+
+               if (ret)
+                       printf("equal\n");
+               else
+                       printf("different\n");
+               return !ret;
+       }
+
        fprintf(stderr, "%s: unknown function name: %s\n", argv[0],
                argv[1] ? argv[1] : "(there was none)");
        return 1;