diff options
Diffstat (limited to 'test/backupstorefix')
-rw-r--r-- | test/backupstorefix/testbackupstorefix.cpp | 8 | ||||
-rwxr-xr-x | test/backupstorefix/testfiles/testbackupstorefix.pl.in | 16 |
2 files changed, 15 insertions, 9 deletions
diff --git a/test/backupstorefix/testbackupstorefix.cpp b/test/backupstorefix/testbackupstorefix.cpp index 38492bd1..ac1d0c14 100644 --- a/test/backupstorefix/testbackupstorefix.cpp +++ b/test/backupstorefix/testbackupstorefix.cpp @@ -671,8 +671,12 @@ int test(int argc, const char *argv[]) char name[256]; while(::fgets(line, sizeof(line), f) != 0) { - TEST_THAT(::sscanf(line, "%x %s %s", &id, - flags, name) == 3); + if(StartsWith("WARNING: SSLSecurityLevel not set.", line)) + { + continue; + } + TEST_EQUAL_LINE(3, ::sscanf(line, "%x %s %s", &id, flags, name), + "Unexpected format in initial-listing.txt: <" << line << ">"); bool isDir = (::strcmp(flags, "-d---") == 0); //TRACE3("%x,%d,%s\n", id, isDir, name); MEMLEAKFINDER_NO_LEAKS; diff --git a/test/backupstorefix/testfiles/testbackupstorefix.pl.in b/test/backupstorefix/testfiles/testbackupstorefix.pl.in index fc807155..483087f7 100755 --- a/test/backupstorefix/testfiles/testbackupstorefix.pl.in +++ b/test/backupstorefix/testfiles/testbackupstorefix.pl.in @@ -148,18 +148,20 @@ elsif($ARGV[0] eq 'reroot') or die "can't open copy listing file"; my $err = 0; my $count = 0; - while(<LISTING>) + while(my $line = <LISTING>) { - print LISTING_COPY; - chomp; - s/\[FILENAME NOT ENCRYPTED\]//; - next if /^WARNING: \*\*\*\* BackupStoreFilename encoded with Clear encoding \*\*\*\*/; - my ($id,$type,$name) = split / /; + print LISTING_COPY $line; + chomp $line; + $line =~s/\[FILENAME NOT ENCRYPTED\]//; + next if $line =~ /^WARNING: \*\*\*\* BackupStoreFilename encoded with Clear encoding \*\*\*\*/; + next if $line =~ /^WARNING: SSLSecurityLevel not set./; + my ($id,$type,$name) = split / /, $line; $count++; if($name !~ /\Alost\+found0/) { # everything must be in a lost and found dir - $err = 1 + print "Expected '$name' to be in a lost+found directory, but it was not ($line)"; + $err = 1; } } close LISTING_COPY; |