Migrate tests from "model/switch_request_test.go" to use testi… (#12554)
Этот коммит содержится в:
коммит произвёл
Ben Schumacher
родитель
f21b7618a4
Коммит
041c914de7
@@ -6,6 +6,8 @@ package model
|
|||||||
import (
|
import (
|
||||||
"strings"
|
"strings"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestSwitchRequestJson(t *testing.T) {
|
func TestSwitchRequestJson(t *testing.T) {
|
||||||
@@ -13,7 +15,5 @@ func TestSwitchRequestJson(t *testing.T) {
|
|||||||
json := o.ToJson()
|
json := o.ToJson()
|
||||||
ro := SwitchRequestFromJson(strings.NewReader(json))
|
ro := SwitchRequestFromJson(strings.NewReader(json))
|
||||||
|
|
||||||
if o.Email != ro.Email {
|
require.Equal(t, o.Email, ro.Email, "Emails do not match")
|
||||||
t.Fatal("Emails do not match")
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user