hydra icon indicating copy to clipboard operation
hydra copied to clipboard

v 0.20.0 not working for controllers?

Open ghost opened this issue 15 years ago • 1 comments

Hi there, We're trying to set up hydra, and it works fine for all of our specs in spec/models, but for some reason, our controller tests fail when we try to call a controller action. Here's a sample stack trace:

SystemStackError in 'StaticController should render layout 'basic_with_header_and_footer' for 'learn_more' action' stack level too deep /Users/zozi/zozi/vendor/plugins/render_component/lib/components.rb:138:in process_cleanup_without_render_component' /Users/zozi/zozi/vendor/plugins/render_component/lib/components.rb:138:inprocess_cleanup' /Users/zozi/.gem/ruby/1.8/gems/compass-0.8.17/lib/compass/app_integration/rails/action_controller.rb:7:in process' /Users/zozi/zozi/spec/controllers/test_controller_spec.rb:13: /Users/zozi/.gem/ruby/1.8/gems/rake-0.8.7/lib/rake.rb:636:incall' /Users/zozi/.gem/ruby/1.8/gems/rake-0.8.7/lib/rake.rb:636:in execute' /Users/zozi/.gem/ruby/1.8/gems/rake-0.8.7/lib/rake.rb:631:ineach'

It looks like calling get :action_name is what causes the spec to fail.

Is there a reason why model specs work, but controller specs fail?

Thanks in advance!

ghost avatar Sep 29 '10 21:09 ghost

I have a feeling this might be related to an issue that I have been looking at today. Are you running Rails 3? I've found that if I comment out Hash#stringify_keys in lib/hydra/hash.rb' (which is never used in the project; hydra's test suite also passes without this method) then my controller specs pass. Haven't fully figured out the issue, but take it for what it's worth.

nedcampion avatar Jan 13 '11 18:01 nedcampion