Green Tests, Broken Checkout: The Checks Functional Tests Miss
A green functional suite can't see a renamed field, a slow peak, an open security hole or a form a keyboard can't finish. Add a Pact contract, a k6 test against an SLO, a ZAP baseline scan, and axe plus a keyboard pass.
Key takeaways
- Two teams can both have green tests while their services disagree on a field name; a consumer-driven contract test catches it before the deploy.
- Load-test targets come from a service level objective agreed with the business, not from example thresholds.
- Measure latency percentiles, and use an open workload model so the load does not slow down with the system.
- A ZAP baseline scan is passive and safe to run on every merge request against a test environment, but it cannot find business-logic flaws.
- Automated accessibility checks found about 57% of issues by volume in Deque's study; a keyboard and screen reader pass finds the rest.
Contents
FAQ
Is contract testing non-functional testing?
No. A contract test checks that two services agree on the shape of their requests and responses, which is functional. It belongs with load, security and accessibility checks because a green functional suite misses all four.
Where do performance test thresholds come from?
From your service level objectives, such as p95 checkout latency under 800 ms over 28 days. If there is no SLO, run a baseline, agree targets with the product owner and write them down before judging any result.
Is a clean Lighthouse or axe report enough for accessibility?
No. Automated tools catch only part of the problems. Complete the main flow with a keyboard only and with a screen reader, and check dynamic states such as error messages and modals.
Sources
- QA Skills Path: Specialised Testing (security, accessibility, contracts, test data)
- QA Skills Path: Performance Testing Guide
- Pact documentation
- Grafana k6 documentation: Thresholds
- web.dev: INP becomes a Core Web Vital on March 12
- ZAP: Baseline Scan
- W3C: Web Content Accessibility Guidelines (WCAG) 2.2
- Deque: Automated testing study identifies 57 percent of digital accessibility issues
Only you and the owner see your answer and rating. Send private feedback
Enjoyed it? Support fx-blog with a coffee.
Related posts
AI in Testing: Use It Without Trusting It, and Test AI Features
Trusting AI output gives you tests that can't fail and an assistant that invents policy. Review every AI-written test by breaking the feature on purpose, keep agents out of the gate, and test AI features with eval sets run in CI.
Quality Gates in CI: Make Your Tests Block a Bad Merge
Tests that run only when someone remembers put the gate in a person. Run them in four CI tiers that each block the next, keep the commit gate under ten minutes, give every run fresh data, and quarantine flaky tests the same day.
Why Your UI Tests Flake, and the Fix for Web and Mobile
Flaky UI tests teach a team to ignore red. Fix the three usual causes: brittle locators, fixed sleeps and shared data. Use role and test-id locators, web-first assertions, API setup, Accessibility IDs on mobile, and same-day quarantine.
Comments
Oldest firstNo comments yet. Start the conversation.
Part 4 left the ShopLite checkout green on three browsers and two phones, for one user with a mouse, against services that never change. This part checks what happens with 2,000 users, a keyboard, and a pricing team that renames one field.
The repo tells the rename as a story. The checkout reads
discountAmountfrom the pricing API. The pricing team renames itdiscount_amount, deploys on Tuesday, and checkout shows "€NaN" to every customer. Both teams had green tests, each against its own idea of the other.The QA Skills Path, in seven parts:
A contract test catches the rename
A consumer-driven contract records what the checkout reads from the pricing API, and the pricing API's pipeline proves it still returns that. With Pact:
The consumer test uses matchers such as
likeanddecimal, so the contract fixes the shape ofdiscountAmount, not its value. Before either side deploys, one command asks the broker whether the versions agree:The rename now fails in a pipeline, not in front of customers.
Load-test against a number someone agreed
Every threshold in the repo's performance guide is marked as an example. The real target is a service level objective, such as "p95 checkout latency under 800 ms over 28 days" (95% of requests faster than that). With no SLO, run a baseline and agree targets with the product owner first. Then k6 can fail the run for you:
Measure percentiles, since a fast average can hide a slow p99. Use an open model (a fixed arrival rate, k6's
constant-arrival-rate), because a fixed pool of virtual users slows down with the system and hides the problem. Little's Law sizes it: 50 requests a second at 0.5 s response and 2.5 s think time need about 150 concurrent users.In the browser, Core Web Vitals measure what the customer feels: LCP ≤ 2.5 s, INP ≤ 200 ms, CLS ≤ 0.1. INP replaced FID in March 2024.
Scan for the cheap security wins
A ZAP baseline scan spiders the site and reports what it sees without attacking, so it is safe to run on every merge request against a test environment:
It exits 0 when clean, 1 on a FAIL, 2 on a WARN, 3 on a scanner error;
-Iignores warnings while you triage the first report. Addnpm auditorpip-auditfor vulnerable dependencies andgitleaksfor committed secrets.Check that everyone can pay
The European Accessibility Act has applied to e-commerce in the EU since 28 June 2025, and the standards behind it are built on WCAG; level AA of WCAG 2.2 is the usual target. The repo's axe test scans states, not only pages; here, ShopLite's discount error:
In Deque's study of real audits, automated checks covered about 57% of issues by volume. The rest needs a person, so put the mouse away and buy something:
Tabmoves in reading order, focus is always visible, payment radios work with arrow keys, and a failed "Apply" never throws focus to the top of the page.Try it
The ShopLite checkout now has five kinds of tests: designed cases, API, UI, contracts and these scans. Every one of them runs when someone remembers to run it, on one laptop, against whatever data is lying around. Part 6, Quality Gates in CI: Make Your Tests Block a Bad Merge, moves them all into the pipeline so a failing check stops the merge.
Read this with your AI