.NET Tips and Tricks

Blog archive

Leveraging Acceptance Criteria When Writing Agile User Stories

As near as I can tell, everyone who's doing Agile is writing requirements in the user story format of "As <role> I need to <do something> so that I can <achieve some goal>." For example, "As a customer I need to be able to search the inventory so that I can find the products I want to buy."

It's worth remembering that this is just one format for user stories (and a very good one) -- you shouldn't be trying to force everything into that format (infrastructure or regulatory requirements often sound silly in this format: "As the VP of Finance I need to produce the list of transferred securities every month so that I don't go to jail").

There are some common extensions to this user story format. Popular ones are a "best before" date (for time constrained requirements) and acceptance criteria. The primary purpose of acceptance criteria is to participate in the "definition of done": When these tests are passed, this story is done.

That means, of course, it should always be possible to imagine a test that would prove the criteria has been achieved (preferably an automated test, but that's not essential). Personally, an acceptance criteria of "I can do my job" fails on that "testability" basis alone: How could I tell if you can do your job? Perhaps you were never capable of doing your job.

Also personally, I think you can use acceptance criteria for more than that by leveraging those criteria to create better stories.

One thing you can do with acceptance criteria is use them to provide detail for the user story. This allows you to keep the user story short (focusing on the main goal) but still record detail that matters to the user. For example, this acceptance criteria helps make it clear what the story means by "search":

User Story: As a customer I need to be able to search the inventory so that I can find the products I want to buy.

Acceptance Criteria: Customers can limit the items returned by the search using criteria that are valuable to them (price, delivery date, location).

The other thing you can use acceptance criteria for is to cross-check the user story to see if it's consistent with its criteria. An acceptance test that isn't consistent with the user story can be an indication that the story is incomplete ... or is an example of scope creep (an attempt to extend the user story beyond its mandate). Something like this list of criteria indicates there's probably a problem with the user story:

User Story: As a customer I need to be able to search the inventory so that I can find the products I want to buy.

Acceptance Criteria:
  1. Customers can limit the items returned by the search using criteria that are valuable to them (price, delivery date, location).
  2. Customers earn loyalty points when purchasing "loyalty" products.

It seems to me that criteria 2 doesn't have much to do with the user story. Either the story needs to be extended (" ... including criteria that are important to them, like loyalty points") or there's a need for another story ("As a customer, I want to accumulate loyalty points").

Posted by Peter Vogel on 11/15/2019


comments powered by Disqus

Featured

  • Mads Kristensen Eyes MCP Server for Visual Studio Copilot

    "What MCP server would be helpful to use with Copilot in Visual Studio? I want to write one."

  • Two Different Takes on Cursor/Copilot Vibe Coding Supremacy

    Cursor and GitHub Copilot go head-to-head in a pair of firsthand reviews. One coder returns to Copilot after it adds support for top LLMs. A coding writer falls for Cursor’s conversational style and beginner-friendly flow.

  • Linear Regression with Two-Way Interactions Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of linear regression with two-way interactions between predictor variables. Compared to standard linear regression, which predicts a single numeric value based only on a linear combination of predictor values, linear regression with interactions can handle more complex data while retaining a high level of model interpretability.

  • Vibe Writing

    Why outline when you can prompt? Vibe writing is the new vibe coding, and yes, it’s exactly what it sounds like.

  • Next-gen SQL Projects with Microsoft.Build.Sql

    SQL development is evolving fast, and Microsoft's Drew Skwiers-Koballa will explain it all in a featured session at the VS Live! @ Microsoft HQ developer conference being held at the company's Redmond campus in August.

Subscribe on YouTube

Upcoming Training Events

0 AM
Visual Studio Live! San Diego
September 8-12, 2025
Live! 360 Orlando
November 16-21, 2025
Cloud & Containers Live! Orlando
November 16-21, 2025
Data Platform Live! Orlando
November 16-21, 2025
Visual Studio Live! Orlando
November 16-21, 2025