Skip to content

Commit

Permalink
add license map to self test
Browse files Browse the repository at this point in the history
  • Loading branch information
ytausch committed Aug 19, 2024
1 parent 0ce0e4e commit f0ca4bb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/license/test_discovery.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,14 @@ def test_short_license_id(licence_name, short_licence):
assert get_short_license_id(licence_name) == short_licence


@pytest.mark.parametrize(
"license_id", [lic["licenseId"] for lic in get_all_licenses_from_spdx()]
)
def test_short_license_id_map_to_self(license_id: str):
print(license_id)
assert get_short_license_id(license_id) == license_id


def test_get_other_names_from_opensource():
assert sorted(get_other_names_from_opensource("MIT")) == sorted(["MIT", "Expat"])

Expand Down

0 comments on commit f0ca4bb

Please sign in to comment.