cancel
Showing results for 
Search instead for 
Did you mean: 

Running TestExecute from Powershell - TestExecute.exe is not a valid project.

SOLVED
Occasional Contributor

Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hi all

I'm using TestExecute 14.10.1042.11 x86 with Windows 10 1903 build 18362.295. 

When opening powershell (32 or 64 bit) and calling testexecute.exe I awlays get:

 

Cannot open "C:\Program files (x86)\smartbear\testexecute14\testexecute\bin\testexecute.exe" file because it is not a valid project suite or project file.

 

Wnen running from goold old cmd, everything is fine.

 

Did anyone knows what can be the cause?

 

 

 

Thank you...

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hello. If you look at actual command line of launched process you will see:
"C:\PROGRA~2\SMARTB~1\TESTEX~2\Bin\TESTEX~1.EXE" "C:\Program Files (x86)\SmartBear\TestExecute 14\Bin\TestExecute.exe"
That's where source of the error lies -- PowerShell transfers full path to TestExecute.exe as the first command line argument of the created process.
Best way to launch some executable from PowerShell script is to use Start-Proccess cmdlet.
You may take a look at this usefull arcticle about launching processes form PowerShell:
https://social.technet.microsoft.com/wiki/contents/articles/7703.powershell-running-executables.aspx...

View solution in original post

7 REPLIES 7
Community Hero

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Let's see your command line code please

Occasional Contributor

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hi,

Command line is:

C:\Program files (x86)\smartbear\testexecute 14\testexecute\bin\>.\testexecute.exe

 

testexecute.png

 

Thank you 

Community Hero

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hi,

 

Are initial dot and slash required ( '.\' ) ?

What if you type just testexecute.exe ?

 

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members 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. Postings made by [Community Expert Group] members
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.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
Occasional Contributor

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hi Alex,

testexecute.png

 

The workaround is to use: Invoke-Item "TestExecute.exe"

But I would like to ask anyway why such strange behaviour.

 

Regards tcuser

Occasional Contributor

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

I see the same issue from powershell and command prompt. If I manually launch TestExecute.exe from the Bin directory, it works just fine.

 

If I do TestExecute.exe or .\TestExecute.exe, I get the errors like the original poster said. But, if I change it to lowercase: testexecute.exe, it works no issue.

 

I recently ran Windows updates on this machine (Windows 8.1), and am using TestExecute 14.10.

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Hello. If you look at actual command line of launched process you will see:
"C:\PROGRA~2\SMARTB~1\TESTEX~2\Bin\TESTEX~1.EXE" "C:\Program Files (x86)\SmartBear\TestExecute 14\Bin\TestExecute.exe"
That's where source of the error lies -- PowerShell transfers full path to TestExecute.exe as the first command line argument of the created process.
Best way to launch some executable from PowerShell script is to use Start-Proccess cmdlet.
You may take a look at this usefull arcticle about launching processes form PowerShell:
https://social.technet.microsoft.com/wiki/contents/articles/7703.powershell-running-executables.aspx...

View solution in original post

Community Manager

Re: Running TestExecute from Powershell - TestExecute.exe is not a valid project.

Thanks for the help, Vladimir!

@tcuser3, does it resolve the issue?

 

 

---------
Tanya Gorbunova
SmartBear Community Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others.↓↓↓↓↓
New Here?
Join us and watch the welcome video:
Watch the new Interview
Top Kudoed Authors