Skip to content

Commit 7136870

Browse files
committed
Use require instead of panicking
Signed-off-by: Nelo-T. Wallus <red.brush9525@fastmail.com> Signed-off-by: Nelo-T. Wallus <n.wallus@sap.com>
1 parent 1d430bf commit 7136870

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

test/e2e/framework/backend.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,7 @@ import (
4242

4343
func StartBackend(t *testing.T, clientConfig *rest.Config, args ...string) (net.Addr, *backend.Server) {
4444
signingKey := securecookie.GenerateRandomKey(32)
45-
if len(signingKey) == 0 {
46-
panic("error creating signing key")
47-
}
45+
require.NotEmpty(t, signingKey, "error creating signing key")
4846

4947
return StartBackendWithoutDefaultArgs(t, clientConfig, append([]string{
5048
"--oidc-issuer-client-secret=ZXhhbXBsZS1hcHAtc2VjcmV0",

0 commit comments

Comments
 (0)