summaryrefslogtreecommitdiff
path: root/spec/finders/projects_finder_spec.rb
Commit message (Collapse)AuthorAgeFilesLines
* Resolve "Rename the `Master` role to `Maintainer`" BackendMark Chao2018-07-111-2/+2
|
* Add an option to list only archived projectsMehdi Lahmam2017-08-241-0/+6
| | | | Closes #35994
* Change all `:empty_project` to `:project`rs-empty_project-defaultRobert Speicher2017-08-021-7/+7
|
* Add :owned param to ProjectFinderToon Claes2017-05-301-0/+7
| | | | And use it in the API.
* Change ProjectFinder so starred can be combined with other filtersToon Claes2017-05-301-1/+7
| | | | | The `starred` parameter couldn't be used in combination with `trending` or `non_public`. But this is changed now.
* ProjectsFinder should handle more optionsJacopo2017-04-061-11/+117
| | | | | | | | | | | | | | | | | | | Extended ProjectFinder in order to handle the following options: - current_user - which user use - project_ids_relation: int[] - project ids to use - params: - trending: boolean - non_public: boolean - starred: boolean - sort: string - visibility_level: int - tags: string[] - personal: boolean - search: string - non_archived: boolean GroupProjectsFinder now inherits from ProjectsFinder. Changed the code in order to use the new available options.
* Use `:empty_project` where possible in finder specsrs-empty_project-findersRobert Speicher2017-01-251-4/+4
|
* Allow Member.add_user to handle access requestersRémy Coutable2016-09-281-1/+1
| | | | | | | | | | | | | | | | | | | | | Changes include: - Ensure Member.add_user is not called directly when not necessary - New GroupMember.add_users_to_group to have the same abstraction level as for Project - Refactor Member.add_user to take a source instead of an array of members - Fix Rubocop offenses - Always use Project#add_user instead of project.team.add_user - Factorize users addition as members in Member.add_users_to_source - Make access_level a keyword argument in GroupMember.add_users_to_group and ProjectMember.add_users_to_projects - Destroy any requester before adding them as a member - Improve the way we handle access requesters in Member.add_user Instead of removing the requester and creating a new member, we now simply accepts their access request. This way, they will receive a "access request granted" email. - Fix error that was previously silently ignored - Stop raising when access level is invalid in Member, let Rails validation do their work Signed-off-by: Rémy Coutable <remy@rymai.me>
* Add a spec for ProjectsFinder project_ids_relation optionAhmad Sherif2016-08-151-0/+8
| | | | Follow-up 1003454c
* Fix ProjectsFinder specAhmad Sherif2016-08-151-57/+12
| | | | Follow-up on 1003454c
* Address feedbackDouwe Maan2016-03-221-1/+1
|
* Fix specsFelipe Artur2016-03-181-1/+1
|
* Bring shared project feature tests from EEDmitriy Zaporozhets2016-03-121-1/+33
| | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Port GitLab EE ProjectsFinder changesgitlab-ee-d39de0ea-backportYorick Peterse2015-11-201-5/+12
| | | | | | | These changes were added in GitLab EE commit d39de0ea91b26b8840195e5674b92c353cc16661. The tests were a bit bugged (they used a non existing group, thus not testing a crucial part) which I only noticed when porting CE changes to EE.
* Refactor ProjectsFinder to not pluck IDsYorick Peterse2015-11-181-35/+40
| | | | | | | | | | | | | | | | | | | This class now uses a UNION (when needed) instead of plucking tens of thousands of project IDs into memory. The tests have also been re-written to ensure all different use cases are tested properly (assuming I didn't forget any cases). The finder has also been broken up into 3 different finder classes: * ContributedProjectsFinder: class for getting the projects a user contributed to. * PersonalProjectsFinder: class for getting the personal projects of a user. * ProjectsFinder: class for getting generic projects visible to a given user. Previously a lot of the logic of these finders was handled directly in the users controller.
* Add `Group#add_*` convenience methodsrs-group-convenience-methodsRobert Speicher2015-08-071-1/+1
| | | | Encapsulates the logic for `Gitlab::Access::WHATEVER` levels.
* Updated rspec to rspec 3.x syntaxJeroen van Baarsen2015-02-121-16/+16
| | | | Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
* Make use of project factory traitsRobert Speicher2014-03-191-4/+4
|
* Update tests and fix Finders readmeDmitriy Zaporozhets2014-02-251-0/+51
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>