gitlab 4.2.0 → 4.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (84) hide show
  1. checksums.yaml +5 -5
  2. data/.rubocop.yml +33 -0
  3. data/.travis.yml +8 -3
  4. data/README.md +7 -7
  5. data/Rakefile +11 -3
  6. data/gitlab.gemspec +11 -11
  7. data/lib/gitlab.rb +2 -2
  8. data/lib/gitlab/api.rb +2 -1
  9. data/lib/gitlab/cli.rb +2 -6
  10. data/lib/gitlab/cli_helpers.rb +18 -20
  11. data/lib/gitlab/client.rb +8 -5
  12. data/lib/gitlab/client/branches.rb +4 -4
  13. data/lib/gitlab/client/build_variables.rb +64 -2
  14. data/lib/gitlab/client/deployments.rb +32 -0
  15. data/lib/gitlab/client/groups.rb +49 -0
  16. data/lib/gitlab/client/issues.rb +71 -0
  17. data/lib/gitlab/client/merge_requests.rb +1 -0
  18. data/lib/gitlab/client/pipeline_schedules.rb +133 -0
  19. data/lib/gitlab/client/pipeline_triggers.rb +2 -2
  20. data/lib/gitlab/client/projects.rb +1 -1
  21. data/lib/gitlab/client/repository_files.rb +2 -2
  22. data/lib/gitlab/client/users.rb +5 -5
  23. data/lib/gitlab/configuration.rb +2 -2
  24. data/lib/gitlab/error.rb +10 -2
  25. data/lib/gitlab/file_response.rb +1 -1
  26. data/lib/gitlab/help.rb +5 -6
  27. data/lib/gitlab/page_links.rb +2 -2
  28. data/lib/gitlab/request.rb +34 -50
  29. data/lib/gitlab/shell.rb +5 -8
  30. data/lib/gitlab/version.rb +1 -1
  31. data/spec/fixtures/deployment.json +57 -0
  32. data/spec/fixtures/deployments.json +116 -0
  33. data/spec/fixtures/group_edit.json +14 -0
  34. data/spec/fixtures/group_subgroups.json +16 -0
  35. data/spec/fixtures/pipeline_schedule.json +32 -0
  36. data/spec/fixtures/pipeline_schedule_create.json +21 -0
  37. data/spec/fixtures/pipeline_schedule_update.json +26 -0
  38. data/spec/fixtures/pipeline_schedule_variable.json +5 -0
  39. data/spec/fixtures/pipeline_schedule_variable_update.json +5 -0
  40. data/spec/fixtures/pipeline_schedules.json +22 -0
  41. data/spec/gitlab/api_spec.rb +11 -0
  42. data/spec/gitlab/cli_helpers_spec.rb +14 -15
  43. data/spec/gitlab/cli_spec.rb +11 -11
  44. data/spec/gitlab/client/award_emojis_spec.rb +55 -55
  45. data/spec/gitlab/client/boards_spec.rb +12 -12
  46. data/spec/gitlab/client/branches_spec.rb +22 -22
  47. data/spec/gitlab/client/build_variables_spec.rb +93 -10
  48. data/spec/gitlab/client/builds_spec.rb +36 -36
  49. data/spec/gitlab/client/commits_spec.rb +21 -21
  50. data/spec/gitlab/client/deployments_spec.rb +38 -0
  51. data/spec/gitlab/client/environments_spec.rb +18 -18
  52. data/spec/gitlab/client/groups_spec.rb +73 -22
  53. data/spec/gitlab/client/issues_spec.rb +121 -22
  54. data/spec/gitlab/client/jobs_spec.rb +13 -13
  55. data/spec/gitlab/client/keys_spec.rb +2 -2
  56. data/spec/gitlab/client/labels_spec.rb +12 -12
  57. data/spec/gitlab/client/merge_requests_spec.rb +23 -23
  58. data/spec/gitlab/client/milestones_spec.rb +12 -12
  59. data/spec/gitlab/client/namespaces_spec.rb +3 -3
  60. data/spec/gitlab/client/notes_spec.rb +40 -40
  61. data/spec/gitlab/client/pipeline_schedules_spec.rb +158 -0
  62. data/spec/gitlab/client/pipeline_triggers_spec.rb +17 -17
  63. data/spec/gitlab/client/pipelines_spec.rb +22 -22
  64. data/spec/gitlab/client/projects_spec.rb +75 -75
  65. data/spec/gitlab/client/repositories_spec.rb +16 -16
  66. data/spec/gitlab/client/repository_files_spec.rb +10 -10
  67. data/spec/gitlab/client/runners_spec.rb +20 -22
  68. data/spec/gitlab/client/services_spec.rb +6 -6
  69. data/spec/gitlab/client/snippets_spec.rb +12 -12
  70. data/spec/gitlab/client/system_hooks_spec.rb +12 -12
  71. data/spec/gitlab/client/tags_spec.rb +19 -20
  72. data/spec/gitlab/client/todos_spec.rb +12 -12
  73. data/spec/gitlab/client/users_spec.rb +49 -49
  74. data/spec/gitlab/error_spec.rb +50 -23
  75. data/spec/gitlab/file_response_spec.rb +6 -6
  76. data/spec/gitlab/help_spec.rb +5 -5
  77. data/spec/gitlab/objectified_hash_spec.rb +8 -8
  78. data/spec/gitlab/page_links_spec.rb +1 -1
  79. data/spec/gitlab/paginated_response_spec.rb +4 -4
  80. data/spec/gitlab/request_spec.rb +19 -19
  81. data/spec/gitlab/shell_spec.rb +12 -12
  82. data/spec/gitlab_spec.rb +13 -14
  83. data/spec/spec_helper.rb +10 -45
  84. metadata +46 -3
