<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Tips for Unit Testing</title>
	<atom:link href="http://devver.net/blog/2008/07/tips-for-unit-testing/feed/" rel="self" type="application/rss+xml" />
	<link>http://devver.net/blog/2008/07/tips-for-unit-testing/</link>
	<description>A Boulder startup improving the way developers work.</description>
	<pubDate>Fri, 21 Nov 2008 04:14:46 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.3</generator>
		<item>
		<title>By: Doron</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-131</link>
		<dc:creator>Doron</dc:creator>
		<pubDate>Mon, 14 Jul 2008 12:30:42 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-131</guid>
		<description>Nice tips, a good way to prevent beginners from early despair. 

Pingback from the Typemock dev team blog - http://blog.typemock.com</description>
		<content:encoded><![CDATA[<p>Nice tips, a good way to prevent beginners from early despair. </p>
<p>Pingback from the Typemock dev team blog - <a href="http://blog.typemock.com" rel="nofollow">http://blog.typemock.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael Easter</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-127</link>
		<dc:creator>Michael Easter</dc:creator>
		<pubDate>Thu, 10 Jul 2008 16:10:16 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-127</guid>
		<description>Good stuff... however I want to amplify the point that automated testing is more than 'unit' testing.

We use dbUnit for integration testing of our Hibernate mappings and it has been a tremendous success.  We migrated from an OODB to Postgres in a giant refactoring and dbUnit was vital to the effort.</description>
		<content:encoded><![CDATA[<p>Good stuff&#8230; however I want to amplify the point that automated testing is more than &#8216;unit&#8217; testing.</p>
<p>We use dbUnit for integration testing of our Hibernate mappings and it has been a tremendous success.  We migrated from an OODB to Postgres in a giant refactoring and dbUnit was vital to the effort.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ben</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-125</link>
		<dc:creator>Ben</dc:creator>
		<pubDate>Wed, 09 Jul 2008 14:25:37 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-125</guid>
		<description>@Greg - thanks for the book suggestion, I'll check it out.

As always, I suspect it's a balance. Some amount of DRYness in tests is probably a good thing (for instance a few helper methods for operations that really are universal). 

However, if you push things too far, you start seeing things like fixtures and setup/teardown methods, which have good intentions, but I think many people have found to be very brittle. That's why I try to keep my tests somewhere in the middle (AKA "moist").</description>
		<content:encoded><![CDATA[<p>@Greg - thanks for the book suggestion, I&#8217;ll check it out.</p>
<p>As always, I suspect it&#8217;s a balance. Some amount of DRYness in tests is probably a good thing (for instance a few helper methods for operations that really are universal). </p>
<p>However, if you push things too far, you start seeing things like fixtures and setup/teardown methods, which have good intentions, but I think many people have found to be very brittle. That&#8217;s why I try to keep my tests somewhere in the middle (AKA &#8220;moist&#8221;).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Reflective Perspective - Chris Alcock &#187; The Morning Brew #132</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-124</link>
		<dc:creator>Reflective Perspective - Chris Alcock &#187; The Morning Brew #132</dc:creator>
		<pubDate>Wed, 09 Jul 2008 07:14:06 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-124</guid>
		<description>[...] Tips for Unit Testing - Ben posts a collection of good tips on unit testing [...]</description>
		<content:encoded><![CDATA[<p>[...] Tips for Unit Testing - Ben posts a collection of good tips on unit testing [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Greg</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-123</link>
		<dc:creator>Greg</dc:creator>
		<pubDate>Wed, 09 Jul 2008 05:25:37 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-123</guid>
		<description>Read xUnit Test Patterns, there are a lot of test patterns that have DRY underpinnings.</description>
		<content:encoded><![CDATA[<p>Read xUnit Test Patterns, there are a lot of test patterns that have DRY underpinnings.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ben</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-122</link>
		<dc:creator>Ben</dc:creator>
		<pubDate>Wed, 09 Jul 2008 04:32:05 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-122</guid>
		<description>@Greg - I tried, man, I tried. I worked hard to make my tests DRY for months, and trust me, it just created more problems than it solved.

Readability was one problem, but more importantly, making tests DRY makes them lest independent, which is a maintainability nightmare.

I'd say that if you find yourself needing to DRY up your tests (to reduce duplication), then your tests aren't specific enough. If each test is verifying one specific thing, you shouldn't need to write a bunch of helper methods.</description>
		<content:encoded><![CDATA[<p>@Greg - I tried, man, I tried. I worked hard to make my tests DRY for months, and trust me, it just created more problems than it solved.</p>
<p>Readability was one problem, but more importantly, making tests DRY makes them lest independent, which is a maintainability nightmare.</p>
<p>I&#8217;d say that if you find yourself needing to DRY up your tests (to reduce duplication), then your tests aren&#8217;t specific enough. If each test is verifying one specific thing, you shouldn&#8217;t need to write a bunch of helper methods.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: website design</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-120</link>
		<dc:creator>website design</dc:creator>
		<pubDate>Tue, 08 Jul 2008 21:24:49 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-120</guid>
		<description>I have slowly become more and more a believer of unit testing. One thing I find myself doing is instead of writing little single scripts or going into the interpreter directly is writing little unit tests when I am exploring new code. I have done this a lot recently when working with Amazon's simpleDB, write code to write an object to the DB, before hooking it into any of my application, I write a test and make sure everything is doing what I expect.</description>
		<content:encoded><![CDATA[<p>I have slowly become more and more a believer of unit testing. One thing I find myself doing is instead of writing little single scripts or going into the interpreter directly is writing little unit tests when I am exploring new code. I have done this a lot recently when working with Amazon&#8217;s simpleDB, write code to write an object to the DB, before hooking it into any of my application, I write a test and make sure everything is doing what I expect.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jack</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-111</link>
		<dc:creator>Jack</dc:creator>
		<pubDate>Tue, 08 Jul 2008 09:25:58 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-111</guid>
		<description>@Greg - whilst I partially agree, it is better to have moist tests than none at all. My tests start wet, then I get them moist and finally I try to get them dry. The point being that the test code only exists to find bugs in the production code. if wet code does that initially then I don't see a problem with it. You can always refactor to your hearts content later.</description>
		<content:encoded><![CDATA[<p>@Greg - whilst I partially agree, it is better to have moist tests than none at all. My tests start wet, then I get them moist and finally I try to get them dry. The point being that the test code only exists to find bugs in the production code. if wet code does that initially then I don&#8217;t see a problem with it. You can always refactor to your hearts content later.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Greg</title>
		<link>http://devver.net/blog/2008/07/tips-for-unit-testing/#comment-109</link>
		<dc:creator>Greg</dc:creator>
		<pubDate>Tue, 08 Jul 2008 06:08:37 +0000</pubDate>
		<guid isPermaLink="false">http://devver.net/blog/?p=29#comment-109</guid>
		<description>Tests should be DRY. If DRYing them up makes them less readable, you're doing it wrong.</description>
		<content:encoded><![CDATA[<p>Tests should be DRY. If DRYing them up makes them less readable, you&#8217;re doing it wrong.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
