Testing tal cache states could be easier

Bug #586466 reported by Curtis Hovey
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
High
Gary Poster

Bug Description

There are cases where the cache age will vary based on the state of the object...long ages for complete object and short ages for object being worked. To verify that the cache age matches the state of the object, I inserted a comment.

It would be easier to verify the cache state of a chunk if the tal cache: directive automatically did it. I am only interested in this state for testing, so I only need a verification for the test runner env. I do not want comments in the production pages.

Related branches

Revision history for this message
Gary Poster (gary) wrote :

Implementation thought: it seems to me it would be easiest, and also a nice indication of the machinery working, if the test version of the tal component would show the comment with information about how long the snippet is to be cached when it renders a cached version. That would mean that the first time a view was rendered, the comment would not be present because the content was not cached; the second time, the comment would be present, because you would be seeing cached content. This could also encourage people to verify that cacheing is working as they expect, which wouldn't be all bad.

Changed in launchpad-foundations:
status: New → Triaged
importance: Undecided → High
assignee: nobody → Stuart Bishop (stub)
milestone: none → 10.06
Revision history for this message
Curtis Hovey (sinzui) wrote :

I like the suggestion. I had not considered that the first rendering does not represent a cached version.

Gary Poster (gary)
Changed in launchpad-foundations:
assignee: Stuart Bishop (stub) → Gary Poster (gary)
Revision history for this message
Ursula Junque (ursinha) wrote : Bug fixed by a commit
Changed in launchpad-foundations:
status: Triaged → Fix Committed
tags: added: qa-needstesting
Gary Poster (gary)
tags: added: qa-ok
removed: qa-needstesting
Curtis Hovey (sinzui)
Changed in launchpad-foundations:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.