Skip to content

Commit bb7eeb1

Browse files
committed
use resolved tmp path
1 parent ae7e388 commit bb7eeb1

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

  • crates/vite_task_bin/tests/test_snapshots

crates/vite_task_bin/tests/test_snapshots/main.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use std::{
1313
use copy_dir::copy_dir;
1414
use redact::{redact_e2e_output, redact_snapshot};
1515
use tokio::runtime::Runtime;
16-
use vite_path::{AbsolutePath, RelativePathBuf};
16+
use vite_path::{AbsolutePath, AbsolutePathBuf, RelativePathBuf};
1717
use vite_str::Str;
1818
use vite_task::{CLIArgs, Session};
1919
use vite_task_bin::CustomTaskSubcommand;
@@ -209,13 +209,13 @@ fn run_case(runtime: &Runtime, tmpdir: &AbsolutePath, fixture_path: &Path) {
209209
fn test_snapshots() {
210210
let tokio_runtime = Runtime::new().unwrap();
211211
let tmp_dir = tempfile::tempdir().unwrap();
212-
let tmp_dir_path = AbsolutePath::new(tmp_dir.path()).unwrap();
212+
let tmp_dir_path = AbsolutePathBuf::new(tmp_dir.path().canonicalize().unwrap()).unwrap();
213213

214214
let tests_dir = std::env::current_dir().unwrap().join("tests");
215215

216216
insta::glob!(tests_dir, "test_snapshots/fixtures/*", |case_path| run_case(
217217
&tokio_runtime,
218-
tmp_dir_path,
218+
&tmp_dir_path,
219219
case_path
220220
));
221221
}

0 commit comments

Comments
 (0)