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

Function test_refs_get_shorthand

test/test_refs.py:137–142  ·  view source on GitHub ↗
(testrepo: Repository)

Source from the content-addressed store, hash-verified

135
136
137def test_refs_get_shorthand(testrepo: Repository) -> None:
138 reference = testrepo.references.get('refs/heads/master')
139 assert reference is not None
140 assert reference.shorthand == 'master'
141 reference = testrepo.references.create('refs/remotes/origin/master', LAST_COMMIT)
142 assert reference.shorthand == 'origin/master'
143
144
145def test_refs_set_target_with_message(testrepo: Repository) -> None:

Callers

nothing calls this directly

Calls 2

getMethod · 0.45
createMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…