Merge pull request #13996 from Snuffleupagus/downloadutils-link-check

Make `verifyManifestFiles` fail for non-linked test-cases with a `"link": true`-entry
This commit is contained in:
Jonas Jenwald 2021-09-10 14:05:01 +02:00 committed by GitHub
commit 5678c75562
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 2 deletions

View File

@ -142,6 +142,15 @@ function verifyManifestFiles(manifest, callback) {
verifyNext();
return;
}
if (item.link && !fs.existsSync(item.file + ".link")) {
console.error(
`WARNING: Unneeded \`"link": true\`-entry for the "${item.id}" test.`
);
error = true;
i++;
verifyNext();
return;
}
calculateMD5(item.file, function (err, md5) {
if (err) {
console.log('WARNING: Unable to open file for reading "' + err + '".');

View File

@ -3490,7 +3490,6 @@
"md5": "8039aba56790d3597d2bc8c794a51301",
"rounds": 1,
"lastPage": 5,
"link": true,
"type": "eq"
},
{ "id": "text_clip_cff_cid",
@ -3564,7 +3563,6 @@
"file": "pdfs/issue925.pdf",
"md5": "f58fe943090aff89dcc8e771bc0db4c2",
"rounds": 1,
"link": true,
"type": "eq"
},
{ "id": "issue9291",