加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

【jenkins-plugin】 无法读取生成的xml-report报告的解决方法

发布时间:2020-12-16 05:30:23 所属栏目:百科 来源:网络整理
导读:问题原因: jenkins-plugin-report无法识别绝对路径,只能识别相对路径 报错信息如下: coverage-report: [mkdir] Created dir: D:JKworkspaced9_rm3_engine_dev1.0.0_cudviewrmv3_engineengine_j2eedoccoveragereport [cobertura-report] Cobertura

问题原因:


jenkins-plugin-report无法识别绝对路径,只能识别相对路径



报错信息如下:

coverage-report:

[mkdir] Created dir: D:JKworkspaced9_rm3_engine_dev1.0.0_cudviewrmv3_engineengine_j2eedoccoveragereport

[cobertura-report] Cobertura 1.9.4.1 - GNU GPL License (NO WARRANTY) - See COPYRIGHT file

[cobertura-report] Cobertura: Loaded information on 114 classes.

[cobertura-report] Report time: 913ms

BUILD SUCCESSFUL

Total time: 1 minute 44 seconds

Publishing Cobertura coverage report...

No coverage results were found using the pattern 'view/rmv3_engine/engine_j2ee/doc/coveragereport/coverage.xml' relative to 'D:JKworkspaced9_rm3_engine_dev1.0.0_cudview'. Did you enter a pattern relative to the correct directory? Did you generate the XML report(s) for Cobertura?

Build step 'Publish Cobertura Coverage Report' changed build result to FAILURE

Recording test results

Finished: FAILURE

覆盖率报告已经生成,在工作区也可以找到,路径是:'view/rmv3_engine/engine_j2ee/doc/coveragereport/coverage.xml',但jenkins对于这个路径似乎不认,以前用svn的时候可以找到,改成CC后就找不到了

解决方法:

job配置里面将覆盖率的路径设置为:**/coverage.xml 就可以了。



After trying in different ways to solve the above problem,I could solve it by placing the TestResult.xml file in the workspace folder for the project in Hudson s jobs folder and giving only TestResult.xml under Publish NUnit test result report instead of giving the absolute path to the xml file.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读