Skip to content

Commit b2219d6

Browse files
authored
fix unnecessary to_resolved calls in test cases (#73501)
### What? These cases cause warnings by the new check.
1 parent 1ddc35d commit b2219d6

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

turbopack/crates/turbopack-tests/tests/execution.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ async fn prepare_test(resource: RcStr) -> Result<Vc<PreparedTest>> {
248248
path: path.to_resolved().await?,
249249
project_path: project_path.to_resolved().await?,
250250
tests_path: tests_path.to_resolved().await?,
251-
project_root: project_root.to_resolved().await?,
251+
project_root,
252252
options,
253253
}
254254
.cell())
@@ -320,7 +320,7 @@ async fn run_test(prepared_test: Vc<PreparedTest>) -> Result<Vc<RunTestResult>>
320320
import_externals: true,
321321
..Default::default()
322322
},
323-
preset_env_versions: Some(env.to_resolved().await?),
323+
preset_env_versions: Some(env),
324324
tree_shaking_mode: options.tree_shaking_mode,
325325
rules: vec![(
326326
ContextCondition::InDirectory("node_modules".into()),

turbopack/crates/turbopack-tests/tests/snapshot.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ async fn run_test(resource: RcStr) -> Result<Vc<FileSystemPath>> {
296296
css: CssOptionsContext {
297297
..Default::default()
298298
},
299-
preset_env_versions: Some(env.to_resolved().await?),
299+
preset_env_versions: Some(env),
300300
rules: vec![(
301301
ContextCondition::InDirectory("node_modules".into()),
302302
ModuleOptionsContext {
@@ -357,8 +357,8 @@ async fn run_test(resource: RcStr) -> Result<Vc<FileSystemPath>> {
357357
project_root,
358358
path,
359359
path,
360-
chunk_root_path.to_resolved().await?,
361-
static_root_path.to_resolved().await?,
360+
chunk_root_path,
361+
static_root_path,
362362
env,
363363
options.runtime_type,
364364
)

0 commit comments

Comments
 (0)