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

Function test_branches_upstream_name

test/test_branch_empty.py:79–86  ·  view source on GitHub ↗
(repo: Repository)

Source from the content-addressed store, hash-verified

77
78
79def test_branches_upstream_name(repo: Repository) -> None:
80 remote_master = repo.branches.remote['origin/master']
81 commit = repo[remote_master.target]
82 assert isinstance(commit, Commit)
83 master = repo.branches.create('master', commit)
84
85 master.upstream = remote_master
86 assert master.upstream_name == 'refs/remotes/origin/master'
87
88
89#

Callers

nothing calls this directly

Calls 1

createMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…