示例#1
0
def test__validate_with_incorrect_multifile_field():
    tag = {
        "name": "Name",
        "description": "Description",
        "multifile": "Multifile"
    }
    assert _validate(tag, []) is False
示例#2
0
def test__validate_with_not_supported_category():
    tag = {
        "name": "Name",
        "description": "Description",
        "multifile": "true",
        "categories": ["category1"]
    }
    assert _validate(tag, ["category"]) is False
示例#3
0
def test__validate_without_incorrect_categories_field():
    tag = {
        "name": "Name",
        "description": "Description",
        "multifile": "true",
        "categories": "Categories"
    }
    assert _validate(tag, []) is False
示例#4
0
def test__validate_with_all_fields():
    tag = {
        "name": "Name",
        "description": "Description",
        "multifile": "true",
        "categories": ["category"],
        "pipeline_options": "--option option"
    }
    assert _validate(tag, ["category"]) is True
示例#5
0
def test__validate_without_multifile_field():
    tag = {"name": "Name", "description": "Description"}
    assert _validate(tag, []) is False
示例#6
0
def test__validate_without_description_field():
    tag = {"name": "Name"}
    assert _validate(tag, []) is False
示例#7
0
def test__validate_without_name_field():
    tag = {}
    assert _validate(tag, []) is False