<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Gojko Adzic &#187; agile</title>
	<atom:link href="http://gojko.net/tag/agile/feed/" rel="self" type="application/rss+xml" />
	<link>http://gojko.net</link>
	<description>Building software that matters</description>
	<lastBuildDate>Wed, 04 Aug 2010 11:38:56 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Clean Acceptance Tests, August 3rd, central London</title>
		<link>http://gojko.net/2010/07/26/clean-acceptance-tests-august-3rd-central-london/</link>
		<comments>http://gojko.net/2010/07/26/clean-acceptance-tests-august-3rd-central-london/#comments</comments>
		<pubDate>Mon, 26 Jul 2010 19:04:51 +0000</pubDate>
		<dc:creator>gojko</dc:creator>
				<category><![CDATA[articles]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[agile testing]]></category>

		<guid isPermaLink="false">http://gojko.net/?p=1956</guid>
		<description><![CDATA[The next meeting of the UK agile testing user group is on the 3rd of August in central London. Here are the details of the talk: Dan Leong on Clean Acceptance Tests This presentation discusses how our agile team renewed our focus and understanding of our acceptance tests when the team members changed. Our group [...]]]></description>
			<content:encoded><![CDATA[<p>The next meeting of the UK agile testing user group is on the 3rd of August in central London. Here are the details of the talk:</p>
<h2>Dan Leong on Clean Acceptance Tests</h2>
<p>This presentation discusses how our agile team renewed our focus and understanding of our acceptance tests when the team members changed. Our group found some core shared values in the context of acceptance testing which we expressed in the style of the agile manifesto. We then looked at our existing tests to find bad test smells that we could learn from. The whole exercise was a good experience and we encourage you to try something similar in your teams.</p>
<p>Dan Leong is a team lead at Sky Network Services, where they have been using agile/XP techniques for over 4 years to deliver the company&#8217;s broadband and voice provisioning system. He has over 10+ experience working in companies ranging from small .com start-ups to global advertising and media companies. Like the rest of us, he&#8217;s trying to figure out how to do things better.</p>
<p>The event is free to attend, but up front registration is required. <b><a href="http://tinyurl.com/2w3hbhw">Register now</a></b></p>
]]></content:encoded>
			<wfw:commentRss>http://gojko.net/2010/07/26/clean-acceptance-tests-august-3rd-central-london/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Guardian pulling the plug?</title>
		<link>http://gojko.net/2010/07/21/guardian-pulling-the-plug/</link>
		<comments>http://gojko.net/2010/07/21/guardian-pulling-the-plug/#comments</comments>
		<pubDate>Wed, 21 Jul 2010 11:58:00 +0000</pubDate>
		<dc:creator>gojko</dc:creator>
				<category><![CDATA[articles]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[cloud computing]]></category>
		<category><![CDATA[ddd]]></category>
		<category><![CDATA[guardian]]></category>
		<category><![CDATA[thoughtworks]]></category>

		<guid isPermaLink="false">http://gojko.net/?p=1936</guid>
		<description><![CDATA[The Unite union (of the let&#8217;s screw BA travellers for several weeks every few months fame) created a Facebook group to stop jobs in the technology department being outsourced and offshored at Guardian News Media Ltd, publisher of the Guardian, the Observer and guardian.co.uk. According to the group web site, the board of Guardian News [...]]]></description>
			<content:encoded><![CDATA[<p>The Unite union (of the let&#8217;s screw BA travellers for several weeks every few months fame) created a<br />
<a href='http://www.facebook.com/group.php?gid=102289763160121&#038;v=info'>Facebook group to stop jobs in the technology department being outsourced and offshored at Guardian News Media Ltd</a>, publisher of the Guardian, the Observer and guardian.co.uk. According to the group web site, the board of Guardian News Media is meeting tomorrow to make a decision on outsourcing a large part of their IT department.</p>
<p>Without taking a position on who&#8217;s right or wrong in this case, I&#8217;m very interested in how this whole thing is going to play out. A recent major rewrite of <a href='http://www.guardian.co.uk'>their flagship web site</a> is one of the most publicised apparently successful IT projects in the UK.  <span id="more-1936"></span></p>
<p>Amazon uses them as <a href='http://aws.amazon.com/solutions/case-studies/guardian/'>a case study for cloud computing</a>. </p>
<p>Phil Willis spoke at several conferences, including Qcon London last year, on how applying domain driven design on this project <a href='http://www.infoq.com/presentations/rebuild-guardian-ddd-wills'>helped domain experts to get involved in software development, and how they maintained a deep, malleable domain model, whilst meeting deadlines</a>. This is one of the <a href='http://domaindrivendesign.org/node/155'>key case studies used by the Domain Driven Design community to prove that DDD works</a>.</p>
<p>ThoughtWorks use them as a <a href='http://www.thoughtworks.com/guardian-qtb'>reference of how they help big companies implement agile processes</a>. On the back of that project, they got to do the same with <a href='http://www.tradermediagroup.com/2009/02/auto-trader-redesigns-website-with-sapient-thoughtworks-2/'>AutoTrader</a>, ran by a Guardian subsidiary Trader Media. Their web site <a href='http://www.thoughtworks.com/guardian'>quotes Tom Turcan</a>, General Manager for Digital: “A multi-million pound project running on time, and absorbing growth in scope – remarkable”.</p>
<p>A common thread here is that DDD, clouds, agile apparently gave better service more efficiently and produced more business value for the same investment. If the Guardian News Media board is now thinking of pulling the plug on all that, then that is seriously casting a shadow on those claims. Cloud computing aside, both Domain Driven Design and Agile development rely heavily on on-site close collaboration of business users and IT development teams. I guess a multi-million pound project running on time, and absorbing growth in scope, is less remarkable than the money they expect to save by sending the jobs abroad. Or maybe this is a confirmation that their new web site runs on its own and doesn&#8217;t need that many people to maintain it.</p>
<p>Update (2:30 PM) <a href="http://www.theregister.co.uk/2010/07/21/guardian_strike_threat/">The Register picked up the story this morning as well </a></p>
]]></content:encoded>
			<wfw:commentRss>http://gojko.net/2010/07/21/guardian-pulling-the-plug/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Stop automating manual test scripts!</title>
		<link>http://gojko.net/2010/07/19/stop-automating-manual-test-scripts/</link>
		<comments>http://gojko.net/2010/07/19/stop-automating-manual-test-scripts/#comments</comments>
		<pubDate>Mon, 19 Jul 2010 10:54:41 +0000</pubDate>
		<dc:creator>gojko</dc:creator>
				<category><![CDATA[articles]]></category>
		<category><![CDATA[acceptance testing]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[agile testing]]></category>
		<category><![CDATA[specification by example]]></category>

		<guid isPermaLink="false">http://gojko.net/?p=1917</guid>
		<description><![CDATA[Creating an Executable Specification from existing manual test scripts might seem as a logical thing to do when starting out with Specification by Example and Agile Acceptance Testing. Such scripts already describe what the system does, and the testers are running them anyway, so automation will surely help. Not really &#8212; this is in fact [...]]]></description>
			<content:encoded><![CDATA[<p>Creating an <a href="http://www.acceptancetesting.info/key-ideas/executable-specifications/">Executable Specification</a> from existing manual test scripts might seem as a logical thing to do when starting out with Specification by Example and Agile Acceptance Testing. Such scripts already describe what the system does, and the testers are running them anyway, so automation will surely help. Not really &mdash; this is in fact one of the most common failure patterns.<span id="more-1917"></span></p>
<p>The problem is that manual and automated checks are affected by a completely different set of constraints. With manual testing, the time spent preparing the context is often a key bottleneck. With automated testing, people spend most time on understanding what is wrong when a test fails.</p>
<p>For example, to prepare for a manual test that checks user account management rules, you might have to log on to an administrative application, create a user, log on as that new user to the client application, and change the password after first use. To avoid doing this several times during the test, manual scripts often reuse the context. So you would create the user once, block that account and verify that the user cannot log on, reset the password to verify that it is re-enabled, then set some user preferences and verify they change the home page correctly. This approach helps a tester run through the script quicker.</p>
<p>With automated testing, time spent on setting up the user is no longer a problem. Automated tests generally go through many more cases than manual tests, and when they run correctly nobody is really looking at them. Once a test fails, someone has to go in and understand what went wrong. If a test is described as a sequence of interdependent steps, it will be very hard to understand what exactly caused the problem, because the context changes throughout the script. The fact that a single script is checking ten different things also makes it more probable that the test will fail because it is affected by lots of different areas of code. In the previous example with user account management, if the password reset function stops working, we won&#8217;t be able to set the user preferences correctly.  If we had ten different, smaller, focused and independent tests instead of one big script, a bug in the password reset function won&#8217;t affect the test results for user preferences. That makes tests more resilient to change and reduces the cost of maintenance. It also helps us pin-point the problems quicker.  </p>
<p>Instead of plainly automating manual test scripts, think about what the script is testing and describe that with a group of independent, focused tests. This will significantly reduce the automation overhead and maintenance costs.</p>
]]></content:encoded>
			<wfw:commentRss>http://gojko.net/2010/07/19/stop-automating-manual-test-scripts/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to do agile when we only have 50 crap developers?</title>
		<link>http://gojko.net/2010/07/05/how-to-do-agile-when-we-only-have-50-crap-developers/</link>
		<comments>http://gojko.net/2010/07/05/how-to-do-agile-when-we-only-have-50-crap-developers/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 06:28:38 +0000</pubDate>
		<dc:creator>gojko</dc:creator>
				<category><![CDATA[articles]]></category>
		<category><![CDATA[agile]]></category>

		<guid isPermaLink="false">http://gojko.net/?p=1915</guid>
		<description><![CDATA[Why do people complaining that they can&#8217;t do agile development with 50 crap developers not see that the problem is in the second part of that statement, not the first? I got an e-mail last week that shows the point perfectly: We discussed whether an agile approach is right, and I concluded that not everyone [...]]]></description>
			<content:encoded><![CDATA[<p>Why do people complaining that they can&#8217;t do agile development with 50 crap developers not see that the problem is in the second part of that statement, not the first? I got an e-mail last week that shows the point perfectly: </p>
<blockquote><p>
We discussed whether an agile approach is right, and I concluded that not everyone can work that way.
</p></blockquote>
<p>Quite true. I find it self-evident that not everyone can do software development, agile or any other way. That requires brains, knowledge, experience is a plus, and hopefully some talent as well. And of course, there is no generic approach that works in every context.</p>
<blockquote><p>
We think that an agile approach asks programmers to be much more engaged than when they&#8217;re just being served what to do
</p></blockquote>
<p>It&#8217;s hard for me to make a comparison to answer this. I&#8217;ve always tried to be very engaged in my own work and I expected the same from everyone else working with me, even before I ever did anything resembling agile. I&#8217;ve never seen a project where people were asked not to be engaged into what they need to do, but out of general principle I would refuse to participate in one. </p>
<p>If your programmers aren&#8217;t engaged and they get everything served to them, your problem is right there. It is not in a process, agile or non agile.</p>
<blockquote><p>
Which means the choice of people is very important
</p></blockquote>
<p>I completely agree. Once again, this isn&#8217;t particularly specific to agile software development approaches &#8211; or even software development at all. This is important for any craft. My former colleague Relja Jovic, who was the executive editor at PC World Yugoslavia when I worked there, used to say &#8220;From shit, you can only make a shit pie&#8221; whenever we were asked to get someone unqualified to write an article (&#8220;how hard can it be?&#8221;). That holds true for programming, testing, analysis, project management and anything else to do with delivering software. With crap people, you get crap output. Tough luck. Maybe hire people who know how to deliver software instead?</p>
]]></content:encoded>
			<wfw:commentRss>http://gojko.net/2010/07/05/how-to-do-agile-when-we-only-have-50-crap-developers/feed/</wfw:commentRss>
		<slash:comments>19</slash:comments>
		</item>
		<item>
		<title>Anatomy of a good acceptance test</title>
		<link>http://gojko.net/2010/06/16/anatomy-of-a-good-acceptance-test/</link>
		<comments>http://gojko.net/2010/06/16/anatomy-of-a-good-acceptance-test/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 02:50:00 +0000</pubDate>
		<dc:creator>gojko</dc:creator>
				<category><![CDATA[articles]]></category>
		<category><![CDATA[acceptance testing]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[agile testing]]></category>
		<category><![CDATA[live documentation]]></category>
		<category><![CDATA[specification by example]]></category>

		<guid isPermaLink="false">http://gojko.net/?p=1891</guid>
		<description><![CDATA[The long term benefits of agile acceptance testing come from live documentation – a description of the system functionality which is reliable, easily accessible and much easier to read and understand than the code. In order to be effective as live specification, acceptance tests have to be written in a way that enables others to [...]]]></description>
			<content:encoded><![CDATA[<p>The long term benefits of agile acceptance testing come from <a href="http://www.acceptancetesting.info/key-ideas/live-documentation/">live documentation</a> – a description of the system functionality which is reliable, easily accessible and much easier to read and understand than the code. In order to be effective as live specification, acceptance tests have to be written in a way that enables others to pick them up months or even years later and easily understand what they do, why they are there and what they describe. Here are some simple heuristics that will help you measure and improve your tests to make them better as a live specification.<span id="more-1891"></span></p>
<p>The five most important things to think about are:</p>
<ul>
<li>It needs to be self explanatory</li>
<li>It needs to be focused</li>
<li>It needs to be a specification, not a script</li>
<li>It needs to be in domain language</li>
<li>It needs to be about business functionality, not about software design</li>
</ul>
<p>Here is a really good example:</p>
<p><img src="http://gojko.s3.amazonaws.com/offer2.png" width="500" /></p>
<p>It has all the elements listed above. Whenever I&#8217;ve shown it to people in the workshops, I did not have to use a single word to explain it. The title and the introductory paragraph explain the structure of the test data enough that readers don&#8217;t need to work back from the data to understand the rule. But the examples are there to make it actually testable and explain the behaviour in edge cases. It is focused on a very particular rule of free delivery availability, does not explain how the books are purchased but just what the available delivery mechanism is, and does not try to talk about any implementation specifics.</p>
<p>Here is a really bad example (taken from <a href="http://fitnesse.org/FitNesse.UserGuide.PayrollTests.AddAndPayTest">http://fitnesse.org/FitNesse.UserGuide.PayrollTests.AddAndPayTest</a>)</p>
<p><img src="http://gojko.s3.amazonaws.com/bad_example_acceptance_test.png" /></p>
<p>This test has so many bad things in it that it is actually a good example to demonstrate what happens when people don&#8217;t take care about writing good tests. </p>
<p>First of all, although it has a title and some text around the tables to seemingly explain what&#8217;s going on, the effect of that is marginal. Why is this test &#8220;simple&#8221;, and what exactly in payroll is it checking? It fails straight away on the self-explanatory litmus-test.</p>
<p>Second, it&#8217;s not really clear what this test is checking. We need to work backwards. It seems to verify that the cheques are printed with unique numbers, starting from the next available number that&#8217;s configurable in the system. It also seems to validate the data printed on each cheque. And that there is one cheque printed per employee (I&#8217;ll come back to this later).</p>
<p>There is a lot of seemingly incidental complexity there &#8211; names and addresses aren&#8217;t really used anywhere in the test apart from setting up the employees. There are some database IDs there which are completely irrelevant for the business rules, but they are used to match up employees and the paycheck inspector. </p>
<p>Paycheck inspector is obviously an invented thing just for testing. No company is going to have Peter Sellers in a Clouseau outfit inspecting cheques as they go out. If you have enough employees to have to print cheques, you don&#8217;t want to inspect them manually. That&#8217;s what this test is about, anyway.</p>
<p>There is also a very interesting issue of those blank cells in the assertion part of the test, and the two Paycheck inspector tables which seem unrelated. Blank cells in Fitnesse are used to print test results for debugging and troubleshooting, they don&#8217;t check anything. So this is an automated test that a human has to look over &mdash; pretty much defeating the purpose of automation. Blank cells are typically a sign of instability in tests (more on this a bit later) and they are often a signal that you&#8217;re missing something &#8211; either testing in the wrong place or missing a rule that would help make the system process repeatable and testable.</p>
<p>The language is inconsistent, which makes it hard to make a connection between inputs and outputs at first. What is the 1001 value in the table below? The column header tells us that it is a number &#8211; well thanks for that, I though it was a sausage. There is a &#8220;cheque number&#8221; above, but what kind of a cheque number is that? What is the relationship between these two things?</p>
<p>So this test is very very bad. </p>
<p>Presuming that the addresses are there because cheques are printed as part of a statement with an address ready for automated envelope packaging, this test fails to check at least one very important thing (and I&#8217;ll come back to this later as well): that the right people got paid the right amounts. If the first person got both cheques, this test would happily pass. If they both got each-others salaries, this test would pass. If a date far in the future was printed on the cheque, our employees might not be able to cash it in but the test would still pass. The reason these cells are blank is because there is another hidden rule there: ordering of cheques coming out. There is nothing specifying that. So a technical workaround for a functional gap is to create a test that gives us loads of false positives.</p>
<p>Is this test checking one thing or many things? Without the context information it&#8217;s hard to tell. If the cheque printing system is used for anything else, I&#8217;d pull out the fact that cheque numbers are unique and start from a configured number into a separate page. If we only ever print salary cheques, it&#8217;s probably part of a single thing (salary cheque printing).</p>
<p>Now, let&#8217;s clean it up. Let&#8217;s try to work back and drop all the incidental stuff. Let&#8217;s use a nice descriptive title, such as &#8220;Payroll Cheque Printing&#8221;. And let&#8217;s add a paragraph that explains the structure of the test.</p>
<p>A cheque has the payee name, amount, payment date. A cheque does not have a name and a salary. If the cheque is printed on a statement, it also has an address that will be used for automatic envelope packaging. A combination of a name and address should be enough for us to match the employee with his cheque &mdash; we don&#8217;t really need the database IDs. We can make the system more testable by agreeing on an ordering rule, whatever it is. For example, alphabetic by name.</p>
<p>Let&#8217;s also pull the context to the start of the test. Our context is the payroll date and the next available cheque number, along with employee salary data. Let&#8217;s make it explicit what the number is for, so that the readers don&#8217;t have to figure this out for themselves in the future. We can also make this block stick out visually to show that it is about the context.</p>
<p>The action that gets kicked off doesn&#8217;t necessarily need to be listed in the test. A payroll run can be executed implicitly by the table that checks payroll results. This is an example of focusing on what&#8217;s being tested instead of how it is being checked. There is no need to have a separate step that says &#8220;Next we pay them&#8221;.</p>
<p>Let&#8217;s also rename that paycheck inspector to something that makes more sense. Because we want whoever automates this to ensure that we check for all cheques printed, let&#8217;s put that in the header. Otherwise, someone might use subset matching and the system might print every cheque twice and we won&#8217;t notice.</p>
<p>And here is the cleaned version. </p>
<p><img src="http://gojko.s3.amazonaws.com/fixed_acceptance_test.png" width="500" /></p>
<p>Much easier to understand, without all that incidental stuff.  And now comes the punchline. When we look at the test like this, without database IDs, without all the unnecessary clutter, we can have a nice shot at answering the question &#8220;Are we missing something?&#8221;. What are the edge cases that might break this? We don&#8217;t really need to ensure validity of employee data, hopefully that&#8217;s done in another part of the system. But is there any kind of valid employee data that would be an edge case for this test &#8211; can we play with the numbers to make this illogical in some way?</p>
<p>An obvious answer to that is &#8211; what happens if an employee has a salary of 0? Do we still print the cheque? The rule as we described it says &#8220;One cheque per employee&#8221; &#8211; so any employees that have been fired years ago and no longer receive salaries would still get cheques printed, with zeroes on them. We could then have a discussion with the business on making this rule stronger and ensuring that cheques don&#8217;t go out when they don&#8217;t need to do.</p>
<p>FitNesse gets a lot of bad reputation because of this kind of broken tests. Concordion was built as an answer. Some people at my recent workshop on this example pointed out that Given-When-Then structure of Cucumber would be better at preventing some of these problems.  I don&#8217;t think so. It&#8217;s not about the tools &#8211; people can do this kind of bad test design with any tool, and likewise they could do nice and clean tests with FitNesse. I guess the fact that the basic examples coming with FitNesse are so bad doesn&#8217;t help, but the problem is not in the tool. It&#8217;s about the process and effort put into making the tests easy to understand. The funny thing is it doesn&#8217;t take a lot more effort to make the test nice and clean, but it brings a lot more value that way.   </p>
<p><i>If you found this article helpful, you&#8217;ll love my <a href="http://neuri.co.uk/training/hands-on-agile-acceptance-testing/">three day workshop on effective specification by example and agile acceptance testing</a></i></p>
]]></content:encoded>
			<wfw:commentRss>http://gojko.net/2010/06/16/anatomy-of-a-good-acceptance-test/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
	</channel>
</rss>
