Skip to content

Commit

Permalink
Fixed tests errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
dekiel committed Jan 9, 2025
1 parent b143e0d commit 5e2461d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
2 changes: 0 additions & 2 deletions pkg/oidc/oidc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,6 @@ var _ = Describe("OIDC", func() {
Verifier: verifier,
Logger: logger,
}
// verifierConfig, err = tioidc.NewVerifierConfig(logger, clientID)
Expect(err).NotTo(HaveOccurred())
ctx = context.Background()
rawToken, err = os.ReadFile("test-fixtures/raw-oidc-token")
Expect(err).NotTo(HaveOccurred())
Expand Down
13 changes: 11 additions & 2 deletions pkg/oidc/oidc_unit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,16 @@ import (
)

var _ = Describe("OIDC", func() {
var (
logger *zap.SugaredLogger
)
BeforeEach(func() {
l, err := zap.NewDevelopment()
Expect(err).NotTo(HaveOccurred())

logger = l.Sugar()
})

Describe("maskToken", func() {
It("should mask the token if length is less than 15", func() {
token := "shorttoken"
Expand Down Expand Up @@ -41,7 +51,6 @@ var _ = Describe("OIDC", func() {
var (
tokenProcessor TokenProcessor
err error
logger *zap.SugaredLogger
trustedIssuers map[string]Issuer
rawToken []byte
)
Expand Down Expand Up @@ -74,4 +83,4 @@ var _ = Describe("OIDC", func() {
})
})
})
})
})

0 comments on commit 5e2461d

Please sign in to comment.