<?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>32 Statuses &#187; Methodology</title>
	<atom:link href="http://www.32statuses.com/category/methodology/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.32statuses.com</link>
	<description>The good, the bad, and the ugly of software development.</description>
	<lastBuildDate>Mon, 11 Oct 2010 01:53:35 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Code coverage metrics</title>
		<link>http://www.32statuses.com/2010/08/code-coverage-metrics/</link>
		<comments>http://www.32statuses.com/2010/08/code-coverage-metrics/#comments</comments>
		<pubDate>Sun, 08 Aug 2010 20:29:41 +0000</pubDate>
		<dc:creator>Jack Littleton</dc:creator>
				<category><![CDATA[Methodology]]></category>
		<category><![CDATA[metrics]]></category>
		<category><![CDATA[unit testing]]></category>

		<guid isPermaLink="false">http://www.32statuses.com/?p=539</guid>
		<description><![CDATA[A common evil that often rides along with unit testing is the unit testing metric. These metrics come in many flavors, including percent code coverage, number of tests and percentage of tests passing. Like any statistic, there is the potential for misuse and misinterpretation, which is the point of a post on Javalobby titled &#8220;Effective [...]]]></description>
			<content:encoded><![CDATA[<div id="attachment_555" class="wp-caption alignright" style="width: 160px"><a href="http://www.32statuses.com/wp-content/uploads/2010/08/Big_Unit_2009.png"><img class="size-full wp-image-555" title="Big_Unit_2009" src="http://www.32statuses.com/wp-content/uploads/2010/08/Big_Unit_2009.png" alt="" width="150" height="243" /></a><p class="wp-caption-text">Randy Johnson (The Big Unit)</p></div>
<p>A common evil that often rides along with unit testing is the unit testing metric. These metrics come in many flavors, including percent code coverage, number of tests and percentage of tests passing. Like any statistic, there is the potential for misuse and misinterpretation, which is the point of a post on <a href="http://java.dzone.com">Javalobby</a> titled &#8220;<a href="http://java.dzone.com/articles/effective-code-coverage-and">Effective Code Coverage (and Metrics in General)</a>&#8220;.</p>
<blockquote><p><strong>Management mandates to have X% of code coverage.</strong><br />
&#8230; Upper management, without a  clue about the health of the codebase, mandates that developers should  reach X% of code coverage. Period. &#8230; In many cases, when the codebase was not designed with testability in mind, I’ve seen developers writing a lot of test cases, <em>without any assertions</em>! All the tests pass, and the code coverage goal is met.</p></blockquote>
<p>This seems like a pretty easy problem to solve. Review the unit tests. Ensure that there are actual assertions (i.e. tests) going on inside each test method. Problem solved.</p>
<p>Unit tests are code. Just as code should be reviewed, both by peers and architects, so should unit tests.</p>
<p>I have never seen this happen.  However, if I ever do encounter it, here&#8217;s what I would do (in this specific order):</p>
<ol>
<li>Re-examine the company&#8217;s culture of mandating unit testing, and determine what it was that would cause otherwise reputable developers (you don&#8217;t hire anything but, right?) to go to such lengths to play the system.</li>
<li>If you can&#8217;t find anything wrong with the company&#8217;s culture, look harder. A good, honest developer will not do this unless pushed to the limit. Are there abstract and unrealistic deadlines being set? Do they have the tools they need to write the tests? How about training?  The company, from the top executive down, must embrace and support developer-driven testing.</li>
</ol>
<p>What I have seen, however, are projects with a lack of unit tests. This is almost always due to technical leadership failing (architects and team leads) to emphasize the importance of user testing, or the aforementioned lack of executive sponsorship.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.32statuses.com/2010/08/code-coverage-metrics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Eureka II: Why pair programming rubs me the wrong way</title>
		<link>http://www.32statuses.com/2010/01/eureka-ii-why-pair-programming-rubs-me-the-wrong-way/</link>
		<comments>http://www.32statuses.com/2010/01/eureka-ii-why-pair-programming-rubs-me-the-wrong-way/#comments</comments>
		<pubDate>Wed, 27 Jan 2010 06:23:41 +0000</pubDate>
		<dc:creator>Jack Littleton</dc:creator>
				<category><![CDATA[Methodology]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[eureka]]></category>
		<category><![CDATA[pair programming]]></category>
		<category><![CDATA[xp]]></category>

		<guid isPermaLink="false">http://www.32statuses.com/?p=360</guid>
		<description><![CDATA[I&#8217;ve never liked the idea of pair programming.  I was involved with it once, and it was a complete cluster [expletive deleted]. But even ignoring those experiences, I still have a visceral reaction to hearing the words &#8220;pair programming&#8221;. It wasn&#8217;t until I read a blog titled &#8220;50 Strategies For Making Yourself Work&#8221; that it [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.32statuses.com/wp-content/uploads/2010/01/performance_anxiety.jpg"><img class="alignright size-medium wp-image-368" title="performance_anxiety" src="http://www.32statuses.com/wp-content/uploads/2010/01/performance_anxiety-225x300.jpg" alt="" width="225" height="300" /></a>I&#8217;ve never liked the idea of <a title="Not to be confused with Pear Programming." href="http://www.extremeprogramming.org/rules/pair.html">pair programming</a>.  I was involved with it once, and it was a complete cluster [<a title="Ask yourself, what would Nixon think about pair programming?" href="http://www.amazon.com/Expletive-Deleted-Good-Look-Language/dp/0743274342">expletive deleted</a>]. But even ignoring those experiences, I still have a visceral reaction to hearing the words &#8220;pair programming&#8221;. It wasn&#8217;t until I read a blog titled &#8220;<a href="http://www.sfwa.org/2005/01/50-strategies-for-making-yourself-work/">50 Strategies For Making Yourself Work</a>&#8221; that it dawned on me.  It was the following quote:</p>
<blockquote><p>You’ll be less likely to slack off if someone else is counting on you to perform.</p></blockquote>
<p><!-- BODY { FONT-FAMILY:Tahoma; FONT-SIZE:10pt } P { FONT-FAMILY:Tahoma; FONT-SIZE:10pt } DIV { FONT-FAMILY:Tahoma; FONT-SIZE:10pt } TD { FONT-FAMILY:Tahoma; FONT-SIZE:10pt } -->What&#8217;s interesting is that this wasn&#8217;t an article about pair programing; it didn&#8217;t even have anything to do with software development.  But as I read this, I had the mental image of somebody standing over my shoulder, <a title="Every little thing I do is magic." href="http://www.lyricstime.com/sting-i-ll-be-watching-you-lyrics.html">watching every little thing I did</a>. I don&#8217;t work well in that situation. Yes, <a title="Could you turn away?" href="http://www.beachpsych.com/pages/cc68.html">performance anxiety</a>. Things that would have taken me five minutes to complete would then become ten.</p>
<p>I think the visceral reaction comes from the lack of trust that pair programming communicates. &#8220;You’ll be less likely to slack off if someone else is counting on you to  perform&#8221; means &#8220;you cannot be trusted to work on your own, so we&#8217;re going to set someone right beside you and have them watch your every move.&#8221; In my mind, knowing that someone is depending upon me to get something to them by the end of the day is all I need to get things done; I don&#8217;t need someone to watch over me as I do it. If knowing someone depends upon your work doesn&#8217;t keep you from slacking off, why would someone staring over your shoulder?</p>
<p>What are the other reasons?</p>
<ol>
<li><span style="text-decoration: underline;"><strong>You&#8217;ll have to have a 100% increase in productivity just to break even</strong></span>. Because there will now be two people doing the work of one, that &#8220;work unit&#8221; will need to become 100% more productive. While I do see some productivity increases in pairing (for example, catching the mistake of using a = instead of a ==, or other similar &#8216;typo&#8217; bugs), but I cannot imagine how paring would double productivity. And if the pair does manage to double their productivity, that&#8217;s just breaking even. No benefit.</li>
<li><span style="text-decoration: underline;"><strong>You lose your individuality</strong></span>. You&#8217;re now basically working with a <a title="Mornin', Ralph." href="http://www.staples.com/Pyramid-Technologies-TimeTrax-EZ-Time-Clock/product_645518?cm_mmc=GoogleBase-_-Shopping-_-Technology%3ETime_Clocks_Recorders_%26_Cards-_-645518-TTEZ">punch clock</a>, given that you have to coordinate your time with your pair. Let&#8217;s say you&#8217;re used to varying your commute time based upon traffic conditions. No more, now that you have to arrive (and leave) with your pair. Need to duck out to see your kid&#8217;s school play, go to the doctor, just get out of the office for a while and <a title="Best coffee EVAR" href="http://www.itsagrind.com/">grab a coffee</a>. Nope, no way, nada. You&#8217;ve become a sycophant in the corporate rat race. Yes, the people you use to laugh at. Now you&#8217;re one of them, thanks to pairing.</li>
<li><strong><span style="text-decoration: underline;">With the loss of individuality comes the loss of creativity</span></strong>. Having a pair will impact your trial-and-error process (because nobody likes to have people watch their failures, and trial-and-error is more error than anything else), as well as the time you just need to sit there and think something out. Yes, sometimes a pair will be useful when thinking something (particularly with the hard stuff), but most of the time it isn&#8217;t.</li>
<li> <span style="text-decoration: underline;"><strong>Interrupaloosa!</strong></span> You&#8217;ve managed to figure something out, you&#8217;re typing away wildly, your hands barely keeping up with your thought process when: &#8220;Um, hey, wait. What does that do?&#8221; says your pair. The sound you hear are the boxcars of your thought process being crushed as the train flies off the tracks. Interruptions from the general business day are bad enough, but when you&#8217;re joined at the hip by an endless stream of interruptions, you&#8217;re productivity is going to plummet. Just like your train of thought goes rolling end over end down the steep canyon.</li>
</ol>
<p>So there you go. There are my reasons for not liking pair programming. I&#8217;m standing by, awaiting the Agile police to come and take me away for having the audacity to doubt The One True Methodology.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.32statuses.com/2010/01/eureka-ii-why-pair-programming-rubs-me-the-wrong-way/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why unit testing alone is not enough</title>
		<link>http://www.32statuses.com/2010/01/why-unit-testing-alone-is-not-enough/</link>
		<comments>http://www.32statuses.com/2010/01/why-unit-testing-alone-is-not-enough/#comments</comments>
		<pubDate>Thu, 07 Jan 2010 06:52:47 +0000</pubDate>
		<dc:creator>Jack Littleton</dc:creator>
				<category><![CDATA[Methodology]]></category>
		<category><![CDATA[maven]]></category>
		<category><![CDATA[refactoring]]></category>
		<category><![CDATA[subversion]]></category>

		<guid isPermaLink="false">http://www.32statuses.com/?p=130</guid>
		<description><![CDATA[Sometimes we can fall into a false sense of security when we see all our unit tests pass. But sometimes we forget that the application must also run, and unit tests do not cover that.]]></description>
			<content:encoded><![CDATA[<p>Sometimes we can fall into a false sense of security when we see all our unit tests pass. But sometimes we forget that the application must also run, and unit tests do not cover that.</p>
<div id="attachment_293" class="wp-caption alignright" style="width: 160px"><a href="http://www.32statuses.com/wp-content/uploads/2009/11/facepalm.jpg"><img class="size-thumbnail wp-image-293" title="facepalm" src="http://www.32statuses.com/wp-content/uploads/2009/11/facepalm-150x150.jpg" alt="facepalm" width="150" height="150" /></a><p class="wp-caption-text">Urgh.</p></div>
<p>There was a refactoring push recently to smooth out the build process for a web application I work with. The .war file being generated was getting bloated, and it was due to many unneeded .jar files being included during the build. The refactoring process involved using some dependency-checking functions with <a href="http://maven.apache.org/">maven</a>.  It was a labor-intensive and iterative process. After a few days, it was thought that the effort had completed.  After all, maven was no longer complaining about either unreferenced .jars, or required .jars not being found. Not only were there no compile errors, there weren&#8217;t any warnings, either. Things looked very good.</p>
<p>That is, until we deployed and tried to start the server.  The application server barfed almost immediately after starting the application.  The problem: overzealous removal of .jar files from the project&#8217;s .pom file. The root problem was that we were looking at compile-time dependencies to determine if .jar files could be removed, we weren&#8217;t taking runtime dependencies into account.  The fix was to include the dependent .jar files with a &#8220;runtime&#8221; scope in our .pom files.</p>
<p>The moral of this story is that while unit tests are great, and an amazing tool to reduce project defect count (particularly when used in conjunction with <a href="http://www.agiledata.org/essays/tdd.html">Test Driven Development</a>), it&#8217;s not the end-all test tool. In this case, the .pom files, as well as any other changes from the refactor, should not have been committed to source control until after the application was actually deployed (locally, on the developer&#8217;s workstation), and put through it&#8217;s paces.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.32statuses.com/2010/01/why-unit-testing-alone-is-not-enough/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

