I am running powershell from batch script. Here is sample code.
powershell.exe Set-ExecutionPolicy Bypass -Force
set logDir=C:\testfolder\
mkdir %logDir%
powershell.exe C:\<folder>\test.ps1 >> "%logDir%test.log"
Getting error: "test.ps1" is not recognized as the name of a cmdlet This issue occurred only on particular VM. The same script execution completes on other windows machines. Need solution for this issue.