Ask a Question

TestExecute, CMD & UAC

jpnjordan
Occasional Contributor

TestExecute, CMD & UAC

Hi All,

 

I have an interesting issue I thought I'd reach out to the community for help with.

 

My setup:

 

  1. UAC is completely disabled (see 1.png)
  2. A VB.NET ClickOnce console application monitors a folder for a indication of a new compile of our desktop software.
  3. When a compile occurs, it grabs the latest copy of the TC project from TFS, installs the compile and calls a batch file.
  4. The batch file contains the TestExecute command line, which instructs TETestExecute to run the project.
  5. Once the testing finishes and TestExecute closes, the CMD window doesn't close...which means the ClickOnce application can't continue and I need to intervene (which I'm trying to avoid)

Enabling UAC does allow the CMD window to close, but then I can't install our software (TE doesn't recognise the objects). Disabling UAC again allows TE to recognise the objects, but then the CMD window doesn't close. Quite the pickle.

 

Example batch file: 

 

"c:\Program Files (x86)\SmartBear\TestExecute 12\bin\TestExecute.exe" "C:\TestComplete\Automation.pjs" /el:"C:\TestComplete\CanaryExport.mht" /r /project:"Canary" /exit /DoNotShowLog /SilentMode

Again, I've tried adding "exit" or "exit 0" to the end of the batch file but that's not helped.

 

So, I'm a little bit stuck. I'll give SmartBear Support a try if no-one's had similar experiences, but it hits me as more of an environment issue. 

 

Cheers

3 REPLIES 3
Marsha_R
Champion Level 3
jpnjordan
Occasional Contributor

I've given the solution stated there a try, but unfortunately it didn't work.

 

I think the issue is that it doesn't recognise that TestExecute has closed, so CMD waits for it.

 

Edit: 

Thought I'd add the contents of the new bat file, in case I didn't understand the solution.

"c:\Program Files (x86)\SmartBear\TestExecute 12\bin\TestExecute.exe" "C:\TestComplete\Automation.pjs" /el:"C:\TestComplete\CanaryExport.mht" /r /project:"Canary" /exit /DoNotShowLog /SilentMode
taskkill /f /im cmd.exe

try 

taskkill /f /im "cmd.exe"

 

 

also make sure you are running as Administrator

cancel
Showing results for 
Search instead for 
Did you mean: