Replaced t.Fatal with require.Equal (#12536)

This commit is contained in:
Nilesh Kevlani
2019-10-03 02:55:36 +05:30
committed by Elias Nahum
parent 2f77622b89
commit 1f6cf84bb2

View File

@@ -6,6 +6,8 @@ package model
import (
"strings"
"testing"
"github.com/stretchr/testify/require"
)
func TestMfaSecretJson(t *testing.T) {
@@ -13,7 +15,5 @@ func TestMfaSecretJson(t *testing.T) {
json := secret.ToJson()
result := MfaSecretFromJson(strings.NewReader(json))
if secret.Secret != result.Secret {
t.Fatal("Secrets do not match")
}
require.Equal(t, secret.Secret, result.Secret, "Secrets do not match")
}