Hi,
I want to test all the jasper reports of my application. I want to be able to detect:
- Compilation problems (Would checking that
JasperCompileManager.compileReport(some inputStream)
doesn´t throwJRException
is a good option for this?) - Filling problems (Would checking that
JasperFillManager.fillReport(someReport, someParameters, someDataSource)
doesn´t throwJRException
is a good option for this?) - Rendering problems: detect "null" strings appearing, text looking truncated in the exported PDF file
- Any other idea?
Ideally I would like to keep the testing process the most generic possible. The thing is that each jasper has a different data source so for detecting this errors i need to generate at list some data (right?) and this data I need to generate is different for each jasper of my application. So i don´t know how much testing code I would be able to reuse. What approach would you take?
Thanks!