Re:What is the smallest possible valid PDF?
by pmiller2 on Friday March 20, 2020 @07:57PM
(#22642979)
I'm curious why you needed the absolute smallest PDF file for testing? As an intellectual exercise, golfing the PDF format sounds like a bit of fun, but given that https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pd... is 13KB, I would think you could load that in a test suite on pretty much any reasonable, non-embedded platform. And, why would you want to load it on an embedded platform, anyway?
[ Parent
| on HN ]
Re:What is the smallest possible valid PDF?
by kadoban on Saturday March 21, 2020 @01:26AM
(#22644711)
Testing near/at boundary conditions is generally good practice.
A minimal size file could easily catch some cases where your code assumes some sort of structure (some flag, header, metadata structure, etc.) exists when it's possible it actually doesn't.