Skip to content

Instantly share code, notes, and snippets.

@jwieringa
Created September 1, 2012 21:37
Show Gist options
  • Save jwieringa/3588181 to your computer and use it in GitHub Desktop.
Save jwieringa/3588181 to your computer and use it in GitHub Desktop.
Ripped from Specification by Example

Step 1

Identify what the business goal is for building software.

Business goal

Increase repeat sales to existing customers by 50% over the next 12 months

Step 2

From the business goal, derive the scope of the feature(s)

Scope: User stories for a basic loyalty system

As a marketing manager
I want customers to register personal details by join gin a VIP program
In order to be able to do direct marketing of products to existing customers
As a marketing manager 
I want the system to offer **free delivery** on certain items to VIP customers
In order to entice existing customers to register for the VIP program
As an existing customer
I want to receive information on available special offers
In order to save money

Step 3

With the business owner, product owner, developers, and tester create key examples that describe feature. The below builds off from story #2. In these key examples we are coming to an agreement on what we mean by free delivery.

Key Examples: Free delivery

VIP customer with five books in the cart gets free delivery
VIP customer with four books in the cart doesn't get free delivery.

Step 4

Refine the specification using the key examples. This document should be self-explanatory and formatted in a way that will make it easy to automate.

Specification with examples: Free Delivery

Free delivery is offered to VIP customers once they purchase a certain number of books.
Free delivery is not offered to regular customers or VIP customers buying anything other than books
Given that the minimum number of books to get free delivery is five
Then we expect the following: 
  | Customer Type | Cart Contents      | Delivery       |
  | VIP           | 5 books            | Free, Standard |
  | VIP           | 4 books            | Standard       |
  | Regular       | 10 books           | Standard       | 
  | VIP           | 5 Blenders         | Standard       |
  | VIP           | 5 Books, 1 Blender | Standard       |
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment