Upload test reports
Enhance CI Autopilot by uploading test reports
By default, CI Autopilot analyzes general CI logs to identify failures. Adding structured test reports enables more precise, test-level analysis with better root cause identification and more targeted fix recommendations.
Prerequisites
GitHub repository with GitHub Action workflows
10-15 minutes for setup
Step 1 of 3: Configure test framework to generate test reports
Select test framework and follow the instructions to configure test reports: Test Frameworks
Validating reports (JUnit XML files)
You can validate your test reports using the Trunk CLI. If you don't have it installed already, you can install and run the validate
command like this:
curl -fsSLO --retry 3 https://trunk.io/releases/trunk && chmod +x trunk
./trunk flakytests validate --junit-paths "./junit.xml"
This will not upload anything to Trunk. To improve detection accuracy, you should address all errors and warnings before proceeding to the next steps.
✅ Success: The test reports pass the validation checks
Step 2 of 3: Configure GitHub Actions to upload test reports
CI Autopilot currently only supports GitHub Actions.
Follow the setup guide to upload test results: GitHub Actions
✅ Success: The updated workflow uploads test reports successfully
Step 3 of 3: Confirm test reports are uploaded
Currently, the best way to validate test result uploads are successfully processed by Trunk is by looking into the Uploads tab for Flaky Tests.
Select "Flaky Tests" in the top navigation
Click on the "Uploads" tab
Select your repository in the repository selector on the top right

✅ Success: The uploaded test reports are showing up in the uploads view
Last updated