@@ -8,11 +8,11 @@ describe Gitlab::Client do
8
8
  @issues = Gitlab.issues(3)
9
9
  end
10
10
 
11
- it "should get the correct resource" do
11
+ it "gets the correct resource" do
12
12
  expect(a_get("/projects/3/issues")).to have_been_made
13
13
  end
14
14
 
15
- it "should return a paginated response of project's issues" do
15
+ it "returns a paginated response of project's issues" do
16
16
  expect(@issues).to be_a Gitlab::PaginatedResponse
17
17
  expect(@issues.first.project_id).to eq(3)
18
18
  end
@@ -24,11 +24,11 @@ describe Gitlab::Client do
24
24
  @issues = Gitlab.issues('gitlab-org/gitlab-ce')
25
25
  end
26
26
 
27
- it "should get the correct resource" do
27
+ it "gets the correct resource" do
28
28
  expect(a_get("/projects/gitlab-org%2Fgitlab-ce/issues")).to have_been_made
29
29
  end
30
30
 
31
- it "should return a paginated response of project's issues" do
31
+ it "returns a paginated response of project's issues" do
32
32
  expect(@issues).to be_a Gitlab::PaginatedResponse
33
33
  expect(@issues.first.project_id).to eq(3)
34
34
  end
@@ -40,11 +40,11 @@ describe Gitlab::Client do
40
40
  @issues = Gitlab.issues
41
41
  end
42
42
 
43
- it "should get the correct resource" do
43
+ it "gets the correct resource" do
44
44
  expect(a_get("/issues")).to have_been_made
45
45
  end
46
46
 
47
- it "should return a paginated response of user's issues" do
47
+ it "returns a paginated response of user's issues" do
48
48
  expect(@issues).to be_a Gitlab::PaginatedResponse
49
49
  expect(@issues.first.closed).to be_falsey
50
50
  expect(@issues.first.author.name).to eq("John Smith")
@@ -58,11 +58,11 @@ describe Gitlab::Client do
58
58
  @issue = Gitlab.issue(3, 33)
59
59
  end
60
60
 
61
- it "should get the correct resource" do
61
+ it "gets the correct resource" do
62
62
  expect(a_get("/projects/3/issues/33")).to have_been_made
63
63
  end
64
64
 
65
- it "should return information about an issue" do
65
+ it "returns information about an issue" do
66
66
  expect(@issue.project_id).to eq(3)
67
67
  expect(@issue.assignee.name).to eq("Jack Smith")
68
68
  end
@@ -74,12 +74,12 @@ describe Gitlab::Client do
74
74
  @issue = Gitlab.create_issue(3, 'title')
75
75
  end
76
76
 
77
- it "should get the correct resource" do
77
+ it "gets the correct resource" do
78
78
  expect(a_post("/projects/3/issues").
79
79
  with(body: { title: 'title' })).to have_been_made
80
80
  end
81
81
 
82
- it "should return information about a created issue" do
82
+ it "returns information about a created issue" do
83
83
  expect(@issue.project_id).to eq(3)
84
84
  expect(@issue.assignee.name).to eq("Jack Smith")
85
85
  end
