<?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>Netinlet &#187; ruby testing</title>
	<atom:link href="http://netinlet.com/article/tag/ruby-testing/feed/" rel="self" type="application/rss+xml" />
	<link>http://netinlet.com</link>
	<description>doug's mostly ignored place on the web</description>
	<lastBuildDate>Wed, 20 May 2009 21:03:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Testing private and protected methods with ruby</title>
		<link>http://netinlet.com/article/2007/04/18/testing-private-and-protected-methods-with-ruby/</link>
		<comments>http://netinlet.com/article/2007/04/18/testing-private-and-protected-methods-with-ruby/#comments</comments>
		<pubDate>Wed, 18 Apr 2007 22:48:00 +0000</pubDate>
		<dc:creator>doug</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ruby testing]]></category>

		<guid isPermaLink="false">http://netinlet.com/?p=124</guid>
		<description><![CDATA[When I have to test my protected and private methods in ruby, I make the methods public for the scope of the test. MyClass.send(:public, *MyClass.protected_instance_methods) MyClass.send(:public, *MyClass.private_instance_methods) Just place this code in your testing class substituting your class name. Include the namespace if applicable.]]></description>
			<content:encoded><![CDATA[<p>When I have to test my protected and private methods in ruby, I make the methods public for the scope of the test.</p>
<p>
<code><br />
  MyClass.send(:public, *MyClass.protected_instance_methods)  <br />
  MyClass.send(:public, *MyClass.private_instance_methods)<br />
</code>
</p>
<p>Just place this code in your testing class substituting your class name.  Include the namespace if applicable.</p>
]]></content:encoded>
			<wfw:commentRss>http://netinlet.com/article/2007/04/18/testing-private-and-protected-methods-with-ruby/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
