RFR: 8335231: [macos] Test java/awt/print/PrinterJob/Cancel/PrinterJobCancel.java failed on macOS because the case didn't get the expected PrintAbortException

Prasanta Sadhukhan psadhukhan at openjdk.org
Mon Jul 8 09:59:33 UTC 2024


On Fri, 5 Jul 2024 09:26:27 GMT, Tejesh R <tr at openjdk.org> wrote:

> > I am not able to reproduce in windows, and I guess neither the submitter who raised this issue as it is mentioned in JBS `Is it a platform-specific issue: Yes. This issue only happens on macOS.` Maybe there is some issue in your physical printer configuration in which case you can try with "Microsoft Print-to-pdf" option
> 
> Yeah, Print-to-pdf works fine. Not sure about printer config issue.

It seems it's timing related...For some network printers, it might take more time to setup..for example, the printer I tested Xerox Altalink it was taking time in `Win32PrintService.getMediaPrintableArea` called from `RasterPrinterJob.setAttributes` and it has around 66 media sizes namely "A3, A4, A5, Postcard, envelope, Letter" etc so looping through all media sizes were taking time, so 
increasing time between actual printing start and cancelling (which is 5s presently in the testcase) helps for those printers..

-------------

PR Comment: https://git.openjdk.org/jdk/pull/20027#issuecomment-2213571469


More information about the client-libs-dev mailing list