diff options
author | Morlinest <morlinest@gmail.com> | 2017-10-17 17:20:22 +0200 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2017-10-17 23:20:22 +0800 |
commit | ccd3577970b64078eb156a736b1583833f80b4a3 (patch) | |
tree | 4abdd588adfc3f24992953ba2ad6fe0dcf614a6e /models/fixtures | |
parent | af4a094e5d1be13c0fe863c1cd6e56c62b1a9b79 (diff) | |
download | gitea-ccd3577970b64078eb156a736b1583833f80b4a3.tar.gz gitea-ccd3577970b64078eb156a736b1583833f80b4a3.zip |
Fix repository search function (#2689)
* Fix and remove FIXME
* Respect membership visibility
* Fix/rewrite searchRepositoryByName function
* Add unit tests
* Add integration tests
* Remove Searcher completely
* Remove trailing space
Diffstat (limited to 'models/fixtures')
-rw-r--r-- | models/fixtures/access.yml | 26 | ||||
-rw-r--r-- | models/fixtures/org_user.yml | 8 | ||||
-rw-r--r-- | models/fixtures/team.yml | 4 | ||||
-rw-r--r-- | models/fixtures/team_user.yml | 8 | ||||
-rw-r--r-- | models/fixtures/user.yml | 19 |
5 files changed, 59 insertions, 6 deletions
diff --git a/models/fixtures/access.yml b/models/fixtures/access.yml index 34d5c5c594..9c149b78d0 100644 --- a/models/fixtures/access.yml +++ b/models/fixtures/access.yml @@ -38,4 +38,28 @@ id: 7 user_id: 15 repo_id: 24 - mode: 4 # owner
\ No newline at end of file + mode: 4 # owner + +- + id: 8 + user_id: 18 + repo_id: 23 + mode: 4 # owner + +- + id: 9 + user_id: 18 + repo_id: 24 + mode: 4 # owner + +- + id: 10 + user_id: 18 + repo_id: 22 + mode: 2 # write + +- + id: 11 + user_id: 18 + repo_id: 21 + mode: 2 # write
\ No newline at end of file diff --git a/models/fixtures/org_user.yml b/models/fixtures/org_user.yml index c7fe2cf369..50d8ef5e68 100644 --- a/models/fixtures/org_user.yml +++ b/models/fixtures/org_user.yml @@ -37,3 +37,11 @@ is_public: true is_owner: true num_teams: 1 + +- + id: 6 + uid: 18 + org_id: 17 + is_public: false + is_owner: true + num_teams: 1
\ No newline at end of file diff --git a/models/fixtures/team.yml b/models/fixtures/team.yml index 298de648dd..2b2186deae 100644 --- a/models/fixtures/team.yml +++ b/models/fixtures/team.yml @@ -44,5 +44,5 @@ name: Owners authorize: 4 # owner num_repos: 2 - num_members: 1 - unit_types: '[1,2,3,4,5,6,7]' + num_members: 2 + unit_types: '[1,2,3,4,5,6,7]'
\ No newline at end of file diff --git a/models/fixtures/team_user.yml b/models/fixtures/team_user.yml index 8d9d920378..56025bb0b7 100644 --- a/models/fixtures/team_user.yml +++ b/models/fixtures/team_user.yml @@ -32,4 +32,10 @@ id: 6 org_id: 17 team_id: 5 - uid: 15
\ No newline at end of file + uid: 15 + +- + id: 7 + org_id: 17 + team_id: 5 + uid: 18
\ No newline at end of file diff --git a/models/fixtures/user.yml b/models/fixtures/user.yml index e1fbc9e578..73ec1c8593 100644 --- a/models/fixtures/user.yml +++ b/models/fixtures/user.yml @@ -263,5 +263,20 @@ avatar_email: user17@example.com num_repos: 2 is_active: true - num_members: 1 - num_teams: 1
\ No newline at end of file + num_members: 2 + num_teams: 1 + +- + id: 18 + lower_name: user18 + name: user18 + full_name: User 18 + email: user18@example.com + passwd: 7d93daa0d1e6f2305cc8fa496847d61dc7320bb16262f9c55dd753480207234cdd96a93194e408341971742f4701772a025a # password + type: 0 # individual + salt: ZogKvWdyEx + is_admin: false + avatar: avatar18 + avatar_email: user18@example.com + num_repos: 0 + is_active: true
\ No newline at end of file |