BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
df99883d
Commit
df99883d
authored
Jan 06, 2017
by
Z.J. van de Weg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add tests for admin service templates
parent
b46ad4c9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
1 deletion
+27
-1
_help.html.haml
...ws/projects/services/slack_slash_commands/_help.html.haml
+1
-1
services_controller_spec.rb
spec/controllers/admin/services_controller_spec.rb
+26
-0
No files found.
app/views/projects/services/slack_slash_commands/_help.html.haml
View file @
df99883d
-
pretty_name
=
defined?
(
@project
)
?
@project
.
path
_with_namespace
:
"namespace / path"
-
pretty_name
=
defined?
(
@project
)
?
@project
.
name
_with_namespace
:
"namespace / path"
-
run_actions_text
=
"Perform common operations on this project:
#{
pretty_name
}
"
.well
...
...
spec/controllers/admin/services_controller_spec.rb
0 → 100644
View file @
df99883d
require
'spec_helper'
describe
Admin
::
ServicesController
do
let
(
:admin
)
{
create
(
:admin
)
}
before
{
sign_in
(
admin
)
}
describe
'GET #edit'
do
let!
(
:project
)
{
create
(
:empty_project
)
}
Service
.
available_services_names
.
each
do
|
service_name
|
context
"
#{
service_name
}
"
do
let!
(
:service
)
do
service_template
=
service_name
.
concat
(
"_service"
).
camelize
.
constantize
service_template
.
where
(
template:
true
).
first_or_create
end
it
'successfully displays the template'
do
get
:edit
,
id:
service
.
id
expect
(
response
).
to
have_http_status
(
200
)
end
end
end
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