# What Is a Test Reporter? — Definition, Formats and Running Several at Once

Canonical: https://commareports.com/glossary/test-reporter
Published: 2026-11-06

> A test reporter turns a runner's events into output: console text, JUnit XML, JSON or an HTML report. How Jest, Vitest, Playwright, pytest, Mocha and Go configure them, and why most CI pipelines want two.

# Test reporter

**A test reporter is the part of a test runner that turns its events into
output.** The runner executes tests and decides what passed. The reporter
listens (run started, test finished, run complete) and writes the result
somewhere: the terminal, a [JUnit XML](/glossary/junit-xml) file, JSON, or
an [HTML report](/glossary/html-report).

Reporters are pluggable, so the same run can produce several outputs.
That's the normal setup, not an advanced one.

## The usual three

| Reporter type | Who reads it                    | Example output                                 |
| ------------- | ------------------------------- | ---------------------------------------------- |
| Console       | Whoever is watching the job     | Dots, a list, a summary line                   |
| JUnit XML     | The CI system, the code host    | `junit.xml` for test tabs and PR checks        |
| HTML          | Reviewers, QA, PMs, the on-call | `report.html` or a `playwright-report/` folder |

JSON reporters (`--json` in Jest, `json` in Playwright) are a fourth,
mostly for your own scripts and dashboards.

## How each runner configures them

**Jest** — a `reporters` array. Setting it replaces the defaults, so keep
`"default"`:

```js
reporters: ["default", ["jest-junit", { outputDirectory: "reports" }]];
```

**Vitest** — repeat `--reporter`, or set `reporters` in the config:

```bash
vitest run --reporter=default --reporter=junit --outputFile.junit=junit.xml
```

**Playwright** — a list of `[name, options]` tuples:

```ts
reporter: [
  ["list"],
  ["junit", { outputFile: "results/junit.xml" }],
  ["html", { open: "never" }],
],
```

**pytest** — flags combine: `--junitxml=junit.xml` is built in,
`--html=report.html --self-contained-html` comes from the pytest-html
plugin.

**Mocha and Cypress** — `--reporter` takes one reporter. To get more,
wrap them with `mocha-multi-reporters` or `cypress-multi-reporters`.

**Go** — `go test` has no reporter plugins, only `-json`. Tools like
`gotestsum --junitfile junit.xml` read that stream and write the other
formats.

**.NET** — loggers: `dotnet test --logger trx --logger "junit"` (the
second one from the JunitXml.TestLogger package).

## Where reporters go wrong

- **The defaults disappear.** Jest and Playwright replace the default
  reporter when you configure one. The terminal goes quiet.
- **The CLI overrides the config.** A `--reporter` or `--reporters` flag in
  a CI script replaces the configured list rather than adding to it. See
  [Jest HTML report not generated](/fix/jest-html-report-not-generated).
- **The HTML report isn't one file.** Playwright, Allure, Vitest and
  jest-html-reporters write a folder, and the page loads its data from it.
  Send only the HTML and it opens blank. See
  [self-contained HTML](/glossary/self-contained-html).
- **The report never leaves CI.** It's uploaded as a
  [build artifact](/glossary/build-artifact), behind a login, and expires
  under [retention](/glossary/artifact-retention).

## The HTML report is the one people read

JUnit XML tells CI a test failed. The HTML report shows why: the assertion
diff, the screenshot, the trace, the timing. It's also the output most
likely to be stuck in a zip. Publishing it to a link, with each run as a
revision of the same page, turns it into something a team can discuss.
Comma does that with one `curl` from CI ([publish from CI](/docs/ci)), and
the [JUnit XML viewer](/tools/junit-xml-viewer) turns a `junit.xml` into an
HTML report when the runner doesn't have one.

## Try it

Comma is free — unlimited reports, unlimited commenters, unlimited
revision history.

**[Publish a test report →](https://commareports.com/)**

### Related

- [JUnit XML](/glossary/junit-xml) · [HTML report](/glossary/html-report) · [Self-contained HTML](/glossary/self-contained-html)
- [Flaky test](/glossary/flaky-test) · [Playwright trace](/glossary/playwright-trace)
- [Jest HTML report not generated](/fix/jest-html-report-not-generated)
- [Glossary](/glossary)
