<?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"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Unit Test Assertions: What Could Possibly Go Wrong?</title>
	<atom:link href="http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/</link>
	<description>A collection of articles from pramatr.com on technology, security, software and anything we find interesting</description>
	<lastBuildDate>Wed, 28 Jul 2010 12:28:21 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Pramatr</title>
		<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/comment-page-1/#comment-89</link>
		<dc:creator>Pramatr</dc:creator>
		<pubDate>Fri, 21 Nov 2008 18:56:00 +0000</pubDate>
		<guid isPermaLink="false">http://pramatr.com/2007/11/06/unit-test-assertions-what-could-possibly-go-wrong/#comment-89</guid>
		<description>@Asgeir S. Nilsen: Thanks for the tip, I have looked at this briefly but I haven&#039;t really played with it enough to have an opinion ;-). I does look handy though, I&#039;m interested to see how useful it is.</description>
		<content:encoded><![CDATA[<p>@Asgeir S. Nilsen: Thanks for the tip, I have looked at this briefly but I haven&#8217;t really played with it enough to have an opinion <img src='http://69.89.31.94/~pramatrc/blog/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> . I does look handy though, I&#8217;m interested to see how useful it is.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Asgeir S. Nilsen</title>
		<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/comment-page-1/#comment-88</link>
		<dc:creator>Asgeir S. Nilsen</dc:creator>
		<pubDate>Wed, 14 Nov 2007 10:43:00 +0000</pubDate>
		<guid isPermaLink="false">http://pramatr.com/2007/11/06/unit-test-assertions-what-could-possibly-go-wrong/#comment-88</guid>
		<description>Nice article.  One suggestion to get more readable messages is to use JUnit 4.4&#039;s &lt;i&gt;assertThat&lt;/i&gt; method together with hamcrest matchers.&lt;br/&gt;&lt;br/&gt;You can then state an assertion as&lt;br/&gt;&lt;br/&gt;&lt;i&gt;&lt;br/&gt;assertThat(actual, equalTo(expected));&lt;br/&gt;&lt;/i&gt;&lt;br/&gt;&lt;br/&gt;and get a very nice error message back if the assertion fails.</description>
		<content:encoded><![CDATA[<p>Nice article.  One suggestion to get more readable messages is to use JUnit 4.4&#8217;s <i>assertThat</i> method together with hamcrest matchers.</p>
<p>You can then state an assertion as</p>
<p><i><br />assertThat(actual, equalTo(expected));<br /></i></p>
<p>and get a very nice error message back if the assertion fails.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pramatr</title>
		<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/comment-page-1/#comment-87</link>
		<dc:creator>Pramatr</dc:creator>
		<pubDate>Mon, 12 Nov 2007 19:25:00 +0000</pubDate>
		<guid isPermaLink="false">http://pramatr.com/2007/11/06/unit-test-assertions-what-could-possibly-go-wrong/#comment-87</guid>
		<description>The message versions are very much personal preference. The book I mentioned does discuss this issue a little. If you are running this through Eclipse and following TDD, I can completely understand your point. One assertion per test, why do I need a message? Lots of the tests I&#039;ve had to maintain however, haven&#039;t been this well written. The message therefore helps example the maintainer understand what&#039;s going on.

I do prefer your chosen TDD approach :-), it&#039;s pretty hard convincing everyone it&#039;s the way to go however.</description>
		<content:encoded><![CDATA[<p>The message versions are very much personal preference. The book I mentioned does discuss this issue a little. If you are running this through Eclipse and following TDD, I can completely understand your point. One assertion per test, why do I need a message? Lots of the tests I&#8217;ve had to maintain however, haven&#8217;t been this well written. The message therefore helps example the maintainer understand what&#8217;s going on.</p>
<p>I do prefer your chosen TDD approach <img src='http://69.89.31.94/~pramatrc/blog/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> , it&#8217;s pretty hard convincing everyone it&#8217;s the way to go however.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dean</title>
		<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/comment-page-1/#comment-86</link>
		<dc:creator>Dean</dc:creator>
		<pubDate>Mon, 12 Nov 2007 19:03:00 +0000</pubDate>
		<guid isPermaLink="false">http://pramatr.com/2007/11/06/unit-test-assertions-what-could-possibly-go-wrong/#comment-86</guid>
		<description>I rarely use the message versions of the assertions. I use very meaningful names everywhere, I run all my tests in Eclipse where I get a clickable stack trace, I use TDD so I know what I just changed since the last test run, and I use the expected vs. actual assertions where possible. As a result, I rarely need more information. Not writing the messages reduces clutter, saves a lot of time, and requires zero maintenance of the messages!</description>
		<content:encoded><![CDATA[<p>I rarely use the message versions of the assertions. I use very meaningful names everywhere, I run all my tests in Eclipse where I get a clickable stack trace, I use TDD so I know what I just changed since the last test run, and I use the expected vs. actual assertions where possible. As a result, I rarely need more information. Not writing the messages reduces clutter, saves a lot of time, and requires zero maintenance of the messages!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Adam Peters</title>
		<link>http://www.pramatr.com/blog/2008/11/06/unit-test-assertions-what-could-possibly-go-wrong/comment-page-1/#comment-85</link>
		<dc:creator>Adam Peters</dc:creator>
		<pubDate>Sun, 11 Nov 2007 16:53:00 +0000</pubDate>
		<guid isPermaLink="false">http://pramatr.com/2007/11/06/unit-test-assertions-what-could-possibly-go-wrong/#comment-85</guid>
		<description>xUnit Test Patterns sounds like an interesting read. Thanks for the links to the site, I&#039;d be quite interested to see your review!</description>
		<content:encoded><![CDATA[<p>xUnit Test Patterns sounds like an interesting read. Thanks for the links to the site, I&#8217;d be quite interested to see your review!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
