Bigsun Technologies logo

Bigsun Udaan › Business analysis guides › User Story and Acceptance Criteria Example

Worked example

A sample user story with acceptance criteria

A user story describes what a person needs, in everyday words. Acceptance criteria say exactly how we will know it has been done properly.

The format

As a [type of user], I want [something], so that [benefit].

Example

Story LM-01 — Apply for leave

As an employee, I want to apply for leave online, so that my manager can approve it without long email chains.

Acceptance criteria

Each criterion can use the pattern Given (the starting point), When (the action), Then (the result).

  1. Given I am signed in and have 5 days of balance, when I submit a 2-day request with valid dates, then the request is saved with the status “Pending” and I see a confirmation message.
  2. Given I have 1 day of balance, when I request 3 days of paid leave, then the system does not submit the request and tells me my balance is not enough.
  3. Given I am filling in the form, when I choose an end date earlier than the start date, then the system shows a clear error message next to the date.
  4. Given I submit a valid request, when it is saved, then my manager receives a notification.
  5. Given I leave a required field empty, when I press Submit, then the empty field is highlighted and the request is not submitted.

What makes a good story? (the INVEST checklist)

LetterMeaningQuestion to ask
IIndependentCan it be built without waiting for another story?
NNegotiableIs it about the need, rather than fixing every detail?
VValuableDoes it matter to a real user?
EEstimableIs it clear enough for a team to judge the effort?
SSmallCan it be finished in a short period of time?
TTestableCan we write a test to show it works?

Template you can copy

Story ID and title: ________________

As a ________________, I want ________________, so that ________________.

Acceptance criteria:

  1. Given ________ when ________ then ________.
  2. Given ________ when ________ then ________.
  3. Given ________ when ________ then ________.

Notes, assumptions and open questions: ________________

Practice

  1. Write a user story for the manager approving or rejecting a leave request. Add at least three acceptance criteria.
  2. Write a user story for the Sunrise Stationers store keeper who wants to see urgent orders first (from the process exercise).
  3. Check each story against the INVEST checklist. Is any story too big?

Original educational material created by Bigsun Technologies for the Bigsun Udaan initiative. The people, companies and figures in the examples are fictional. This is a learning aid, not an accredited course or a guarantee of employment.