我想开始比赛测试运行程序.batReadyApi的参数。我尝试将一些XML部分(下面代码中的PeriodEnd)作为参数传递给子流程.Popen地址:
argslist = ['C:/Program Files/SmartBear/ReadyAPI-1.9.0/bin/testrunner.bat',
'-a', '-s', 'TestSuite', '-c', 'TestCase', '-f', 'C:/temp/', '-P',
'PeriodEnd=<PeriodEnd>2017-04-11T00:00:00.000Z</PeriodEnd>',
'C:/temp/soapui-project.xml']
proc = Popen(argslist, stdout=PIPE, stderr=PIPE)
这将产生以下错误:
The system cannot find the file specified.
我发现,“<;”和“>;”就是问题所在。我怎样才能逃脱他们或者把他们交给波本?你知道吗
\
用于转义字符,请尝试\<
https://docs.python.org/2.0/ref/strings.html
可能使用
"
而不是'
CMD中的转义字符是
^
。你知道吗相关问题 更多 >
编程相关推荐