testexecute from scheduler possible to activate desktop session
Until recently we have been running tests inside an always open vmware player guest host, but is there a way for testexecute to activate a desktop session from task scheduler. Running directly from task scheduler gives me a session locked.
Company domain polices prevents me from overriding power and sleep.
Solved! Go to Solution.
You do need an interactive user session to run testcomplete/execute. We use jenkins to do what you're trying to achieve but you will still need a interactive user.
I am not sure if this will help you but you could try this with a second user
TestComplete's sessioncreater feature might be what you're looking for
Hope this helps.
Thanks @Reshail , even as local administrator (laps) I only have 3 entries in
Group policies: Computer Configuration\Administrative Templates\System\Logon
which only relates to running scripts on login.
thanks @hkim5, session-creator does not propagate other parameters to the tests, we have lots of parameters we forward to the test complete environment.
I never got it to run, it does not have the /run parameter, my tests never starts.
I have command line scripts for both testcomplete and testexecute and they both need the /run parameter to actually start.
Below are my startup scripts, as you see there are a lots of own parameters that we pick up with a parser and put into Project.Variables,
session parameters like /UseSameSession /useSessionN should be built into the testexecute binary. because this is what is started form task-scheduler.
start from test execute:
& "C:\\Program Files (x86)\\SmartBear\\TestExecute 14\\x64\\Bin\\TestExecute.exe" "C:\\SharedArea\\TestAutomation_test4\\TestProject\\LraTestProjectSuite.pjs" /r /p:EpicIteration /lraenvironment:SemiReal /lrapath:"C:\\SharedArea\\TestAutomation_test4\\TestedApp" /lrapathlocal:"C:\\SharedArea\\TestAutomation_test4\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\local-test4.config" /lrapathbuypass:"C:\\SharedArea\\TestAutomation_test4\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\buypass-test4.config" /lrapathmixed:"C:\\SharedArea\\TestAutomation_test4\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\mixed-test4.config" /e /el:"C:\\SharedArea\\reports\\SemiReal\\Win10-202003061024\\index.mht" /testUsersDatafilePath:"C:\\SharedArea\\TestAutomation_test4\\TestProject\\Stores\\Files\\mobjtest-test4.json" /executionTime:"202003061024" /ErrorLog:"C:\\SharedArea\\reports\\SemiReal\\Win10-202003061024\\errors.log" /ForceConversion /SilentMode
start from test complete:
& "C:\\Program Files (x86)\\SmartBear\\TestComplete 14\\x64\\Bin\\TestComplete.exe"C:\\SharedArea\\TestAutomation_8065\\TestProject\\LraTestProjectSuite.pjs /r /p:EpicIteration /lraenvironment:SemiReal /lrapath:"C:\\SharedArea\\TestAutomation_8065\\TestedApp" /lrapathlocal:"C:\\SharedArea\\TestAutomation_8065\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\local-test22.config" /lrapathbuypass:"C:\\SharedArea\\TestAutomation_8065\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\buypass-test22.config" /lrapathmixed:"C:\\SharedArea\\TestAutomation_8065\\TestedApp\\LraClient.exe /appconfig:TestConfigs\\mixed-test22.config" /e /el:"C:\\SharedArea\\reports\\SemiReal\\Win10-2020.03.06_10-24-50\\index.html" /testUsersDatafilePath:"C:\\SharedArea\\TestAutomation_8065\\TestProject\\Stores\\Files\\mobj-test22.json" /executionTime::"2020.03.06_10-24-50" /ErrorLog:"C:\\SharedArea\\reports\\SemiReal\\Win10-2020.03.06_10-24-50\\errors.log" /ForceConversion /SilentMode /exit
I did not use SessionCreator, so wondering whether created session closes when test run is over or remains open?
If the latter, you may consider scenario to open a user session using SessionCreator and run some dummy test. Then use your CI tool to start real test run in the already existing session as usual.
/Alex [Community Champion]
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.