-
Notifications
You must be signed in to change notification settings - Fork 575
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
refactor: replace cc parser with split functions [CC-1021] #2167
refactor: replace cc parser with split functions [CC-1021] #2167
Conversation
08a6088
to
8b65497
Compare
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.
Looks good. Tests are breaking though, you will need to update the mocking
8b65497
to
c8135f2
Compare
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.
Looks good, I asked for a few small changes
src/cli/commands/test/iac-local-execution/extract-line-number.ts
Outdated
Show resolved
Hide resolved
src/cli/commands/test/iac-local-execution/extract-line-number.ts
Outdated
Show resolved
Hide resolved
ab88d74
to
86aee3d
Compare
86aee3d
to
c200e4c
Compare
c200e4c
to
1ed7d11
Compare
@@ -147,7 +147,7 @@ | |||
"devDependencies": { | |||
"@types/cross-spawn": "^6.0.2", | |||
"@types/fs-extra": "^9.0.11", | |||
"@types/jest": "^26.0.20", | |||
"@types/jest": "^27.0.1", |
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.
This dependency was updated due to failure in regression tests due to the fact that the jest
dependency is a newer version than the types
What does this PR do?
This PR updates the version of the
cloud-config-parser
dependency to use a newer version that takes care of a performance issue.Instead of calculating the treeMap for each line in the file, we are calculating the treeMap once for each file, and sending it to the parser to get the correct line number.
Therefore, for a file that has multiple issues, we only calculate the treeMap once.
Where should the reviewer start?
How should this be manually tested?
snyk iac test
with--json
or--sarif
flags.What are the relevant tickets?
Jira Ticket CC-1021
Snapshots