~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_btree_index.py

  • Committer: Aaron Bentley
  • Date: 2008-10-26 10:00:24 UTC
  • mfrom: (0.12.70 shelf-manager)
  • mto: This revision was merged to the branch mainline in revision 3823.
  • Revision ID: aaron@aaronbentley.com-20081026100024-08whjq5p54yah68r
Merge shelf-manager into shelf-ui

Show diffs side-by-side

added added

removed removed

Lines of Context:
434
434
        self.assertEqual(sorted(nodes), nodes)
435
435
        self.assertEqual(16, len(nodes))
436
436
 
 
437
    def test_set_optimize(self):
 
438
        builder = btree_index.BTreeBuilder(key_elements=2, reference_lists=2)
 
439
        builder.set_optimize(for_size=True)
 
440
        self.assertTrue(builder._optimize_for_size)
 
441
        builder.set_optimize(for_size=False)
 
442
        self.assertFalse(builder._optimize_for_size)
 
443
 
437
444
    def test_spill_index_stress_2_2(self):
438
445
        # test that references and longer keys don't confuse things.
439
446
        builder = btree_index.BTreeBuilder(key_elements=2, reference_lists=2,