<?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: Fun with jMock</title>
	<atom:link href="http:///2009/11/22/fun-with-jmock/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.palantirtech.com/2009/11/22/fun-with-jmock/</link>
	<description>Articles from the Engineering Group at Palantir Technologies</description>
	<lastBuildDate>Tue, 24 Jan 2012 09:51:18 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Steve Freeman</title>
		<link>http://blog.palantirtech.com/2009/11/22/fun-with-jmock/comment-page-1/#comment-267</link>
		<dc:creator>Steve Freeman</dc:creator>
		<pubDate>Tue, 24 Nov 2009 11:20:14 +0000</pubDate>
		<guid isPermaLink="false">http://blog.palantirtech.com/?p=1274#comment-267</guid>
		<description>Thanks for the reference. There are a few extra points to note:

Adding @RunWith(JMock.class) to the JUnit class will call assertIsSatisfied() automatically for each test

When we specify a query, such as:

oneOf(service).getObject(realm.getId(), myObject.getId()); will(returnValue(myObject));

we usually make that 

allowing(service).getObject(realmId, objectId);  will(returnValue(myObject));

Queries don&#039;t change the world outside the object, so we stub them to express that relationships and to make the tests more resilient as the code changes.</description>
		<content:encoded><![CDATA[<p>Thanks for the reference. There are a few extra points to note:</p>
<p>Adding @RunWith(JMock.class) to the JUnit class will call assertIsSatisfied() automatically for each test</p>
<p>When we specify a query, such as:</p>
<p>oneOf(service).getObject(realm.getId(), myObject.getId()); will(returnValue(myObject));</p>
<p>we usually make that </p>
<p>allowing(service).getObject(realmId, objectId);  will(returnValue(myObject));</p>
<p>Queries don&#8217;t change the world outside the object, so we stub them to express that relationships and to make the tests more resilient as the code changes.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

