Skip to content

Commit b58eb1d

Browse files
committed
test(cli): canonicalize cache fixture roots
1 parent 3804548 commit b58eb1d

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

‎cli/src/execution/lifecycle.rs‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2677,11 +2677,11 @@ mod tests {
26772677

26782678
// One project root disappears; one cache is left on an older schema.
26792679
fs::remove_dir_all(temp.path().join("deleted")).expect("remove project");
2680-
let stale_key = crate::cache::CacheLocation::for_project(
2681-
Some(cache.as_path()),
2682-
&temp.path().join("stale"),
2683-
)
2684-
.expect("stale location");
2680+
let stale_root =
2681+
fs::canonicalize(temp.path().join(".").join("stale")).expect("canonical stale project");
2682+
let stale_key =
2683+
crate::cache::CacheLocation::for_project(Some(cache.as_path()), &stale_root)
2684+
.expect("stale location");
26852685
let connection =
26862686
rusqlite::Connection::open(&stale_key.database_path).expect("open stale cache");
26872687
connection

0 commit comments

Comments
 (0)