Skip to content

Commit

Permalink
Update expected output post toolkit upgrade #569
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Druez <[email protected]>
  • Loading branch information
tdruez committed May 29, 2023
1 parent 259a51d commit 5701f94
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 162 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
run: make docs

- name: Run tests
run: bin/python manage.py test --verbosity=2 --noinput -k=test_scanpipe_pipes_scancode_make_results_summary
run: bin/python manage.py test --verbosity=2 --noinput
env:
SCANCODEIO_DB_NAME: ${{ env.POSTGRES_DB }}
SCANCODEIO_DB_USER: ${{ env.POSTGRES_USER }}
Expand Down
161 changes: 1 addition & 160 deletions scanpipe/tests/data/scancode/is-npm-1.0.0_summary.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,165 +37,6 @@
]
},
"key_files": [
{
"path": "package/package.json",
"type": "file",
"name": "package.json",
"status": "application-package",
"tag": "",
"extension": ".json",
"size": 563,
"md5": "c843e88ecb274d5d573c71be330bff8b",
"sha1": "943efb8abda9b9cdaa4ea73f5709563b948af50b",
"sha256": "522879426298e078881de533b9b3a82fa3bece1336a84bddacf4620008b5d0a3",
"sha512": "",
"mime_type": "application/json",
"file_type": "JSON data",
"programming_language": "",
"is_binary": false,
"is_text": true,
"is_archive": false,
"is_media": false,
"is_key_file": true,
"detected_license_expression": "mit",
"detected_license_expression_spdx": "MIT",
"license_detections": [
{
"matches": [
{
"score": 100.0,
"matcher": "2-aho",
"end_line": 5,
"rule_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/mit_30.RULE",
"start_line": 5,
"matched_text": " \"license\": \"MIT\",",
"match_coverage": 100.0,
"matched_length": 2,
"rule_relevance": 100,
"rule_identifier": "mit_30.RULE",
"license_expression": "mit"
}
],
"identifier": "mit-3fce6ea2-8abd-6c6b-3ede-a37af7c6efee",
"license_expression": "mit"
}
],
"license_clues": [],
"percentage_of_license_text": 3.33,
"compliance_alert": "",
"copyrights": [],
"holders": [],
"authors": [],
"package_data": [
{
"md5": null,
"name": "is-npm",
"purl": "pkg:npm/[email protected]",
"sha1": null,
"size": null,
"type": "npm",
"holder": null,
"sha256": null,
"sha512": null,
"parties": [
{
"url": "http://sindresorhus.com",
"name": "Sindre Sorhus",
"role": "author",
"type": "person",
"email": "[email protected]"
}
],
"subpath": null,
"vcs_url": "https://github.com/sindresorhus/is-npm",
"version": "1.0.0",
"keywords": [
"npm",
"is",
"check",
"detect",
"env",
"environment"
],
"copyright": null,
"namespace": null,
"extra_data": {},
"qualifiers": {},
"description": "Check if your code is running as an npm script",
"notice_text": null,
"api_data_url": "https://registry.npmjs.org/is-npm/1.0.0",
"dependencies": [
{
"purl": "pkg:npm/ava",
"scope": "devDependencies",
"extra_data": {},
"is_runtime": false,
"is_optional": true,
"is_resolved": false,
"resolved_package": {},
"extracted_requirement": "0.0.3"
}
],
"download_url": "https://registry.npmjs.org/is-npm/-/is-npm-1.0.0.tgz",
"homepage_url": null,
"release_date": null,
"code_view_url": null,
"datasource_id": "npm_package_json",
"file_references": [],
"source_packages": [],
"bug_tracking_url": null,
"primary_language": "JavaScript",
"license_detections": [
{
"matches": [
{
"score": 100.0,
"matcher": "1-spdx-id",
"end_line": 1,
"rule_url": null,
"start_line": 1,
"matched_text": "MIT",
"match_coverage": 100.0,
"matched_length": 1,
"rule_relevance": 100,
"rule_identifier": "spdx-license-identifier-mit-5da48780aba670b0860c46d899ed42a0f243ff06",
"license_expression": "mit"
}
],
"identifier": "mit-a822f434-d61f-f2b1-c792-8b8cb9e7b9bf",
"license_expression": "mit"
}
],
"repository_download_url": "https://registry.npmjs.org/is-npm/-/is-npm-1.0.0.tgz",
"repository_homepage_url": "https://www.npmjs.com/package/is-npm",
"other_license_detections": [],
"other_license_expression": null,
"declared_license_expression": "mit",
"extracted_license_statement": "['MIT']",
"other_license_expression_spdx": null,
"declared_license_expression_spdx": "MIT"
}
],
"for_packages": [
"pkg:npm/[email protected]?uuid=ba110d49-b6f2-4c86-8d89-a6fd34838ca8"
],
"emails": [
{
"email": "[email protected]",
"end_line": 9,
"start_line": 9
}
],
"urls": [
{
"url": "http://sindresorhus.com/",
"end_line": 10,
"start_line": 10
}
],
"extra_data": {},
"content": "{\n \"name\": \"is-npm\",\n \"version\": \"1.0.0\",\n \"description\": \"Check if your code is running as an npm script\",\n \"license\": \"MIT\",\n \"repository\": \"sindresorhus/is-npm\",\n \"author\": {\n \"name\": \"Sindre Sorhus\",\n \"email\": \"[email protected]\",\n \"url\": \"http://sindresorhus.com\"\n },\n \"engines\": {\n \"node\": \">=0.10.0\"\n },\n \"scripts\": {\n \"test\": \"node test.js\"\n },\n \"files\": [\n \"index.js\"\n ],\n \"keywords\": [\n \"npm\",\n \"is\",\n \"check\",\n \"detect\",\n \"env\",\n \"environment\"\n ],\n \"devDependencies\": {\n \"ava\": \"0.0.3\"\n }\n}\n"
},
{
"path": "package/readme.md",
"type": "file",
Expand Down Expand Up @@ -358,7 +199,7 @@
"other_license_expression": "",
"other_license_expression_spdx": "",
"other_license_detections": [],
"extracted_license_statement": "['MIT']",
"extracted_license_statement": "- MIT\n",
"notice_text": "",
"source_packages": [],
"extra_data": {},
Expand Down
1 change: 0 additions & 1 deletion scanpipe/tests/pipes/test_scancode.py
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,6 @@ def test_scanpipe_pipes_scancode_make_results_summary(self, regen=FIXTURES_REGEN

scan_output_location = self.data_location / "is-npm-1.0.0_scan_package.json"
summary = scancode.make_results_summary(project1, scan_output_location)
print(json.dumps(summary, indent=2))
expected_location = self.data_location / "scancode/is-npm-1.0.0_summary.json"
if regen:
expected_location.write_text(json.dumps(summary, indent=2))
Expand Down

0 comments on commit 5701f94

Please sign in to comment.