I have a scenario to verify Print Properties dialog opening up correctly after clicking on Print button. Aware of Robot utility class in Java which can emulate keyboard events like Escape/Enter etc. to operate on that window.
Is there any way we can verify the new dialog opened up is a Print dialog - something to verify dialog title i.e. Print or retrieve text from that windows dialog or something else which will confirm dialog to be a Print dialog.
答案 0 :(得分:0)
您可以使用基于图像的自动化工具。我使用基于JAVA Robot类的SIKULI。 http://www.sikuli.org/
在SIKULI中,您必须截取弹出窗口或其标题的屏幕截图,然后将其用于比较。 SIKULI作为JAVA API提供,可与Selenium集成。 SIKULI还使用tesseract提供光学图像识别功能。这也可用于验证弹出窗口的标题。
希望这会对你有所帮助。