diff options
author | Bob Van Landuyt <bob@vanlanduyt.co> | 2019-07-03 19:44:05 +0200 |
---|---|---|
committer | Bob Van Landuyt <bob@vanlanduyt.co> | 2019-07-10 17:15:43 +0200 |
commit | 32184839c3983babe53ea93fc16b7cde5ada95f6 (patch) | |
tree | 80b91701e08c15eafd49f7449e238847736244e2 /spec/fixtures | |
parent | e787676b3752405cbe4ae75788c6cff53154783d (diff) | |
download | gitlab-ce-32184839c3983babe53ea93fc16b7cde5ada95f6.tar.gz |
Fetch users from Phabricator to link to issues
We fetch the users from Phabricator based on their Phabricator ID. If
a user with the same username exists and is a member of the project,
we set them as assignee or author.
When a user is applicable, we also cache it in Redis so we don't have
to perform the request again for the same phid.
Diffstat (limited to 'spec/fixtures')
-rw-r--r-- | spec/fixtures/phabricator_responses/user.search.json | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/spec/fixtures/phabricator_responses/user.search.json b/spec/fixtures/phabricator_responses/user.search.json new file mode 100644 index 00000000000..f3ec653a23e --- /dev/null +++ b/spec/fixtures/phabricator_responses/user.search.json @@ -0,0 +1,62 @@ +{ + "result": { + "data": [ + { + "id": 1, + "type": "USER", + "phid": "PHID-USER-hohoho", + "fields": { + "username": "jane", + "realName": "Jane Doe", + "roles": [ + "admin", + "verified", + "approved", + "activated" + ], + "dateCreated": 1405970599, + "dateModified": 1406705963, + "policy": { + "view": "public", + "edit": "no-one" + } + }, + "attachments": {} + }, + { + "id": 2, + "type": "USER", + "phid": "PHID-USER-hihihi", + "fields": { + "username": "john", + "realName": "John Doe", + "roles": [ + "admin", + "verified", + "approved", + "activated" + ], + "dateCreated": 1403609184, + "dateModified": 1559138722, + "policy": { + "view": "public", + "edit": "no-one" + } + }, + "attachments": {} + } + ], + "maps": {}, + "query": { + "queryKey": null + }, + "cursor": { + "limit": "100", + "after": null, + "before": null, + "order": null + } + }, + "error_code": null, + "error_info": null +} |