pdf.js/test
Jonas Jenwald 57a1ea840f
Ensure that saveDocument works if there's no /ID-entry in the PDF document (issue 13279) (#13280)
First of all, while it should be very unlikely that the /ID-entry is an *indirect* object, note how we're using `Dict.get` when parsing it e.g. in `PDFDocument.fingerprint`. Hence we definitely should be consistent here, since if the /ID-entry is an *indirect* object the existing code in `src/core/writer.js` would already fail.
Secondly, to fix the referenced issue, we also need to check that the /ID-entry actually is an Array before attempting to access its contents in `src/core/writer.js`.

*Drive-by change:* In the `xrefInfo` object passed to the `incrementalUpdate` function, re-name the `encrypt` property to `encryptRef` since its data is fetched using `Dict.getRaw` (given the names of the other properties fetched similarly).
2021-04-22 12:08:56 +02:00
..
chromium Enable the ESLint no-var rule globally 2021-03-13 16:12:53 +01:00
font Convert the font-test ttx helper function to use the Fetch API 2021-04-20 23:44:15 +02:00
integration Add support for basic structure tree for accessibility. 2021-04-09 09:56:28 -07:00
pdfs Implement visibility expressions for optional content 2021-04-14 17:39:41 +03:00
resources Introduce Puppeteer for handling browsers during tests 2020-04-27 13:03:12 +02:00
stats Enable the ESLint no-var rule in the test/stats/ folder 2021-03-14 10:15:45 +01:00
ttx Update fonttools location and version (issue 6223) 2015-07-17 12:51:09 +02:00
types Add typescript definitions 2020-07-30 11:10:37 +02:00
unit Ensure that saveDocument works if there's no /ID-entry in the PDF document (issue 13279) (#13280) 2021-04-22 12:08:56 +02:00
.eslintrc Enable ESLint rules that no longer need to be disabled on a directory/file-basis 2021-01-22 17:47:03 +01:00
.gitignore Ignore test snapshots directory. 2013-03-15 11:24:08 -07:00
add_test.js Enable the ESLint no-var rule in test/add_test.js 2021-03-14 10:25:51 +01:00
annotation_layer_builder_overrides.css Enable the Stylelint length-zero-no-unit rule 2021-01-10 14:09:36 +01:00
downloadutils.js Enable the ESLint no-var rule globally 2021-03-13 16:12:53 +01:00
driver.js Merge pull request #13171 from brendandahl/struct-tree 2021-04-09 21:32:44 +02:00
integration-boot.js Add support for basic structure tree for accessibility. 2021-04-09 09:56:28 -07:00
test_manifest.json Implement visibility expressions for optional content 2021-04-14 17:39:41 +03:00
test_slave.html Use the SimpleLinkService when running "annotations" reference tests 2017-09-12 15:24:46 +02:00
test.js Update the yargs package to the latest version 2021-04-16 12:04:35 +02:00
testutils.js Enable the ESLint no-var rule globally 2021-03-13 16:12:53 +01:00
text_layer_test.css Add support for basic structure tree for accessibility. 2021-04-09 09:56:28 -07:00
webserver.js Enable the ESLint no-var rule globally 2021-03-13 16:12:53 +01:00