TestComplete12: Excel sheet not found error when executing as batch
On TestComplete 9, I was using the Windows Task Scheduler to run a suite of (scripted) tests by command line execution every day. I also use Excel to parameterize input for the tests. This had been working fine.
Recently, I upgraded to TestComplete 12. I adjusted the execution command appropriately (executable path etc.). Now, when I execute the command through Task Scheduler or as a batch, the test suite fails to execute. Each and every test begins, reports an Excel sheet not found (when retrieving the parameterized input), then continues to the next test.
This process happens for the entire project suite instantly.
However, when I execute the exact same command by executing it through Windows Run program (instantaneous), it runs without any issues.
While I can still execute the test suite, the loss of autonomy is undesirable. Does anybody have any work around or solution to this issue? Is it simply a lacking feature (or rather loss of due to TestComplete 9's ability)? I would appreciate any help.
Here is the command I use:
"C:\SmartBear\TestComplete 12\Bin\TestComplete.exe" "<project suite path>.pjs" /r /p:<project>/exportLog:"<results export path>.mht" /e /SilentMode
Note: The original TestComple 9 command I used was the exact same-except for the executable path and /SilentMode. SilentMode was added to suppress the Save dialog that appears after exiting (new log reference - new feature from 9 to 12). I have tried all variations with/without /SilentMode and /e.
I'm still thinking it's a permissions thing in some way... Running it at the "Run" prompt in windows is running it using your user account. Running it as a task in task scheduler or as a batch, potentially, may be using a different user account or privilege level or, if it's running as you, it MIGHT not be running with the most elevated privileges you have (admin).
Try in your task setting the security options to have it run as an administrator. I know it seems strange, but give it a shot and see if that works.