rebot 汇聚多个output.xml文件时 失败的解决方案

起因:

[jenkins@hzNgJenkins 187]$ rebot --nostatusrc -o output.xml -N verification_2H_Main --logtitle verification_2H_Main --reporttitle verification_2H_Main /home/jenkins/.jenkins/jobs/Verification_2H_CITB2/builds/184/robot-plugin/output.xml /home/jenkins/.jenkins/jobs/Verification_2H_CITB12/builds/184/robot-plugin/output.xml /home/jenkins/.jenkins/jobs/Verification_2H_CITB10/builds/184/robot-plugin/output.xml /home/jenkins/.jenkins/jobs/Verification_2H_CITB8/builds/184/robot-plugin/output.xml /home/jenkins/.jenkins/jobs/Verification_2H_CITB6/builds/185/robot-plugin/output.xml /home/jenkins/.jenkins/jobs/Verification_2H_CITB4/builds/185/robot-plugin/output.xml
Killed

调查:

通过 top -b >> /tmp/1.txt

发现是swap内存被消耗光了,原来的2G swap 不够

解决:

通过文件方式扩大swap分解的大小


创建要作为swap分区的文件:

root 用户登陆

touch /home/swapfile

dd if=/dev/zero of=/home/swapfile bs=1M count=8192


格式化为交换分区文件:

[root@hzNgJenkins home]# mkswap /home/swapfile
Setting up swapspace version 1, size = 8388604 KiB
no label, UUID=8556066c-dbed-4a26-941b-aab2e0a51a76
[root@hzNgJenkins home]#

#启用交换分区文件

chmod 0600 /home/swapfile

swapon /home/swapfile

# free -m 查看结果


#系统开机自启动:

在文件/etc/fstab中添加一行:

/home/swapfile          swap                    swap    defaults        0 0

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
根据你提供的批处理文件内容以及错误信息,问题出在合并测试报告,原因是合并的输出包含不同的根测试套件。 在你的批处理文件中,你分别执行了三个测试套件,并将它们的输出分别保存为`output1.xml`、`output2.xml`和`output3.xml`。然后你使用`rebot`命令合并这些输出文件生成最终的测试报告。 然而,错误信息提示无法合并包含不同根测试套件的输出。具体来说,原始测试套件是'Goodlistsuite',而被合并的是'Singalgoodcombi'。 要解决这个问题,你需要确保合并的输出文件具有相同的根测试套件。可以通过以下方式进行修改: 1. 检查测试套件文件中的根测试套件名称,确保它们的名称相同。 2. 确保`Goodlistsuite.robot`、`Singalgoodcombi.robot`和`Goodgroupsuite.robot`文件中的根测试套件名称相同。 3. 在执行`robot`命令,使用`--name`选项为每个测试套件指定一个相同的根测试套件名称。 例如: ```bat @echo off set ROBOT_REPORT_DIR=reports robot --outputdir %ROBOT_REPORT_DIR% --variablefile "variables.py" --name "MyRootSuite" --test test_* --output output1.xml "Goodmanage\Goodlistsuite.robot" robot --outputdir %ROBOT_REPORT_DIR% --variablefile "variables.py" --name "MyRootSuite" --test test_* --output output2.xml "Goodmanage\Singalgoodcombi.robot" robot --outputdir %ROBOT_REPORT_DIR% --variablefile "variables.py" --name "MyRootSuite" --test test_* --output output3.xml "Goodmanage\Goodgroupsuite.robot" rebot --outputdir %ROBOT_REPORT_DIR% --output final_report.html --merge %ROBOT_REPORT_DIR%\output1.xml %ROBOT_REPORT_DIR%\output2.xml %ROBOT_REPORT_DIR%\output3.xml ``` 请确保在执行`robot`命令,将`--name`选项的值设置为相同的根测试套件名称。然后使用`rebot`命令合并输出文件生成最终的测试报告。这样应该可以解决合并输出文件出现不同根测试套件的问题。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

youcharming

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值