|
7 | 7 | from unittest.mock import MagicMock, NonCallableMagicMock |
8 | 8 |
|
9 | 9 | import pytest |
10 | | -from license_expression import Licensing |
11 | 10 |
|
| 11 | +from spdx_tools.common.spdx_licensing import spdx_licensing |
12 | 12 | from spdx_tools.spdx.jsonschema.annotation_converter import AnnotationConverter |
13 | 13 | from spdx_tools.spdx.jsonschema.package_converter import PackageConverter |
14 | 14 | from spdx_tools.spdx.jsonschema.package_properties import PackageProperty |
@@ -123,9 +123,9 @@ def test_successful_conversion(converter: PackageConverter): |
123 | 123 | checksums=[Checksum(ChecksumAlgorithm.SHA1, "sha1"), Checksum(ChecksumAlgorithm.BLAKE2B_256, "blake")], |
124 | 124 | homepage="homepage", |
125 | 125 | source_info="sourceInfo", |
126 | | - license_concluded=Licensing().parse("MIT and GPL-2.0"), |
127 | | - license_info_from_files=[Licensing().parse("MIT"), Licensing().parse("GPL-2.0")], |
128 | | - license_declared=Licensing().parse("MIT or GPL-2.0 "), |
| 126 | + license_concluded=spdx_licensing.parse("MIT and GPL-2.0"), |
| 127 | + license_info_from_files=[spdx_licensing.parse("MIT"), spdx_licensing.parse("GPL-2.0")], |
| 128 | + license_declared=spdx_licensing.parse("MIT or GPL-2.0 "), |
129 | 129 | license_comment="licenseComment", |
130 | 130 | copyright_text="copyrightText", |
131 | 131 | summary="summary", |
@@ -168,9 +168,9 @@ def test_successful_conversion(converter: PackageConverter): |
168 | 168 | ], |
169 | 169 | converter.json_property_name(PackageProperty.HOMEPAGE): "homepage", |
170 | 170 | converter.json_property_name(PackageProperty.SOURCE_INFO): "sourceInfo", |
171 | | - converter.json_property_name(PackageProperty.LICENSE_CONCLUDED): "MIT AND GPL-2.0", |
172 | | - converter.json_property_name(PackageProperty.LICENSE_INFO_FROM_FILES): ["MIT", "GPL-2.0"], |
173 | | - converter.json_property_name(PackageProperty.LICENSE_DECLARED): "MIT OR GPL-2.0", |
| 171 | + converter.json_property_name(PackageProperty.LICENSE_CONCLUDED): "MIT AND GPL-2.0-only", |
| 172 | + converter.json_property_name(PackageProperty.LICENSE_INFO_FROM_FILES): ["MIT", "GPL-2.0-only"], |
| 173 | + converter.json_property_name(PackageProperty.LICENSE_DECLARED): "MIT OR GPL-2.0-only", |
174 | 174 | converter.json_property_name(PackageProperty.LICENSE_COMMENTS): "licenseComment", |
175 | 175 | converter.json_property_name(PackageProperty.COPYRIGHT_TEXT): "copyrightText", |
176 | 176 | converter.json_property_name(PackageProperty.SUMMARY): "summary", |
|
0 commit comments