[英]When QTP is installed with Java Addin, an client application developed in Java does not launch
Problem: An application developed in Java does not launch when used with QTP having Java Addin enabled 问题:与启用了Java插件的QTP一起使用时,用Java开发的应用程序无法启动
When Java Addin is enable in QTP, the following environment variables is set 在QTP中启用Java插件时,将设置以下环境变量
_JAVA_OPTIONS : -Xrunjvmhook -Xbootclasspath/a:C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes;C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes\jasmine.jar
IBM_JAVA_OPTIONS : -Xrunjvmhook -Xbootclasspath/a:C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes;C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes\jasmine.jar
When we try to launch the Java Client application for which we need to automate, it fails to launch 当我们尝试启动需要为其自动化的Java客户端应用程序时,它无法启动
We tried removing the above environment variables but the QTP fails to recognize the objects in the Java Client application 我们尝试删除上述环境变量,但是QTP无法识别Java Client应用程序中的对象
I faced this issues. 我遇到了这个问题。 After much of tries, I recognize that change Environment Variable is not the perfect way to solve this.
经过大量尝试,我认识到更改环境变量并不是解决此问题的完美方法。 Try somethings:
尝试一下:
If Oracle jdk version <> UFT jdk version: 如果Oracle jdk版本<> UFT jdk版本:
The last way, change System Variables: 最后一种方法,更改系统变量:
Empty all them then reinstall Oracle Java first. 清空所有它们,然后首先重新安装Oracle Java。 Now, your java app will work well but UFT cannot recognize java applet.
现在,您的Java应用程序可以正常运行,但UFT无法识别Java小程序。 Change 3 environment variables above back to QTP path (such as:
将上面的3个环境变量更改回QTP路径(例如:
_JAVA_TOOLS = -Xrunjvmhook -Xbootclasspath/a:"C:\\Program Files (x86)\\HP\\Unified Functional Testing\\bin\\java_shared\\classes";"C:\\Program Files (x86)\\HP\\Unified Functional Testing\\bin\\java_shared\\classes\\jasmine.jar"
_JAVA_TOOLS = -Xrunjvmhook -Xbootclasspath / a:“ C:\\ Program Files(x86)\\ HP \\ Unified Functional Testing \\ bin \\ java_shared \\ classes”;“ C:\\ Program Files(x86)\\ HP \\ Unified Functional Testing \\ bin \\ java_shared \\ classes \\ jasmine.jar“
JAVA_TOOL_OPTIONS = -agentlib:jvmhook )
JAVA_TOOL_OPTIONS = -agentlib:jvmhook)
Restart all to get affect, QTP now work well with java. 重新启动所有程序以使其生效,QTP现在可以与Java很好地配合使用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.