80
80
self.failIf(delta.modified)
83
def test_mkdir_w_nested_trees(self):
84
"""'bzr mkdir' with nested trees"""
95
self.run_bzr('mkdir', 'dir', 'a/dir', 'a/b/dir')
96
self.failUnless(os.path.isdir('dir'))
97
self.failUnless(os.path.isdir('a/dir'))
98
self.failUnless(os.path.isdir('a/b/dir'))
100
from bzrlib.diff import compare_trees
102
b_a = Branch.open('a')
103
b_b = Branch.open('a/b')
105
delta = compare_trees(b.basis_tree(), b.working_tree())
106
self.assertEquals(len(delta.added), 1)
107
self.assertEquals(delta.added[0][0], 'dir')
108
self.failIf(delta.modified)
110
delta = compare_trees(b_a.basis_tree(), b_a.working_tree())
111
self.assertEquals(len(delta.added), 1)
112
self.assertEquals(delta.added[0][0], 'dir')
113
self.failIf(delta.modified)
115
delta = compare_trees(b_b.basis_tree(), b_b.working_tree())
116
self.assertEquals(len(delta.added), 1)
117
self.assertEquals(delta.added[0][0], 'dir')
118
self.failIf(delta.modified)
83
121
def test_branch_add_in_unversioned(self):
84
122
"""Try to add a file in an unversioned directory.