Troubleshoot
This topic provides troubleshooting for known issues when working with OpenText Functional Testing for Developers.
Repairing the installation does not work
Issue: Errors occur when I run the installation repair, or the product does not function properly after the repair.
Possible solution: Provide full read and write permissions to the registry keys under HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Mercury Interactive\Setup\HP Lean Functional Testing.
Then, run the repair process again.
The installation wizard does not open on CentOS
Issue: When I run the installation wizard, the command line installer opens instead, and an error similar to this occurs:
GUI mode is not supported : Can't connect to X11 window server using ':0' as the value of the DISPLAY variable.
Solution: Run the installation from a command line, or perform the following steps to use the wizard:
-
Quit the command-line installer
-
In the terminal, in the folder where the installer is located, run the following command to enable access to the X Window System server:
xhost +
-
Run the installation wizard again
After the installation, you can block access to the X Window System server by running: xhost -
Java applications do not run when I launch the runtime engine
Issue: After I launch the runtime engine, Java applications that usually run on my computer without any problem do not run.
Solution: Manually make the following change in the c:\Windows\mercury.ini file:
- Add the process name of your Java application to the end of the file using the following format:
<processName>.exe=0
- Restart the runtime engine.
Java applications do not run after I install OpenText Functional Testing for Developers
If your Java application silently fails to open or behaves unexpectedly after you install OpenText Functional Testing for Developers, the Java Add-in may be interfering with your application's functionality. You can disable the Java Add-in on a specific application, and still enable it to test other Java applications.
To disable the Java Add-in on a specific application, add a -Dmic.inject=false argument to the command line that runs the application.
Alternatively, if the application uses a configuration file for start up, you can add the -Dmic.inject=false setting to the configuration file instead.
Similarly, you can add the -Dmic.inject=false setting to the configuration files of services whose functionality is affected by the presence of OpenText Functional Testing for Developers.
Fail to launch the runtime engine from the IDE (Windows only)
Issue: When I try to enable OpenText Functional Testing for Developers from my IDE, I get an error message that the runtime engine could not be launched.
Possible cause: The wmic
command used by the launcher is not recognized on your machine. This is usually because wmic
is not included in your machine's path.
To verify the problem cause:
- From the bin folder in your <Installdir>, open a command line window.
-
Run the command:
leanft.bat start
The following error message confirms that the cause of the failure is the unrecognized wmic
command.
failed to get list of processes. err: Error: Command failed: wmic process where "name='node.exe'" get ProcessId,CommandLine /Format:list
'wmic' is not recognized as an internal or external command, operable program or batch file
Solution:
-
Edit your system PATH environment variable and add to it the path of the
wmic
command.Tip: The path to add is usually
%SystemRoot%\System32\Wbem;
-
Test this fix by typing
wmic
in a new command line window. This should open the wmi command line interface, which prompts with: wmic:root\cli> -
Enable OpenText Functional Testing for Developers from your IDE.
Runtime: Tests fail to launch Firefox ESR on Linux or Mac
Issue: In some cases, when running BrowserFactory.launch(BrowserType.FIREFOX) on a Linux or Mac machine, to launch a Firefox ESR version, the test fails.
Solution: The BrowserFactory.launch methods opens the Firefox version from /usr/bin/firefox (on Linux) or /Applications/Firefox.app (on Mac).
Make sure that your Firefox installations are set up such that the CLI commands "firefox
" (on Ubuntu) or "open /Applications/Firefox.app
" (on a Mac) successfully open the installed Firefox ESR version.
Runtime: Test gets stuck after browser opens
Issue: When running a test, the test gets stuck after the browser opens, before navigation.
Solution: If you have a proxy set up, make sure it is not localhost or 127.0.0.1.
Runtime: GetTextLocation or GetVisibleText methods fail
Issue: When running a test, GetTextLocation or GetVisibleText methods fail.
Solution: Make sure that you included the ABBYY OCR Engine in the installation. For details, see Install on Windows.
The IDE plugin is not working in my IDE
Issue: I see the Functional Testing for Developers menu in my IDE but its options are unavailable and I can't enable it.
Solution: If your IDE is configured to use a proxy server, make sure that the proxy bypass is enabled for localhost.
Eclipse: The IDE plugin is not working in Eclipse
There might be different scenarios where the plugin does not work.
No Functional Testing for Developers menu
Issue: I installed OpenText Functional Testing for Developers on Eclipse, but I do not see the Functional Testing for Developers menu.
Solution:
Scenario | Solution |
---|---|
For Eclipse Kepler/Luna users only |
To use the Eclipse IDE for Java EE Developers or Eclipse Standard editions with the IDE plugin, you must deploy the Google Gson plugin to your Eclipse folder:
Restart Eclipse. |
For deployment on Mac |
You may not have read/write permissions to the following directory: /Applications/Eclipse.app/Contents/Eclipse/configuration/org.eclipse.osgi Apply the required permissions to this folder. |
I moved Eclipse
Issue: I moved Eclipse to a different location on my computer and now the plugin doesn't work. I tried to change the location in the OpenText Functional Testing for Developers setup but it still doesn't work.
Solution: If you change the location of your Eclipse installation after installing the plugin, the plugin does not work. To rectify this, you need to uninstall the IDE plugin from Eclipse, and reinstall it using the path to the new location:
- On your computer, open Uninstall programs and run the OpenText Functional Testing for Developers setup in Change mode.
- Clear the Eclipse checkbox, and click Change. This removes the IDE plugin from Eclipse.
- Run the OpenText Functional Testing for Developers setup in Change mode again.
- Select Eclipse and click the Change button adjacent to the file path box to enter the new location of the Eclipse installation.
- Click Change to complete the installation.
Eclipse: "View Last Run Results" is unavailable in the Functional Testing for Developers menu after running a test
Issue: I get the following error in my Eclipse console output:
java.io.IOException: Cannot run program "wmic": CreateProcess error=2, The system cannot find the file specified
Solution: Make sure that you have the Java JRE/JDK path configured in your PATH environment variable. The path should point to the location of java.exe.
Example: C:\Program Files (x86)\Java\jre1.8.0_91\bin
Web is not recognized on Google Chrome
Possible cause: To test web applications in Google Chrome, the OpenText Functional Testing Agent extension needs to be installed. If OpenText Functional Testing for Developers was installed before Google Chrome was installed, the browser extension is missing.
Solution:
-
Manually install the browser extension, as described in Set up Google Chrome for testing.
After the OpenText Functional Testing Agent extension is installed, it is displayed in the Chrome Extensions list.
-
Restart the computer.
-
Restart the runtime engine.
Objects in my application are not recognized
Issue: The objects in my application are not recognized. What should I do?
Solutions:
- If you are testing Web objects, make sure you have followed the instructions for setting up your web browsers for testing and that you open the web browser after the runtime engine is active. For details, see Set up web browsers and controls.
- Make sure your application was developed with a supported technology and version. For details, see the Support Matrix.
- If you need to test specific objects that are not supported by default, create Insight test objects to interact with your objects using image-based recognition. For details, see Insight image-based identification (Windows only).
-
To support WebAgGrid or WebUIGrid test objects, you must specifically load the AgGrid or UIGrid Web child add-in in addition to the Web add-in.
Object Identification Center (OIC) not identifying browser (design)
Issue: During design time, the OIC is not able to identify my browser.
Solution: If you have a proxy set up, make sure it is not localhost or 127.0.0.1.
Object Identification Center (OIC): Can't add objects to an application model
Issue: The OIC recognizes the objects in my application, but I cannot save objects from the OIC to an application model.
Possible cause: The Internet browser is set to use a proxy that blocks all connections. This is unnecessarily blocking local connections as well.
Solution: Configure the Internet Options to allow local connections:
- In Local Area Network settings, select Bypass proxy server for local addresses.
- In the advance proxy settings, enter the following addresses in the Exceptions list under Do not use proxy server for addresses beginning with:
localhost;127.0.0.1
Object Identification Center (OIC) not recognizing objects
This may be caused by different issues.
The browser was opened first
Possible cause: The browser was open before the OIC was opened, or before the IDE was opened.
Solution:
- Close the IDE/OIC.
- Close browser.
- Open the IDE/OIC, and then open the browser.
Unsupported AUT technology
Possible cause: The application's technology is not supported.
Solution:
For a complete list of supported technologies, see the .NET SDK Reference, Java SDK Reference, or JavaScript SDK Reference
To see supported versions of each technology, see the Support Matrix.
Object Identification Center (OIC) in Eclipse not working after upgrade
Issue: I just upgraded OpenText Functional Testing for Developers. Now when I open the OIC in Eclipse, it flashes open but then disappears. I tried to invoke the OIC from command line, but the same thing happens. The log tells me that "C:\Program" failed to run.
Possible cause | Solution |
---|---|
The installation path contains spaces. | Uninstall and reinstall using a path that contains no spaces. |
The JRE/JDE versions do not match. | Ensure that OpenText Functional Testing for Developers is calling the correct JRE/JDK installed on your computer. |
Some dialog boxes do not open on Linux
Issue: Opening the following dialog boxes from the Functional Testing for Developers menu in the IDE does not work on Linux: The Settings dialog box, the OIC, the Test Recorder, and the Device Lab.
Opening these dialog boxes from the Windows Start menu or the system tray results in an error similar to this:
./bin/leanft/UFT Developer: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
Possible cause: To work with OpenText Functional Testing for Developers dialog boxes on Linux, the libXss library must be installed on your machine.
Solution: Install the libXss library by running the following command: # yum install libXScrnSaver
Cannot open the OIC or Test Recorder on Linux
Issue: On Linux, the OIC and Test Recorder do not start when you try to open them from the Eclipse Functional Testing for Developers menu or from a command line.
Possible solution: To open the OIC or Test Recorder, make sure you are using a non-root user.
Application model in Visual Studio is showing a blank screen
In Visual Studio, the Application model window suddenly goes blank.
Solution:
- Open PackagePreferences.json, located in %appdata%\LeanFT\Preferences.
-
Locate the EnableAppModelLargeAddressSpace parameter, and change the value from false to true.
It should look as follows:
"EnableAppModelLargeAddressSpace": true
Eclipse/IntelliJ IDEA IDE error: "A class file was not written..."
After adding an object to your application model, you may encounter this error when saving the application model (Eclipse) or building the project (IntelliJ IDEA).
This is caused by adding an object with an exceedingly long name to the application model.
Change the new object's code name so it does not exceed 210 characters and try again.
Report not building after running test
Issue: The report is not being generated after the test runs
Solution: Make sure you have write permissions to the report output folder. The location may be specified in a LEANFT_REPORTS_TARGETDIR environment variable, in the test's App.config or leanft.properties file, or inside your test using the ReportConfiguration methods.
Mobile: Device logs not showing up in run results report
Issue: I ran a test on a mobile device, but I don't see the device log in the HTML report.
Solution: To see device logs in the HTML report, you must include a Launch or Restart method to ensure that app opens on the device. For details, see Create mobile tests.
Test runs only from IDE. Otherwise I get 'Object not found' failure
On some operating systems, a test that can run from the IDE, fails to run independently.
Possible solutions:
- Turn of UAC.
- Run the test as an administrator.
OpenText Application Quality Management: Cannot run test. I get a message about Remote Agent configuration
This issue might occur in different scenarios.
Java asset configuration issue
Issue: When I run a JUnit test (Java) from OpenText Application Quality Management, I get the following error: "Cannot run test. Check Remote Agent configuration."
Possible cause: The Java assets may not be correctly defined in the Remote Agent configuration.
Solution: Make sure the classpath to your Java assets is correctly formatted.
Use the following syntax:
<javaAssets>%CLASSPATH%;$LEANFT_INSTALL_DIR\SDK\Java/*;<junit.jar path>;<hamcrest-core.jar path></javaAssets>
Important: Use a semi-colon (;) separated list for the classpath.
Example (including the hamcrest-core JAR):
<javaAssets>%CLASSPATH%;$LEANFT_INSTALL_DIR\SDK\Java/*;C:\JUnit\junit-4.11.jar;C:\JUnit\hamcrest-core-1.3.jar</javaAssets>
For more details, see javaAssets in Configure the Remote Agent .
Remote agent configuration issue
Issue: When I run a test from OpenText Application Quality Management, I get the following error: "... test runs on this host are not allowed. You can change these permissions Check Remote Agent configuration file on the host computer."
Possible cause: The default Remote Agent configuration does not to allow running ALM tests on a remote computer (allowRun = false).
Solution: In the Remote Agent configuration file on the host computer, the allowRun value must be set to true.
For full instructions, see Configure the Remote Agent .
OpenText Application Quality Management: Cannot run a NUnit 3 test with parameters from OpenText Application Quality Management
Possible cause: You may be using the ALM data source that is meant for NUnit 2.6 tests. Instead, for NUnit 3 tests, you should be using the ALMStatic data source.
Solution: For NUnit 3 tests, use the ALMStatic data source.
For example:
[TestCaseSource("ALMStatic")]
public void Test(string param)
{
...
}
Cannot run test cases built with the MSTest 2.x templates
Test cases built using the MsTest 2.x template on Visual Studio 2017 are not running. Sometimes there is no output message, and sometimes a "0 tests found" message is displayed.
Possible cause: When the MSTest 2.x nuget packages are installed, a property file is imported into the project file, adding several DLLs marked Copy To Output Directory - Copy If Newer. When a project is created using the MsTest 2.x project template, Visual Studio does not copy these DLLs to the output folder during the build.
Workaround:
-
Open the problematic MSTest 2.x project in VS2017. In a text editor, modify the .csproj file by adding an empty line at the end. Save the file, delete the empty line, and then save the file again.
-
In the message dialog box that open in Visual Studio, select Reload all.
-
Rebuild the project.
The IDE plugin disappears after upgrading IntelliJ IDEA
Possible cause: The new version of IntelliJ IDEA was installed in a different location.
Solution: do one of the following:
- Run the installer in Change mode and select to include IntelliJ IDEA as a plugin again. For details, see Change or uninstall.
Or
-
Copy the folder containing the plugin files into IntelliJ IDEA's plugin folder.
The OpenText Functional Testing for Developers folder containing the plugin files: <Installdir>\IDE\IntelliJ\plugins\LeanFT.
IntelliJ IDEA's plugin folder: <IntelliJ_installdir>\plugins, for example: C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2019.1.2>\plugins
Issues when using the .NET templates for .NET 6 or later
The table below describes different issues that might occur with the .NET templates.
Issue | Solution |
---|---|
When creating a .NET project in Visual Studio, the solution appears empty. |
Possible solution: Make sure that the PATH environment variable meets these templates' requirements. See Prerequisites to installing the templates manually. |
When creating a .NET project in Visual Studio, a "package restore failed" error occurs for some packages, such as MSTest.TestFramework, NUnit, or NUnit3TestAdapter. | In the NuGet Package Manager, ensure that you have a package source pointing to nuget.org. If it is missing, you can add it manually, setting Source to the URL: https://api.nuget.org/v3/index.json. |
Visual Studio does not list the .NET project templates in visual studio | If the .NET SDK was not installed when OpenText Functional Testing for Developers was installed, the templates will not be registered in Visual Studio. You can rerun the installation in repair mode or install the templates manually. See (Optional) Manually install the .NET templates. |
See also: