Skip to content

Commit 55f7cb3

Browse files
fix merge
1 parent 1c58cba commit 55f7cb3

File tree

6 files changed

+15
-15
lines changed

6 files changed

+15
-15
lines changed

integrations/api_repo_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -347,8 +347,8 @@ func TestAPIOrgRepoCreate(t *testing.T) {
347347
{ctxUserID: 1, orgName: "user3", repoName: "repo-admin", expectedStatus: http.StatusCreated},
348348
{ctxUserID: 2, orgName: "user3", repoName: "repo-own", expectedStatus: http.StatusCreated},
349349
{ctxUserID: 2, orgName: "user6", repoName: "repo-bad-org", expectedStatus: http.StatusForbidden},
350-
{ctxUserID: 27, orgName: "user3", repoName: "repo-creator", expectedStatus: http.StatusCreated},
351-
{ctxUserID: 27, orgName: "user6", repoName: "repo-not-creator", expectedStatus: http.StatusForbidden},
350+
{ctxUserID: 28, orgName: "user3", repoName: "repo-creator", expectedStatus: http.StatusCreated},
351+
{ctxUserID: 28, orgName: "user6", repoName: "repo-not-creator", expectedStatus: http.StatusForbidden},
352352
}
353353

354354
prepareTestEnv(t)

models/fixtures/user.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@
5050
avatar: avatar3
5151
avatar_email: [email protected]
5252
num_repos: 3
53-
num_members: 2
54-
num_teams: 3
53+
num_members: 3
54+
num_teams: 4
5555

5656
-
5757
id: 4
@@ -102,8 +102,8 @@
102102
avatar: avatar6
103103
avatar_email: [email protected]
104104
num_repos: 0
105-
num_members: 1
106-
num_teams: 1
105+
num_members: 2
106+
num_teams: 2
107107

108108
-
109109
id: 7
File renamed without changes.

models/org_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ func TestUser_GetMembers(t *testing.T) {
101101
assert.NoError(t, org.GetMembers())
102102
if assert.Len(t, org.Members, 3) {
103103
assert.Equal(t, int64(2), org.Members[0].ID)
104-
assert.Equal(t, int64(27), org.Members[1].ID)
104+
assert.Equal(t, int64(28), org.Members[1].ID)
105105
assert.Equal(t, int64(4), org.Members[2].ID)
106106
}
107107
}

models/user_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -153,13 +153,13 @@ func TestSearchUsers(t *testing.T) {
153153
}
154154

155155
testUserSuccess(&SearchUserOptions{OrderBy: "id ASC", Page: 1},
156-
[]int64{1, 2, 4, 5, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 21, 24, 27})
156+
[]int64{1, 2, 4, 5, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 21, 24, 27, 28})
157157

158158
testUserSuccess(&SearchUserOptions{Page: 1, IsActive: util.OptionalBoolFalse},
159159
[]int64{9})
160160

161161
testUserSuccess(&SearchUserOptions{OrderBy: "id ASC", Page: 1, IsActive: util.OptionalBoolTrue},
162-
[]int64{1, 2, 4, 5, 8, 10, 11, 12, 13, 14, 15, 16, 18, 20, 21, 24, 27})
162+
[]int64{1, 2, 4, 5, 8, 10, 11, 12, 13, 14, 15, 16, 18, 20, 21, 24, 28})
163163

164164
testUserSuccess(&SearchUserOptions{Keyword: "user1", OrderBy: "id ASC", Page: 1, IsActive: util.OptionalBoolTrue},
165165
[]int64{1, 10, 11, 12, 13, 14, 15, 16, 18})

models/userlist_test.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ func TestUserListIsPublicMember(t *testing.T) {
1717
orgid int64
1818
expected map[int64]bool
1919
}{
20-
{3, map[int64]bool{2: true, 4: false, 27: true}},
21-
{6, map[int64]bool{5: true, 27: true}},
20+
{3, map[int64]bool{2: true, 4: false, 28: true}},
21+
{6, map[int64]bool{5: true, 28: true}},
2222
{7, map[int64]bool{5: false}},
2323
{25, map[int64]bool{24: true}},
2424
{22, map[int64]bool{}},
@@ -43,8 +43,8 @@ func TestUserListIsUserOrgOwner(t *testing.T) {
4343
orgid int64
4444
expected map[int64]bool
4545
}{
46-
{3, map[int64]bool{2: true, 4: false, 27: false}},
47-
{6, map[int64]bool{5: true, 27: false}},
46+
{3, map[int64]bool{2: true, 4: false, 28: false}},
47+
{6, map[int64]bool{5: true, 28: false}},
4848
{7, map[int64]bool{5: true}},
4949
{25, map[int64]bool{24: false}}, // ErrTeamNotExist
5050
{22, map[int64]bool{}}, // No member
@@ -69,8 +69,8 @@ func TestUserListIsTwoFaEnrolled(t *testing.T) {
6969
orgid int64
7070
expected map[int64]bool
7171
}{
72-
{3, map[int64]bool{2: false, 4: false, 27: false}},
73-
{6, map[int64]bool{5: false, 27: false}},
72+
{3, map[int64]bool{2: false, 4: false, 28: false}},
73+
{6, map[int64]bool{5: false, 28: false}},
7474
{7, map[int64]bool{5: false}},
7575
{25, map[int64]bool{24: true}},
7676
{22, map[int64]bool{}},

0 commit comments

Comments
 (0)