summaryrefslogtreecommitdiff
path: root/spec/controllers
Commit message (Collapse)AuthorAgeFilesLines
...
* | fix pipelines/index.html.haml merge conflictRegis2017-01-025-3/+140
|\ \ | |/
| * Fix redirect after update file when user has forked projectFelipe Artur2016-12-291-1/+31
| |
| * applies url_for so that we dont lose filters when redirecting19988-prevent-empty-pagination-when-list-not-emptyTiago Botelho2016-12-234-8/+10
| |
| * adds specs for respective behaviourTiago Botelho2016-12-214-2/+107
| |
* | merge master and fix application.rb conflictRegis2016-12-233-4/+79
|\ \ | |/
| * Merge branch '23638-remove-builds-tab' into 'master' Kamil Trzciński2016-12-211-4/+0
| |\ | | | | | | | | | | | | | | | | | | Resolve "Remove Builds tab from Merge Requests and Commits" Closes #23638 See merge request !7763
| | * Removes builds tab from merge requestFilipa Lacerda2016-12-211-4/+0
| | | | | | | | | | | | Fix specs
| * | Merge branch 'zj-mattermost-slash-config' into 'master' Kamil Trzciński2016-12-211-0/+58
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | Mattermost slash auto config Closes #24769 See merge request !8070
| | * | Add new testsZ.J. van de Weg2016-12-211-1/+6
| | | |
| | * | Merge branch 'zj-mattermost-slash-config' of gitlab.com:gitlab-org/gitlab-ce ↵Kamil Trzcinski2016-12-201-0/+53
| | |\ \ | | | | | | | | | | | | | | | into zj-mattermost-slash-config
| | | * | Add controller testZ.J. van de Weg2016-12-201-0/+53
| | | | |
| * | | | Merge branch 'fix/group-path-rename-error' into 'master' Douwe Maan2016-12-211-0/+21
| |\ \ \ \ | | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | Fix error 500 renaming group. Also added specs and changelog. Closes #17922 and #23223 See merge request !8201
| | * | | added more specsJames Lopez2016-12-211-2/+2
| | | | |
| | * | | Fix error 500 renaming group. Also added specs and changelog.James Lopez2016-12-201-0/+21
| | |/ /
* | | | Add controller specs for pipeline index API endpointGrzegorz Bizon2016-12-211-1/+21
|/ / / | | | | | | | | | [ci skip]
* | | Merge branch '19703-direct-link-pipelines' into 'master' Grzegorz Bizon2016-12-201-0/+47
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolve "Direct link from pipeline list to builds" ## What does this MR do? - Adds a dropdown with builds in the mini pipeline graph in the pipelines table - Unnest a lot of CSS related with pipelines in order to make it reusable ## Screenshots ![Screen_Shot_2016-12-15_at_14.45.41](/uploads/ca1c61842a422a34383e029d668034b7/Screen_Shot_2016-12-15_at_14.45.41.png) ![Screen_Shot_2016-12-15_at_14.45.49](/uploads/952e3277143639ce4ad111103034faeb/Screen_Shot_2016-12-15_at_14.45.49.png) ![Screen_Shot_2016-12-15_at_14.46.02](/uploads/f7369a124b1c3c0db4194de2cb637ef0/Screen_Shot_2016-12-15_at_14.46.02.png) ![graph_animation](/uploads/9bae036cb5acff499f992a4722943d72/graph_animation.gif) ## Does this MR meet the acceptance criteria? - [x] [Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [ ] API support added - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if it does - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? Closes #25071 Closes #19703 See merge request !8097
| * | Fix stage and pipeline specs and rubocop offenses19703-direct-link-pipelinesGrzegorz Bizon2016-12-201-9/+10
| | |
| * | Move test for HTML stage endpoint to controller specsGrzegorz Bizon2016-12-201-0/+46
| |/
* | Merge branch '22348-gitea-importer' into 'master' Rémy Coutable2016-12-202-207/+52
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It adds a brand new importer for Gitea! This is a continuation of !6945 started by @bkc. Gitea aims to be 100% GitHub-compatible but there's a few differences: - Gitea is not an OAuth provider (yet): https://github.com/go-gitea/gitea/issues/27 - This means we cannot map Gitea users given an assignee ID => assignees are not set on imported issues and merge requests - No releases API for now: https://github.com/go-gitea/gitea/issues/330 - API version is `v1` (GitHub is `v3`) - The IID field for milestones is `id` compared to `number` in GitHub. - Issues, PRs, milestones, labels don't have a `url` field (the importer now fallback to `''` in that case) **Known issues:** - Comments are not imported because comments JSON always have a blank `html_url`/`issue_url`/`pull_request_url`, so the IID cannot be extracted and the issuable cannot be found... :( This is tracked in https://github.com/go-gitea/gitea/issues/401, and solved by https://github.com/gogits/gogs/pull/3624 but this needs to be submitted / merged in Gitea. This is noted in the documentation. ## Are there points in the code the reviewer needs to double check? 1. I've made `Import::GiteaController` inherit from `Import::GithubController` since both controllers should be identical in the long-term and their current differences are small. 1. I've added a base `IssuableFormatter` class from which `IssueFormatter` & `PullRequestFormatter` inherit 1. I've added shared examples for GitHub/Gitea importer classes 1. I've made `Gitlab::ImportSources` more robust and tested! :christmas_tree: 1. I've added routing specs for import routes! :christmas_tree: Closes #22348 See merge request !8116
| * | Namespace access token session key in `Import::GithubController`Rémy Coutable2016-12-192-2/+2
| | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | Modify GithubImport to support GiteaRémy Coutable2016-12-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The reason is that Gitea plan to be GitHub-compatible so it makes sense to just modify GitHubImport a bit for now, and hopefully we can change it to GitHubishImport once Gitea is 100%-compatible. Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | Rename Gogs to Gitea, DRY the controller and improve viewsRémy Coutable2016-12-192-208/+53
| | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | | Add terminal UI and controller actionsFatih Acet2016-12-191-0/+1
| | |
* | | Add terminals to the Kubernetes deployment serviceNick Thomas2016-12-191-0/+68
| |/ |/|
* | Fix 500 error for invalid path when visiting blame pageJeff Stubler2016-12-171-0/+5
|/ | | | Closes #25761.
* Merge remote-tracking branch 'origin/master' into bitbucket-oauth2Douglas Barbosa Alexandre2016-12-162-0/+110
|\
| * Add a controller spec for personal access tokens.Timothy Andrew2016-12-161-0/+49
| | | | | | | | | | | | Split the existing feature spec into both feature and controller specs. Feature specs assert on browser DOM, and controller specs assert on database state.
| * 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
* | Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into bitbucket-oauth2Valery Sizov2016-12-146-12/+147
|\ \ | |/
| * Merge branch 'issue_13270' into 'master' Sean McGivern2016-12-131-0/+55
| |\ | | | | | | | | | | | | | | | | | | Allow to delete tag release note closes #13270 See merge request !8001
| | * Allow to delete tag release noteissue_13270Felipe Artur2016-12-121-0/+55
| | |
| * | Merge branch 'jej-23867-use-mr-finder-instead-of-access-check' into 'security'Douwe Maan2016-12-081-1/+14
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace MR access checks with use of MergeRequestsFinder Split from !2024 to partially solve https://gitlab.com/gitlab-org/gitlab-ce/issues/23867 :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 - [x] :bomb: app/finders/notes_finder.rb:17 - [x] :warning: app/views/layouts/nav/_project.html.haml:80 [`.count`] - [x] :bomb: app/controllers/concerns/creates_commit.rb:84 - [x] :traffic_light: app/controllers/projects/commits_controller.rb:24 - [x] :traffic_light: app/controllers/projects/compare_controller.rb:56 - [x] :vertical_traffic_light: app/controllers/projects/discussions_controller.rb:29 - [x] :white_check_mark: app/controllers/projects/todos_controller.rb:27 - [x] :vertical_traffic_light: app/models/commit.rb:268 - [x] :white_check_mark: lib/gitlab/search_results.rb:71 - [x] https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#d1c10892daedb4d4dd3d4b12b6d071091eea83df_267_266 Memoize ` merged_merge_request(current_user)` - [x] https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#d1c10892daedb4d4dd3d4b12b6d071091eea83df_248_247 Expected side effect for `merged_merge_request!`, consider `skip_authorization: true`. - [x] https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#d1c10892daedb4d4dd3d4b12b6d071091eea83df_269_269 Scary use of unchecked `merged_merge_request?` See merge request !2033
| * fix: 24982- Remove'Signed in successfully' messagejnoortheen2016-12-071-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | After this change the sign-in-success flash message will not be shown refactor: set flash message to be nil while signing in test: changed tests to reflect removal of sign-in message refactor: adding signed_in message back See Merge Request !7837 issue#24982
| * Feature: delegate all open discussions to IssueBob Van Landuyt2016-12-051-0/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | When a merge request can only be merged when all discussions are resolved. This feature allows to easily delegate those discussions to a new issue, while marking them as resolved in the merge request. The user is presented with a new issue, prepared with mentions of all unresolved discussions, including the first unresolved note of the discussion, time and link to the note. When the issue is created, the discussions in the merge request will get a system note directing the user to the newly created issue.
| * Merge branch 'fix/rename-mwbs-to-merge-when-pipeline-succeeds' into 'master' Kamil Trzciński2016-12-051-1/+3
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rename MWBS service to Merge When Pipeline Succeeds ## What does this MR do? This MR renames Merge When Build Succeeds feature to Merge When Pipeline Succeeds, because we recently changed the behavior, see https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/6675. ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG.md) entry added - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [x] All builds are passing ## What are the relevant issue numbers? Closes #23354 See merge request !7135
| | * Merge branch 'master' into fix/rename-mwbs-to-merge-when-pipeline-succeedsGrzegorz Bizon2016-11-306-15/+109
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (110 commits) Rewrite an HTTP link to use HTTPS Edit /spec/features/profiles/preferences_spec.rb to match changes in 084d90ac Add blue back to sub nav active Remove JSX/React eslint plugins. Fix a transient spec failure Adds hoverstates for collapsed Issue/Merge Request sidebar Moved groups above projects Add StackProf to the Gemfile, along with a utility to get a profile for a spec Update Sidekiq-cron to fix compatibility issues with Sidekiq 4.2.1 Add a CHANGELOG entry Alert user when logged in user email is not the same as the invitation Expose timestamp in build entity used by serializer Rename `MergeRequest#pipeline` to `head_pipeline` Remove unnecessary database indexes CE-specific changes gitlab-org/gitlab-ee#1137 Fixing typo & Clarifying Key name fix started_at check fix blob controller spec failure - updated not to use file-path- fix blob controller spec failure Merge branch 'jej-use-issuable-finder-instead-of-access-check' into 'security' ... Conflicts: app/controllers/projects/merge_requests_controller.rb lib/api/merge_requests.rb spec/requests/api/merge_requests_spec.rb
| | * \ Merge branch 'master' into fix/rename-mwbs-to-merge-when-pipeline-succeedsGrzegorz Bizon2016-11-255-27/+99
| | |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (312 commits) Fix bad selection on dropdown menu for tags filter Fixed issue boards scrolling with a lot of lists & issues You can only assign default_branch when editing a project ... Don't convert data which already is the target type Stop supporting Google and Azure as backup strategies renames some of the specs and adds changelog entry Fixed dragging issue moving wrong issue after multiple drags of issue Fixed issue boards issue sorting when dragging issue into list Rephrase some system notes to be compatible with new system note style Add missing JIRA file that redirects to the new location Fix documentation to create the `pg_trm` extension before creating the DB Document that we always use `do...end` for `before` in RSpec Backport Note#commands_changes from EE Log mv_namespace parameters Add default_branch attr to Project API payload in docs. Fix title case to sentence case properly escape username validation error message flash Remove header ids from University docs Add missing documentation. Added test that checks the correct select box is there for the LFS ... ... Conflicts: app/services/system_note_service.rb spec/features/merge_requests/merge_when_pipeline_succeeds_spec.rb spec/services/merge_requests/merge_when_pipeline_succeeds_service_spec.rb spec/services/system_note_service_spec.rb
| | * | | Rename MWBS service to Merge When Pipeline SucceedsGrzegorz Bizon2016-11-211-1/+3
| | | | |
| * | | | Fix URL rewritting in the Help section25199-fix-broken-urls-in-help-pageRémy Coutable2016-12-011-9/+15
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | | | | Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into bitbucket-oauth2Valery Sizov2016-11-309-42/+174
|\ \ \ \ \ | |/ / / /
| * | | | Do not raise error in AutocompleteController#users when not authorizedSemyon Pupkov2016-11-301-0/+9
| | |_|/ | |/| | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/issues/25031
| * | | Merge branch 'ee-1137-follow-up-protected-branch-users-and-groups' into ↵Douwe Maan2016-11-301-2/+2
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'master' CE-specific changes for gitlab-org/gitlab-ee#1137 ## What does this MR do? - gitlab-org/gitlab-ee#1137 is a `technical debt` issue to clean up the EE protected branch access levels (for users and groups) implementation. - Some of this cleanup bleeds over to code shared by CE and EE, which is why this MR is required. - An EE-specific MR has also been created: gitlab-org/gitlab-ee!927 See merge request !7821
| | * | | CE-specific changes gitlab-org/gitlab-ee#1137ee-1137-follow-up-protected-branch-users-and-groupsTimothy Andrew2016-11-291-2/+2
| | | |/ | | |/| | | | | | | | | | | | | | | | | | | | | - Extract all common {push,merge} access level model code into the `ProtectedBranchAccess` module - Use the HTTP verb to define controller specs
| * | | fix blob controller spec failure - updated not to use file-path-fix/blob-controller-specJames Lopez2016-11-291-1/+1
| | | |
| * | | Merge branch 'jej-fix-missing-access-check-on-issues' into 'security'Douwe Maan2016-11-282-2/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix missing access checks on issue lookup using IssuableFinder Split from !2024 to partially solve https://gitlab.com/gitlab-org/gitlab-ce/issues/23867 :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 - [x] :white_check_mark: app/controllers/projects/branches_controller.rb:39 - `before_action :authorize_push_code!` helpes limit/prevent exploitation. Always checks for reporter access so fine with confidential issues, issues only visible to team, etc. - [x] :traffic_light: app/models/cycle_analytics/summary.rb:9 [`.count`] - [x] :white_check_mark: app/controllers/projects/todos_controller.rb:19 - [x] Potential double render in app/controllers/projects/todos_controller.rb - https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2024/diffs#cedccb227af9bfdf88802767cb58d43c2b977439_24_24 See merge request !2030
| * | | Merge branch 'jej-22869' into 'security'Douwe Maan2016-11-281-0/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix information disclosure in `Projects::BlobController#update` It was possible to discover private project names by modifying `from_merge_request`parameter in `Projects::BlobController#update`. This fixes that. - [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG.md) entry added - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) https://gitlab.com/gitlab-org/gitlab-ce/issues/22869 See merge request !2023
| * | | Ensure user is authenticated to create a new snippet25026-authenticate-user-for-new-snippetRémy Coutable2016-11-281-0/+22
| | | | | | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | | Merge branch 'fix-dead-help-link' into 'master' Rémy Coutable2016-11-281-11/+3
| |\ \ \ | | |/ / | |/| | | | | | | | | | Fix a broken link and avoid potential creation of future broken links on the help page. See merge request !7582
| | * | Fix broken external links in help/index.htmlDavid Wagner2016-11-201-11/+3
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An external link was recently added but was broken because 'https://gitlab.com/help/' was prepended to every link in the page. Since no link in the main help readme begins with "help" and since doing so wouldn't make sense, the substitution conditionaly prepending "help" can be simplified and reused. Signed-off-by: David Wagner <david@marvid.fr>
| * | Merge branch 'rephrase-system-notes' into 'master' Robert Speicher2016-11-251-1/+1
| |\ \ | | | | | | | | | | | | | | | | Rephrase some system notes to be compatible with new system note style See merge request !7692