[llvm] [LIT] replace `lit.util.mkdir` with `pathlib.Path.mkdir` (PR #163948)

Alexander Richardson via llvm-commits llvm-commits at lists.llvm.org
Sat Nov 1 01:54:22 PDT 2025


================
@@ -1,2 +1,10 @@
 ## Tests glob pattern handling in the mkdir command.
+
+## This mkdir should fail because the `example_file*.input`s are regular files.
 # RUN: not mkdir %S/example_file*.input
+
+# RUN: mkdir %S/example_dir1.new
+# RUN: mkdir %S/example_dir2.new
+
+## This mkdir should succeed (so RUN should fail) because the `example_dir*.news` that already exist are directories.
+# RUN: not mkdir %S/example_dir*.new
----------------
arichardson wrote:

Ah I was not aware that %S is actually in the build tree. LGTM

https://github.com/llvm/llvm-project/pull/163948


More information about the llvm-commits mailing list