@@ -91,12 +91,12 @@ describe Gitlab::Client do
91
91
  @issue = Gitlab.edit_issue(3, 33, title: 'title')
92
92
  end
93
93
 
94
- it "should get the correct resource" do
94
+ it "gets the correct resource" do
95
95
  expect(a_put("/projects/3/issues/33").
96
96
  with(body: { title: 'title' })).to have_been_made
97
97
  end
98
98
 
99
- it "should return information about an edited issue" do
99
+ it "returns information about an edited issue" do
100
100
  expect(@issue.project_id).to eq(3)
101
101
  expect(@issue.assignee.name).to eq("Jack Smith")
102
102
  end
@@ -108,12 +108,12 @@ describe Gitlab::Client do
108
108
  @issue = Gitlab.close_issue(3, 33)
109
109
  end
110
110
 
111
- it "should get the correct resource" do
111
+ it "gets the correct resource" do
112
112
  expect(a_put("/projects/3/issues/33").
113
113
  with(body: { state_event: 'close' })).to have_been_made
114
114
  end
115
115
 
116
- it "should return information about an closed issue" do
116
+ it "returns information about an closed issue" do
117
117
  expect(@issue.project_id).to eq(3)
118
118
  expect(@issue.assignee.name).to eq("Jack Smith")
119
119
  end
@@ -125,12 +125,12 @@ describe Gitlab::Client do
125
125
  @issue = Gitlab.reopen_issue(3, 33)
126
126
  end
127
127
 
128
- it "should get the correct resource" do
128
+ it "gets the correct resource" do
129
129
  expect(a_put("/projects/3/issues/33").
130
130
  with(body: { state_event: 'reopen' })).to have_been_made
131
131
  end
132
132
 
133
- it "should return information about an reopened issue" do
133
+ it "returns information about an reopened issue" do
134
134
  expect(@issue.project_id).to eq(3)
135
135
  expect(@issue.assignee.name).to eq("Jack Smith")
136
136
  end
@@ -142,11 +142,11 @@ describe Gitlab::Client do
142
142
  @issue = Gitlab.subscribe_to_issue(3, 33)
143
143
  end
144
144
 
145
- it "should get the correct resource" do
145
+ it "gets the correct resource" do
146
146
  expect(a_post("/projects/3/issues/33/subscribe")).to have_been_made
147
147
  end
148
148
 
149
- it "should return information about the subscribed issue" do
149
+ it "returns information about the subscribed issue" do
150
150
  expect(@issue.project_id).to eq(3)
151
151
  expect(@issue.assignee.name).to eq("Jack Smith")
152
152
  end
@@ -158,11 +158,11 @@ describe Gitlab::Client do
158
158
  @issue = Gitlab.unsubscribe_from_issue(3, 33)
159
159
  end
160
160
 
161
- it "should get the correct resource" do
161
+ it "gets the correct resource" do
162
162
  expect(a_post("/projects/3/issues/33/unsubscribe")).to have_been_made
163
163
  end
164
164
 
165
- it "should return information about the unsubscribed issue" do
165
+ it "returns information about the unsubscribed issue" do
166
166
  expect(@issue.project_id).to eq(3)
167
167
  expect(@issue.assignee.name).to eq("Jack Smith")
168
168
  end
@@ -174,13 +174,112 @@ describe Gitlab::Client do
174
174
  @issue = Gitlab.delete_issue(3, 33)
175
175
  end
176
176
 
177
- it "should get the correct resource" do
177
+ it "gets the correct resource" do
178
178
  expect(a_delete("/projects/3/issues/33")).to have_been_made
179
179
  end
180
180
 
181
- it "should return information about a deleted issue" do
181
+ it "returns information about a deleted issue" do
182
182
  expect(@issue.project_id).to eq(3)
183
183
  expect(@issue.id).to eq(33)
184
184
  end
185
185
  end
