コード例 #1
0
ファイル: test_europeana.py プロジェクト: tushar912/cccatalog
def test_get_license_url_with_multiple_license():
    rights_field = [
        "http://noncc.org/",
        "http://creativecommons.org/publicdomain/zero/1.0/"
    ]
    expect_license = "http://creativecommons.org/publicdomain/zero/1.0/"
    assert europeana._get_license_url(rights_field) == expect_license
コード例 #2
0
def test_get_license_url_with_non_cc_license():
    rights_field = ["http://noncc.org/"]

    assert europeana._get_license_url(rights_field) is None
コード例 #3
0
def test_get_license_url_with_real_example():
    rights_field = ["http://creativecommons.org/publicdomain/zero/1.0/"]

    assert europeana._get_license_url(
        rights_field) == "http://creativecommons.org/publicdomain/zero/1.0/"