mirror of
https://github.com/aquasecurity/trivy.git
synced 2025-12-22 07:10:41 -08:00
fix: include packages unless it is not needed (#6765)
Signed-off-by: knqyf263 <knqyf263@gmail.com>
This commit is contained in:
@@ -39,10 +39,10 @@ type csArgs struct {
|
||||
|
||||
func TestClientServer(t *testing.T) {
|
||||
tests := []struct {
|
||||
name string
|
||||
args csArgs
|
||||
golden string
|
||||
wantErr string
|
||||
name string
|
||||
args csArgs
|
||||
golden string
|
||||
override func(t *testing.T, want, got *types.Report)
|
||||
}{
|
||||
{
|
||||
name: "alpine 3.9",
|
||||
@@ -270,6 +270,9 @@ func TestClientServer(t *testing.T) {
|
||||
Target: "https://github.com/knqyf263/trivy-ci-test",
|
||||
},
|
||||
golden: "testdata/test-repo.json.golden",
|
||||
override: func(t *testing.T, want, got *types.Report) {
|
||||
want.ArtifactName = "https://github.com/knqyf263/trivy-ci-test"
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
@@ -284,7 +287,7 @@ func TestClientServer(t *testing.T) {
|
||||
}
|
||||
|
||||
runTest(t, osArgs, tt.golden, "", types.FormatJSON, runOptions{
|
||||
override: overrideUID,
|
||||
override: overrideFuncs(overrideUID, tt.override),
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user