diff options
| author | Philipp Krones <hello@philkrones.com> | 2020-02-10 16:42:50 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-02-10 16:42:50 +0100 |
| commit | c86c09b19a7db3749c2c43a9fa964aa45ac13af1 (patch) | |
| tree | 835b2f27b934bd1b6b4257413b1b6f0f3804e405 | |
| parent | f940b04de6524f94140f3630434f89034e0a6481 (diff) | |
| download | rust-c86c09b19a7db3749c2c43a9fa964aa45ac13af1.tar.gz rust-c86c09b19a7db3749c2c43a9fa964aa45ac13af1.zip | |
Use current_dir instead of cargo_metadata
Co-Authored-By: lzutao <taolzu@gmail.com>
| -rw-r--r-- | tests/cargo/mod.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/cargo/mod.rs b/tests/cargo/mod.rs index 5f06a97d3e9..3c385343f70 100644 --- a/tests/cargo/mod.rs +++ b/tests/cargo/mod.rs @@ -1,4 +1,3 @@ -use cargo_metadata::MetadataCommand; use lazy_static::lazy_static; use std::env; use std::path::PathBuf; @@ -7,7 +6,7 @@ lazy_static! { pub static ref CARGO_TARGET_DIR: PathBuf = { match env::var_os("CARGO_TARGET_DIR") { Some(v) => v.into(), - None => MetadataCommand::new().exec().unwrap().target_directory, + None => env::current_dir().unwrap().join("target"), } }; pub static ref TARGET_LIB: PathBuf = { |
