Can't seem to get test report output working with tap-xunit from npm

In accordance with the docs I setup an npm script to specifically dump xunit output (via tap-xunit) to the $CIRCLE_TEST_REPORTS directory. I see this file, properly formatted and all, being put into the artifacts, but I’m still getting the UI message after each build that I should “Set up your test runner to output in JUnit-style XML.”

Here’s the npm script I’m using (it’s called test:circleci in my package.json file):

blue-tape test/*.js | tap-xunit > $CIRCLE_TEST_REPORTS/test_result.xml

I call it with my circle.yml via:

test:
  override:
    - npm run test:circleci

Everything runs fine and the build is successful. I mentioned before the file does get created in the build artifacts. Any help is appreciated.

Thanks!

Hey,

What worked for me was to output the test-result.xml file to $CIRCLE_TEST_REPORTS/junit/test-results.xml.

Cheers,

Mike

1 Like

Hey there,

Very late reply, but I’ve had success with this script: http://taint.org/2008/03/26/124602a.html

1 Like