You can clone with
I have an ordinary helper module that has a method, where part of it's implementation calls the #asset_path helper. This works fine.
I have an ActionView::TestCase that tests/calls this helper. This generally works fine, unless it tries to call the helper method that calls asset_path.
I get a:
undefined method `asset_path' for #<BentoSearchHelperTest:0x0000000f9aefc0>
As you can see I'm using rails 3.2.8.
I believe this is a bug. But correct me if I'm wrong and I'm doing something wrong or something.
Hmmm. I am not sure. @pixeltrix are the url helpers included in ActionView::TestCase? Should they be?
I'm able to reproduce this in 3.2.8
AssetUrlHelper is not included in ActionView::Helpers in 3-2-stable, but it's already fixed in master (@9fa1a54). So it should be ok to include it in 3-2-stable too.
I still seeing this issue in 3.2.9rc2 Not sure if it is fixed in edge since I am having some issues installing from edge at the moment but I believe the commit you pointed to is merged in with the 3.2.3-stable branch.
related to #7218
What is the current status? Should we add the Asset URL helpers to ActionView::Helpers in 3.2.x or is it okay to leave it as it is? Should we close this one (and the related issue), or do we welcome a pull request?
We can fix this one
Is it safe to just backport the commit?
@lunks unfortunately not. That commit change show sprockets glue with Rails to make possible to us extract sprockets-rails.
Adding asset_path to ActionView::Helpers::AssetTagHelper