Skip to content

Commit 0fc2397

Browse files
authored
macros: add missing local flavor to tokio::main error message (#7597)
1 parent f07233f commit 0fc2397

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests-build/tests/fail/macros_invalid_input.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ error: Failed to parse value of `flavor` as string.
4040
23 | #[tokio::test(flavor = 123)]
4141
| ^^^
4242

43-
error: No such runtime flavor `foo`. The runtime flavors are `current_thread` and `multi_thread`.
43+
error: No such runtime flavor `foo`. The runtime flavors are `current_thread`, `local`, and `multi_thread`.
4444
--> tests/fail/macros_invalid_input.rs:26:24
4545
|
4646
26 | #[tokio::test(flavor = "foo")]

tokio-macros/src/entry.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ impl RuntimeFlavor {
2222
"single_thread" => Err("The single threaded runtime flavor is called `current_thread`.".to_string()),
2323
"basic_scheduler" => Err("The `basic_scheduler` runtime flavor has been renamed to `current_thread`.".to_string()),
2424
"threaded_scheduler" => Err("The `threaded_scheduler` runtime flavor has been renamed to `multi_thread`.".to_string()),
25-
_ => Err(format!("No such runtime flavor `{s}`. The runtime flavors are `current_thread` and `multi_thread`.")),
25+
_ => Err(format!("No such runtime flavor `{s}`. The runtime flavors are `current_thread`, `local`, and `multi_thread`.")),
2626
}
2727
}
2828
}

0 commit comments

Comments
 (0)