Skip to main content
Free plan, no cardStart free

Use CasesScenario walkthrough

Use Case: Smart Test Selection in CI, or Why Your 45-Minute Pipeline Is a Choice

Run the tests a change can reach, read why each one was picked, and keep the full suite for the night. The 45 minutes were a default.

Summarise with AI

Opens a new chat with only this request: Summarise the key points of this article: https://dokimore.com/blog/smart-test-selection-ci-pipeline

45 → 8–12Minutes per commit in the walkthrough scenario; your ratio is the number a trial measures
1Written rationale per selected test, with a confidence score for the whole selection
0Pipeline-time percentages we publish; the scenario below is arithmetic, not a measurement

In short

  • Test selection answers one question per change: which tests could this change possibly affect? Running only those cuts the per-commit wait; the full suite still runs on a schedule as the safety net.
  • The best-known industrial result, from Meta’s engineering research, reports that predictive selection halved the infrastructure cost of testing changes while still reporting over 95% of individual test failures.
  • Playwright already ships a simple form, --only-changed, which runs the test files changed since a Git reference and the test files that import them. Dokimore’s selection works at the flow level, with a written reason per pick and a confidence score that tells you when to run everything instead.

About this article

Format
Scenario walkthrough: how a team would use the platform for one job; a scenario, not a customer story.
Written for
QA leads and test managers · Engineering managers · Developers who own their tests
Where it applies
Every market. The rules that differ by country are on the country pages.

This is a scenario walkthrough of how the feature works. It is not a customer story, and the numbers in it were chosen so that the arithmetic is easy to follow.

The scenario

A team has about 2,400 browser and API tests. The full suite takes 45 minutes, so developers batch their commits, feedback arrives cold, and when the suite fails at minute 43 the investigation starts an hour after the code was written. The instinct to run fewer tests is right. Doing it by hand, by deleting the slow ones and skipping the annoying ones, is how coverage dies quietly.

What the research measured

The technique has a name in the literature, test impact analysis or predictive test selection, and one widely cited industrial result. Meta’s engineers trained a model on the history of which changes broke which tests and used it to pick the tests to run for a new change. Their paper, "Predictive Test Selection" by Machalica, Samylkin, Porth and Chandra, reports that the approach halved the total infrastructure cost of testing code changes while still reporting more than 95% of individual test failures to developers.

Two things about that result matter for a smaller team. It is a measured trade, not a free lunch: some failures are found later, at the scheduled full run. And it depends on history; a selection system knows nothing on day one and gets better as it watches your suite.

What your framework already does

If your tests are Playwright, you already have the simplest version. Since version 1.46 the --only-changed option runs the test files that changed since a Git reference and the test files that import any changed file, and --last-failed, since 1.44, re-runs only the failures from the previous run. Both work at the file level: a change to a shared component runs the test files that import it, not the recorded flows that reach it through the page. Playwright’s CI guide adds the other free lever, sharding a suite across machines when one machine is too slow.

In the product

How Dokimore selects

Smart test selection in Dokimore works on recorded flows rather than files. It maps a change set, or a requirement such as a Jira issue read as text, to the flows that can reach what changed: the flows that visit the component, the journeys that traverse it, and the API checks behind the endpoints it calls. Each pick carries a written rationale you can read, and the selection as a whole carries a confidence score. When the confidence is low, the right action is to run everything, and the screen says so instead of pretending.

In the scenario, a commit that touches the checkout component selects the checkout flows, the journeys that pass through checkout and the API tests behind its endpoints: a few hundred tests rather than 2,400, and a per-commit loop in the 8 to 12 minute range. The full suite still runs nightly. We do not publish a headline percentage, because the saving is the selection ratio on your own commits, and that depends on how coupled your codebase is.

For the manager reading this

Multiply your suite duration by your team’s commits per day. That is the wait your team pays, every day, in minutes you can put in a spreadsheet. Then measure instead of estimating: a 14-day trial on real commits produces your actual selection ratio, which turns the decision from a promise into your own number. Smart test selection is on the Solo Pro plan and above; it runs in the platform today, and exported tests run in your own CI.

What to do next

  1. Multiply your suite duration by your team’s commits per day; that is the wait you pay every day, in minutes.
  2. If your tests are Playwright, turn on --only-changed and --last-failed first; file-level selection is free.
  3. Keep the full suite on a schedule as the safety net before you select anything on a commit.
  4. Measure your own selection ratio on real commits for two weeks instead of trusting a headline percentage; the smart test selection guide says what the platform selects from.
  5. Read the written rationale per pick, and run everything when the confidence score says so.

Questions people ask

What is test impact analysis?

A way of choosing which tests to run for a change by working out which tests the change could affect, from a dependency map, from execution history, or from a model trained on both. Its purpose is a shorter feedback loop per commit while a scheduled full run keeps the coverage. Predictive test selection is the learned form of it.

Does test selection miss failures?

Some, by design, and the good systems say how many. Meta’s published result reports over 95% of individual failures still surfaced while infrastructure cost halved; the remainder are caught at the full run. Dokimore shows a confidence score for every selection and recommends running everything when it is low, and the full suite runs on the schedule you set.

What input does smart test selection use?

A change set, or a requirement in text, such as a Jira issue read as requirements. It maps that to the recorded flows that can reach the change and the API checks behind the endpoints involved, and writes a reason for each pick.

Can I run the selected tests in my own CI pipeline?

The selection runs in the platform today; there is no pipeline trigger yet. Exported tests, as Playwright, Selenium, Robot Framework or pytest code, run in your CI, where Playwright’s own --only-changed and --last-failed options give file-level selection for free.

How we measured this

  • The suite size and durations in this walkthrough are a scenario chosen for arithmetic clarity, not a measurement of any customer. The selection ratio on your own commits is the number a trial produces.
  • The research result is quoted from the paper’s own abstract, read on the date beside the reference. We have not reproduced it.
  • Dokimore’s behaviour is the product on the article date: a written rationale per pick, a confidence score per selection, a Jira issue accepted as a requirement, no pipeline trigger.
  • Corrected 2026-10-28: an earlier version said --only-changed runs only the test files changed since a Git reference. Its 1.46 release notes say it also runs every test file that imports a changed file, and this version says so.

Sources

  1. Machalica, Samylkin, Porth, Chandra, "Predictive Test Selection", ICSE (Software Engineering in Practice): infrastructure cost halved, over 95% of failures still reported read
  2. Playwright release notes: --last-failed (1.44) and --only-changed (1.46) read
  3. Playwright CI guide: one worker in CI, sharding for wider parallelism read

See it on your own project

Every new account starts a 14-day Solo Pro trial, then 14 days on the Free plan. No card. Record one flow and measure the difference on your own numbers.

  • Free plan, no card
  • 14-day Solo Pro trial
  • Demo replies within one business day
  • Data hosted in India