283
286
builder.add_file("5", "TREE_ROOT", "name7", "a\nb\nc\nd\ne\nf\n", True)
284
287
builder.change_contents("5", other="a\nz\nc\nd\ne\nf\n",
285
288
this="a\nb\nc\nd\ne\nz\n")
286
builder.merge(merge_factory)
287
self.assertEqual(builder.this.get_file("1").read(), "text4" )
288
self.assertEqual(builder.this.get_file("2").read(), "text2" )
289
self.assertEqual(builder.this.get_file("5").read(),
290
"a\nz\nc\nd\ne\nz\n")
291
self.assertIs(builder.this.is_executable("1"), True)
292
self.assertIs(builder.this.is_executable("2"), False)
293
self.assertIs(builder.this.is_executable("3"), True)
289
conflicts = builder.merge(merge_factory)
291
self.assertEqual([], conflicts)
292
self.assertEqual("text4", builder.this.get_file("1").read())
293
self.assertEqual("text2", builder.this.get_file("2").read())
294
self.assertEqual("a\nz\nc\nd\ne\nz\n",
295
builder.this.get_file("5").read())
296
self.assertTrue(builder.this.is_executable("1"))
297
self.assertFalse(builder.this.is_executable("2"))
298
self.assertTrue(builder.this.is_executable("3"))
296
304
def contents_test_conflicts(self, merge_factory):