-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathyank_gem.feature
43 lines (38 loc) · 1.95 KB
/
yank_gem.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
Feature: yank gem
As a developer
I want to yank gems from the server
In order to defend other developers from sub-awesome code
Scenario: yank existing gem version specifying a platform
Given the following gems exist:
| name | version number | platform |
| terran | 1.0.0 | ruby |
| terran | 2.0.0 | ruby |
| terran | 2.0.0 | x86-darwin-10 |
When I make a DELETE request to "/api/v1/gems" with gem_name "terran", version "2.0.0", and platform "ruby"
Then the response status is 200
And the full gem index contains exactly the following gems:
| name | version number | platform |
| terran | 1.0.0 | ruby |
| terran | 2.0.0 | x86-darwin-10 |
Scenario: yank existing gem version without specifying a platform
Given the following gems exist:
| name | version number | platform |
| terran | 1.0.0 | ruby |
| terran | 2.0.0 | ruby |
| terran | 2.0.0 | x86-darwin-10 |
When I make a DELETE request to "/api/v1/gems" with gem_name "terran" and version "2.0.0"
Then the response status is 200
And the full gem index contains exactly the following gems:
| name | version number | platform |
| terran | 1.0.0 | ruby |
Scenario: yank non-existent gem
Given the following gems exist:
| name | version number | platform |
| terran | 1.0.0 | ruby |
| terran | 2.0.0 | x86-darwin-10 |
When I make a DELETE request to "/api/v1/gems" with gem_name "terran", version "2.0.0", and platform "ruby"
Then the response status is 404
And the full gem index contains exactly the following gems:
| name | version number | platform |
| terran | 1.0.0 | ruby |
| terran | 2.0.0 | x86-darwin-10 |