/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/test_diff.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2019-07-27 23:53:10 UTC
  • mfrom: (7356.1.10 exitstack)
  • Revision ID: breezy.the.bot@gmail.com-20190727235310-ccs69jhu4pq55qsi
Use contextlib.ExitStack rather than our homegrown OperationWithCleanups.

Merged from https://code.launchpad.net/~jelmer/brz/exitstack/+merge/369203

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
import tempfile
22
22
 
23
23
from .. import (
 
24
    cleanup,
24
25
    diff,
25
26
    errors,
26
27
    osutils,
1021
1022
 
1022
1023
    def call_gtabtd(self, path_list, revision_specs, old_url, new_url):
1023
1024
        """Call get_trees_and_branches_to_diff_locked."""
 
1025
        exit_stack = cleanup.ExitStack()
 
1026
        self.addCleanup(exit_stack.close)
1024
1027
        return diff.get_trees_and_branches_to_diff_locked(
1025
 
            path_list, revision_specs, old_url, new_url, self.addCleanup)
 
1028
            path_list, revision_specs, old_url, new_url, exit_stack)
1026
1029
 
1027
1030
    def test_basic(self):
1028
1031
        tree = self.make_branch_and_tree('tree')