Getting "The object does not exist." errors for all objects when test script is started from local m
Hi there,
I am trying to figure out the best practice to run test scripts on remote machine for our desktop applications (Windows Forms and Windows Presentation Foundation).
I installed TestComplete on remote machine, created a test script and created a PowerShell file with CMD command inside to run a TestComplete script.
I can successfully launch & run a test script from PowerShell file on remote machine.
As a result, I have a working schema on remote machine:
run PowerShell file => CMD command => TestComplete script
As a next step, I am trying to launch my test execution on remote machine from local machine, like this:
run PowerShell file on local machine => PowerShell file on remote machine => CMD command => TestComplete script
I able to start TestComplete script on remote machine from PowerShell file on local machine, however my script contains only "The object does not exist. See details for additional information" errors for all objects.
I am wondering if someone can explain why we have different behavior for the same test script on same machine:
- Passed when it started from remote machine
- Failed when it started from local machine
Or maybe we can use different approach to run test scripts on remote computer?
Thank you in advance
On my VM, I also use a PowerShell script to launch either,
Start-Process 'C:\Program Files (x86)\SmartBear\TestExecute 15\x64\Bin\TestExecute.exe' -ArgumentList """C:\Sandbox\TestComplete\ALS\ALS.pjs"" /run /exit /DoNotShowLog -Wait | Out-Null
Or
& 'C:\Program Files (x86)\SmartBear\TestExecute 15\x64\Bin\SessionCreator.exe' RunTest /UserName:***** /password:***** /UseActiveSession /ScreenResolution:"1920*1080" /ProjectPath:"C:\Sandbox\TestComplete\ALS\ALS.pjs" | Out-Null
If I’m logged onto the VM, I’ll use the first command to run the automation. Otherwise, I’ll use the second command, together with tscon (which disconnects me from the VM, but my session remains active). The VM can not be locked, otherwise it won’t have a GUI.
I have a Task Schedular set, to run the PowerShell script, which I can invoke manually.
Note, the commands used in the PowerShell script i.e. Start-Process and &. These are important, because the PowerShell script won't exit, until the automation has finished (it's not running in a seperate process)