From 3c1d5812afcded65ab085302a647fef7d1933ea4 Mon Sep 17 00:00:00 2001 From: Yann Collet Date: Wed, 14 Sep 2022 11:04:24 -0700 Subject: add a test to catch issue #1164 where `--test -m files*.lz4` would create a bunch of `files*` files. `--test` should not create any file. It turns out the bug was already fixed when #1164 was filled, but it also shows that the CI system was blind to such issues when it happened. The new test was run with `v1.9.3` and triggered an error, as expected. --- tests/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/Makefile b/tests/Makefile index 93a5581..62e364a 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -312,8 +312,14 @@ test-lz4-multiple: lz4 datagen # compress multiple files, one of which is absent (must fail) ! $(LZ4) -f -m $(FPREFIX)-concat1 notHere $(FPREFIX)-concat2 # must fail : notHere not present # test lz4-compressed file + $(RM) $(FPREFIX)-concat1 $(FPREFIX)-concat2 $(LZ4) -tm $(FPREFIX)-concat1.lz4 + # ensure the test doesn't create artifact + test ! -f $(FPREFIX)-concat1 # must not create file artefact + # test multiple lz4-compressed file $(LZ4) -tm $(FPREFIX)-concat1.lz4 $(FPREFIX)-concat2.lz4 + test ! -f $(FPREFIX)-concat1 # must not create file artefact + test ! -f $(FPREFIX)-concat2 # must not create file artefact # test multiple lz4 files, one of which is absent (must fail) ! $(LZ4) -tm $(FPREFIX)-concat1.lz4 notHere.lz4 $(FPREFIX)-concat2.lz4 @$(RM) $(FPREFIX)* -- cgit v0.12