We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8bcf3d5 commit 60a9f51Copy full SHA for 60a9f51
1 file changed
scbctl/cmd/scans_test.go
@@ -4,6 +4,7 @@
4
package cmd
5
6
import (
7
+ "context"
8
"errors"
9
"testing"
10
@@ -88,6 +89,16 @@ func TestScanCommand(t *testing.T) {
88
89
t.Errorf("expected no error, but got: %v", err)
90
}
91
92
+ if tc.expectedError == nil {
93
+ scans := &v1.ScanList{}
94
+ if listErr := client.List(context.Background(), scans); listErr != nil {
95
+ t.Fatalf("failed to list scans: %v", listErr)
96
+ }
97
+ if len(scans.Items) != 1 {
98
+ t.Fatalf("expected 1 scan to created but got %d", len(scans.Items))
99
100
101
+
102
})
103
104
0 commit comments