我在Octopus Deploy中有一个流程步骤,通过调用PowerShell脚本来运行一些Selenium WebDriver测试,但它导致了一个错误。
PowerShell脚本如下所示:
set nunitPath="C:\AutomatedTests"
cd %nunitPath%\
nunit-console SiteCore.nunit /include:BulkyWasteTests当部署和运行脚本的过程步骤发生时,会发生以下错误:
Set-Location : Cannot find path 'C:\Octopus\Work\20170110115049-7\%nunitPath%\' because it does not exist.
At C:\Octopus\Work\20170110115049-7\Script.ps1:2 char:3
+ cd %nunitPath%\
+ CategoryInfo : ObjectNotFound: (C:\Octopus\Work...-7\%nunitPath %\:String) [Set-Location], ItemNotFoundException
+ FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.SetLocationCommand
The remote script failed with exit code 1我不明白为什么错误报告的位置与PowerShell脚本中指定的位置不同。非常感谢您的帮助。
https://stackoverflow.com/questions/41572082
复制相似问题