public inbox for bzip2-devel@sourceware.org
 help / color / mirror / Atom feed
* [bzip2-tests] Remove testfilecopy after second decompression attempt.
@ 2019-01-01  0:00 Mark Wielaard
  0 siblings, 0 replies; only message in thread
From: Mark Wielaard @ 2019-01-01  0:00 UTC (permalink / raw)
  To: bzip2-devel; +Cc: Mark Wielaard

I committed this small tweak that makes sure the test dir is fully
cleaned up.

We run tests twice, once in default mode and once in small mode.
For the recompression/redecompression attempt we create a copy of
the original input file. Which we remove after the first attempt
in default mode. It should also be removed after the second attempt
in small mode. Otherwise we keep a possibly very large file around.
---
 run-tests.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/run-tests.sh b/run-tests.sh
index 8fccf2c..c07deea 100755
--- a/run-tests.sh
+++ b/run-tests.sh
@@ -137,6 +137,8 @@ while IFS= read -r -d '' bzfile; do
            nogood=$[${nogood}+1]; continue; }
   fi
 
+  rm "${copy}"
+
 done < <(find ${TESTS_DIR} -type f -name \*\.bz2 -print0)
 
 echo
-- 
1.8.3.1

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-07-03 18:59 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-01  0:00 [bzip2-tests] Remove testfilecopy after second decompression attempt Mark Wielaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).