Bruno Cardoso
2010-Sep-21 15:58 UTC
[rspec-users] Failure/Error: Unable to find matching line from backtrace can''t convert nil into String
I''m getting this errors from this spec: http://pastie.org/private/lm9nrqnmhqobs1avf3skgw Failures: 1) Account Account should have a relation belongs to with customer Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 2) Account Account should have a relation belongs to with account status Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 3) Account Account should have a has many relation with account managers Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 4) Account Account should have a has many relation with account relations Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 5) Account Account should be possible to create an account with only status, b ucket and creation_date Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 6) Account Account should return an error if bucket is nil Failure/Error: Unable to find matching line from backtrace can''t convert nil into String # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 The spec is very simple. This was working with rails2+rspec1.3.... I''m using rails3+rspec2 now. The error message is not very clear. Any idea why this happens?
David Chelimsky
2010-Sep-22 01:05 UTC
[rspec-users] Failure/Error: Unable to find matching line from backtrace can''t convert nil into String
On Sep 21, 2010, at 10:58 AM, Bruno Cardoso wrote:> I''m getting this errors from this spec: http://pastie.org/private/lm9nrqnmhqobs1avf3skgw > > Failures: > 1) Account Account should have a relation belongs to with customer > Failure/Error: Unable to find matching line from backtrace > can''t convert nil into String > # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 > > The spec is very simple. This was working with rails2+rspec1.3.... I''m > using rails3+rspec2 now. The error message is not very clear. > > Any idea why this happens?http://github.com/rspec/rspec-core/issues#issue/146
Bruno Cardoso
2010-Sep-22 09:39 UTC
[rspec-users] Failure/Error: Unable to find matching line from backtrace can''t convert nil into String
Hi David, Thanks for the reply but that didn''t fix my problem. I think this is somehow related to fixtures, at least I only get this problem on the specs that use fixtures and if I remove the fixtures, it works. On Sep 22, 2:05?am, David Chelimsky <dchelim... at gmail.com> wrote:> On Sep 21, 2010, at 10:58 AM, Bruno Cardoso wrote: > > > I''m getting this errors from this spec:http://pastie.org/private/lm9nrqnmhqobs1avf3skgw > > > Failures: > > ?1) Account Account should have a relation belongs to with customer > > ? ? Failure/Error: Unable to find matching line from backtrace > > ? ? can''t convert nil into String > > ? ? # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 > > > The spec is very simple. This was working with rails2+rspec1.3.... I''m > > using rails3+rspec2 now. The error message is not very clear. > > > Any idea why this happens? > > http://github.com/rspec/rspec-core/issues#issue/146 > _______________________________________________ > rspec-users mailing list > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users
Bruno Cardoso
2010-Sep-22 11:30 UTC
[rspec-users] Failure/Error: Unable to find matching line from backtrace can''t convert nil into String
TypeError: can''t convert nil into String D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:519:in `create_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:518:in `map'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:518:in `create_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-jdbc- adapter-0.9.7-java/lib/jdbc_adapter/jdbc_mysql.rb:141:in `disable_referential_integrity'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:515:in `create_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activesupport-3.0.0/ lib/active_support/benchmarkable.rb:55:in `silence'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:514:in `create_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:975:in `load_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ lib/active_record/fixtures.rb:950:in `setup_fixtures'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- rails-2.0.0.beta.22/lib/rspec/rails/adapters.rb:11:in `setup'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:29:in `instance_eval'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:29:in `run_in'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `run_all'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `each'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `run_all'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/hooks.rb:103:in `run_hook'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in `eval_before_eachs'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in `each'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in `eval_before_eachs'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:128:in `run_before_each'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:51:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:93:in `call'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:93:in `with_around_hooks'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:49:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:87:in `call'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:87:in `with_pending_capture'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:86:in `catch'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:86:in `with_pending_capture'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example.rb:48:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:235:in `run_examples'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:232:in `map'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:232:in `run_examples'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/example_group.rb:216:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `run_examples'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `each'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `inject'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `run_examples'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:26:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/reporter.rb:11:in `report'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/command_line.rb:23:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/runner.rb:36:in `run_in_process'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/lib/rspec/core/runner.rb:27:in `run'' D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/bin/rspec:3 D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- core-2.0.0.beta.22/bin/rspec:19:in `load'' D:/ruby/rubies/jruby-1.5.2/bin/rspec:19 D:/ruby/rubies/jruby-1.5.2/bin/rspec:1:in `load'' -e:1: On Sep 22, 10:39?am, Bruno Cardoso <bcardoso.h... at gmail.com> wrote:> Hi David, > > Thanks for the reply but that didn''t fix my problem. > > I think this is somehow related to fixtures, at least I only get this > problem on the specs that use fixtures and if I remove the fixtures, > it works. > > On Sep 22, 2:05?am, David Chelimsky <dchelim... at gmail.com> wrote: > > > On Sep 21, 2010, at 10:58 AM, Bruno Cardoso wrote: > > > > I''m getting this errors from this spec:http://pastie.org/private/lm9nrqnmhqobs1avf3skgw > > > > Failures: > > > ?1) Account Account should have a relation belongs to with customer > > > ? ? Failure/Error: Unable to find matching line from backtrace > > > ? ? can''t convert nil into String > > > ? ? # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 > > > > The spec is very simple. This was working with rails2+rspec1.3.... I''m > > > using rails3+rspec2 now. The error message is not very clear. > > > > Any idea why this happens? > > >http://github.com/rspec/rspec-core/issues#issue/146 > > _______________________________________________ > > rspec-users mailing list > > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users > > _______________________________________________ > rspec-users mailing list > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users
Bruno Cardoso
2010-Sep-22 13:53 UTC
[rspec-users] Failure/Error: Unable to find matching line from backtrace can''t convert nil into String
Ok... found the problem... had this line in my spec helper commented =| config.fixture_path = "#{::Rails.root}/spec/fixtures" On Sep 22, 12:30?pm, Bruno Cardoso <bcardoso.h... at gmail.com> wrote:> TypeError: can''t convert nil into String > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:519:in `create_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:518:in `map'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:518:in `create_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-jdbc- > adapter-0.9.7-java/lib/jdbc_adapter/jdbc_mysql.rb:141:in > `disable_referential_integrity'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:515:in `create_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activesupport-3.0.0/ > lib/active_support/benchmarkable.rb:55:in `silence'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:514:in `create_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:975:in `load_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/activerecord-3.0.0/ > lib/active_record/fixtures.rb:950:in `setup_fixtures'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > rails-2.0.0.beta.22/lib/rspec/rails/adapters.rb:11:in `setup'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:29:in `instance_eval'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:29:in `run_in'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `run_all'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `each'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:60:in `run_all'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/hooks.rb:103:in `run_hook'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in > `eval_before_eachs'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in `each'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:186:in > `eval_before_eachs'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:128:in `run_before_each'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:51:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:93:in `call'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:93:in `with_around_hooks'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:49:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:87:in `call'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:87:in > `with_pending_capture'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:86:in `catch'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:86:in > `with_pending_capture'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example.rb:48:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:235:in > `run_examples'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:232:in `map'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:232:in > `run_examples'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/example_group.rb:216:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `run_examples'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `each'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `inject'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:43:in `run_examples'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:26:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/reporter.rb:11:in `report'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/command_line.rb:23:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/runner.rb:36:in `run_in_process'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/lib/rspec/core/runner.rb:27:in `run'' > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/bin/rspec:3 > D:/ruby/rubies/jruby-1.5.2/lib/ruby/gems/1.8/gems/rspec- > core-2.0.0.beta.22/bin/rspec:19:in `load'' > D:/ruby/rubies/jruby-1.5.2/bin/rspec:19 > D:/ruby/rubies/jruby-1.5.2/bin/rspec:1:in `load'' > -e:1: > > On Sep 22, 10:39?am, Bruno Cardoso <bcardoso.h... at gmail.com> wrote: > > > Hi David, > > > Thanks for the reply but that didn''t fix my problem. > > > I think this is somehow related to fixtures, at least I only get this > > problem on the specs that use fixtures and if I remove the fixtures, > > it works. > > > On Sep 22, 2:05?am, David Chelimsky <dchelim... at gmail.com> wrote: > > > > On Sep 21, 2010, at 10:58 AM, Bruno Cardoso wrote: > > > > > I''m getting this errors from this spec:http://pastie.org/private/lm9nrqnmhqobs1avf3skgw > > > > > Failures: > > > > ?1) Account Account should have a relation belongs to with customer > > > > ? ? Failure/Error: Unable to find matching line from backtrace > > > > ? ? can''t convert nil into String > > > > ? ? # D:\ruby\rubies\jruby-1.5.2\bin\rspec:19 > > > > > The spec is very simple. This was working with rails2+rspec1.3.... I''m > > > > using rails3+rspec2 now. The error message is not very clear. > > > > > Any idea why this happens? > > > >http://github.com/rspec/rspec-core/issues#issue/146 > > > _______________________________________________ > > > rspec-users mailing list > > > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users > > > _______________________________________________ > > rspec-users mailing list > > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users > > _______________________________________________ > rspec-users mailing list > rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users