~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_lru_cache.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2009-04-16 15:25:00 UTC
  • mfrom: (4294.1.1 jam-integration)
  • Revision ID: pqm@pqm.ubuntu.com-20090416152500-83w2bul0hwhhm7gd
(jam) Remove _LRUNode from the linked list as well as the dict.

Show diffs side-by-side

added added

removed removed

Lines of Context:
138
138
 
139
139
        # We hit the max
140
140
        self.assertEqual(10, len(cache))
 
141
        self.assertEqual([11, 10, 9, 1, 8, 7, 6, 5, 4, 3],
 
142
                         [n.key for n in cache._walk_lru()])
141
143
 
142
144
    def test_cleanup_shrinks_to_after_clean_count(self):
143
145
        cache = lru_cache.LRUCache(max_cache=5, after_cleanup_count=3)