mirror of
https://github.com/anchore/syft.git
synced 2026-11-01 15:06:36 +01:00
Require ordering of relationships when comparing parser output (#2160)
* require ordering of relationships when comparing parser output Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * [wip] fix cataloger test Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> * change method of relationship sort to simple string dump Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com> --------- Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
This commit is contained in:
@@ -271,6 +271,11 @@ func TestParseConanlock(t *testing.T) {
|
||||
},
|
||||
}
|
||||
|
||||
// relationships require IDs to be set to be sorted similarly
|
||||
for i := range expected {
|
||||
expected[i].SetID()
|
||||
}
|
||||
|
||||
var expectedRelationships = []artifact.Relationship{
|
||||
{
|
||||
From: expected[1], // boost
|
||||
|
||||
Reference in New Issue
Block a user