def inv_to_chk_inv(test, inv): """CHKInventory needs a backing VF, so we create one.""" factory = groupcompress.make_pack_factory(True, True, 1) trans = test.get_transport('chk-inv') trans.ensure_base() vf = factory(trans) # We intentionally use a non-standard maximum_size, so that we are more # likely to trigger splits, and get increased test coverage. chk_inv = CHKInventory.from_inventory(vf, inv, maximum_size=100, search_key_name='hash-255-way') return chk_inv
def make_vf(self): t = self.get_transport('') factory = groupcompress.make_pack_factory(True, True, 1) return factory(t)
def make_vf(self): t = self.get_transport("") factory = groupcompress.make_pack_factory(True, True, 1) return factory(t)