about summary refs log tree commit diff
path: root/src/bootstrap
diff options
context:
space:
mode:
authorYuki Okushi <jtitor@2k36.org>2021-05-07 15:20:30 +0900
committerGitHub <noreply@github.com>2021-05-07 15:20:30 +0900
commit87faf2e64f11ed3e1271af890a181b191fbb77a1 (patch)
tree8285c87d06d7609b41fe410ad6900c5ab02f7d61 /src/bootstrap
parent47050275f4bacfeb2d67d23697ea01340f0c0ab2 (diff)
parentcdbfea5c6cce88680239ddb796f1c8d2621e76d3 (diff)
downloadrust-87faf2e64f11ed3e1271af890a181b191fbb77a1.tar.gz
rust-87faf2e64f11ed3e1271af890a181b191fbb77a1.zip
Rollup merge of #84990 - GuillaumeGomez:sort-rustdoc-gui-tests, r=Mark-Simulacrum
Sort rustdoc-gui tests

The rustdoc-gui tests were randomly run. Not really a big issue but I prefer the tests to be sorted.
Diffstat (limited to 'src/bootstrap')
-rw-r--r--src/bootstrap/test.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
index edb4bb9938b..c98398cf1d2 100644
--- a/src/bootstrap/test.rs
+++ b/src/bootstrap/test.rs
@@ -831,6 +831,7 @@ impl Step for RustdocGUI {
             command.arg("src/test/rustdoc-gui/lib.rs").arg("-o").arg(&out_dir);
             builder.run(&mut command);
 
+            let mut tests = Vec::new();
             for file in fs::read_dir("src/test/rustdoc-gui").unwrap() {
                 let file = file.unwrap();
                 let file_path = file.path();
@@ -839,13 +840,17 @@ impl Step for RustdocGUI {
                 if !file_name.to_str().unwrap().ends_with(".goml") {
                     continue;
                 }
+                tests.push(file_path);
+            }
+            tests.sort_unstable();
+            for test in tests {
                 let mut command = Command::new(&nodejs);
                 command
                     .arg("src/tools/rustdoc-gui/tester.js")
                     .arg("--doc-folder")
                     .arg(out_dir.join("test_docs"))
                     .arg("--test-file")
-                    .arg(file_path);
+                    .arg(test);
                 builder.run(&mut command);
             }
         } else {