测试总结未在CircleCI中填充测试结果
问题描述:
在CircleCI中,我有一个构建执行自动化测试。它使用nose2
和junit
插件在XML文件中生成测试结果。测试结果文件的完整路径是:测试总结未在CircleCI中填充测试结果
/project-folder/test/junit/test-result.xml
文件
/project-folder/.circleci/config.yml
在
我CircleCI配置包含此:
- store_artifacts:
path: test/junit/test-results.xml
destination: test-results
- store_test_results:
path: test/junit/test-results.xml
当构建执行时,就已经证实测试结果和文物正确加载:
Uploading artifacts
Uploading /home/circleci/repo/test/junit/test-results.xml to test-results
Uploaded /home/circleci/repo/test/junit/test-results.xml
Uploading test results
Archiving the following test results
* /home/circleci/repo/test/junit/test-results.xml
Uploaded
然而,测试结果仍然没有出现在测试小结标签(SCR下面的eenshot)。
我特地到这里的文件:
但我看不出我缺少的是什么?我也不明白变量$CIRCLE_TEST_REPORTS
在上面的链接中提到了什么。它包含什么以及如何在配置中使用它。
答
要在圆上上传测试结果,您必须确定主测试文件夹而不是文件。
你的情况应该是
- store_test_results:
path: test
至于这么简单...谢谢你洛朗,它的工作:) –