fix TestCreateExistingUser test

This commit is contained in:
A.Unger
2020-10-15 15:43:10 +02:00
parent 97da31627f
commit d5c5e519ba
2 changed files with 7 additions and 4 deletions
@@ -421,11 +421,14 @@ func TestCreateAccount(t *testing.T) {
// https://github.com/owncloud/ocis/accounts/issues/62
func TestCreateExistingUser(t *testing.T) {
createAccount(t, "user1")
_, err := createAccount(t, "user1")
r, err := createAccount(t, "user1")
assert.NoError(t, err)
r, err = createAccount(t, "user1")
t.Log(r)
// Should give error but it does not
assert.Error(t, err)
assert.NoError(t, err)
assertUserExists(t, getAccount("user1"))
cleanUp(t)
+1 -1
View File
@@ -362,7 +362,7 @@ func (s Service) CreateAccount(ctx context.Context, in *proto.CreateAccountReque
acc.PasswordProfile.Password = ""
}
out = acc
*out = *acc
// TODO: assign user role to all new users for now, as create Account request does not have any role field
if s.RoleService == nil {