-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(nodejs): add license parser to pnpm analyser #7036
Merged
Merged
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
782557f
feat(nodejs) add more tests for pnpm analyser
oscarbc96 b3899cc
feat(nodejs) add more tests for pnpm analyser
oscarbc96 5a07ec0
feat(nodejs) add license to pnpm analyser
oscarbc96 0e90bcc
Merge branch 'aquasecurity:main' into main
oscarbc96 c27fb90
update docs
oscarbc96 d360db3
fix variable
oscarbc96 a17cece
fix required method
oscarbc96 c08e0fc
trigger ci
oscarbc96 52ab6fd
fix import order / linting
oscarbc96 7ea2074
fix nit
oscarbc96 9253830
Merge branch 'aquasecurity:main' into main
oscarbc96 13472d5
fix tests
oscarbc96 32c6e44
Merge branch 'aquasecurity:main' into main
oscarbc96 8d23465
update tests
oscarbc96 3abf950
update docs
oscarbc96 c17d457
update tests
oscarbc96 3d7f877
remove licenceClassifier and comparer
oscarbc96 b746a75
add integration test
oscarbc96 602b4d9
test(integration): add `list-all-pkgs` for pnpm test case + update go…
DmitriyLewen File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
108 changes: 108 additions & 0 deletions
108
...tdata/fixtures/repo/pnpm/node_modules/.pnpm/jquery@3.3.9/node_modules/jquery/package.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
17 changes: 17 additions & 0 deletions
17
...data/fixtures/repo/pnpm/node_modules/.pnpm/lodash@4.17.4/node_modules/lodash/package.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"SchemaVersion": 2, | ||
"CreatedAt": "2021-08-25T12:20:30.000000005Z", | ||
"ArtifactName": "testdata/fixtures/repo/pnpm", | ||
"ArtifactType": "repository", | ||
"Metadata": { | ||
"ImageConfig": { | ||
"architecture": "", | ||
"created": "0001-01-01T00:00:00Z", | ||
"os": "", | ||
"rootfs": { | ||
"type": "", | ||
"diff_ids": null | ||
}, | ||
"config": {} | ||
} | ||
}, | ||
"Results": [ | ||
{ | ||
"Target": "OS Packages", | ||
"Class": "license" | ||
}, | ||
{ | ||
"Target": "pnpm-lock.yaml", | ||
"Class": "license", | ||
"Licenses": [ | ||
{ | ||
"Severity": "LOW", | ||
"Category": "notice", | ||
"PkgName": "jquery", | ||
"FilePath": "pnpm-lock.yaml", | ||
"Name": "MIT", | ||
"Confidence": 1, | ||
"Link": "" | ||
}, | ||
{ | ||
"Severity": "LOW", | ||
"Category": "notice", | ||
"PkgName": "lodash", | ||
"FilePath": "pnpm-lock.yaml", | ||
"Name": "MIT", | ||
"Confidence": 1, | ||
"Link": "" | ||
} | ||
] | ||
}, | ||
{ | ||
"Target": "Loose File License(s)", | ||
"Class": "license-file" | ||
} | ||
] | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need to create a new gold file.
You need to update
testdata/pnpm.json.golden
file.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if I'm doing this right; the
testdata/pnpm.json.golden
file is not updating. 🤔I'm running
mage test:updateGolden
. @DmitriyLewen Can you help me figure out what might be wrong?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, i missed that
list-all-pkgs
flag is not used forpnpm
testcase.I added flag and updated golden file in 602b4d9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!