2

我想在脚本中使用 rebot.py 来创建日志和报告并将其放入给定的文件夹中。日志和报告参数不起作用:

milo@automoso:~/temp/demoproject> ./rebot demo_output.xml --log /home/autotest/milo/robot_logs/log.html --report /home/autotest/milo/robot_logs/report.html
[ WARN ] Arguments '--log', '/home/autotest/milo/robot_logs/log.html', '--report' and '/home/autotest/milo/robot_logs/report.html' did not exist and were ignored. Validate the used command line syntax.
Log:     /home/milo/temp/demoproject/log.html
Report:  /home/milo/temp/demoproject/report.html
4

1 回答 1

1

选项必须在输出文件的名称之前。将“demo_output.xml”移动到命令的末尾。否则,rebot 认为所有这些参数都是输出文件的名称。

./rebot --log /home/autotest/milo/robot_logs/log.html --report /home/autotest/milo/robot_logs/report.html demo_output.xml 

如果您运行该命令rebot --help,它将在打印输出的顶部显示此用法:

Usage:  rebot|jyrebot|ipyrebot [options] robot_outputs
   or:  python|jython|ipy -m robot.rebot [options] robot_outputs
   or:  python|jython|ipy path/to/robot/rebot.py [options] robot_outputs
   or:  java -jar robotframework.jar rebot [options] robot_outputs
于 2013-05-15T15:26:01.170 回答