fix TestFindOrgs

This commit is contained in:
yp05327 2023-07-21 08:20:20 +00:00
parent 63562c31b8
commit 4d42a63805
4 changed files with 6 additions and 6 deletions

View File

@ -161,7 +161,7 @@
commit_id: 'cb24c347e328d83c1e0c3c908a6b2c0a2fcb8a3d'
commit_message: 'add'
commit_time: 1689838761
pusher_id: 4
pusher_id: 18
is_deleted: false
deleted_by_id: 0
deleted_unix: 0
@ -173,7 +173,7 @@
commit_id: '65f1bf27bc3bf70f64657658635e66094edbcb4d'
commit_message: 'Initial commit'
commit_time: 1489927679
pusher_id: 4
pusher_id: 18
is_deleted: false
deleted_by_id: 0
deleted_unix: 0

View File

@ -108,7 +108,7 @@
-
id: 19
uid: 4
uid: 18
org_id: 38
is_public: false

View File

@ -134,7 +134,7 @@
id: 23
org_id: 38
team_id: 23
uid: 4
uid: 18
-
id: 24

View File

@ -207,8 +207,8 @@ func TestFindRecentlyPushedNewBranches(t *testing.T) {
assert.Equal(t, "user-fork-new-commit", branches[0].Name)
// test new branch from private org with code permisstion repo
user4 := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 4})
branches, err = git_model.FindRecentlyPushedNewBranches(db.DefaultContext, repo, user4, 1689838760)
user18 := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 18})
branches, err = git_model.FindRecentlyPushedNewBranches(db.DefaultContext, repo, user18, 1689838760)
assert.NoError(t, err)
assert.Equal(t, 1, len(branches))
assert.Equal(t, "private-org-fork-new-commit", branches[0].Name)