From 68645839570d37e8b172b25c3249d80e0a4678bd Mon Sep 17 00:00:00 2001 From: yp05327 <576951401@qq.com> Date: Sun, 5 Mar 2023 04:23:51 +0900 Subject: [PATCH] Add default owner team to privated_org and limited_org in unit test (#23109) Related to https://github.com/go-gitea/gitea/pull/22705 's CI result [here](https://drone.gitea.io/go-gitea/gitea/68043/2/16) > IsOrganizationOwner() [E] [63f61849-7] Organization does not have owner team: 23 --- models/fixtures/team.yml | 22 ++++++++++++++++++++++ models/fixtures/user.yml | 4 ++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/models/fixtures/team.yml b/models/fixtures/team.yml index dd434d78a9..be988b8fce 100644 --- a/models/fixtures/team.yml +++ b/models/fixtures/team.yml @@ -151,3 +151,25 @@ num_members: 1 includes_all_repositories: false can_create_org_repo: true + +- + id: 15 + org_id: 22 + lower_name: owners + name: Owners + authorize: 4 # owner + num_repos: 0 + num_members: 0 + includes_all_repositories: false + can_create_org_repo: true + +- + id: 16 + org_id: 23 + lower_name: owners + name: Owners + authorize: 4 # owner + num_repos: 0 + num_members: 0 + includes_all_repositories: false + can_create_org_repo: true \ No newline at end of file diff --git a/models/fixtures/user.yml b/models/fixtures/user.yml index b1c7fc0030..c6081f07d0 100644 --- a/models/fixtures/user.yml +++ b/models/fixtures/user.yml @@ -807,7 +807,7 @@ num_following: 0 num_stars: 0 num_repos: 2 - num_teams: 0 + num_teams: 1 num_members: 0 visibility: 1 repo_admin_change_team_access: false @@ -844,7 +844,7 @@ num_following: 0 num_stars: 0 num_repos: 2 - num_teams: 0 + num_teams: 1 num_members: 0 visibility: 2 repo_admin_change_team_access: false