TestFinch

Sanity test template

A sanity test template with worked examples: narrow checks of one fix and what sits next to it.

Sanity tests check one change narrowly after a fix or a small release: that the change works and that the things right next to it still do. They are quick and focused, not broad. Examples are for an example online shop; replace them with your own app's.

Download .xlsxDownload .csvDownload .md

5 examples and 15 blank rows, with a How to use tab in the .xlsx

Sanity: 5 worked examples
IDChange checkedCheckStepsExpected resultStatusNotes
SAN-01Fix: discount code ignored at checkoutThe discount applies
  1. Add a product to the cart
  2. Enter the code SAVE10 at checkout
The total drops by 10% and the code shows under the total.Passed
SAN-02Fix: discount code ignored at checkoutAn expired code is refused
  1. Enter an expired code at checkout
A message says the code has expired, and the total is unchanged.Passed
SAN-03Fix: discount code ignored at checkoutRemoving the code restores the total
  1. Apply SAVE10
  2. Select Remove next to the code
The total returns to the full price.Passed
SAN-04New: delivery date on product pagesThe date shows
  1. Open a product that is in stock
An estimated delivery date shows under the price.FailedDate missing on mobile
SAN-05New: delivery date on product pagesOut of stock shows no date
  1. Open a product that is out of stock
No delivery date shows, and the page says when it is back.Passed

FlowQA's agent explores your site and writes cases like this one as tests, keeping each only once it has passed twice and failed on a deliberately broken page. Free to start.

Try FlowQA free

The manual case

SMK-02 A registered user can sign in

  1. Open Sign in
  2. Enter a test account's email and password
  3. Select Sign in

Expected: the account page opens with the user's name.

The FlowQA test

account/sign-in

  1. navigate "/sign-in"
  2. fill "Email" with "mia@acme.example"
  3. fill "Password" with "••••••••"
  4. tap button "Sign in"
  5. assert url matches "/account"
  6. assert text "Mia Chen" is visible

An illustration with sample data.

A sanity test checks one change narrowly: that a fix or a small new feature works, and that the things right next to it still do. This page shows a sanity test template with five worked examples for an example online shop, and gives it to you as an Excel workbook, a CSV file or Markdown.

How to use it#

  1. Read the examples above. Each row names the change it checks in the Change checked column, so one release can hold several changes.
  2. Select Download .xlsx for a workbook with a How to use tab, the examples and 20 blank rows, or Download .csv to import the rows into another tool.
  3. For each fix or change in a build, add a few rows: the change itself, the case that used to fail, and one or two things beside it.
  4. Run them as soon as the build arrives, and set Status as you go.

What a sanity test is for#

When a developer says a bug is fixed, a sanity test is the quick check that it really is, before anyone spends time on a full pass. The examples show two changes. For a fixed discount code, they check that the code applies, that an expired code is still refused, and that removing the code restores the total. For a new delivery date on product pages, they check that the date shows, and that an item out of stock shows none. One of those rows failed on mobile, and its note says what was seen, which is what the developer needs to fix it.

Writing good rows#

Name the change in words someone outside the team would understand, or paste the ticket's title. Include the case that was reported, written so that it fails on the old build and passes on the new one. Add the neighbours: the same screen with different input, and the step right after the fixed one. Keep it narrow; if you find yourself checking the whole checkout, that is a regression test.

Questions#

What is the difference between sanity and regression testing?#

Sanity tests check one change quickly. Regression tests re-check features that already worked, across the whole app, so a change does not quietly break them.

Should sanity rows be kept after the release?#

The row for a reported bug is worth keeping: move it into your regression list so the bug cannot come back unnoticed.

Is the template free?#

Yes. Download it without an account and use it in your own plans and tools.