aboutsummaryrefslogtreecommitdiff
path: root/tests/runtests.pl
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2008-03-06 01:11:43 +0000
committerDan Fandrich <dan@coneharvesters.com>2008-03-06 01:11:43 +0000
commit80cec5a62abb2fa7f9d33d7ad80bb49f4aa1a30a (patch)
tree8e9fa2d3db3a2771df1288b0ade92db3e20d5eb0 /tests/runtests.pl
parent6c2c281a7eab0332569e77b0dd705145b2817c64 (diff)
Fixed the test harness so it will write out zero-length data files.
Diffstat (limited to 'tests/runtests.pl')
-rwxr-xr-xtests/runtests.pl10
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/runtests.pl b/tests/runtests.pl
index a868b2c3a..3c7fc882a 100755
--- a/tests/runtests.pl
+++ b/tests/runtests.pl
@@ -1957,13 +1957,11 @@ sub singletest {
unlink($memdump);
}
+ # create a (possibly-empty) file before starting the test
my @inputfile=getpart("client", "file");
- if(@inputfile) {
- # we need to generate a file before this test is invoked
- my %fileattr = getpartattr("client", "file");
-
- my $filename=$fileattr{'name'};
-
+ my %fileattr = getpartattr("client", "file");
+ my $filename=$fileattr{'name'};
+ if(@inputfile || $filename) {
if(!$filename) {
logmsg "ERROR: section client=>file has no name attribute\n";
return -1;