Unable to create a user session - Error in Jenkins
I am trying to run Test Complete projects as a Freestyle Project on Windows server using Jenkins that is installed on the same sever.
Getting below Jenkins error –
Console Output
Started by user Shehnaz Patanwala
Running as SYSTEM
Building in workspace C:\Program Files (x86)\Jenkins\workspace\Test Complete
[TestComplete] The test execution started (PITA_Internal/C:\Users\Public\Install\pita-ui-automation-projects\PITA_Internal\A-Account_Reset_Project\A-Account_Reset_Project.mds).
[TestComplete] Found TestComplete/TestExecute installations:
Type: TE, Version: 14.10.1042.11, Path: "C:\Program Files (x86)\SmartBear\TestExecute 14\x64\bin\TestExecute.exe"
[TestComplete] Selected TestComplete/TestExecute installation:
Type: TE, Version: 14.10.1042.11, Path: "C:\Program Files (x86)\SmartBear\TestExecute 14\x64\bin\TestExecute.exe"
[TestComplete] Launching the test runner.
$ '"C:\Program Files (x86)\SmartBear\TestExecute 14\bin\TestCompleteService14.exe"' //LogonAndExecute //lDomain: "" //lName: "" //lPassword: ******** //lTimeout: "-1" //lUseActiveSession: "true" //lCommandLine: '""C:\Program Files (x86)\SmartBear\TestExecute 14\x64\bin\TestExecute.exe" C:\Users\Public\Install\pita-ui-automation-projects\PITA_Internal\PITA_Internal.pjs /run /SilentMode /ForceConversion /ns /exit "/ExportLog:C:\Program Files (x86)\Jenkins\workspace\Test Complete\1571766356292.tclogx" "/ExportLog:C:\Program Files (x86)\Jenkins\workspace\Test Complete\1571766356292.htmlx" "/ErrorLog:C:\Program Files (x86)\Jenkins\workspace\Test Complete\1571766356292.txt" /project:C:\Users\Public\Install\pita-ui-automation-projects\PITA_Internal\A-Account_Reset_Project\A-Account_Reset_Project.mds /DoNotShowLog /JenkinsTCPluginVersion:2.3"'
[TestComplete] Test runner exit code: -10 (Unable to create a user session).
[TestComplete] [WARNING] Unable to find the log file "1571766356292.tclogx".
[TestComplete] [WARNING] Unable to find the log file "1571766356292.htmlx".
[TestComplete] [WARNING] Errors occurred during the test execution.
[TestComplete] Marking the build as UNSTABLE.
[TestComplete] [WARNING] Unable to publish test results (xml data is empty).
[TestComplete] The test execution finished (PITA_Internal/C:\Users\Public\Install\pita-ui-automation-projects\PITA_Internal\A-Account_Reset_Project\A-Account_Reset_Project.mds).
Build step 'TestComplete Test' changed build result to UNSTABLE
Finished: UNSTABLE
Looks like it’s failing because of not creating a User Session. I have configured my workstation accordingly. Only thing that's missing in Jenkin step is creating a node and cofiguring Jenkins slave agent runs as a service.
Is this a required step to run freestyle job on the server locally?
Thank you Alex, this is a great detailed answer.
Nikolayev I checked your support case and see that the tests are running normally for you. Here's the article with requirements that need to be met: