Avoid clone when constructing runnable label.

This commit is contained in:
Mathew Horner 2024-05-25 15:00:15 -05:00
parent a55e8bf09c
commit 333bedd70f
No known key found for this signature in database
2 changed files with 3 additions and 3 deletions

View file

@ -79,7 +79,7 @@ impl RunnableKind {
impl Runnable {
// test package::module::testname
pub fn label(&self, target: Option<String>) -> String {
pub fn label(&self, target: Option<&str>) -> String {
match &self.kind {
RunnableKind::Test { test_id, .. } => format!("test {test_id}"),
RunnableKind::TestMod { path } => format!("test-mod {path}"),