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
Jérome Perrin
gitlab-ce
Commits
2a0f83f5
Commit
2a0f83f5
authored
Mar 27, 2017
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix environment folder route when special chars present
parent
c848735d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
1 deletion
+20
-1
config/routes/project.rb
config/routes/project.rb
+1
-1
spec/features/projects/environments/environment_spec.rb
spec/features/projects/environments/environment_spec.rb
+19
-0
No files found.
config/routes/project.rb
View file @
2a0f83f5
...
@@ -164,7 +164,7 @@ constraints(ProjectUrlConstrainer.new) do
...
@@ -164,7 +164,7 @@ constraints(ProjectUrlConstrainer.new) do
end
end
collection
do
collection
do
get
:folder
,
path:
'folders/
:id'
get
:folder
,
path:
'folders/
*id'
,
constraints:
{
format:
/(html|json)/
}
end
end
end
end
...
...
spec/features/projects/environments/environment_spec.rb
View file @
2a0f83f5
...
@@ -166,6 +166,25 @@ feature 'Environment', :feature do
...
@@ -166,6 +166,25 @@ feature 'Environment', :feature do
end
end
end
end
feature
'environment folders'
,
:js
do
context
'when folder name contains special charaters'
do
before
do
create
(
:environment
,
project:
project
,
name:
'staging-1.0/review'
,
state: :available
)
visit
folder_namespace_project_environments_path
(
project
.
namespace
,
project
,
id:
'staging-1.0'
)
end
it
'renders a correct environment folder'
do
expect
(
page
).
to
have_http_status
(
:ok
)
expect
(
page
).
to
have_content
(
'Environments / staging-1.0'
)
end
end
end
feature
'auto-close environment when branch is deleted'
do
feature
'auto-close environment when branch is deleted'
do
given
(
:project
)
{
create
(
:project
)
}
given
(
:project
)
{
create
(
:project
)
}
...
...
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