summaryrefslogtreecommitdiff
path: root/cli/tsc.rs
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tsc.rs')
-rw-r--r--cli/tsc.rs8
1 files changed, 2 insertions, 6 deletions
diff --git a/cli/tsc.rs b/cli/tsc.rs
index b355c12fa..57bbeeca3 100644
--- a/cli/tsc.rs
+++ b/cli/tsc.rs
@@ -596,8 +596,6 @@ mod tests {
use crate::module_graph::tests::MockSpecifierHandler;
use crate::module_graph::GraphBuilder;
use deno_core::parking_lot::Mutex;
- use std::env;
- use std::path::PathBuf;
async fn setup(
maybe_specifier: Option<ModuleSpecifier>,
@@ -607,8 +605,7 @@ mod tests {
let specifier = maybe_specifier
.unwrap_or_else(|| resolve_url_or_path("file:///main.ts").unwrap());
let hash_data = maybe_hash_data.unwrap_or_else(|| vec![b"".to_vec()]);
- let c = PathBuf::from(env::var_os("CARGO_MANIFEST_DIR").unwrap());
- let fixtures = c.join("tests/tsc2");
+ let fixtures = test_util::testdata_path().join("tsc2");
let handler = Arc::new(Mutex::new(MockSpecifierHandler {
fixtures,
..MockSpecifierHandler::default()
@@ -633,8 +630,7 @@ mod tests {
specifier: &ModuleSpecifier,
) -> Result<Response, AnyError> {
let hash_data = vec![b"something".to_vec()];
- let c = PathBuf::from(env::var_os("CARGO_MANIFEST_DIR").unwrap());
- let fixtures = c.join("tests/tsc2");
+ let fixtures = test_util::testdata_path().join("tsc2");
let handler = Arc::new(Mutex::new(MockSpecifierHandler {
fixtures,
..Default::default()