186
+
187
+ describe ".move_issue" do
188
+ before do
189
+ stub_post("/projects/3/issues/33/move", "issue")
190
+ @issue = Gitlab.move_issue(3, 33, to_project_id: '4')
191
+ end
192
+
193
+ it "gets the correct resource" do
194
+ expect(a_post("/projects/3/issues/33/move").
195
+ with(body: { to_project_id: '4' })).to have_been_made
196
+ end
197
+
198
+ it "returns information about the moved issue" do
199
+ expect(@issue.project_id).to eq(3)
200
+ expect(@issue.assignee.name).to eq("Jack Smith")
201
+ end
202
+ end
203
+
204
+ describe ".estimate_time_of_issue" do
205
+ before do
206
+ stub_post("/projects/3/issues/33/time_estimate", "issue")
207
+ @issue = Gitlab.estimate_time_of_issue(3, 33, '3h30m')
208
+ end
209
+
210
+ it "gets the correct resource" do
211
+ expect(a_post("/projects/3/issues/33/time_estimate").
212
+ with(body: { duration: '3h30m' })).to have_been_made
213
+ end
214
+
215
+ it "returns information about the estimated issue" do
216
+ expect(@issue.project_id).to eq(3)
217
+ expect(@issue.assignee.name).to eq("Jack Smith")
218
+ end
219
+ end
220
+
221
+ describe ".reset_time_estimate_of_issue" do
222
+ before do
223
+ stub_post("/projects/3/issues/33/reset_time_estimate", "issue")
224
+ @issue = Gitlab.reset_time_estimate_of_issue(3, 33)
225
+ end
226
+
227
+ it "gets the correct resource" do
228
+ expect(a_post("/projects/3/issues/33/reset_time_estimate")).to have_been_made
229
+ end
230
+
231
+ it "returns information about the estimated issue" do
232
+ expect(@issue.project_id).to eq(3)
233
+ expect(@issue.assignee.name).to eq("Jack Smith")
234
+ end
235
+ end
236
+
237
+ describe ".add_time_spent_on_issue" do
238
+ before do
239
+ stub_post("/projects/3/issues/33/add_spent_time", "issue")
240
+ @issue = Gitlab.add_time_spent_on_issue(3, 33, '3h30m')
241
+ end
242
+
243
+ it "gets the correct resource" do
244
+ expect(a_post("/projects/3/issues/33/add_spent_time").
245
+ with(body: { duration: '3h30m' })).to have_been_made
246
+ end
247
+
248
+ it "returns information about the estimated issue" do
249
+ expect(@issue.project_id).to eq(3)
250
+ expect(@issue.assignee.name).to eq("Jack Smith")
251
+ end
252
+ end
253
+
254
+ describe ".reset_time_spent_on_issue" do
255
+ before do
256
+ stub_post("/projects/3/issues/33/reset_spent_time", "issue")
257
+ @issue = Gitlab.reset_time_spent_on_issue(3, 33)
258
+ end
259
+
260
+ it "gets the correct resource" do
261
+ expect(a_post("/projects/3/issues/33/reset_spent_time")).to have_been_made
262
+ end
263
+
264
+ it "returns information about the estimated issue" do
265
+ expect(@issue.project_id).to eq(3)
266
+ expect(@issue.assignee.name).to eq("Jack Smith")
267
+ end
268
+ end
269
+
270
+ describe ".time_stats_for_issue" do
271
+ before do
272
+ stub_get("/projects/3/issues/33/time_stats", "issue")
273
+ @issue = Gitlab.time_stats_for_issue(3, 33)
274
+ end
275
+
276
+ it "gets the correct resource" do
277
+ expect(a_get("/projects/3/issues/33/time_stats")).to have_been_made
278
+ end
279
+
280
+ it "returns information about the issue" do
281
+ expect(@issue.project_id).to eq(3)
282
+ expect(@issue.assignee.name).to eq("Jack Smith")
283
+ end
284
+ end
186
285
  end
@@ -7,7 +7,7 @@ describe Gitlab::Client do
7
7
  @projects = Gitlab.jobs(1)
8
8
  end
9
9
 
10
- it 'should get the correct resource' do
10
+ it 'gets the correct resource' do
11
11
  expect(a_get('/projects/1/jobs')).to have_been_made
12
12
  end
13
13
  end
@@ -18,7 +18,7 @@ describe Gitlab::Client do
18
18
  @projects = Gitlab.jobs(1, scope: %w[created running])
19
19
  end
20
20
 
21
- it 'should get the correct resource' do
21
+ it 'gets the correct resource' do
22
22
  expect(a_get('/projects/1/jobs?scope[]=created&scope[]=running')).to have_been_made
23
23
  end
24
24
  end
@@ -28,7 +28,7 @@ describe Gitlab::Client do
28
28
  stub_get('/projects/1/pipelines/1/jobs', 'pipeline_jobs')
29
29
  @projects = Gitlab.pipeline_jobs(1, 1)
30
30
  end
31
- it 'should get the correct resource' do
31
+ it 'gets the correct resource' do
32
32
  expect(a_get('/projects/1/pipelines/1/jobs')).to have_been_made
