|
This is a combination of three previous low-impact changes, combined to
reduce patch-pushing burden.
((( GF_INTERACTIVE )))
To use this, just define GF_INTERACTIVE (value doesn't matter as long as
the length is non-zero) before running your test. It replaces the TEST
alias with one that will prompt you before executing that line. You can
answer:
'y' to execute the line
'q' to exit the test immediately
anything else to skip this line and continue
This is particularly useful to inspect state in another window while a
test is paused, or to do manual experimentation in the (often complex)
configuration created during a test.
((( CLEANUP.SH )))
tests: add cleanup.sh
Often, a developer might want to run a test up to some point, then bail
out and poke around manually. That leaves state that needs to be
cleaned up before the next test can run properly. This patch adds a
trivial script to invoke that cleanup machinery.
Along the way, code in include.rc to find env.rc was changed to be more
robust across arbitrarily deep (or shallow) directory hierarchies.
((( REPLACE EXISTING TAR FILES INSTEAD OF APPENDING )))
We currently use "tar rf" to collect log files from each test. This
*appends* the new data to whatever's there already, which has two bad
effects when a test is run repeatedly.
* Ever-increasing size of the tar file.
* Ever-increasing time to extract logs from the tar file, with each
copy completely overwriting any previous.
This doesn't seem to be a problem in our regression tests, because the
entire directory is nuked during package removal and reinstallation.
However, when running a test repeatedly during a debug session, the
effects can be quite severe. This is particularly evident with JBR,
because the "logs" that get archived include large journal files.
Certain other translators, such as changelog and CTR, might be prone to
similar effects.
There's no point to having multiple copies of the logs in each tar file.
As far as I know, nobody ever takes advantage of that. Therefore, use
"tar cf" to overwrite any existing archive instead of appending. This
change also handles excluding other .tar files in a portable way.
Change-Id: Iebf77d496a71976c321bbacb49776338a9da586f
Signed-off-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-on: http://review.gluster.org/14874
Smoke: Gluster Build System <jenkins@build.gluster.org>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
|