Skip to content

Conversation

MarcelBochtler
Copy link
Member

@MarcelBochtler MarcelBochtler commented May 6, 2025

This test is currently expected to fail due to a bug in the
cyclonedx-core-java 1.

@MarcelBochtler MarcelBochtler requested a review from a team as a code owner May 6, 2025 11:26
@MarcelBochtler MarcelBochtler marked this pull request as draft May 6, 2025 11:26
@MarcelBochtler MarcelBochtler force-pushed the invalid-cyclonedx-xml branch 2 times, most recently from f1560eb to e075508 Compare May 6, 2025 11:35
@@ -94,6 +96,30 @@ class CycloneDxReporterFunTest : WordSpec({
}
}

"create the expected XML file with authors" {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe instead of adding a new separate test, it would make sense to instead enhance the input of "create the expected XML file". For enhancing it withAuthors() imo is ok. Furthermore, the analog JSON test case IMO should also use / keep on using the same input, so that XML and JSON tests remain analog.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MarcelBochtler would you agree with above? (and update the commit)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MarcelBochtler would you agree with above? (and update the commit)

I would agree if the tests would pass.

But as the test is currently expected to fail, it would either have to be disabled or not being merged at all.
If I add the withAuthors() to the "create the expected XML file" file, we can no longer disable the test.

I'm not sure how to continue here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how to continue here.

I think the best we can do is to either push at CycloneDX/cyclonedx-core-java#638 for a fix, or contribute the fix ourselves.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would agree if the tests would pass.

If we re-target this commit to update the test input data to illustrate an issue with the authors (not serialized), wouldn't the be ok? (And once it's fixed upstream and integrated, the expected results would be updated for good). (If this was merged as-is, then we have to revert it and update the existing tests, which seems unnecessary work)

@sschuberth

This comment was marked as outdated.

Copy link

codecov bot commented May 6, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 56.62%. Comparing base (9a0dbe8) to head (f71bedb).

Additional details and impacted files
@@            Coverage Diff            @@
##               main   #10271   +/-   ##
=========================================
  Coverage     56.62%   56.62%           
  Complexity     1630     1630           
=========================================
  Files           332      332           
  Lines         12324    12324           
  Branches       1139     1139           
=========================================
  Hits           6979     6979           
  Misses         4914     4914           
  Partials        431      431           
Flag Coverage Δ
test-ubuntu-24.04 40.65% <ø> (ø)
test-windows-2022 40.63% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@sschuberth
Copy link
Member

@MarcelBochtler how do we proceed here? I believe the test now proves that there is a problem. So are we good to report this bug upstream?

@MarcelBochtler
Copy link
Member Author

@MarcelBochtler how do we proceed here? I believe the test now proves that there is a problem. So are we good to report this bug upstream?

I reported it upstream already: CycloneDX/cyclonedx-core-java#638
I also mentioned this in the commit message.

@sschuberth
Copy link
Member

I reported it upstream already: CycloneDX/cyclonedx-core-java#638

👍🏻

I also mentioned this in the commit message.

Sorry, I was looking the inital post only, which just generally links to https://github.com/CycloneDX/cyclonedx-core-java.

This test is currently expected to fail due to a bug in the
cyclonedx-core-java [1].

[1]: CycloneDX/cyclonedx-core-java#638

Signed-off-by: Marcel Bochtler <[email protected]>
@MarcelBochtler MarcelBochtler force-pushed the invalid-cyclonedx-xml branch from 44103f4 to f71bedb Compare May 23, 2025 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants