267
267
print >> file('sub/a.txt', 'wb'), "hello"
268
print >> file('b.txt', 'wb'), "hello"
269
print >> file('sub/c.txt', 'wb'), "hello"
268
270
self.runbzr('init')
269
271
self.runbzr('add')
270
272
self.runbzr(('commit', '-m', 'added a'))
271
273
self.runbzr('branch . ../b')
272
274
print >> file('sub/a.txt', 'ab'), "there"
275
print >> file('b.txt', 'ab'), "there"
276
print >> file('sub/c.txt', 'ab'), "there"
273
277
self.runbzr(('commit', '-m', 'Added there'))
274
278
os.unlink('sub/a.txt')
279
os.unlink('sub/c.txt')
276
282
self.runbzr(('commit', '-m', 'Removed a.txt'))
278
284
print >> file('sub/a.txt', 'ab'), "something"
285
print >> file('b.txt', 'ab'), "something"
286
print >> file('sub/c.txt', 'ab'), "something"
279
287
self.runbzr(('commit', '-m', 'Modified a.txt'))
280
288
self.runbzr('merge ../a/')
281
289
assert os.path.exists('sub/a.txt.THIS')
282
290
assert os.path.exists('sub/a.txt.BASE')
292
self.runbzr('merge ../b/')
293
assert os.path.exists('sub/a.txt.OTHER')
294
assert os.path.exists('sub/a.txt.BASE')
284
296
def test_pull(self):
285
297
"""Pull changes from one branch to another."""