Having problems with your account or logging in?
A lot of changes are happening in the community right now. Some may affect you. READ MORE HERE
Highlighted
kovacsakos Super Contributor.
Super Contributor.
2455 views

LeanFT open browser window and navigate

Jump to solution

I recorded a test case with Test Recorder tool in LeanFT with Chrome. When I execute it, it opens a new tab in Chrome, instead of starting a new instance of application. I tried to execute it in Firefox, but in this case it just opens browser window, doesn't navigate to given url.

    Browser browser = BrowserFactory.launch(BrowserType.FIREFOX);
    browser.navigate(env.LOGIN);

Error message: com.hp.lft.sdk.GeneralLeanFtException: launch browser timeout occurred

Labels (1)
0 Likes
1 Solution

Accepted Solutions
Micro Focus Contributor
Micro Focus Contributor

Re: LeanFT open browser window and navigate

Jump to solution

Hi,

The behaviour stated for chrome is the designed behaviour as the Browser object is not a browser application but a browser tab, in case you perform launch it will create a new tab (in case chrome is up) or launch a chrome with a the new tab.

Regarding firefox issue it seems like LeanFT extension is not installed in the Firefox application it can be one of the following: either it is not installed and you can follow the steps here to correct it:

Set up Mozilla Firefox for LeanFT

Or there is a proxy definition which prevents the extension to communicate with the LeanFT runtime engine, in this case I suggest to configure firefox proxy to bypass local addressses. 

Please let me know how it goes.

3 Replies
Micro Focus Expert
Micro Focus Expert

Re: LeanFT open browser window and navigate

Jump to solution

Hi,

The behavior you described regarding Chrome browser is the expected one.

(LeanFT treats each tab as a separate Browser test object.)

Regarding Firefox, have you verified firefox extension is configured correctly on your machine? 

you can see more details here: https://admhelp.microfocus.com/leanft/en/14.03/HelpCenter/Content/HowTo/WebApps.htm

What version of Firefox do you have?

 

 

Micro Focus Contributor
Micro Focus Contributor

Re: LeanFT open browser window and navigate

Jump to solution

Hi,

The behaviour stated for chrome is the designed behaviour as the Browser object is not a browser application but a browser tab, in case you perform launch it will create a new tab (in case chrome is up) or launch a chrome with a the new tab.

Regarding firefox issue it seems like LeanFT extension is not installed in the Firefox application it can be one of the following: either it is not installed and you can follow the steps here to correct it:

Set up Mozilla Firefox for LeanFT

Or there is a proxy definition which prevents the extension to communicate with the LeanFT runtime engine, in this case I suggest to configure firefox proxy to bypass local addressses. 

Please let me know how it goes.

Paschal
Visitor.

Re: LeanFT open browser window and navigate

Jump to solution

I am facing below issue: leanFt navigated to url successfully but cannot identify the objects

com.hp.lft.sdk.ReplayObjectNotFoundException: Cannot identify the object "Web EditField".
Verify that this object's properties match an object currently displayed in your application.
at com.hp.lft.sdk.internal.ReplayExceptionFactory$1.create(ReplayExceptionFactory.java:34)
at com.hp.lft.sdk.internal.ReplayExceptionFactory.createOrDefault(ReplayExceptionFactory.java:197)
at com.hp.lft.sdk.internal.ReplayExceptionFactory.createOrDefault(ReplayExceptionFactory.java:21)
at com.hp.lft.sdk.internal.TestObjectExecuterBehaviorBase$ReplayErrorHandler.onError(TestObjectExecuterBehaviorBase.java:65)
at com.hp.lft.sdk.internal.CommunicationClientImpl.handleError(CommunicationClientImpl.java:221)
at com.hp.lft.sdk.internal.CommunicationClientImpl.send(CommunicationClientImpl.java:96)
at com.hp.lft.sdk.internal.TestObjectExecuterBehavior.executeMethod(TestObjectExecuter.java:33)
at com.hp.lft.sdk.internal.TestObjectBase.executeMethod(TestObjectBase.java:119)
at com.hp.lft.sdk.internal.web.WebEditFieldBase.access$000(WebEditFieldBase.java:8)
at com.hp.lft.sdk.internal.web.WebEditFieldBase$1.invoke(WebEditFieldBase.java:20)
at com.hp.lft.sdk.internal.TestObjectOperationWrapper.executeWithEvents(TestObjectOperationWrapper.java:81)
at com.hp.lft.sdk.internal.TestObjectOperationWrapper.executeWithEvents(TestObjectOperationWrapper.java:102)
at com.hp.lft.sdk.internal.web.WebEditFieldBase.setValue(WebEditFieldBase.java:24)
at com.hp.lft.sdk.internal.web.WebEdit.setValue(WebEdit.java:8)
at com.company.LeanFtTest.Test(LeanFtTest.java:53)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:84)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:714)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:901)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1231)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:127)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:111)
at org.testng.TestRunner.privateRun(TestRunner.java:767)
at org.testng.TestRunner.run(TestRunner.java:617)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:348)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:343)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:305)
at org.testng.SuiteRunner.run(SuiteRunner.java:254)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1224)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1149)
at org.testng.TestNG.run(TestNG.java:1057)
at org.testng.IDEARemoteTestNG.run(IDEARemoteTestNG.java:72)

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.