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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
17518f8a
Commit
17518f8a
authored
May 23, 2019
by
Imre Farkas
Committed by
Rémy Coutable
May 23, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move EE specific lines in API::Services spec
parent
9124676b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
17 deletions
+28
-17
ee/spec/requests/api/services_spec.rb
ee/spec/requests/api/services_spec.rb
+28
-0
spec/requests/api/services_spec.rb
spec/requests/api/services_spec.rb
+0
-17
No files found.
ee/spec/requests/api/services_spec.rb
0 → 100644
View file @
17518f8a
# frozen_string_literal: true
require
"spec_helper"
describe
API
::
Services
do
set
(
:user
)
{
create
(
:user
)
}
set
(
:project
)
do
create
(
:project
,
creator_id:
user
.
id
,
namespace:
user
.
namespace
)
end
describe
'Slack application Service'
do
before
do
project
.
create_gitlab_slack_application_service
stub_application_setting
(
slack_app_verification_token:
'token'
)
end
it
'returns status 200'
do
post
api
(
'/slack/trigger'
),
params:
{
token:
'token'
,
text:
'help'
}
expect
(
response
).
to
have_gitlab_http_status
(
200
)
expect
(
json_response
[
'response_type'
]).
to
eq
(
"ephemeral"
)
end
end
end
spec/requests/api/services_spec.rb
View file @
17518f8a
...
...
@@ -198,21 +198,4 @@ describe API::Services do
expect
(
json_response
[
'properties'
][
'username'
]).
to
eq
(
'new_username'
)
end
end
describe
'Slack application Service'
do
before
do
project
.
create_gitlab_slack_application_service
stub_application_setting
(
slack_app_verification_token:
'token'
)
end
it
'returns status 200'
do
post
api
(
'/slack/trigger'
),
params:
{
token:
'token'
,
text:
'help'
}
expect
(
response
).
to
have_gitlab_http_status
(
200
)
expect
(
json_response
[
'response_type'
]).
to
eq
(
"ephemeral"
)
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