Forum Discussion
From your logs, this warning stands out:
[WARNING] The node is connected via Java Web Start (JNLP). In this mode, the "Run interactive user session" property of the TestComplete Test step is ignored.
This usually happens because JNLP agents in Jenkins cannot create or unlock a desktop session, which is required for interactive TestComplete or TestExecute tests (like UI automation). So even though your pipeline includes:
useActiveSession: true useTCService: true
These settings are ignored in JNLP mode, and TestExecute can only run in the currently active session — assuming it's already unlocked and ready. That’s likely why your interactive tests aren’t running as expected.
✅ Recommended Fix: Switch to Windows Service Launch
To allow TestComplete to run interactively, the Jenkins agent should be configured to run as a Windows service instead of using JNLP.
Steps:
- In Jenkins:
- Go to Manage Jenkins > Manage Nodes and Clouds > [Your Agent] > Configure
- Change Launch method from:
- “Launch agent via Java Web Start (JNLP)”
to:
“Launch agent via Windows Service”
- On the agent machine:
- Install the Jenkins agent as a Windows service (if not already).
- Run the service as a real user account (not Local System) — ideally the same user that runs TestExecute.
- Ensure that user is logged in and the desktop is unlocked when the test runs.
For reference: Running Tests in Jenkins – TestComplete Docs
🔧 Optional Config Update (Recommended)
Here’s a cleaned-up version of your testcompletetest step with a few adjustments:
testcompletetest(
actionOnErrors: 'FAIL', // Fails the build if test fails
credentialsId: 'UTAAdmin_User_Pass',
executorType: 'TE',
executorVersion: '15.40', // Match installed version exactly
generateMHT: true,
sessionScreenResolution: '1680x1050',
suite: "${env.Pjs}",
useTCService: true,
useActiveSession: true,
timeout: '21600', // 6 hours
useTimeout: true
)
💡 Tip:
If you’re not tied to a specific TestExecute version, you can omit executorVersion entirely, and the plugin will automatically select the most recent installed version. This can help avoid mismatches if the machine has been updated.
🧪 Diagnostic Steps (If Test Still Fails or No Results Are Generated)
On the agent machine:
- ✅ Does the test run correctly when executed manually using TestExecute?
- ✅ Does it run in the currently logged-in user’s interactive session?
- Run the test manually (outside Jenkins) and confirm it interacts with the desktop (e.g., opens windows, clicks UI elements).
- If it doesn’t, there may be issues with the TestExecute configuration, user permissions, or session access.
- ✅ Are .mht or other result logs being generated at all?
- 🔍 Check the default TestComplete log folder "C:\Users\{your-user}\Documents\TestComplete 15\Log" or any custom results directory you’ve configured.
In Jenkins:
- 📁 Use this step to archive the .mht logs for post-job inspection:
archiveArtifacts artifacts: '**/*.mht', allowEmptyArchive: true
- ⚠️ Ensure that no cleanup steps (like cleanWs()) are deleting test results before they’re read.
- 🧾 Review the Jenkins console log for signs of early termination or issues with launching the interactive session.
🤖 AI-assisted response
👍 Found it helpful? Click Like
✅ Issue resolved? Click Mark as Solution
Isn't java webstart for JNLP deprecated ?
I was getting the same logs even when the test was working fine before. Please find the logs when test execution worked fine before jenkins upgrade.
[TestComplete] The test execution started (XLVirtual/XLVirtualGroups/FULL). [TestComplete] Found TestComplete/TestExecute installations: Type: TC, Version: 15.69.139.7, Path: "C:\Program Files (x86)\SmartBear\TestComplete 15\x64\bin\TestComplete.exe" Type: TE, Version: 15.69.139.11, Path: "C:\Program Files (x86)\SmartBear\TestExecute 15\x64\bin\TestExecute.exe" Type: TELite, Version: 15.69.139.50, Path: "C:\Program Files (x86)\SmartBear\TestExecuteLite 15\x64\bin\TestExecuteLite.exe" [TestComplete] Selected TestComplete/TestExecute installation: Type: TC, Version: 15.69.139.7, Path: "C:\Program Files (x86)\SmartBear\TestComplete 15\x64\bin\TestComplete.exe" [TestComplete] [WARNING] The node is connected via Java Web Start (JNLP). In this mode, the "Run interactive user session" property of the TestComplete Test step is ignored. TestComplete (or TestExecute) will work in the current user session. [TestComplete] Launching the test runner. $ C:\cygwin64\bin\cygpath -w '"C:\Program Files (x86)\SmartBear\TestComplete 15\x64\bin\SessionCreator.exe"' $ '"C:\Program Files (x86)\SmartBear\TestComplete 15\x64\bin\SessionCreator.exe"' ExecuteProcess '/c:""C:\Program Files (x86)\SmartBear\TestComplete 15\x64\bin\TestComplete.exe"" ""C:\Users\utaadmin\Documents\TestComplete 15 Projects\XLVirtual\XLVirtual.pjs"" /run /SilentMode /ForceConversion /ns /exit "/ExportLog:c:\jenkins-pspc\workspace\LTE\BeOn\BeOn_Android\XLVirtualAndroid-Product\1756958455186.tclogx" "/ExportLog:c:\jenkins-pspc\workspace\LTE\BeOn\BeOn_Android\XLVirtualAndroid-Product\1756958455186.htmlx" "/ErrorLog:c:\jenkins-pspc\workspace\LTE\BeOn\BeOn_Android\XLVirtualAndroid-Product\1756958455186.txt" "/ExportLog:c:\jenkins-pspc\workspace\LTE\BeOn\BeOn_Android\XLVirtualAndroid-Product\1756958455186.mht" "/project:XLVirtualGroups" "/test:FULL" /JenkinsTCPluginVersion:2.9.2' [TestComplete] Test runner exit code: 2. [TestComplete] [WARNING] Error: Unable to find an element by the specified selector.. [TestComplete] [WARNING] Errors occurred during the test execution. [TestComplete] The test execution finished (XLVirtual/XLVirtualGroups/FULL).
- ancybaby21 hours agoOccasional Contributor
Also the tests works fine when I use SessionCreator from jenkins for executing tests. its just that it doesnot work with the Testcomplete plugin now. When it was working fine before , the agent was connected using JNLP. This log statement [WARNING] The node is connected via Java Web Start (JNLP). In this mode, the "Run interactive user session" property of the TestComplete Test step is ignored. was present even when the tests worked fine .