Skip to content
New PeakSolutions

Application Development & QA

Test automation your team will actually trust

New Peak Engineering Practice6 min read
Lines of code on a monitor

A suite that fails at random is worse than no suite at all. Here is how we build automated tests that speed up releases instead of slowing them down.

Most teams we work with already have automated tests. The trouble is that nobody believes them. A build goes red, someone reruns it, it goes green, and everyone moves on. Once that habit forms, real failures slip through and the suite becomes something to work around rather than rely on.

Test at the right level

Slow, brittle suites are usually top-heavy, with hundreds of browser tests checking logic that could be verified in milliseconds further down. Push most checks into fast unit and API tests, and keep end-to-end tests for the handful of journeys that truly matter to customers, such as signing in, checking out or submitting a claim.

Treat flaky tests as defects

  • Track which tests fail intermittently and how often
  • Quarantine a flaky test immediately so it stops blocking releases
  • Fix or delete it within a set time, rather than letting the quarantine grow
  • Look for shared causes such as timing, test data or environment drift
A test only earns its place in the pipeline if a failure makes someone stop and look.

Own the test data

Many unreliable tests depend on data that someone else can change. Give each test the data it needs, create it at the start and clean it up at the end. It takes a little longer to write, and it removes a whole category of mysterious failures.

Make results impossible to ignore

Run the fast tests on every pull request and the full suite before each release. Report results where the team already works, and make a broken main branch the most important thing to fix. When the signal is fast and trustworthy, developers start to rely on it, and releases get both quicker and calmer.

Good automation is not measured by how many tests you have. It is measured by how confidently you can ship on a Friday afternoon.

All insights

Written by the Engineering Practice