<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Using Embedded Resources for Unit Testing&#8230;</title>
	<atom:link href="http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/</link>
	<description></description>
	<lastBuildDate>Fri, 12 Mar 2010 06:35:55 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: David O'Hara</title>
		<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-13949</link>
		<dc:creator>David O'Hara</dc:creator>
		<pubDate>Thu, 13 Dec 2007 18:18:41 +0000</pubDate>
		<guid isPermaLink="false">http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-13949</guid>
		<description>finalkut: I suppose you could continue to pull pieces out (Assembly, Stream) until you get the thinnest layer possible but at some point you&#039;d simply have to have an integration test that gets you that &quot;last mile&quot;. For me, I&#039;m good with leaving it untested since it&#039;s really only used for testing itself and I&#039;m not interested in falling into &quot;testing recursion&quot;.</description>
		<content:encoded><![CDATA[<p>finalkut: I suppose you could continue to pull pieces out (Assembly, Stream) until you get the thinnest layer possible but at some point you&#8217;d simply have to have an integration test that gets you that &#8220;last mile&#8221;. For me, I&#8217;m good with leaving it untested since it&#8217;s really only used for testing itself and I&#8217;m not interested in falling into &#8220;testing recursion&#8221;.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: finalkut</title>
		<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-13946</link>
		<dc:creator>finalkut</dc:creator>
		<pubDate>Thu, 13 Dec 2007 15:42:28 +0000</pubDate>
		<guid isPermaLink="false">http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-13946</guid>
		<description>Here&#039;s a question: how would you unit test your UnwrapXmlResource method?

I have a very similar method - though it is static - in a standard library - and I have pretty good test coverage on everything except for the extraction of an embedded resource.

Because the method I&#039;m testing is more utilitarian than just for unit testing it expects the embedded resource to be in the &quot;entry assembly&quot;  so I use Assembly.GetEntryAssembly().GetManifestResourceStream(resource);

However, with a unit test there is no &quot;EntryAssembly&quot; 

Any thoughts?</description>
		<content:encoded><![CDATA[<p>Here&#8217;s a question: how would you unit test your UnwrapXmlResource method?</p>
<p>I have a very similar method &#8211; though it is static &#8211; in a standard library &#8211; and I have pretty good test coverage on everything except for the extraction of an embedded resource.</p>
<p>Because the method I&#8217;m testing is more utilitarian than just for unit testing it expects the embedded resource to be in the &#8220;entry assembly&#8221;  so I use Assembly.GetEntryAssembly().GetManifestResourceStream(resource);</p>
<p>However, with a unit test there is no &#8220;EntryAssembly&#8221; </p>
<p>Any thoughts?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris Morris</title>
		<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-9562</link>
		<dc:creator>Chris Morris</dc:creator>
		<pubDate>Mon, 23 Jul 2007 01:56:49 +0000</pubDate>
		<guid isPermaLink="false">http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-9562</guid>
		<description>We do embedded resources for our unit tests at eInstruction. Some of them are fat, and we started having problems with memory usage inside Visual Studio with R#, so we now have a separate statically referenced assembly with all our test resources in it.</description>
		<content:encoded><![CDATA[<p>We do embedded resources for our unit tests at eInstruction. Some of them are fat, and we started having problems with memory usage inside Visual Studio with R#, so we now have a separate statically referenced assembly with all our test resources in it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ghosty</title>
		<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-9037</link>
		<dc:creator>Ghosty</dc:creator>
		<pubDate>Thu, 12 Jul 2007 00:02:23 +0000</pubDate>
		<guid isPermaLink="false">http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-9037</guid>
		<description>Interesting that you posted this, as I have just started teaching myself XML this past week ... I am surprised at the flexibility and versatility of the language.</description>
		<content:encoded><![CDATA[<p>Interesting that you posted this, as I have just started teaching myself XML this past week &#8230; I am surprised at the flexibility and versatility of the language.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim Rayburn</title>
		<link>http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-8990</link>
		<dc:creator>Tim Rayburn</dc:creator>
		<pubDate>Tue, 10 Jul 2007 17:04:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.davidohara.net/2007/07/10/using-embedded-resources-for-unit-testing/#comment-8990</guid>
		<description>Dave,
I write about a very similar problem, solved in a similar way, back in Feb 2006.  I often have the situation that I need to access a file on disk for my code.  So I wrote an IDisposable wrapper that uses Embedded Resources just as you describe.  Details can be found here:
http://www.timrayburn.net/2006/02/19/ExternalFileDependencyInNUnit.aspx

Good content! Keep it coming!
Tim</description>
		<content:encoded><![CDATA[<p>Dave,<br />
I write about a very similar problem, solved in a similar way, back in Feb 2006.  I often have the situation that I need to access a file on disk for my code.  So I wrote an IDisposable wrapper that uses Embedded Resources just as you describe.  Details can be found here:<br />
<a href="http://www.timrayburn.net/2006/02/19/ExternalFileDependencyInNUnit.aspx" rel="nofollow">http://www.timrayburn.net/2006/02/19/ExternalFileDependencyInNUnit.aspx</a></p>
<p>Good content! Keep it coming!<br />
Tim</p>
]]></content:encoded>
	</item>
</channel>
</rss>
