diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2019-01-18 15:19:31 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2019-01-22 10:59:10 +0300 |
commit | f13edec8c7f568f32da9e516888ed229c8963051 (patch) | |
tree | 01e7790ee15eda5ab3789ed29b8c11cf4d4bf7a1 /spec/routing/project_routing_spec.rb | |
parent | ce171674b60f5888aa3802e9f6b843762faabd3a (diff) |
Add ability to resolve project id into path
By visiting `projects/:id` you will be redirected to project page with
path in it.
projects/123 => foo/bar
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'spec/routing/project_routing_spec.rb')
-rw-r--r-- | spec/routing/project_routing_spec.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/routing/project_routing_spec.rb b/spec/routing/project_routing_spec.rb index 5c3b37ef11c..a0d01fc8263 100644 --- a/spec/routing/project_routing_spec.rb +++ b/spec/routing/project_routing_spec.rb @@ -122,6 +122,10 @@ describe 'project routing' do route_to('projects#preview_markdown', namespace_id: 'gitlab', id: 'gitlabhq') ) end + + it 'to #resolve' do + expect(get('/projects/1')).to route_to('projects#resolve', id: '1') + end end # members_namespace_project_autocomplete_sources_path GET /:project_id/autocomplete_sources/members(.:format) projects/autocomplete_sources#members |