marathonv5 icon indicating copy to clipboard operation
marathonv5 copied to clipboard

While Automating JNLP Application, I am facing the below error

Open tezzpawar1 opened this issue 1 year ago • 0 comments

Unable to Launch JNLP Application Using Java Driver

I'm facing an issue when trying to launch a JNLP (Java Network Launch Protocol) application using the Java Driver in my automation code. Here's a code snippet that I'm using:

JavaProfile profile = new JavaProfile(JavaProfile.LaunchMode.JAVA_WEBSTART); profile.setJNLPPath("C:\Users\spa6a5t\Music\frmservlet.jnlp"); profile.setJavaHome("C:\Program Files\Java\jdk-17"); Thread.sleep(10000); profile.setStartWindowTitle("Oracle E-Business Suite R12");

driver = new JavaDriver(profile); However, I'm getting the following exception:

Exception in thread "main" org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure. Host info: host: 'WS631212', ip: '10.184.44.49' Build info: version: '4.9.1', revision: 'eb2032df7f' System info: os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '17.0.7' Driver info: net.sourceforge.marathon.javadriver.JavaDriver Command: [null, newSession {capabilities=[Capabilities {browserName: java, browserVersion: 1.0, platformName: any}]}] Capabilities {browserName: java, browserVersion: 1.0, platformName: any} It seems to be related to the java.lang.NoSuchMethodError with 'void org.openqa.selenium.os.CommandLine.(java.lang.String[])'.

I've verified my JNLP file path, Java home, and window title. Could anyone provide guidance on how to resolve this issue and successfully launch the JNLP application using the Java Driver?

tezzpawar1 avatar Oct 26 '23 11:10 tezzpawar1