CircleCI store_artifacts / store_test_results Empty - Fix
store_artifacts uploads nothing, or store_test_results leaves the Tests tab empty. The path points at a missing directory, the report is written after the store step, or the format is not the JUnit XML CircleCI expects.
What this error means
The job succeeds but the Artifacts or Tests tab is empty. Files you expected to surface (coverage, logs, JUnit reports) are not uploaded because the store step captured the wrong or empty path.
store_test_results
- path: test-results
- No test results found at "test-results"
store_artifacts
- path: coverage
- 0 artifacts uploadedCommon causes
Path does not exist or is wrong
The path must point at where the tool actually wrote files. A typo or a relative path resolved from the wrong directory uploads nothing.
Store runs before the report is written
If the test/coverage step has not produced output yet (or it failed before writing), the store step finds an empty directory.
Wrong test report format
store_test_results reads JUnit-style XML. If your runner emits a different format, the Tests tab stays empty even though a file exists.
How to fix it
Emit JUnit XML and store the right path
steps:
- run:
name: Test with JUnit output
command: npx jest --reporters=default --reporters=jest-junit
environment:
JEST_JUNIT_OUTPUT_DIR: ./test-results
- store_test_results:
path: test-results
- store_artifacts:
path: coverage
destination: coverageStore after the producing step, with run-on-fail
- Place
store_test_results/store_artifactsafter the test step. - Add
when: alwaysso reports upload even when tests fail. - Confirm the path matches the reporter’s output directory.
How to prevent it
- Configure the test runner to emit JUnit XML for the Tests tab.
- Store results/artifacts after the producing step, with
when: always. - Verify the path matches the tool’s real output directory.