Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
gitlab-ce
Commits
bb7df766
Commit
bb7df766
authored
Apr 13, 2014
by
GitLab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add short path route for groups.
parent
0f31acd0
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
config/routes.rb
config/routes.rb
+2
-0
spec/routing/routing_spec.rb
spec/routing/routing_spec.rb
+12
-0
No files found.
config/routes.rb
View file @
bb7df766
...
@@ -327,5 +327,7 @@ Gitlab::Application.routes.draw do
...
@@ -327,5 +327,7 @@ Gitlab::Application.routes.draw do
end
end
end
end
get
':id'
=>
"groups#show"
,
constraints:
{
id:
/(?:[^.]|\.(?!atom$))+/
,
format:
/atom/
}
root
to:
"dashboard#show"
root
to:
"dashboard#show"
end
end
spec/routing/routing_spec.rb
View file @
bb7df766
...
@@ -238,3 +238,15 @@ end
...
@@ -238,3 +238,15 @@ end
describe
"Authentication"
,
"routing"
do
describe
"Authentication"
,
"routing"
do
# pending
# pending
end
end
describe
"Groups"
,
"routing"
do
it
"to #show"
do
get
(
"/groups/1"
).
should
route_to
(
'groups#show'
,
id:
'1'
)
end
it
"redirect"
do
# get("/groups/1").should redirect_to("/groups/1")
get
(
"/1"
).
should
route_to
(
'groups#show'
,
id:
'1'
)
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment