Im one of my unit tests, I got an error I cannot even start looking for the 
issue as few information are logged ...

Using the test console , there is no error at all :
> rails console test
>> Loading test environment (Rails 3.2.9.rc3)
>  site1 = FactoryGirl.create(:cms_site, label: "booboo")
>> BEGIN
..
..
>> 

but running my tests > unit 
> ruby -Itest test/unit/user_test.rb -n 
"/should_save_user_with_required_fields/"
>> STARTED
>>  Error: test_should_save_user_with_required_fields(UserTest)
  NoMethodError: undefined method `respond_to?=' for 
#<Cms::Page:0x007fa0435bba68>
  test/factories/cms_layout.rb:14:in `block (3 levels) in <top (required)>'
  test/factories/cms_site.rb:17:in `block (3 levels) in <top (required)>'
  test/unit/user_test.rb:58:in `initialize_user'

  I have a nested FactoryGirl records creation   ( cms_site > cms_layout > 
cms_page )

why it coule be running fine in console and NOt in test ? how can I search 
for more info ?  thanks

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msg/rubyonrails-talk/-/yWnw5ZWPTNsJ.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to