Hello, I’m new to Katalon and I need to resolve a question. In my system, we issue data-based PDF reports. My test boils down to comparing two values present in a PDF report, for example: I need to check if the value “Total 1” is equal to the value “Total 2”, both present in the PDF report. Can I fetch this data from the PDF report using Katalon? How should I do?
Review some of the old ideas on this forum and see which one works for you:
I have a PDF in the URL.
I am able to switch to the URL and read the full content of the PDF.
My requirement is
I need to fetch the value for the field Total from the PDF.
Hi as part of our proof of concept for Katalon we need to prove we can verify text on a generated PDF which opens in a new tab.
The URL of the PDF is variable each time the document is generated:
I’ve tried using the switch to new tab and then get.url however the issue is I don’t know how to convert the PDF into text then use the verify text function.
Below is the current test case code I have:
import static com.kms.katalon.core.checkpoint.CheckpointFactory.findCheckpoint
import static com.…
I am trying to automate reading of text from PDF document which is saved and comparing it to a value.
I am always getting this error
I Verify PDF Contents FAILED.
groovy.lang.GroovyRuntimeException: Could not find matching constructor for: org.apache.pdfbox.pdfparser.PDFParser(java.io.FileInputStream)
Can you please guide how to resolve this issue.
And on other forums:
Katalon Studio does not offer any built-in solution to get values of PDF file. You have to invent a solution for your self.
For example, the following article gives a quick example to convert a PDF to a text file.
Please try to get a text out of a PDF.
However, you would find the text file is a mess of character sequence, which is un-parsable. Therefore not reusable at all.
IMHO, PDF->Text conversion is not very useful.
You can convert a PDF into an image.
Once you converted 2 PDF files into image files, then you can compare 2 image files and find a diff.
AShot you can create a diff image
The following shows my attempt in Katalon Studio to compile a visual diff reports of 2 PDF files downloaded from web:
I have published a GitHub project:
A few years ago, I worked for a media company. I was asked to develop a tool software, which was a sort of web scraping tool. The target page was this; it is still available to public at April 2023. The page looks as follows:
You don’t need to understand Japanese in this page. Just note the following points.
The page contains several links <a href="…">EXCEL</a> to the URLs of Excel files. It contains links to PDF files <a href="……
I am afraid this project is hard for others to reuse, as it requires a lot of technical additives that Katalon Studio misses.