コード例 #1
0
def test_pr_is_do_not_merge():
    labels = [
        {
            "name": "awaiting merge"
        },
        {
            "name": "DO-NOT-MERGE"
        },
    ]
    assert util.pr_is_awaiting_merge(labels) is False

    labels = [{"name": "CLA not signed"}, {"name": "awaiting merge"}]
    assert util.pr_is_awaiting_merge(labels) is False

    labels = [
        {
            "name": "CLA not signed"
        },
        {
            "name": "awaiting merge"
        },
        {
            "name": "DO-NOT-MERGE"
        },
    ]
    assert util.pr_is_awaiting_merge(labels) is False
コード例 #2
0
def test_pr_is_not_awaiting_merge():
    labels = [{
        "name": "CLA Signed",
        "name": "skip issue",
        "name": "awaiting review"
    }]
    assert util.pr_is_awaiting_merge(labels) is False
コード例 #3
0
def test_pr_is_awaiting_merge():
    labels = [{"name": "awaiting merge"}]
    assert util.pr_is_awaiting_merge(labels) is True