4 use PublicInbox::TestCommon;
6 my $tmpdir = File::Spec->tmpdir;
8 diag "note: writes to `$tmpdir' by others results in false-positives";
10 my %cur = map { $_ => 1 } glob("$tmpdir/*");
11 for my $t (@ARGV ? @ARGV : glob('t/*.t')) {
12 open my $fh, '-|', $^X, '-w', $t;
17 next if /^ok / || /\A[0-9]+\.\.[0-9]+\z/;
20 ok(close($fh), $t) or diag(explain(\@out));
24 my @remain = grep { !$cur{$_}++ } glob("$tmpdir/*");
26 is_deeply(\@remain, [], "$t has no leftovers") or
27 diag "$t added: ",explain(\@remain);