MCPcopy Create free account
hub / github.com/libgit2/pygit2 / test_pack_with_delegate

Function test_pack_with_delegate

test/test_packbuilder.py:73–81  ·  view source on GitHub ↗
(testrepo: Repository, tmp_path: Path)

Source from the content-addressed store, hash-verified

71
72
73def test_pack_with_delegate(testrepo: Repository, tmp_path: Path) -> None:
74 # loop through all branches and add each commit to the packbuilder
75 def pack_delegate(pb: PackBuilder) -> None:
76 for branch in pb._repo.branches:
77 br = pb._repo.branches.get(branch)
78 for commit in br.log():
79 pb.add_recur(commit.oid_new)
80
81 confirm_same_repo_after_packing(testrepo, tmp_path, pack_delegate)
82
83
84def setup_second_repo(tmp_path: Path) -> Repository:

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…