TestResult struct containing:
filesChecked— number of files verifiederrors— number of corruption errors found
Verifies archive integrity by checking all stored files.
This function tests the archive by reading and verifying all file data against stored checksums. It detects data corruption without extracting files to disk.
h | archive handle obtained from openArchiveRead |
TestResult struct containing:
filesChecked — number of files verifiederrors — number of corruption errors foundDarException if the archive handle is invalid or testing fails.
Example:
auto archive = openArchiveRead("/backups", "myarchive", "dar");
auto result = testArchive(archive);
if (result.errors == 0)
writefln("Archive OK: %d files verified", result.filesChecked);
else
writefln("CORRUPTION: %d errors in %d files", result.errors, result.filesChecked);Tests an archive using custom TestOptions.
This overload allows partial testing by applying a selection mask or changing what aspects to verify.