Skip to content

Commit bd23e0e

Browse files
committed
canonicalize path in another place to fix rust-lang#128411
1 parent f91da72 commit bd23e0e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/tools/compiletest/src/runtest.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -2968,7 +2968,9 @@ impl<'test> TestCx<'test> {
29682968
for _ in res.stdout.split('\n').filter(|s| s.starts_with("test ")).inspect(|s| {
29692969
if let Some((left, right)) = s.split_once(" - ") {
29702970
let path = left.rsplit("test ").next().unwrap();
2971-
if let Some(ref mut v) = files.get_mut(&path.replace('\\', "/")) {
2971+
let path = fs::canonicalize(&path).expect("failed to canonicalize");
2972+
let path = path.to_str().unwrap().replace('\\', "/");
2973+
if let Some(ref mut v) = files.get_mut(&path) {
29722974
tested += 1;
29732975
let mut iter = right.split("(line ");
29742976
iter.next();

0 commit comments

Comments
 (0)