about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorJubilee <46493976+workingjubilee@users.noreply.github.com>2024-07-12 13:47:07 -0700
committerGitHub <noreply@github.com>2024-07-12 13:47:07 -0700
commit6cdef05a7167292592674d45abca4aec6895d010 (patch)
tree2baabba619c2bd96cee289aae9a20de6685233bf /src
parentafb2fbf6926e64479f885295fa0a7da27f4040a2 (diff)
parentc6cdbe635b08f278ae2d7f1945dca79b9e69ee9c (diff)
Rollup merge of #127338 - Oneirical:ready-your-arbatests, r=jieyouxu
Migrate `extra-filename-with-temp-outputs` and `issue-85019-moved-src-dir` `run-make` tests to rmake

Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Please try:

try-job: armhf-gnu
// try-job: test-various // already tried
try-job: x86_64-msvc
try-job: aarch64-apple
Diffstat (limited to 'src')
-rw-r--r--src/tools/run-make-support/src/lib.rs5
-rw-r--r--src/tools/tidy/src/allowed_run_make_makefiles.txt2
2 files changed, 5 insertions, 2 deletions
diff --git a/src/tools/run-make-support/src/lib.rs b/src/tools/run-make-support/src/lib.rs
index 5655318267a..04b6fd2d6c1 100644
--- a/src/tools/run-make-support/src/lib.rs
+++ b/src/tools/run-make-support/src/lib.rs
@@ -303,6 +303,11 @@ pub fn filename_not_in_denylist<P: AsRef<Path>, V: AsRef<[String]>>(path: P, exp
         .is_some_and(|name| !expected.contains(&name.to_str().unwrap().to_owned()))
 }
 
+/// Returns true if the filename at `path` ends with `suffix`.
+pub fn has_suffix<P: AsRef<Path>>(path: P, suffix: &str) -> bool {
+    path.as_ref().file_name().is_some_and(|name| name.to_str().unwrap().ends_with(suffix))
+}
+
 /// Gathers all files in the current working directory that have the extension `ext`, and counts
 /// the number of lines within that contain a match with the regex pattern `re`.
 pub fn count_regex_matches_in_files_with_extension(re: &regex::Regex, ext: &str) -> usize {
diff --git a/src/tools/tidy/src/allowed_run_make_makefiles.txt b/src/tools/tidy/src/allowed_run_make_makefiles.txt
index 33120cf93f9..07d047a4815 100644
--- a/src/tools/tidy/src/allowed_run_make_makefiles.txt
+++ b/src/tools/tidy/src/allowed_run_make_makefiles.txt
@@ -37,7 +37,6 @@ run-make/extern-fn-with-packed-struct/Makefile
 run-make/extern-fn-with-union/Makefile
 run-make/extern-multiple-copies/Makefile
 run-make/extern-multiple-copies2/Makefile
-run-make/extra-filename-with-temp-outputs/Makefile
 run-make/fmt-write-bloat/Makefile
 run-make/foreign-double-unwind/Makefile
 run-make/foreign-exceptions/Makefile
@@ -60,7 +59,6 @@ run-make/issue-47551/Makefile
 run-make/issue-69368/Makefile
 run-make/issue-83045/Makefile
 run-make/issue-84395-lto-embed-bitcode/Makefile
-run-make/issue-85019-moved-src-dir/Makefile
 run-make/issue-85401-static-mir/Makefile
 run-make/issue-88756-default-output/Makefile
 run-make/issue-97463-abi-param-passing/Makefile