33
33
  end
34
34
  end
@@ -38,7 +38,7 @@ describe Gitlab::Client do
38
38
  stub_get('/projects/1/pipelines/1/jobs?scope[]=running&scope[]=created', 'pipeline_jobs')
39
39
  @projects = Gitlab.pipeline_jobs(1, 1, scope: %w[running created])
40
40
  end
41
- it 'should get the correct resource' do
41
+ it 'gets the correct resource' do
42
42
  expect(a_get('/projects/1/pipelines/1/jobs?scope[]=running&scope[]=created')).to have_been_made
43
43
  end
44
44
  end
@@ -48,7 +48,7 @@ describe Gitlab::Client do
48
48
  stub_get('/projects/1/jobs/1', 'job')
49
49
  @projects = Gitlab.job(1, 1)
50
50
  end
51
- it 'should get the correct resource' do
51
+ it 'gets the correct resource' do
52
52
  expect(a_get('/projects/1/jobs/1')).to have_been_made
53
53
  end
54
54
  end
@@ -58,7 +58,7 @@ describe Gitlab::Client do
58
58
  stub_get('/projects/1/jobs/1/artifacts', 'job')
59
59
  @projects = Gitlab.job_artifacts(1, 1)
60
60
  end
61
- it 'should get the correct resource' do
61
+ it 'gets the correct resource' do
62
62
  expect(a_get('/projects/1/jobs/1/artifacts')).to have_been_made
63
63
  end
64
64
  end
@@ -68,7 +68,7 @@ describe Gitlab::Client do
68
68
  stub_get('/projects/1/jobs/artifacts/master/download?job=Release%20Build', 'job')
69
69
  @projects = Gitlab.job_artifacts_download(1, 'master', 'Release Build')
70
70
  end
71
- it 'should get the correct resource' do
71
+ it 'gets the correct resource' do
72
72
  expect(a_get('/projects/1/jobs/artifacts/master/download?job=Release%20Build')).to have_been_made
73
73
  end
74
74
  end
@@ -78,7 +78,7 @@ describe Gitlab::Client do
78
78
  stub_get('/projects/1/jobs/1/trace', 'job_trace')
79
79
  @projects = Gitlab.job_trace(1, 1)
80
80
  end
81
- it 'should get the correct resource' do
81
+ it 'gets the correct resource' do
82
82
  expect(a_get('/projects/1/jobs/1/trace')).to have_been_made
83
83
  end
84
84
  end
@@ -88,7 +88,7 @@ describe Gitlab::Client do
88
88
  stub_post('/projects/1/jobs/1/cancel', 'job')
89
89
  @projects = Gitlab.job_cancel(1, 1)
90
90
  end
91
- it 'should get the correct resource' do
91
+ it 'gets the correct resource' do
92
92
  expect(a_post('/projects/1/jobs/1/cancel')).to have_been_made
93
93
  end
94
94
  end
@@ -98,7 +98,7 @@ describe Gitlab::Client do
98
98
  stub_post('/projects/1/jobs/1/retry', 'job')
99
99
  @projects = Gitlab.job_retry(1, 1)
100
100
  end
101
- it 'should get the correct resource' do
101
+ it 'gets the correct resource' do
102
102
  expect(a_post('/projects/1/jobs/1/retry')).to have_been_made
103
103
  end
104
104
  end
@@ -108,7 +108,7 @@ describe Gitlab::Client do
108
108
  stub_post('/projects/1/jobs/1/erase', 'job')
109
109
  @projects = Gitlab.job_erase(1, 1)
110
110
  end
111
- it 'should get the correct resource' do
111
+ it 'gets the correct resource' do
112
112
  expect(a_post('/projects/1/jobs/1/erase')).to have_been_made
113
113
  end
114
114
  end
@@ -118,7 +118,7 @@ describe Gitlab::Client do
118
118
  stub_post('/projects/1/jobs/1/play', 'job')
119
119
  @projects = Gitlab.job_play(1, 1)
120
120
  end
121
- it 'should get the correct resource' do
121
+ it 'gets the correct resource' do
122
122
  expect(a_post('/projects/1/jobs/1/play')).to have_been_made
123
123
  end
124
124
  end
@@ -128,7 +128,7 @@ describe Gitlab::Client do
128
128
  stub_post('/projects/1/jobs/1/artifacts/keep', 'job')
129
129
  @projects = Gitlab.job_artifacts_keep(1, 1)
130
130
  end
