Manual Setup

If we don't have an integration for your CI service yet, you can upload reports manually using any tool you're comfortable with. The examples here use cURL.

curl "https://api.check-run-reporter.com/api/v1/submissions" \
  --user token:88888888-4444-4444-4444-aaaaaaaaaaaa \
  -X POST \
  -F report=@"./reports/junit.xml" \
  -F label="Unit Tests" \
  -F sha="$CIRCLE_SHA1" \
  -F root="$(pwd)"

Authorization

Report uploads are authorized using basic authorization. The user should always be "token". Each repository has its own token. You can find your repository tokens on the Repositories page.

Parameters

report
Path to the report file. May be specified more than once.
label
Label used in the GitHub UI to describe this submission. Common lables might be "Unit Tests", "ESLint", etc.
sha
The commit corresponding to this Check Run. This is available as an environment variable in most CI systems. For example, it's $CIRCLE_SHA1 on CircleCI and $BUILDKITE_COMMIT on Buildkite.
root
Stacktraces and (often) test reports contain the full filesystem path to failed test files or thrown exceptions. In order to annotate GitHub Pull Requests, we need those paths to be relative to the repository root. The root parameter should be the filesystem path to the checkout directory. Often, this can simply be "$(pwd)".