Skip to content

Commit

Permalink
Merge pull request #681 from graalvm/bug/sbom-integration-test-jackson
Browse files Browse the repository at this point in the history
Fix type issue in SBOM integration test
  • Loading branch information
rudsberg authored Jan 21, 2025
2 parents d6697e5 + 62ef1fe commit 650ec33
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,14 @@ class SBOMFunctionalTest extends AbstractGraalVMMavenFunctionalTest {
assert mainComponentDependency.get('dependsOn').isEmpty()
// Check that the main component is not found in "components"
assert !rootNode.get('components').any { it.get('bom-ref').asText() == mainComponentId }
assert !rootNode.get('components').any { component ->
def bomRef = component.get('bom-ref')
if (!bomRef) {
return false
}
def bomRefValue = bomRef instanceof String ? bomRef : bomRef.asText()
bomRefValue == mainComponentId
}
return true
} catch (AssertionError | Exception e) {
Expand Down

0 comments on commit 650ec33

Please sign in to comment.