Beispiel #1
0
def test_git_object_eq():
    git_commit = git.GitCommit(rev="sha1-code",
                               title="this is title",
                               body="this is body")
    git_tag = git.GitTag(rev="sha1-code", name="0.0.1", date="2020-01-21")

    assert git_commit == git_tag
    assert git_commit != "sha1-code"
def test_get_commit_tag_is_a_version(gitcommits, tags):
    commit = gitcommits[0]
    tag = git.GitTag(*TAGS[0])
    current_key = changelog.get_commit_tag(commit, tags)
    assert current_key == tag
def tags() -> list:
    tags = [git.GitTag(*tag) for tag in TAGS]
    return tags