[tools] winetest/build-index: Delete obsolete test unit HTML files.

Francois Gouget fgouget at codeweavers.com
Fri Apr 9 04:38:27 CDT 2021


Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
This is not just about removing old test files, but also garbled test 
names that resulted from missing linefeeds, or concurrency issues. For 
instance 000007rsaenh:rsaenh and 006s:font.
---
 winetest/build-index | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/winetest/build-index b/winetest/build-index
index 5903f80ab..94453f4ab 100755
--- a/winetest/build-index
+++ b/winetest/build-index
@@ -341,6 +341,22 @@ EOF
     }
 }
 
+# And delete obsolete test files
+opendir(DIR, "data/tests") or die "could not open the 'data/tests' directory: $!";
+foreach my $entry (readdir(DIR))
+{
+    next if ($entry eq "." or $entry eq "..");
+    my $test = $entry;
+    $test =~ s/\.html$//;
+    next if ($alltests{$test});
+    if (!unlink "data/tests/$entry")
+    {
+        error("could not delete 'data/tests/$entry': $!\n");
+    }
+
+}
+closedir(DIR);
+
 
 #
 # Read each build's total.txt file
-- 
2.20.1




More information about the wine-devel mailing list