Forum Discussion
Hello rraghvani What do you mean?
The testrun does use the GUI, Taskscheduler starts a C# program (Or batch) and that starts the testrun with SessionCreator.exe.
Sessioncreator should create a session on the locked pc where TestExecute can preform the tests.
This worked for atleast the past 2 years, but suddenly I get back Exitcode 7 while I changed nothing.
I have a VM which has TestExecute installed, and a PowerShell script, which has the following command, called by Task Scheduler at a given time.
& 'C:\Program Files (x86)\SmartBear\TestExecute 15\x64\Bin\SessionCreator.exe' RunTest /UserName:TestUser1 /password:'testuser1' /UseActiveSession /ScreenResolution:"1920*1080" /ProjectPath:"C:\Sandbox\TestComplete\ALS\ALS.pjs" /ExportLog:"C:\Sandbox\Log\TC_Automation_$tc_timestamp\index.html" /ExportSummary:"$summary_report" | Out-Null
The VM has been set up to automatically login user 'TestUser1', and the VM is always unlocked (this is my active session). When I invoke the script to launch SessionCreator, it will spool up another session to run the automation scripts.
SessionCreator
The utility opens interactive user sessions required for the TestComplete interaction with your tested application GUI. If an interactive user session is not opened, the test engine will not be able to access the GUI, and your tests will fail.
- MW_Didata2 days agoSuper Contributor
I run the tests on a physical PC. It has Testexecute and Testcomplete Installed.
I use pretty much the same command, but instead of the entire ProjectSuite it runs each project one after the other with the /Project flag.but it no longer works. Like I stated above I even went back to a very basic batch script that should just start the testrun.
That also did not work.
I run other projects on another PC, that one still works. SessionCreator creates the session and testing begins, its only 1 machine that no longer works.- rraghvani2 days ago
Champion Level 3
Use Task Manager, and check the number of Users on both machines? Do both machines have the same OS versions? Check your security options for your Task Schedular, on both machines too.
- MW_Didata2 days agoSuper Contributor
The PC has 2 users, 1 is the admin account of my org, and the other is the user account.
The user account is also an administator on the machine.When checking Task manager only the 2nd user is shown, that is the user that should start the task.
Both machines use the latest Win11 Pro 25H2.In taskschedular the options "Run with highest privileges" and "Run whether use is logged on or not" are both enabled. (Same as the other machine)