def make_simple_text(self): # TODO: all we really need is a VersionedFile instance, we'd like to # avoid creating all the intermediate stuff factory = knit.make_pack_factory(True, True, 2) self.vf = factory(self.get_transport()) # This assumes nothing special happens during __init__, which may be # valid self.ann = self.module.Annotator(self.vf) # A 'simple|content|' # | # B 'simple|new content|' self.vf.add_lines(self.fa_key, [], ["simple\n", "content\n"]) self.vf.add_lines(self.fb_key, [self.fa_key], ["simple\n", "new content\n"])
def make_no_graph_texts(self): factory = knit.make_pack_factory(False, False, 2) self.vf = factory(self.get_transport()) self.ann = self.module.Annotator(self.vf) self.vf.add_lines(self.fa_key, (), ["simple\n", "content\n"]) self.vf.add_lines(self.fb_key, (), ["simple\n", "new content\n"])