<?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>Anlek Consulting &#187; RSpec</title>
	<atom:link href="http://anlek.com/category/rspec/feed/" rel="self" type="application/rss+xml" />
	<link>http://anlek.com</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Thu, 10 Nov 2011 16:29:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>uninitialized constant Test::Unit::TestResult::TestResultFailureSupport Error</title>
		<link>http://anlek.com/2009/10/uninitialized-constant-test-unit-testresult-testresultfailuresupport-error/</link>
		<comments>http://anlek.com/2009/10/uninitialized-constant-test-unit-testresult-testresultfailuresupport-error/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 17:46:57 +0000</pubDate>
		<dc:creator>Andrew Kalek</dc:creator>
				<category><![CDATA[gem]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[RSpec]]></category>

		<guid isPermaLink="false">http://blog.anlek.com/?p=137</guid>
		<description><![CDATA[Today trying to run my RSpec tests and I get an odd error: uninitialized constant Test::Unit::TestResult::TestResultFailureSupport (NameError) /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:105:in `const_missing&#8217; /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.3/lib/test/unit/testresult.rb:28 /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require&#8217; /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require&#8217; /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:158:in `require&#8217; &#8230;. After doing some research online I found out that the issue is caused by Shoulda and Mocha being included in my app. It seems that if you put [...]]]></description>
			<content:encoded><![CDATA[<p>Today trying to run my RSpec tests and I get an odd error:</p>
<blockquote><p>uninitialized constant Test::Unit::TestResult::TestResultFailureSupport (NameError)<br />
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:105:in `const_missing&#8217;<br />
/usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.3/lib/test/unit/testresult.rb:28<br />
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require&#8217;<br />
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require&#8217;<br />
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:158:in `require&#8217;<br />
&#8230;.</p></blockquote>
<p>After doing some research online I found out that the issue is caused by Shoulda and Mocha being included in my app. It seems that if you put a gem dependence for Shoulda before Mocha,  you&#8217;ll get this error, so the <strong>fix</strong> is to place the gem dependence for Mocha before Shoulda.</p>
<blockquote><p>config.gem &#8220;rspec&#8221;, :lib =&gt; false, :version =&gt; &#8220;&gt;=1.2.6&#8243;<br />
config.gem &#8220;rspec-rails&#8221;, :lib =&gt; &#8216;spec/rails&#8217;, :version =&gt; &#8220;&gt;=1.2.6&#8243;<br />
config.gem &#8220;mocha&#8221;<br />
config.gem &#8220;thoughtbot-shoulda&#8221;, :lib =&gt; &#8220;shoulda&#8221;, :source =&gt; &#8220;http://gems.github.com&#8221;</p></blockquote>
<p>Hope that helps</p>
<p><strong>UPDATE:</strong></p>
<p>I hit the same error having shoulda in my environment.rb file, moving it to the test.rb (in environment folder) fixed the issue as well.</p>
]]></content:encoded>
			<wfw:commentRss>http://anlek.com/2009/10/uninitialized-constant-test-unit-testresult-testresultfailuresupport-error/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Error with fsevent and autospec (on Mac)</title>
		<link>http://anlek.com/2009/10/error-with-fsevent-version-0-1-2-and-autospec/</link>
		<comments>http://anlek.com/2009/10/error-with-fsevent-version-0-1-2-and-autospec/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 05:16:18 +0000</pubDate>
		<dc:creator>Andrew Kalek</dc:creator>
				<category><![CDATA[gem]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[RSpec]]></category>
		<category><![CDATA[Ruby]]></category>

		<guid isPermaLink="false">http://blog.anlek.com/?p=129</guid>
		<description><![CDATA[Today I&#8217;ve upgraded my gems and noticed that when running my autospec I get an odd error: [01:09:25 /usr/local/lib/ruby/gems/1.8/gems/ruby-ole-1.2.10/lib/ole/storage/base.rb:146:load] WARN   root name was &#8220;R&#8221; And my autospec would keep printing out: sh: line 1:  6303 Trace/BPT trap          /usr/local/lib/ruby/gems/1.8/gems/autotest-fsevent-0.1.2/fsevent/darwin/fsevent_sleep &#8216;/Users/andrew/rails_apps/example_com&#8217; 2&#62;&#38;1 sh: line 1:  6307 Trace/BPT trap         [...]]]></description>
			<content:encoded><![CDATA[<p>Today I&#8217;ve upgraded my gems and noticed that when running my autospec I get an odd error:</p>
<blockquote><p>[01:09:25 /usr/local/lib/ruby/gems/1.8/gems/ruby-ole-1.2.10/lib/ole/storage/base.rb:146:load]</p>
<p>WARN   root name was &#8220;R&#8221;</p></blockquote>
<div>And my autospec would keep printing out:</div>
<div>
<blockquote>
<div>sh: line 1:  6303 Trace/BPT trap          /usr/local/lib/ruby/gems/1.8/gems/autotest-fsevent-0.1.2/fsevent/darwin/fsevent_sleep &#8216;/Users/andrew/rails_apps/example_com&#8217; 2&gt;&amp;1</div>
<div>sh: line 1:  6307 Trace/BPT trap          /usr/local/lib/ruby/gems/1.8/gems/autotest-fsevent-0.1.2/fsevent/darwin/fsevent_sleep &#8216;/Users/andrew/rails_apps/example_com&#8217; 2&gt;&amp;1</div>
</blockquote>
<div>Unfortunately I don&#8217;t have the time to look into the fsevent code to see if I can make a work around, however I found that you can remove the gem (&#8216;<strong><code>sudo gem uninstall autotest-fsevent</code></strong>&#8216;) and install the older version (&#8216;<strong><code>sudo gem install autotest-fsevent --version 0.1.1</code></strong>&#8216;)</div>
</div>
<div>Hopefully this helps someone out!</div>
<div><strong>UPDATE</strong>: I forgot to mention I was using a Mac OS X 10.5.8, and based on the <a href="http://github.com/svoop/autotest-fsevent/blob/master/History.txt" target="_blank">History.txt</a> they made changes effecting Macs.</div>
<div><strong>UPDATE 2 (Oct 22, 09):</strong> It seems that the same issue exists in fsevent 0.1.3 as well</div>
<div><strong>UPDATE 3 (Mar 05, 2010):</strong> Issue still present in 0.2.1 however I found out that the error is only for OS X 10.5 and will not happen on OS X 10.6.</div>
<div>The full error message is:</div>
<p><code>/usr/local/lib/ruby/gems/1.8/gems/autotest-fsevent-0.2.1/fsevent/darwin/fsevent_sleep ; exit;<br />
~%  /usr/local/lib/ruby/gems/1.8/gems/autotest-fsevent-0.2.1/fsevent/darwin/fsevent_sleep ; exit;<br />
dyld: unknown required load command 0x80000022<br />
zsh: trace trap</code></p>
<p><strong>The only work around (outside of downgrading to version 0.1.1) is to copy fsevent_sleep from version 0.1.1 to version 0.2.1. However I&#8217;m not sure how stable that solution is.</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://anlek.com/2009/10/error-with-fsevent-version-0-1-2-and-autospec/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

