Skip to content
Tests

List tests

Every test with a run of the source (all by default) in the period and its metrics - stability, flaky rate, failure rate, runs, time lost, its last 20 runs, the branches it ran on and where it fails most - ranked by the chosen sort. Counts finished runs of the source - all by default - without mass-failure runs, on every branch unless branch names one (see population). Moderate: aggregate queries over the period’s results of the source, paged in the database; use the metrics route for one test.

GET/api/v1/projects/{projectId}/tests

Parameters

ParameterDescription
projectIdstring · pathrequired
A project id from GET /projects.
days7 | 14 | 30 | 90 · default 30
The period, in days, ending now. Must not exceed the plan’s retention (Standard 60, Pro 90 days); a longer period is refused with 400 invalid_period rather than answered with less data.
searchstring
Case-insensitive substring of the test name or its file.
branchstring
Only runs on this branch, the name exactly. Every branch when absent.
sourceci | local | all · default all
Which runs count, by where they ran: all - every run (the default since 1.0.0-beta.18; ci before); ci - runs a shard reported a CI provider for; local - runs no shard did. The response’s population names the one counted.
browserstring
Only tests of this Playwright project - the items’ browser field, exactly (e.g. chromium). Every test when absent.
sortstability | flakyRate | failureRate | runs | timeLost · default stability
Ranking, the worst first: stability (the default) lowest first; flakyRate, failureRate, runs and timeLost highest first. Ties go to the most runs (for runs: the lowest stability), then to the test name and file. A rate with nothing to divide by (null) sorts after every number.
pageinteger · default 1
1-based page number. A page past the end answers the last page.
perPageinteger · default 50
Rows per page, 1 to 100.

Responses

200400401403404429500