diff --git a/src/tools/tidy/src/error_codes.rs b/src/tools/tidy/src/error_codes.rs index 026f7d87418..4498666da1e 100644 --- a/src/tools/tidy/src/error_codes.rs +++ b/src/tools/tidy/src/error_codes.rs @@ -289,11 +289,12 @@ fn check_error_codes_tests(root_path: &Path, error_codes: &[String], errors: &mu continue; } - let file = match fs::read_to_string(test_path) { + let file = match fs::read_to_string(&test_path) { Ok(file) => file, Err(err) => { println!( - "WARNING: Failed to read UI test file (`{test_path}`) for `{code}` but the file exists. The test is assumed to work:\n{err}" + "WARNING: Failed to read UI test file (`{}`) for `{code}` but the file exists. The test is assumed to work:\n{err}", + test_path.display() ); continue; }