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
2b8005ae
Commit
2b8005ae
authored
Feb 27, 2017
by
Robert Schilling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
New runner API returns 204
parent
7d60876b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
runner.rb
lib/api/runner.rb
+1
-1
runner_spec.rb
spec/requests/api/runner_spec.rb
+4
-1
No files found.
lib/api/runner.rb
View file @
2b8005ae
...
...
@@ -38,7 +38,7 @@ module API
end
desc
'Deletes a registered Runner'
do
http_codes
[[
20
0
,
'Runner was deleted'
],
[
403
,
'Forbidden'
]]
http_codes
[[
20
4
,
'Runner was deleted'
],
[
403
,
'Forbidden'
]]
end
params
do
requires
:token
,
type:
String
,
desc:
%q(Runner's authentication token)
...
...
spec/requests/api/runner_spec.rb
View file @
2b8005ae
...
...
@@ -123,6 +123,7 @@ describe API::Runner do
context
'when no token is provided'
do
it
'returns 400 error'
do
delete
api
(
'/runners'
)
expect
(
response
).
to
have_http_status
400
end
end
...
...
@@ -130,6 +131,7 @@ describe API::Runner do
context
'when invalid token is provided'
do
it
'returns 403 error'
do
delete
api
(
'/runners'
),
token:
'invalid'
expect
(
response
).
to
have_http_status
403
end
end
...
...
@@ -139,7 +141,8 @@ describe API::Runner do
it
'deletes Runner'
do
delete
api
(
'/runners'
),
token:
runner
.
token
expect
(
response
).
to
have_http_status
200
expect
(
response
).
to
have_http_status
204
expect
(
Ci
::
Runner
.
count
).
to
eq
(
0
)
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