Skip to content

Commit 100df77

Browse files
committed
update path
1 parent f557133 commit 100df77

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

crates/vite_task_graph/tests/snapshots.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,7 @@ fn snapshot_execution_graph(
108108

109109
fn stabilize_absolute_path(path: &mut Arc<AbsolutePath>, base_dir: &AbsolutePath) {
110110
let relative_path = path.strip_prefix(base_dir).unwrap().unwrap();
111-
let new_base_dir =
112-
AbsolutePath::new(if cfg!(windows) { "C:\\workspace" } else { "/workspace" }).unwrap();
111+
let new_base_dir = AbsolutePath::new("//?/").unwrap(); // this path is considered absolute on all platforms
113112
*path = new_base_dir.join(relative_path).into();
114113
}
115114

crates/vite_task_graph/tests/snapshots/snapshots__query - ambiguous task name@transitive-dependency-workspace.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ AmbiguousPackageName {
77
package_name: "@test/a",
88
package_paths: [
99
AbsolutePath(
10-
"/workspace/packages/a",
10+
"//?/packages/a",
1111
),
1212
AbsolutePath(
13-
"/workspace/packages/another-a",
13+
"//?/packages/another-a",
1414
),
1515
],
1616
}

0 commit comments

Comments
 (0)