Agileista

Inciting the Agile Revolution

Testing user stories

Posted by Eben Halford Mon, 31 Mar 2008 19:55:00 GMT

Having had some time to myself recently, I've been reflecting on all the weird and wonderful implementations of Agile/Scrum that I've either; heard about, observed or been directly involved with. In doing this I've been reminded that it's all to easy to overcomplicate your agile process. In some cases even ignoring what could be considered the basics all together, without first trying them. One that I was reminded of recently is testing.

Why test?
Well it seems obvious doesn't it - we test stuff to see if it works. More than that we have tests and criteria so that we can see just how well it works and how healthy the work is. We test so that we can deliver value through quality software. So that we know what level of quality we are achieving; testing is one slice of the quality cake, a leading indicator of code and functional quality and sometimes lagging indicator of quality issues.

Creating acceptance tests also allows the Product Owner and the Team to explore the requirements and behavior together - its part of the conversation that they have when fleshing out the requirement before an iteration.

What is testing?
There are two main sides to testing and both are about delivering value . Above the waterline you have quality indicators that are visible to everyone. These deal with the experiential quality of the story. Below the waterline is code quality testing. This helps us to understand how expensive development and maintenance of the code is. A good agile or scrum implementation uses Acceptance Criteria or Q&A style functional black box testing, adding code testing such as unit testing and continuous integration. Omitting to do either side of this testing can have some pretty negative consequences.

Different types of testing

Acceptance criteria cover the visible or functional above the waterline tests. Validating functional correctness of the story. By defining how the story will interact with the user and visa versa the Product Owner (PO) can test for expected functionality. Acceptance criteria can also define any restrictions in functionality: for example, only accepting Visa for an ecommerce payment story or stating that no registrations can come from a web based email account.

From the team's perspective these tests also let the team know when they are ‘done’ with a story because if a story does not pass its Acceptance Criteria, it is not accepted as complete by the customer or Product Owner. If this happens the team are not awarded the estimated points for the story and the story is considered to have not been delivered, remaining on the backlog until it is.

Acceptance tests can also be used for release and regression testing. This moves us nicely on to code quality and build quality testing. The team need to know that what they've coded won’t break everything. Continuous Integration checks the entire code base each time code is committed to the repository and Test driven development can help you to build safe to re-factor code that also conforms to the acceptance criteria tests. The quality state of the code-base will affect the complexity estimates the team make for a given story as much as anything.

If you make sure to get those acceptance criteria exposed and agreed before each Sprint then at least that gives you and your team the ability to implement as much or as little testing as needed. If you don’t have acceptance criteria then your options for testing and knowing if you're doing the right thing are limited. What are everyone else’s experiences of testing in an Agile or Scrum environment?

Posted in | no comments | Tags , , , , , , , | atom

Trackbacks

Use the following link to trackback from your own site:
http://www.agileista.com/trackbacks?article_id=testing-user-stories&day=31&month=03&year=2008

Comments

Leave a response

Leave a comment