Test Summary Not Populated With Test Results in CircleCI

Viewed 2250

In CircleCI, I have a build executing automated tests. It generates tests results in an XML file using nose2 and junit plugin. The complete path of the test result file is:

/project-folder/test/junit/test-result.xml

My CircleCI configuration in the file /project-folder/.circleci/config.yml contains this:

- store_artifacts:
    path: test/junit/test-results.xml
    destination: test-results

- store_test_results:
    path: test/junit/test-results.xml

When the build executes, it confirms that test results and artifacts are properly loaded:

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 

However, the test results still do not appear in the Test Summary tab (see screenshot below).

Test Summary Empty

I have looked into the documentation here:

But I fail to see what I am missing? I also do not understand what the variable $CIRCLE_TEST_REPORTS refers to in the link above. What does it contain and how I should use it in my configuration.

1 Answers

To upload tests results on circle, you have to speficy the main test folder not the files.

In your case it should be

- store_test_results:
    path: test
Related