-
-
Couldn't load subscription status.
- Fork 217
feat: Dependency track tags reporting #2473
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
base: master
Are you sure you want to change the base?
feat: Dependency track tags reporting #2473
Conversation
gschafra
commented
Oct 13, 2025
- Allow providing (multiple) tags for dependency track reporting
|
Can you please add some tests for this feature, so we actually know it works correctly? Also, can you please sign off on your commit? See git documentation on how to do this, if you're no familiar. |
7c34e74 to
b49a059
Compare
Are there already any tests in place concerning the reporting to dependency check using command line parameters (like --project-id)? If yes, where can I find those? AFAICS for the Dependency-Track SBOM submission/reporting features (e.g. |
|
O.k.. sorry... find a way using quibble for mocking and call expectations of |
|
You are correct, we don't have tests for that yet! All the more reason to add some imho. |
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! I didn't know about this useful feature before.
|
Will try to implement unit tests next week. Still try to find a way and the code location to test by mocking out the client (using quibble?) doing the requests to dtrack and verify against against call (parameter) expectations (using Sinon.js?). This seems not so easy in the JS world 😞 |
1ad7ff2 to
fbc9c20
Compare
- Allow providing (multiple) tags for dependency track reporting Signed-off-by: Günter Schafranek <[email protected]>
Signed-off-by: Guenter Schafranek <[email protected]>
fbc9c20 to
89c2627
Compare
Signed-off-by: gschafra <[email protected]>
- Reference (link) to dependency-track release v4.12.0 which introduces the feature - API docu links Signed-off-by: Guenter Schafranek <[email protected]>
- Taking dependency-track project id, name, version and tag into account Signed-off-by: Guenter Schafranek <[email protected]>
Signed-off-by: Guenter Schafranek <[email protected]>
Question: How do you manage the fixed package version overrides in the package.json? I've to add |
Signed-off-by: Guenter Schafranek <[email protected]>
Signed-off-by: Guenter Schafranek <[email protected]>
Yeah, unfortunately that's a manual thing -- currently. I added this a couple of days ago and the idea is to at least consciously think about our dependencies, but some form of listing what is missing for easier adding would be nice... I hope I find some time to do that in the next couple of days. |
|
So, the version locking was not a success... I reverted those changes and I kindly ask you to rebase your PR again. If it's not too complicated, you can remove your overrides as well -- or leave them in if everything works with them there. |
Signed-off-by: gschafra <[email protected]>
Signed-off-by: Günter Schafranek <[email protected]>
Signed-off-by: Günter Schafranek <[email protected]>
- since pnpm lock changed to added packages Signed-off-by: Günter Schafranek <[email protected]>
097a00a to
09a2613
Compare
Signed-off-by: Günter Schafranek <[email protected]>
8804aa1 to
24b69ca
Compare
Signed-off-by: gschafra <[email protected]>
…nto dependency-track-tags-support # Conflicts: # lib/cli/index.poku.js
Signed-off-by: Guenter Schafranek <[email protected]>
| it("should successfully report the SBOM with given parent project, name, version and multiple single tags", async () => { | ||
| const serverUrl = "https://dtrack.example.com"; | ||
| const projectName = "cdxgen-test-project"; | ||
| const projectVersion = "1.0.0"; | ||
| const projectTag = "tag1"; |
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're doing such an awesome job, that I hate to bring this up: isn't this just a copy of the above test except now it has a parent set? I'm asking because the test-description says 'multiple' (although it also says 'single'), so I figured this would test with multiple tags...
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.
Yup, test is not ready yet... I'm massively struggling with test stubs (from ESM modules [got]) , which seems not to reset correctly between tests or/and affecting each other concerning expecations (call count). I've "consultated" various info sources (yes, even GPT and co.) but unfortunately without success. I'll dive deeper into this next week when I have some free time.
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.
Please take your time. It will be super cool to have such advanced tests!