Beispiel #1
0
def test_merge_commit_detection_pygit2(repository_with_merge_commits):
    """Test detection of merge and non-merge commits with PyGit2."""
    pytest.importorskip("pygit2")
    commits = _pygit2_commits('HEAD^..', repository_with_merge_commits)
    first_commit, second_commit = commits
    assert _is_merge_commit(commits[0])
    assert not _is_merge_commit(commits[1])
Beispiel #2
0
def test_merge_commit_detection_git(repository_with_merge_commits):
    """Test detection of merge and non-merge commits with GitPython."""
    pytest.importorskip("git")
    commits = _git_commits('HEAD^..', repository_with_merge_commits)
    first_commit, second_commit = commits
    assert _is_merge_commit(first_commit)
    assert not _is_merge_commit(second_commit)
def test_merge_commit_detection_pygit2(repository_with_merge_commits):
    """Test detection of merge and non-merge commits with PyGit2."""
    pytest.importorskip("pygit2")
    commits = _pygit2_commits('HEAD^..', repository_with_merge_commits)
    first_commit, second_commit = commits
    assert _is_merge_commit(commits[0])
    assert not _is_merge_commit(commits[1])
def test_merge_commit_detection_git(repository_with_merge_commits):
    """Test detection of merge and non-merge commits with GitPython."""
    pytest.importorskip("git")
    commits = _git_commits('HEAD^..', repository_with_merge_commits)
    assert _is_merge_commit(commits[0])
    assert not _is_merge_commit(commits[1])