Skip to content

Commit 8cbd005

Browse files
committed
[TESTS] createUser via the user model helper for integration tests (squash)
See https://codeberg.org/forgejo/forgejo/pulls/2295
1 parent c6a53c3 commit 8cbd005

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

tests/integration/integration_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,8 +286,7 @@ func createUser(ctx context.Context, t testing.TB, user *user_model.User) func()
286286
assert.NoError(t, db.Insert(ctx, user))
287287

288288
if len(user.Email) > 0 {
289-
changePrimaryEmail := true
290-
assert.NoError(t, user_model.UpdateUser(ctx, user, changePrimaryEmail))
289+
assert.NoError(t, user_service.ReplacePrimaryEmailAddress(ctx, user, user.Email))
291290
}
292291

293292
return func() {

0 commit comments

Comments
 (0)