ReferenceResults
Metrics
Every metric Endform calculates from your suite runs, test runs, and test attempts, including exact formulas, exclusions, and ranking thresholds.
Endform calculates pass rates, durations, flakiness, rankings, and usage from your recorded suite runs, test runs, and test attempts. This page documents how each metric is defined and where it is available.
Worked example
Consider a single 30-second suite run where checkout.spec.ts fails on attempt 1 in 12 seconds, retries, and passes on attempt 2 in 10 seconds:
- Suite run outcome and duration:
pass,30s(wall-clock duration of the suite run). - Test run outcome and duration:
pass,22s(sum of attempt 1 and attempt 2 durations). - Flaky run: Yes (
testRun.outcome = passandtestRun.testAttemptsCount > 1). - Flake time:
12s(duration of the failed attempt inside this eventually passing test run). - Billable minutes:
22s(0.37minutes, summing both attempts).
Metric overview
| Metric | Dataset | Unit | Available in |
|---|---|---|---|
Run count (count) | suite-runs, test-runs | Count | Dashboard, CLI, MCP |
Suite pass rate (suiteRun.passRate) | suite-runs | Percent | Dashboard, CLI, MCP |
Test pass rate (testRun.passRate) | test-runs | Percent | Dashboard, CLI, MCP |
Average duration (average-duration) | suite-runs, test-runs | Duration (seconds in CLI and MCP) | Dashboard, CLI, MCP |
Duration percentiles (p50, p75, p95, p99) | suite-runs, test-runs | Duration | Dashboard |
| Flake rate, flaky tests, flakiness score, flake time | test-runs, test-attempts | Percent / Count / Duration | Dashboard |
| Most failing tests, slowest tests | test-runs | Percent / Duration | Dashboard |
Billable minutes (billableMinutes) | test-attempts | Minutes | Dashboard |
Most expensive tests (usedMs, retryMs) | test-attempts | Duration | Dashboard |
See Analytics for the CLI flags and MCP parameters used to query count, pass-rate, and average-duration.
Volume and pass rate
Run count (count)
Total number of matching rows in the selected dataset (suite-runs or test-runs). On test-runs, count includes skipped test runs unless you filter them out (for example testRun.outcome != skip).
Suite pass rate (suiteRun.passRate)
passed suite runs / total suite runs * 100A suite run counts as passed when every non-quarantined test run in the suite passed or was skipped. Failed tests covered by an active quarantine rule do not fail the suite run.
Test pass rate (testRun.passRate)
passed test runs / non-skipped test runs * 100- Skipped runs are excluded (
testRun.outcome != skip) from both numerator and denominator. - Retried passes count as passes: A test run that failed on attempt 1 and passed on retry has
testRun.outcome = pass. - Quarantined failures count as failures: Quarantine prevents a test from failing the suite run, while Endform keeps its real
failoutcome in test-run metrics.
Duration and feedback time
Average duration (average-duration)
Arithmetic mean of durationMs across matching runs, returned in seconds by the CLI and MCP server:
- On
suite-runs: Mean wall-clock suite run duration. - On
test-runs: Mean test run duration (where each test run's duration is the sum of its attempts' durations), excluding skipped test runs. - Overall series value: Weighted by the number of observations in each time bucket (
sum(bucket value * bucket observations) / total observations), rather than an unweighted average of bucket means.
Duration percentiles (p50, p75, p95, p99)
Shown in Dashboard Analytics charts, the Feedback Time summary, and Suite and Test pages:
p50(median): Half of runs finished at or below this duration.p75,p95,p99: Upper-tail durations showing slower runs and outliers.- Exclusions: Test-run percentiles exclude skipped runs (
testRun.outcome != skip). Suite-run percentiles use wall-clock suite duration across all completed suite runs in the scope.
Flakiness
Endform classifies flakiness from retry evidence in recorded test runs:
-
Flaky run: A test run that eventually passed after needing at least one retry (
testRun.outcome = passandtestRun.testAttemptsCount > 1). A test run that fails all of its attempts is counted as a failure, not a flaky run. -
Flake rate:
flaky runs / non-skipped test runs. -
Flaky tests count: The number of distinct tests in the selected window that meet both thresholds:
- At least 5 non-skipped runs (
assessableTestscounts all tests meeting this minimum). - A flake rate of at least 1% (
>= 0.01) with at least 1 flaky run.
- At least 5 non-skipped runs (
-
Flakiness score (ranking): Flaky tests in the dashboard are ordered by the 95% confidence Wilson score lower bound (
z = 1.96) offlakeRate:(p + z^2 / (2n) - z * sqrt((p * (1 - p) + z^2 / (4n)) / n)) / (1 + z^2 / n)where
p = flaky runs / nandn = non-skipped runs. Using the lower bound prevents a test with few runs (such as 1 flake in 5 runs) from outranking a test with strong evidence of flakiness (such as 40 flakes in 100 runs). Ties break byflakyRunsdescending. -
Flake time: Sum of
testAttempt.durationMsacross every failed attempt belonging to a flaky (eventually passing) test run. This measures runner time spent on attempts that failed before a retry recovered the test.
Failure and slowness rankings
Most failing tests
Ranks tests by persistent failure rate in the selected window:
- Excludes skipped test runs (
testRun.outcome != skip). - Requires at least 25 non-skipped runs and at least 1 failed run.
- Ordered by the 95% confidence Wilson score lower bound (
z = 1.96) offailRate = failed runs / non-skipped runs, with ties broken byfailedRunsandtotalRuns.
Slowest tests
Ranks tests by non-skipped testRun.durationMs:
- Sorted by total duration: Sums
testRun.durationMsacross all non-skipped runs in the window (minimum 1 run). Highlights tests that consume the most cumulative test time. - Sorted by average duration: Averages
testRun.durationMsacross non-skipped runs (requires at least 5 runs). Highlights individual slow tests that set suite wall-clock time.
Usage and cost
Billable minutes (billableMinutes)
sum(testAttempt.durationMs) / 60,000Summed across all executed test attempts in the window, including retries and quarantined attempts. See Billing for plan details and usage views.
Most expensive tests
Ranks tests within a suite by total attempt time (usedMs = sum(testAttempt.durationMs)), and breaks out retry spend separately (retryMs = sum(testAttempt.durationMs) for attempts with attemptIndex > 0).
Time windows and bucketing
- Automatic bucket intervals: Time series group data into
hour,day, orweekbuckets (weeks start on Monday). Queries are capped at 1,000 buckets. - Timezones: The CLI and MCP server bucket in
UTC. The dashboard buckets in your browser's timezone. - Empty buckets: CLI and MCP responses omit buckets with zero observations.
- Period-over-period comparisons: Dashboard summary tiles compare the selected window against the immediately preceding window of the same length.
- Lookback and retention: CLI and MCP
analyticsandsamplesqueries accept time periods starting up to 60 days before the request time. Underlying run records are retained according to Security and data.
Related pages
Last updated