Is @fund nil? I'm guessing here, but the []= could be from the underlying attributes (@<a href="http://fund.id">fund.id</a> is the same as @fund.attributes['id']).<br><br><div><span class="gmail_quote">On 5/16/07,
<b class="gmail_sendername">Jim Hughes</b> <<a href="mailto:jeem@hughesorama.com">jeem@hughesorama.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Here's a snippet:<br><br> it "should provide the fund" do<br> get(:timesheet,{:id=>@<a href="http://fund.id">fund.id</a>})<br> assigns[:fund].should == @fund<br> end<br><br>Works fine on my box, fails on my CI server. Here's the output:
<br><br>NoMethodError in 'The FundController timesheet should provide the fund'<br>You have a nil object when you didn't expect it!<br>You might have expected an instance of Array.<br>The error occurred while evaluating nil.[]=
<br>./spec/controllers/fund_controller_spec.rb:19:<br>./script/spec:4:<br><br>The line raising is the "get" line. I don't see a foo[bar] = x,<br>implied anywhere in the statement.<br><br>Has anyone seen this?
<br><br>Thanks for any help.<br><br>Jim<br>_______________________________________________<br>rspec-users mailing list<br><a href="mailto:rspec-users@rubyforge.org">rspec-users@rubyforge.org</a><br><a href="http://rubyforge.org/mailman/listinfo/rspec-users">
http://rubyforge.org/mailman/listinfo/rspec-users</a><br></blockquote></div><br>