131
- it 'should get the correct resource' do
131
+ it 'gets the correct resource' do
132
132
  expect(a_post('/projects/1/jobs/1/artifacts/keep')).to have_been_made
133
133
  end
134
134
  end
@@ -7,11 +7,11 @@ describe Gitlab::Client do
7
7
  @key = Gitlab.key(1)
8
8
  end
9
9
 
10
- it "should get the correct resource" do
10
+ it "gets the correct resource" do
11
11
  expect(a_get("/keys/1")).to have_been_made
12
12
  end
13
13
 
14
- it "should return information about a key" do
14
+ it "returns information about a key" do
15
15
  expect(@key.id).to eq(1)
16
16
  expect(@key.title).to eq("narkoz@helium")
17
17
  end
@@ -7,11 +7,11 @@ describe Gitlab::Client do
7
7
  @labels = Gitlab.labels(3)
8
8
  end
9
9
 
10
- it "should get the correct resource" do
10
+ it "gets the correct resource" do
11
11
  expect(a_get("/projects/3/labels")).to have_been_made
12
12
  end
13
13
 
14
- it "should return a paginated response of project's labels" do
14
+ it "returns a paginated response of project's labels" do
15
15
  expect(@labels).to be_a Gitlab::PaginatedResponse
16
16
  expect(@labels.first.name).to eq("Backlog")
17
17
  end
@@ -23,12 +23,12 @@ describe Gitlab::Client do
23
23
  @label = Gitlab.delete_label(3, "Backlog")
24
24
  end
25
25
 
26
- it "should get the correct resource" do
26
+ it "gets the correct resource" do
27
27
  expect(a_delete("/projects/3/labels").
28
28
  with(body: { name: 'Backlog' })).to have_been_made
29
29
  end
30
30
 
31
- it "should return information about a deleted snippet" do
31
+ it "returns information about a deleted snippet" do
32
32
  expect(@label.name).to eq("Backlog")
33
33
  end
34
34
  end
@@ -39,12 +39,12 @@ describe Gitlab::Client do
39
39
  @label = Gitlab.edit_label(3, "TODO", new_name: 'Backlog')
40
40
  end
41
41
 
42
- it "should get the correct resource" do
42
+ it "gets the correct resource" do
43
43
  expect(a_put("/projects/3/labels").
44
44
  with(body: { name: 'TODO', new_name: "Backlog" })).to have_been_made
45
45
  end
46
46
 
47
- it "should return information about an edited label" do
47
+ it "returns information about an edited label" do
48
48
  expect(@label.name).to eq("Backlog")
49
49
  end
50
50
  end
@@ -55,12 +55,12 @@ describe Gitlab::Client do
55
55
  @label = Gitlab.create_label(3, 'Backlog', '#DD10AA')
56
56
  end
57
57
 
58
- it "should get the correct resource" do
58
+ it "gets the correct resource" do
59
59
  expect(a_post("/projects/3/labels").
60
60
  with(body: { name: 'Backlog', color: '#DD10AA' })).to have_been_made
61
61
  end
62
62
 
63
- it "should return information about a created label" do
63
+ it "returns information about a created label" do
64
64
  expect(@label.name).to eq('Backlog')
65
65
  expect(@label.color).to eq('#DD10AA')
66
66
  end
@@ -72,11 +72,11 @@ describe Gitlab::Client do
72
72
  @label = Gitlab.subscribe_to_label(3, 'Backlog')
73
73
  end
74
74
 
75
- it "should get the correct resource" do
75
+ it "gets the correct resource" do
76
76
  expect(a_post("/projects/3/labels/Backlog/subscribe")).to have_been_made
77
77
  end
78
78
 
79
- it "should return information about the label subscribed to" do
79
+ it "returns information about the label subscribed to" do
80
80
  expect(@label.name).to eq('Backlog')
81
81
  expect(@label.subscribed).to eq(true)
82
82
  end
@@ -88,11 +88,11 @@ describe Gitlab::Client do
88
88
  @label = Gitlab.unsubscribe_from_label(3, 'Backlog')
89
89
  end
90
90
 
91
- it "should get the correct resource" do
91
+ it "gets the correct resource" do
92
92
  expect(a_post("/projects/3/labels/Backlog/unsubscribe")).to have_been_made
93
93
  end
94
94
 
95
- it "should return information about the label subscribed to" do
95
+ it "returns information about the label subscribed to" do
96
96
  expect(@label.name).to eq('Backlog')
97
97
  expect(@label.subscribed).to eq(false)
98
98
  end