I’m having trouble testing helpers. I’ve found the topfunky helper
testing plugin (http://nubyonrails.com/articles/2006/04/07/test-your-
helpers), and I’ve seen the helper testing discussion in the rails
recipe book, but both are falling short. Please let me know if I’m
My helpers often need access to current url details, such as the
action and params, and session values. These solutions don’t seem to
What would be really nice is to have a functional test that would
establish the state for the url and session, and then have it yield or
call back so that the helper functions could be tested.
I might be able to do helper tests after the processing of the
request (in a functional test), if I could figure out how to invoke
My best idea so far is to refactor my helper methods so that I have a
version of the function that doesn’t rely on the session or controller
state, and instead has the appropriate values provided as parameters.
Any other ideas or suggestions?