~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_tree.py

Convert the test_delta tests to intertree_implementation and workingtree_implementation tests as appropriate.

Show diffs side-by-side

added added

removed removed

Lines of Context:
61
61
 
62
62
    calls = []
63
63
 
64
 
    def compare(self):
65
 
        self.calls.append(('compare',))
 
64
    def compare(self, specific_files=None):
 
65
        self.calls.append(('compare', specific_files))
66
66
    
67
67
    @classmethod
68
68
    def is_compatible(klass, source, target):
79
79
            InterTree.register_optimiser(RecordingOptimiser)
80
80
            tree = self.make_branch_and_tree('1')
81
81
            tree2 = self.make_branch_and_tree('2')
 
82
            # do a series of calls:
 
83
            # trivial usage
82
84
            tree.compare(tree2)
 
85
            # pass in all optional arguments by position
 
86
            tree.compare(tree2, 'specific')
 
87
            # pass in all optional arguments by keyword
 
88
            tree.compare(tree2, specific_files='specific')
83
89
        finally:
84
90
            InterTree._optimisers = old_optimisers
85
 
        self.assertEqual([('compare',)], RecordingOptimiser.calls)
 
91
        self.assertEqual(
 
92
            [
 
93
             ('compare', None),
 
94
             ('compare', 'specific'),
 
95
             ('compare', 'specific'),
 
96
            ], RecordingOptimiser.calls)