From 8aac3fef838b0932772c3e0e5d23b972ace430d9 Mon Sep 17 00:00:00 2001 From: Jono Yang Date: Thu, 11 May 2023 16:55:59 -0700 Subject: [PATCH] Update openssl package builder #74 * Update expected test results Signed-off-by: Jono Yang --- minecode/mappers/openssl.py | 2 +- .../openssl/openssl_mapper_expected.json | 30 +++++++++++++++++-- 2 files changed, 29 insertions(+), 3 deletions(-) diff --git a/minecode/mappers/openssl.py b/minecode/mappers/openssl.py index 72c34429..d7fc6c83 100644 --- a/minecode/mappers/openssl.py +++ b/minecode/mappers/openssl.py @@ -51,7 +51,7 @@ def build_packages(resource_uri, purl=None): version=version, size=resource_uri.size, release_date=parse_date(resource_uri.last_modified_date), - declared_license='OpenSSL License', + extracted_license_statement='OpenSSL License', homepage_url='https://www.openssl.org/', download_url=uri, copyright='Copyright (c) 1998-2018 The OpenSSL Project\nCopyright (c) 1995-1998 Eric A. Young, Tim J. Hudson\nAll rights reserved.', diff --git a/minecode/tests/testfiles/openssl/openssl_mapper_expected.json b/minecode/tests/testfiles/openssl/openssl_mapper_expected.json index 5741f8d7..3854d99d 100644 --- a/minecode/tests/testfiles/openssl/openssl_mapper_expected.json +++ b/minecode/tests/testfiles/openssl/openssl_mapper_expected.json @@ -22,8 +22,34 @@ "code_view_url":"https://github.com/openssl/openssl", "vcs_url":"git+https://github.com/openssl/openssl.git", "copyright":"Copyright (c) 1998-2018 The OpenSSL Project\nCopyright (c) 1995-1998 Eric A. Young, Tim J. Hudson\nAll rights reserved.", - "license_expression":null, - "declared_license":"OpenSSL License", + "holder":null, + "declared_license_expression":"openssl-ssleay", + "declared_license_expression_spdx":"OpenSSL", + "license_detections":[ + { + "license_expression":"openssl-ssleay", + "matches":[ + { + "score":100.0, + "start_line":1, + "end_line":1, + "matched_length":2, + "match_coverage":100.0, + "matcher":"1-hash", + "license_expression":"openssl-ssleay", + "rule_identifier":"openssl-ssleay_2.RULE", + "rule_relevance":100, + "rule_url":"https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/openssl-ssleay_2.RULE", + "matched_text":"OpenSSL License" + } + ], + "identifier":"openssl_ssleay-0967947a-f286-908c-a7e9-120531930cb6" + } + ], + "other_license_expression":null, + "other_license_expression_spdx":null, + "other_license_detections":[], + "extracted_license_statement":"OpenSSL License", "notice_text":null, "source_packages":[], "extra_data":{},