diff options
Diffstat (limited to 'api/user_test.go')
-rw-r--r-- | api/user_test.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/api/user_test.go b/api/user_test.go index e236adeaf..8b95bdf55 100644 --- a/api/user_test.go +++ b/api/user_test.go @@ -54,6 +54,13 @@ func TestCreateUser(t *testing.T) { } } + ruser.Data.(*model.User).Email = "test2@nowhere.com" + if _, err := Client.CreateUser(ruser.Data.(*model.User), ""); err != nil { + if err.Message != "An account with that username already exists." { + t.Fatal(err) + } + } + ruser.Data.(*model.User).Email = "" if _, err := Client.CreateUser(ruser.Data.(*model.User), ""); err != nil { if err.Message != "Invalid email" { |