#34 ✓hold
Rob Sanheim

cache_fu: make action caching stuff work with edge rails

Reported by Rob Sanheim | July 12th, 2007 @ 11:30 PM

This patch was tested against edge rails, revision 6881 (from may 28th).

Its needed because there is a new :cache_path option allowed in core action caching to override the path for the cached action. This is not in 1.2 gem Rails or 1.2.3 stable in svn. I'm guessing cache_fu could be made to play nice with either edge or stable, but it would require more time and testing.

I've separated out the new specs that are strictly for edge rails at the bottom of the fragment cache spec.

Comments and changes to this ticket

  • Rob Sanheim
  • Chris Wanstrath

    Chris Wanstrath July 12th, 2007 @ 11:30 PM

    • State changed from “new” to “open”

    I would really hate to break cache_fu for the plebians not running on edge. Maybe it's as simple as adding an ActsAsCached.on_edge? method and a) hiding the tests behind that b) defining stuff in the fragment_cache.rb conditionally? It could simply check if a controller responds to action_cache_path, which I think is a sure-fire sign of edgeness.

    What do you think? I bring it up because I usually run cache_fu tests against both edge and gems, and with this patch my gems version falls flat on its face.

  • Rob Sanheim

    Rob Sanheim July 12th, 2007 @ 11:30 PM

    Yeah, something like testing for edge should be possible. I'll take a look at making the patch more robust soon...

  • Chris Wanstrath

    Chris Wanstrath July 12th, 2007 @ 11:30 PM

    • State changed from “open” to “hold”

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.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Shared Ticket Bins

People watching this ticket

Referenced by

Pages