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

Function test_refs_set_sha_prefix

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

Source from the content-addressed store, hash-verified

104
105
106def test_refs_set_sha_prefix(testrepo: Repository) -> None:
107 NEW_COMMIT = '5ebeeebb320790caf276b9fc8b24546d63316533'
108 reference = testrepo.references.get('refs/heads/master')
109 assert reference is not None
110 reference.set_target(NEW_COMMIT[0:6])
111 assert reference.target == NEW_COMMIT
112
113
114def test_refs_get_type(testrepo: Repository) -> None:

Callers

nothing calls this directly

Calls 2

set_targetMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…