summaryrefslogtreecommitdiff
path: root/spec/controllers/search_controller_spec.rb
Commit message (Collapse)AuthorAgeFilesLines
* Add latest changes from gitlab-org/gitlab@13-4-stable-eeGitLab Bot2020-09-191-33/+74
|
* Add latest changes from gitlab-org/gitlab@13-3-stable-eeGitLab Bot2020-08-201-0/+19
|
* Add latest changes from gitlab-org/gitlab@13-2-stable-eeGitLab Bot2020-07-201-0/+5
|
* Add latest changes from gitlab-org/gitlab@13-1-stable-eeGitLab Bot2020-06-181-6/+1
|
* Add latest changes from gitlab-org/gitlab@13-0-stable-eeGitLab Bot2020-05-201-9/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-03-131-0/+8
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-01-271-6/+6
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-01-141-13/+7
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-12-261-0/+42
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-021-1/+1
|
* Load search result counts asynchronouslyMarkus Koller2019-08-121-90/+112
| | | | | | Querying all counts for the different search results in the same request led to timeouts, so we now only calculate the count for the *current* search results, and request the others in separate asynchronous calls.
* Merge branch 'sh-avoid-loading-pipeline-status' into 'master'Nick Thomas2019-06-271-0/+13
|\ | | | | | | | | Avoid loading pipeline status in search results See merge request gitlab-org/gitlab-ce!30111
| * Avoid loading pipeline status in search resultsStan Hu2019-06-271-0/+13
| | | | | | | | | | | | | | This improves the performance of search, since the pipeline status is not displayed. Identified in https://gitlab.com/gitlab-org/gitlab-ce/issues/56627
* | Enable Gitaly ref caching for SearchControllersh-add-gitaly-ref-caching-search-controllerStan Hu2019-06-261-0/+4
|/ | | | | | | As we noticed in https://gitlab.com/gitlab-org/gitlab-ce/issues/56627#note_185828742, clicking on the "Issues" tab often requests the same reference in rendering Markdown.
* Use wiki partial in search resultsMario de la Ossa2019-04-251-0/+24
|
* Add some frozen string to spec/**/*.rbgfyoung2019-04-151-0/+2
| | | | | | | | | | Adds frozen string to the following: * spec/bin/**/*.rb * spec/config/**/*.rb * spec/controllers/**/*.rb xref https://gitlab.com/gitlab-org/gitlab-ce/issues/59758
* Move Contribution Analytics related spec in ↵Imre Farkas2019-04-091-0/+39
| | | | spec/features/groups/group_page_with_external_authorization_service_spec to EE
* Revert "Merge branch 'if-57131-external_auth_to_ce' into 'master'"Andreas Brandl2019-04-051-39/+0
| | | This reverts merge request !26823
* Move Contribution Analytics related spec in ↵Imre Farkas2019-04-051-0/+39
| | | | spec/features/groups/group_page_with_external_authorization_service_spec to EE
* Enable the Layout/ExtraSpacing cop56392-enable-the-layout-extraspacing-copRémy Coutable2019-01-241-1/+1
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Update specs to rails5 formatblackst0ne-convert-specs-rails5-styleblackst0ne2018-12-191-6/+6
| | | | | | | | | | Updates specs to use new rails5 format. The old format: `get :show, { some: params }, { some: headers }` The new format: `get :show, params: { some: params }, headers: { some: headers }`
* Render a 403 when showing an access denied messagebvl-403-for-external-auth-service-ceBob Van Landuyt2018-06-051-1/+1
| | | | | | | | When we want to show an access denied message to a user, we don't have to hide the resource's existence. So in that case we render a 403, this 403 is not handled by nginx on omnibus installs, making sure the message is visible to the user.
* Port `read_cross_project` ability from EEBob Van Landuyt2018-02-221-0/+26
|
* Change all `:empty_project` to `:project`rs-empty_project-defaultRobert Speicher2017-08-021-4/+4
|
* Correct RSpec/SingleLineHook cop offensesRobert Speicher2017-06-141-1/+3
|
* Add traits for ProjectFeatures to Project factorySemyon Pupkov2017-02-051-13/+3
| | | | https://gitlab.com/gitlab-org/gitlab-ce/issues/24007
* Merge branch 'jej-note-search-uses-finder' into 'security' Douwe Maan2016-12-151-0/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix missing Note access checks in by moving Note#search to updated NoteFinder Split from !2024 to partially solve https://gitlab.com/gitlab-org/gitlab-ce/issues/23867 ## Which fixes are in this MR? :warning: - Potentially untested :bomb: - No test coverage :traffic_light: - Test coverage of some sort exists (a test failed when error raised) :vertical_traffic_light: - Test coverage of return value (a test failed when nil used) :white_check_mark: - Permissions check tested ### Note lookup without access check - [x] :white_check_mark: app/finders/notes_finder.rb:13 :download_code check - [x] :white_check_mark: app/finders/notes_finder.rb:19 `SnippetsFinder` - [x] :white_check_mark: app/models/note.rb:121 [`Issue#visible_to_user`] - [x] :white_check_mark: lib/gitlab/project_search_results.rb:113 - This is the only use of `app/models/note.rb:121` above, but importantly has no access checks at all. This means it leaks MR comments and snippets when those features are `team-only` in addition to the issue comments which would be fixed by `app/models/note.rb:121`. - It is only called from SearchController where `can?(current_user, :download_code, @project)` is checked, so commit comments are not leaked. ### Previous discussions - [x] https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#b915c5267a63628b0bafd23d37792ae73ceae272_13_13 `: download_code` check on commit - [x] https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#b915c5267a63628b0bafd23d37792ae73ceae272_19_19 `SnippetsFinder` should be used - `SnippetsFinder` should check if the snippets feature is enabled -> https://gitlab.com/gitlab-org/gitlab-ce/issues/25223 ### Acceptance criteria met? - [x] Tests added for new code - [x] TODO comments removed - [x] Squashed and removed skipped tests - [x] Changelog entry - [ ] State Gitlab versions affected and issue severity in description - [ ] Create technical debt issue for NotesFinder. - Either split into `NotesFinder::ForTarget` and `NotesFinder::Search` or consider object per notable type such as `NotesFinder::OnIssue`. For the first option could create `NotesFinder::Base` which is either inherited from or which can be included in the other two. - Avoid case statement anti-pattern in this finder with use of `NotesFinder::OnCommit` etc. Consider something on the finder for this? `Model.finder(user, project)` - Move `inc_author` to the controller, and implement `related_notes` to replace `non_diff_notes`/`mr_and_commit_notes` See merge request !2035
* Remove invalid testDmitriy Zaporozhets2014-01-091-18/+0
| | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Updated convience method to privateIzaak Alpert2013-11-131-1/+1
|
* Allow public repo searchingIzaak Alpert2013-11-131-0/+18
GITLAB-1386 Change-Id: I9a0bbe8db1a9bb00cef33b3e1854d78844b70a45