从Jenkins 2.39升级到 Jenkins 2.42,在构建的时候出现错误。
Recording test results
ERROR: Step ‘Publish JUnit test result report’ failed: No test report files were found. Configuration error?
Finished: FAILURE
期间没做过任何的修改,只是将本地的 gradle 从2.11升级到了gradle 3.3
进入项目的配置选择,发现红色的提示。
根据Jenkins的提示:
'build/test-results/*.xml' doesn't match anything: 'build' exists but not 'build/test-results/*.xml'
Fileset ‘includes’ setting that specifies the generated raw XML report files, such as ‘myproject/target/test-reports/*.xml’. Basedir of the fileset is the workspace root.
修改了设置的格式,由
build/test-results/*.xml
改为
build/test-results/**/*.xml
重新构建,即可通过。