Unit tests

Automated checks of one function or class in isolation.

Mandatory for 18 of 46 product types. Usually run by a developer.

What it catches

What it misses

Which product types need it and why

Status of unit tests on every published playbook, with the risk ids or the condition behind it.
Product typeStatusReason or condition
accounting and invoicing SaaSmandatoryRisks: Records silently wrong
buy now pay later servicemandatoryRisks: Money leaves or fails to arrive
clinical trial management softwaremandatoryRisks: Physical or psychological harm to a user
crypto exchangemandatoryRisks: Money leaves or fails to arrive
data pipelinemandatoryRisks: Records silently wrong
desktop applicationmandatoryRisks: Records silently wrong
e-signature servicemandatoryRisks: Records silently wrong
email marketing platformmandatoryRisks: Fine or enforcement by a regulator
ERP systemmandatoryRisks: Money leaves or fails to arrive
expense management toolmandatoryRisks: Records silently wrong
identity and access management servicemandatoryRisks: Fraud or abuse by users
insurance appmandatoryRisks: Records silently wrong, Money leaves or fails to arrive
lending platformmandatoryRisks: Records silently wrong, Money leaves or fails to arrive
loyalty program appmandatoryRisks: Money leaves or fails to arrive
machine learning model servicemandatoryRisks: Users or operators act on wrong numbers, Fine or enforcement by a regulator
software as a medical devicemandatoryRisks: Physical or psychological harm to a user
SDK or client librarymandatoryRisks: Third-party dependency fails
stock trading appmandatoryRisks: Users or operators act on wrong numbers, Money leaves or fails to arrive
dating apprecommendedBecomes mandatory when matching, distance or eligibility rules change.
messaging apprecommendedBecomes mandatory when encryption, ordering or delivery receipt logic changes.
mobile banking apprecommendedBecomes mandatory when interest or fee calculation moves from the core platform into the bank's own code.
mobile gamerecommendedBecomes mandatory when drop rates, rewards or pricing rules change.
neobankrecommendedBecomes mandatory when the neobank runs its own ledger instead of the partner bank's.
ride-hailing apprecommendedBecomes mandatory when the risk "Money leaves or fails to arrive" is attached to this product type with verified evidence (see the methodology).
subscription box servicerecommendedBecomes mandatory when plans with different cycle lengths ship.
ecommerce storeoptionalMay help: discount stacking, tax and shipping rules can be checked in code without a deployed build.
electronic health record systemoptionalMay help on dose calculation, unit conversion and date logic in medication modules.
fleet and logistics trackingoptionalMay help: duty-time arithmetic across midnight and timezones breaks quietly.
government services portaloptionalMay help where eligibility rules change by law.
grocery delivery appoptionalMay help when fees vary by basket size or region.
smart home or IoT appoptionalMay help: schedule logic breaks quietly across daylight saving changes.
kids appoptionalMay help where gate logic is custom.
language learning appoptionalMay help where streak complaints appear after travel.
LLM-based assistantoptionalMay help: catches template and parsing breaks without calling the model.
online marketplaceoptionalMay help: fee, tax and payout split arithmetic can be checked in code without a deployed build.
mental health appoptionalMay help on the logic that decides which screens show crisis resources and which events go to analytics.
patient portaloptionalMay help on the rules that decide which results a proxy or adolescent account can see.
pharmacy delivery appoptionalMay help: checks days-supply arithmetic and refill-date calculation without a deployed build.
social networkoptionalMay help: age and visibility rules have fixed inputs and outputs.
telemedicine appoptionalMay help on the scheduling code that maps appointment times across the patient's and clinician's time zones.
event ticketing platformoptionalMay help when fees vary by venue or price tier.
travel booking appoptionalMay help when fees vary by supplier or country.
video conferencing tooloptionalOptional: supports the intruder cases with code-level checks on meeting ID generation.
wearable companion appoptionalMay help: checks on unit conversion and threshold logic before device testing.
EV charging appnot neededNot needed as a separate item: price and kWh calculations are covered by data integrity checks. Becomes optional when tariff logic moves into the app.
peer-to-peer payment appnot neededNot needed as a separate plan item: fee and limit rules are checked inside e2e and data-integrity runs. Becomes recommended when fee tiers or limits vary by user type.

Done conditions used on playbook pages

Each mandatory cell has its own done condition, written for that product type.

Tools

Alphabetical. Not recommendations.

5 tools shown

unit tests

  • JestJavaScript test runner with mocking and snapshots. webapiopen-source
  • JUnitTest framework for the JVM. apiandroidopen-source
  • pytestTest framework for Python with fixtures and plugins. apiopen-source
  • VitestTest runner for Vite-based JavaScript and TypeScript projects. webapiopen-source
  • XCTestApple's framework for unit and UI tests. iosopen-source