From be6065c55fb392c5ad199c772fa41c5d71185538 Mon Sep 17 00:00:00 2001 From: venoosoo <120491991+venoosoo@users.noreply.github.com> Date: Sun, 17 May 2026 22:58:42 +0300 Subject: [PATCH 1/2] tests: added one test for decompress without --dir --- tests/integration.rs | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/tests/integration.rs b/tests/integration.rs index dcd5671a2..edc4e133e 100644 --- a/tests/integration.rs +++ b/tests/integration.rs @@ -1362,3 +1362,28 @@ fn decompress_concatenated_lz4_frames() { encoder.finish().unwrap() }); } + +#[test] +fn decompress_into_cwd() { + let (_tempdir, dir) = testdir().unwrap(); + let before = &dir.join("before"); + let after = &dir.join("after"); + fs::create_dir_all(before).unwrap(); + fs::create_dir_all(after).unwrap(); + create_random_files(before, 2, &mut SmallRng::from_os_rng()); + let compressed_archive = dir.join(format!("archive.zip")); + crate::utils::cargo_bin() + .arg("compress") + .arg(&before) + .arg(&compressed_archive) + .assert() + .success(); + crate::utils::cargo_bin() + .current_dir(&after) + .arg("decompress") + .arg(&compressed_archive) + .arg("--yes") + .assert() + .success(); + assert_same_directory(before, &after.join("before"), false); +} \ No newline at end of file From f0a92c814035eefc91de83181a9075bbfce521d0 Mon Sep 17 00:00:00 2001 From: venoosoo <120491991+venoosoo@users.noreply.github.com> Date: Sun, 17 May 2026 23:07:25 +0300 Subject: [PATCH 2/2] apply cargo fmt --- tests/integration.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/integration.rs b/tests/integration.rs index edc4e133e..5f082fbfb 100644 --- a/tests/integration.rs +++ b/tests/integration.rs @@ -1384,6 +1384,6 @@ fn decompress_into_cwd() { .arg(&compressed_archive) .arg("--yes") .assert() - .success(); + .success(); assert_same_directory(before, &after.join("before"), false); -} \ No newline at end of file +}