cyclonedx-core-java icon indicating copy to clipboard operation
cyclonedx-core-java copied to clipboard

ToolInformation - Equals, HashCode, and multi-tool parsing fixes w/tests

Open gdgib-roche opened this issue 1 year ago • 2 comments

  1. The new ToolInformation class did not have equals & hashCode methods, which prevented equality checks during downstream unit testing
  2. The custom deserializer for ToolInformation did not correctly handle multiple components & services, in XML format due to the way jackson nests the nodes

gdgib-roche avatar Apr 18 '24 17:04 gdgib-roche

Just added a unit test for serialization along with fixes to that too. FWIW, the previous code was semi-symmetrical across serialization & deserialization, it just also didn't work or generate/parse the expected XML. My sympathy to whoever had to understand the jackson internals enough to do this, I find them sometime frustratingly complex and I'm an expert on this kind of stuff.

gdgib-roche avatar Apr 25 '24 18:04 gdgib-roche

Will look into the failing workflow next week.

gdgib-roche avatar Apr 25 '24 18:04 gdgib-roche