Skip to content

Commit

Permalink
fix: tests in handlers
Browse files Browse the repository at this point in the history
  • Loading branch information
shridarpatil committed Jun 7, 2024
1 parent eb82101 commit 98d9ac0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/otpgateway/handlers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ func init() {
constants: constants{
OtpTTL: 10 * time.Second,
OtpMaxAttempts: 10,
OtpMaxGenerate: 10,
},
store: redis.New(redis.Conf{
Host: rd.Host(),
Expand Down Expand Up @@ -248,6 +249,7 @@ func TestCheckOTPAttempts(t *testing.T) {
p.Set("id", dummyOTPID)
p.Set("otp", dummyOTP)
p.Set("max_attempts", "5")
p.Set("max_generate", "5")
p.Set("to", dummyToAddress)
p.Set("provider", dummyProvider)

Expand Down Expand Up @@ -287,6 +289,7 @@ func TestDeleteOnOTPCheck(t *testing.T) {
p.Set("id", dummyOTPID)
p.Set("otp", dummyOTP)
p.Set("max_attempts", "5")
p.Set("max_generate", "5")
p.Set("to", dummyToAddress)
p.Set("provider", dummyProvider)

Expand Down

0 comments on commit 98d9ac0

Please sign in to comment.