gofpdi icon indicating copy to clipboard operation
gofpdi copied to clipboard

Not able to compare pdf byte by byte

Open SezalAgrawal opened this issue 5 years ago • 1 comments

Steps to check this error:

  1. I tried generating pdf1 which imports a template pdf. Stored it as reference
  2. Generated pdf2 same way by importing template
  3. used referenceCompare() from gofpdf example package, which compares 2 pdf byte by byte
  4. There are lot of differences in both files.

How should I compare the files for my testing? Note: I generated some simple pdfs from gofpdf that did not involve importing templates. And I was able to compare them successfully.

SezalAgrawal avatar Dec 27 '19 12:12 SezalAgrawal

The issue might be in putImportedObjects.

If you're able to get it to import the same every time, please feel free to submit a pull request.

phpdave11 avatar May 17 '20 18:05 phpdave11