# -*-perl-*-

# As most of the tests fail intentionally, we have to filter our own output
$Silent = $silent = 1;


$afterallexpect = q{Failed \d+/\d+ test scripts};
$afterallok = 0;
while (<>){
    m|t/dumpcore| and $silent = 0;
    m|t/error| and $silent = $Silent;
    s/\[.*\]// if $silent;
    next if $silent && ! /^t/ && ! /Failed/;
    print;
    $afterallok++ if m|^$afterallexpect|;
}

if ($afterallok) {
    print qq{

... don\'t panic! These tests all should fail, everything seems perfectly okay

};
} else {
    print <<END;
Expected: "$afterallexpect"
Not ok
END
    die "Not ok";
}
