/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 bzrlib/tests/per_workingtree/test_locking.py

merge 2.0 branch rev 4647

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
    errors,
22
22
    lockdir,
23
23
    )
24
 
from bzrlib.tests.workingtree_implementations import TestCaseWithWorkingTree
 
24
from bzrlib.tests.per_workingtree import TestCaseWithWorkingTree
25
25
 
26
26
 
27
27
class TestWorkingTreeLocking(TestCaseWithWorkingTree):
105
105
 
106
106
        :param methodname: The lock method to use to establish locks.
107
107
        """
 
108
        # This write locks the local tree, and then grabs a read lock on a
 
109
        # copy, which is bogus and the test just needs to be rewritten.
 
110
        self.thisFailsStrictLockCheck()
108
111
        # when unlocking the last lock count from tree_write_lock,
109
112
        # the tree should do a flush().
110
113
        # we test that by changing the inventory using set_root_id
128
131
        tree.set_root_id('new-root')
129
132
        # to detect that the inventory is written by unlock, we
130
133
        # first check that it was not written yet.
 
134
        # TODO: This requires taking a read lock while we are holding the above
 
135
        #       write lock, which shouldn't actually be possible
131
136
        reference_tree = tree.bzrdir.open_workingtree()
132
137
        self.assertEqual(old_root, reference_tree.get_root_id())
133
138
        # now unlock the second held lock, which should do nothing.