investigate page link model not parsing
Reported by Nicholas Rutherford | October 29th, 2009 @ 02:45 AM
I have a PageLink model, when I do "Then 2 page links should exist" I get this error:
You have a nil object when you didn't expect it!
The error occurred while evaluating nil.klass (NoMethodError)
/Users/nicholasrutherford/dev/workspace/ar_site/vendor/gems/pickle-0.1.20/lib/pickle/session.rb:42:in `find_models'
./features/step_definitions/pickle_steps.rb:20:in `__instance_exec0'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/core_ext/instance_exec.rb:26:in `send'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/core_ext/instance_exec.rb:26:in `instance_exec'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/core_ext/instance_exec.rb:48:in `cucumber_instance_exec'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/core_ext/instance_exec.rb:69:in `cucumber_run_with_backtrace_filtering'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/core_ext/instance_exec.rb:36:in `cucumber_instance_exec'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/rb_support/rb_step_definition.rb:55:in `invoke'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/step_match.rb:23:in `invoke'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/step_invocation.rb:58:in `invoke'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/step_invocation.rb:37:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:99:in `visit_step'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:158:in `broadcast'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:98:in `visit_step'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/step_collection.rb:15:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/step_collection.rb:14:in `each'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/step_collection.rb:14:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:93:in `visit_steps'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:158:in `broadcast'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:92:in `visit_steps'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/scenario.rb:45:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/step_mother.rb:191:in `before_and_after'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/scenario.rb:43:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/scenario.rb:98:in `with_visitor'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/scenario.rb:37:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:51:in `visit_feature_element'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:158:in `broadcast'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:50:in `visit_feature_element'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/feature.rb:25:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/feature.rb:24:in `each'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/feature.rb:24:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:20:in `visit_feature'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:158:in `broadcast'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:19:in `visit_feature'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/features.rb:29:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/features.rb:17:in `each'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/features.rb:17:in `each'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/features.rb:28:in `accept'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:14:in `visit_features'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:158:in `broadcast'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/ast/tree_walker.rb:13:in `visit_features'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/cli/main.rb:55:in `execute!'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/../lib/cucumber/cli/main.rb:24:in `execute'
/Users/nicholasrutherford/.gem/ruby/1.8/gems/cucumber-0.4.2/bin/cucumber:9
/Users/nicholasrutherford/.gem/ruby/1.8/bin/cucumber:19:in `load'
/Users/nicholasrutherford/.gem/ruby/1.8/bin/cucumber:19
features/visitor_menu/admin/defining_the_visitor_menu.feature:31:in `Then 2 page links should exist'
I can get rid of this error by using "Then 2 page_links should exist"
Comments and changes to this ticket
-
Nicholas Rutherford November 2nd, 2009 @ 09:56 PM
different but related:
Then I should be on the site_images page
works as expected, producing the correct path_to(page_name) from webrat's paths (augmented by script/generate pickle paths)
but using
Then I should be on the site_images page
produces
(rdb:1) path_to("the site images page") "/site_images.%23%3Csite:0x4247940%3E"
-
Nicholas Rutherford September 13th, 2011 @ 09:43 PM
- Assigned user cleared.
- Milestone order changed from 0 to 0
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Assign tickets to <b>Ian White</b>, so I get notified