-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add option to for dependency validator to allow list dependenci…
…es that can violate consistency check (#1920) * chore: created param to track inconsistent dependencies * chore: changed knownInconsistentDependencyViolations to record for easier lookup * fix: updated dependency validator to be more general in testing for known inconsistent dependencies * chore: updated error message for incorrect verions * chore: removed unused code * fix: updated tests to include array for new parameter in dependendies validator * chore: removed unnecessary comment * chore: minor adjustment to test * Update scripts/components/dependencies_validator.ts Co-authored-by: Kamil Sobol <[email protected]> * chore: changed variable name, moved find statement * chore: added test for inconsistent dependency that has multiple versions in use * chore: test added to check multiple dependencies that are marked as inconsistent yield correct results * chore: added test for known vs unknown inconsistent dependencies * chore: moved execa comment to check_dependencies.ts * Revert "chore: moved execa comment to check_dependencies.ts" This reverts commit 44a9051. * chore: moved execa comment to check_dependencies from dependencies_validator --------- Co-authored-by: Vieltojarvi <[email protected]> Co-authored-by: Kamil Sobol <[email protected]>
- Loading branch information
1 parent
5d6eef2
commit 5f48700
Showing
9 changed files
with
216 additions
and
13 deletions.
There are no files selected for viewing
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
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
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
9 changes: 9 additions & 0 deletions
9
...onents/test-resources/dependency-version-inconsistent-test-packages/package1/package.json
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,9 @@ | ||
{ | ||
"name": "package1", | ||
"dependencies": { | ||
"glob": "^7.2.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^3.8.2-alpha.6" | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
...onents/test-resources/dependency-version-inconsistent-test-packages/package2/package.json
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,9 @@ | ||
{ | ||
"name": "package2", | ||
"dependencies": { | ||
"glob": "^3.4.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^3.8.2-alpha.6" | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
...onents/test-resources/dependency-version-inconsistent-test-packages/package3/package.json
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,9 @@ | ||
{ | ||
"name": "package2", | ||
"dependencies": { | ||
"glob": "^1.6.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^3.8.2-alpha.6" | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...resources/dependency-version-multiple-inconsistencies-test-packages/package1/package.json
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,12 @@ | ||
{ | ||
"name": "package1", | ||
"dependencies": { | ||
"glob": "^7.2.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^3.8.2-alpha.6" | ||
}, | ||
"peerDependencies": { | ||
"yargs": "~14.2.3" | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...resources/dependency-version-multiple-inconsistencies-test-packages/package2/package.json
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,12 @@ | ||
{ | ||
"name": "package2", | ||
"dependencies": { | ||
"glob": "^7.2.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^2.0.0" | ||
}, | ||
"peerDependencies": { | ||
"yargs": "~14.2.3" | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...resources/dependency-version-multiple-inconsistencies-test-packages/package3/package.json
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,12 @@ | ||
{ | ||
"name": "package3", | ||
"dependencies": { | ||
"glob": "^5.3.0" | ||
}, | ||
"devDependencies": { | ||
"zod": "^3.8.2-alpha.6" | ||
}, | ||
"peerDependencies": { | ||
"yargs": "~14.2.3" | ||
} | ||
} |