# No test results were found. Check your test reporting configuration. The test_results path 'test-results/*.xml' did not match any files.

- **ID:** `cicd/circleci-no-test-results-found`
- **Domain:** cicd
- **Category:** test_error
- **Error Code:** `CIRCLECI_NO_TEST_RESULTS`
- **Verification:** ai_generated
- **Fix Rate:** 88%

## Root Cause

CircleCI cannot find test result files because the glob pattern in the `store_test_results` step does not match the actual output location, or the test runner did not generate the expected XML files.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| CircleCI CLI 0.1.x | active | — | — |
| CircleCI Server 4.x | active | — | — |
| CircleCI hosted runners (medium, large) | active | — | — |

## Workarounds

1. **Explicitly create the test results directory and run tests with output redirected: `mkdir -p test-results && npm test -- --reporter junit --reporter-options output=test-results/junit.xml` and then use `path: test-results/` in store_test_results.** (90% success)
   ```
   Explicitly create the test results directory and run tests with output redirected: `mkdir -p test-results && npm test -- --reporter junit --reporter-options output=test-results/junit.xml` and then use `path: test-results/` in store_test_results.
   ```
2. **Use CircleCI's `collect_test_results` orb: `- orb: circleci/node@5.0.0` and configure `run: command: npm test` then `store_test_results: path: test-results` after ensuring the test framework outputs to that path.** (85% success)
   ```
   Use CircleCI's `collect_test_results` orb: `- orb: circleci/node@5.0.0` and configure `run: command: npm test` then `store_test_results: path: test-results` after ensuring the test framework outputs to that path.
   ```

## Dead Ends

- **** — Changing the glob pattern to `**/*.xml` without verifying the actual output directory structure often still fails because the test runner outputs files to a different relative path than expected. (60% fail)
- **** — Adding `ls -la test-results` before the store step may show files but the store step still fails if the files are generated inside a Docker container and not mounted to the workspace. (75% fail)
