mirror of
https://github.com/anchore/syft.git
synced 2026-11-01 23:16:30 +01:00
fix: improve node classifier version matching (#3284)
Signed-off-by: witchcraze <witchcraze@gmail.com>
This commit is contained in:
@@ -625,6 +625,36 @@ func Test_Cataloger_PositiveCases(t *testing.T) {
|
||||
Metadata: metadata("go-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "node/0.10.48/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
Name: "node",
|
||||
Version: "0.10.48",
|
||||
PURL: "pkg:generic/node@0.10.48",
|
||||
Locations: locations("node"),
|
||||
Metadata: metadata("nodejs-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "node/0.12.18/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
Name: "node",
|
||||
Version: "0.12.18",
|
||||
PURL: "pkg:generic/node@0.12.18",
|
||||
Locations: locations("node"),
|
||||
Metadata: metadata("nodejs-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "node/4.9.1/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
Name: "node",
|
||||
Version: "4.9.1",
|
||||
PURL: "pkg:generic/node@4.9.1",
|
||||
Locations: locations("node"),
|
||||
Metadata: metadata("nodejs-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "node/19.2.0/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
|
||||
Reference in New Issue
Block a user