Skip to content

Commit 5dadaf0

Browse files
hulthebuggmagnet
authored andcommitted
Add list-tests command to test-manager
1 parent 139029c commit 5dadaf0

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

test/test-manager/src/main.rs

+14
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@ enum Commands {
5959
keep_changes: bool,
6060
},
6161

62+
/// List all tests and their priority.
63+
ListTests,
64+
6265
/// Spawn a runner instance and run tests
6366
RunTests {
6467
/// Name of the runner config
@@ -198,6 +201,17 @@ async fn main() -> Result<()> {
198201

199202
Ok(())
200203
}
204+
Commands::ListTests => {
205+
println!("priority\tname");
206+
for test in tests::get_tests() {
207+
println!(
208+
"{priority:8}\t{name}",
209+
name = test.name,
210+
priority = test.priority.unwrap_or(0),
211+
);
212+
}
213+
Ok(())
214+
}
201215
Commands::RunTests {
202216
name,
203217
display,

0 commit comments

Comments
 (0)