1 --- a/tests/integration.rs
2 +++ b/tests/integration.rs
3 @@ -16,20 +16,13 @@ impl CommandUnderTest {
4 fn new() -> CommandUnderTest {
5 // To find the directory where the built binary is, we walk up the directory tree of the test binary until the
6 // parent is "target/".
7 - let mut binary_path = env::current_exe().expect("need current binary path to find binary to test");
10 - let parent = binary_path.parent();
11 - if parent.is_none() {
12 - panic!("Failed to locate binary path from original path: {:?}", env::current_exe());
14 - let parent = parent.unwrap();
15 - if parent.is_dir() && parent.file_name().unwrap() == "target" {
21 + let mut binary_path = PathBuf::from(
25 + .join("@shortTarget@")
26 + .join(env!("cargoBuildType")),
30 if cfg!(target_os = "windows") {