使用 jemmy 测试 java web start 应用程序
问题描述:
我需要使用 Jemmy 创建一些 gui 测试,但我不知道如何使用 javaws 应用程序启动它.在教程/示例/等中是这样的:
I need to create some gui tests using Jemmy but I have no idea how to launch it with javaws application. In tutorials/examples/etc is something like that:
new ClassReference("org.netbeans.jemmy.explorer.GUIBrowser")
.startApplication();
此代码打开一个示例窗口,但是我如何使用 ClassReference 对象打开 *.jnlp
文件?或者是另一种用java web start应用程序连接"jemmy的方法吗?
This code opens an example window, but how can I, using ClassReference object open *.jnlp
file? Or is it another way to "connect" jemmy with java web start application?
感谢提前.
答
您可以通过准备包含 Jemmy 的特殊构建并从以 jnlp 模式运行的应用本身调用 Jemmy 来实现这一点.
You can achieve this by preparing special build with Jemmy included and call Jemmy from the app run in jnlp mode itself.