Skip to content

Commit

Permalink
Improve output for test case
Browse files Browse the repository at this point in the history
Signed-off-by: Dan Luhring <[email protected]>
  • Loading branch information
luhring committed Jan 22, 2021
1 parent 8ecfb59 commit 2c95f98
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions syft/cataloger/javascript/parse_package_json_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ func TestParsePackageJSON_Partial(t *testing.T) { // see https://github.com/anch
t.Fatalf("failed to parse package-lock.json: %+v", err)
}

if len(actual) != 0 {
t.Errorf("no packages should've been returned")
if actualCount := len(actual); actualCount != 0 {
t.Errorf("no packages should've been returned (but got %d packages)", actualCount)
}
}

0 comments on commit 2c95f98

Please sign in to comment.