teamcity_ruby 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (19) hide show
  1. data/lib/teamcity_ruby/build_configuration.rb +38 -15
  2. data/lib/teamcity_ruby/version.rb +1 -1
  3. data/lib/teamcity_ruby.rb +2 -0
  4. data/spec/cassettes/TeamcityRuby_BuildConfiguration/{a_existing_build_configuration/can_get_a_build_step_added_to_it.yml → an_existing_build_configuration/has_a_build_step_added_to_it.yml} +103 -103
  5. data/spec/cassettes/TeamcityRuby_BuildConfiguration/{a_existing_build_configuration/can_get_a_build_trigger_added_to_it.yml → an_existing_build_configuration/has_a_build_trigger_added_to_it.yml} +93 -93
  6. data/spec/cassettes/TeamcityRuby_BuildConfiguration/{a_existing_build_configuration/can_get_a_vcs_root_attached_with_specific_checkout_rules.yml → an_existing_build_configuration/has_a_vcs_root_attached_to_it_with_specific_checkout_rules.yml} +106 -106
  7. data/spec/cassettes/TeamcityRuby_BuildConfiguration/an_existing_build_configuration/has_settings_definitions.yml +333 -0
  8. data/spec/cassettes/TeamcityRuby_BuildConfiguration/fetches_a_specific_build_configuration_by_id.yml +80 -80
  9. data/spec/cassettes/TeamcityRuby_BuildConfiguration/lists_all_build_configurations.yml +116 -116
  10. data/spec/cassettes/TeamcityRuby_Project/creates_a_project_copying_its_settings_from_a_source_project.yml +93 -93
  11. data/spec/cassettes/TeamcityRuby_Project/creates_a_project_with_a_parent_project.yml +48 -48
  12. data/spec/cassettes/TeamcityRuby_Project/destroys_a_specific_project.yml +64 -64
  13. data/spec/cassettes/TeamcityRuby_Project/fetches_a_specific_project_by_id_locator.yml +64 -64
  14. data/spec/cassettes/TeamcityRuby_Project/fetches_a_specific_project_by_name_locator.yml +56 -56
  15. data/spec/cassettes/TeamcityRuby_Project/lists_all_projects_including_root_built_in_on_TeamCity_.yml +68 -68
  16. data/spec/cassettes/TeamcityRuby_VcsRoot/lists_all_vcs_roots.yml +52 -52
  17. data/spec/spec_helper.rb +1 -0
  18. data/spec/teamcity_ruby/build_configuration_spec.rb +12 -4
  19. metadata +12 -10
@@ -17,27 +17,27 @@ http_interactions:
17
17
  message: OK
18
18
  headers:
19
19
  Date:
20
- - Sat, 19 Apr 2014 18:41:00 GMT
21
- Transfer-Encoding:
22
- - chunked
20
+ - Fri, 23 May 2014 04:53:05 GMT
23
21
  Server:
24
22
  - Apache-Coyote/1.1
25
- Set-Cookie:
26
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
27
- - TCSESSIONID=E8EE014814C072ED3FCB9ADEB6ED63A9; Path=/; HttpOnly
28
- Content-Type:
29
- - application/json
23
+ Cache-Control:
24
+ - no-cache
25
+ - no-store
30
26
  Pragma:
31
27
  - no-cache
28
+ Transfer-Encoding:
29
+ - chunked
30
+ Content-Type:
31
+ - application/json
32
+ Set-Cookie:
33
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
34
+ - TCSESSIONID=61C5A04873EBB4E2D15762000661E478; Path=/; HttpOnly
32
35
  Expires:
33
36
  - Thu, 01 Jan 1970 00:00:00 GMT
34
- Cache-Control:
35
- - no-cache
36
- - no-store
37
37
  body:
38
38
  string: "{\"project\":[{\"id\":\"_Root\",\"name\":\"<Root project>\",\"href\":\"/httpAuth/app/rest/projects/id:_Root\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=_Root\"},{\"id\":\"SampleProject\",\"name\":\"Sample Project\",\"href\":\"/httpAuth/app/rest/projects/id:SampleProject\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=SampleProject\",\"parentProjectId\":\"_Root\"}]}"
39
39
  http_version:
40
- recorded_at: Sat, 19 Apr 2014 18:38:15 GMT
40
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
41
41
  - request:
42
42
  method: delete
43
43
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:_Root
@@ -54,30 +54,30 @@ http_interactions:
54
54
  message: Forbidden
55
55
  headers:
56
56
  Date:
57
- - Sat, 19 Apr 2014 18:41:00 GMT
58
- Transfer-Encoding:
59
- - chunked
57
+ - Fri, 23 May 2014 04:53:05 GMT
60
58
  Server:
61
59
  - Apache-Coyote/1.1
62
- Set-Cookie:
63
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
64
- - TCSESSIONID=08E004B6DA4FA00A41A3DB43AC1B9603; Path=/; HttpOnly
65
- Content-Type:
66
- - text/plain
60
+ Cache-Control:
61
+ - no-cache
62
+ - no-store
67
63
  Pragma:
68
64
  - no-cache
65
+ Transfer-Encoding:
66
+ - chunked
67
+ Content-Type:
68
+ - text/plain
69
+ Set-Cookie:
70
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
71
+ - TCSESSIONID=3814D64B54278B5FD80688A41AC6528C; Path=/; HttpOnly
69
72
  Expires:
70
73
  - Thu, 01 Jan 1970 00:00:00 GMT
71
- Cache-Control:
72
- - no-cache
73
- - no-store
74
74
  body:
75
75
  string: |-
76
76
  Error has occurred during request processing (Forbidden).
77
77
  Error: jetbrains.buildServer.serverSide.auth.AccessDeniedException: Root project cannot be removed
78
78
  Access denied. Check the user has enough permissions to perform the operation.
79
79
  http_version:
80
- recorded_at: Sat, 19 Apr 2014 18:38:15 GMT
80
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
81
81
  - request:
82
82
  method: delete
83
83
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:SampleProject
@@ -94,23 +94,23 @@ http_interactions:
94
94
  message: No Content
95
95
  headers:
96
96
  Date:
97
- - Sat, 19 Apr 2014 18:41:00 GMT
97
+ - Fri, 23 May 2014 04:53:05 GMT
98
98
  Server:
99
99
  - Apache-Coyote/1.1
100
- Set-Cookie:
101
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
102
- - TCSESSIONID=BF5A2EA5B92248AF3D7DBD8F27F42390; Path=/; HttpOnly
100
+ Cache-Control:
101
+ - no-cache
102
+ - no-store
103
103
  Pragma:
104
104
  - no-cache
105
+ Set-Cookie:
106
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
107
+ - TCSESSIONID=32111CFA8AE22CBB79385DDB6A32CBFF; Path=/; HttpOnly
105
108
  Expires:
106
109
  - Thu, 01 Jan 1970 00:00:00 GMT
107
- Cache-Control:
108
- - no-cache
109
- - no-store
110
110
  body:
111
111
  string: ""
112
112
  http_version:
113
- recorded_at: Sat, 19 Apr 2014 18:38:15 GMT
113
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
114
114
  - request:
115
115
  method: get
116
116
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/vcs-roots
@@ -127,27 +127,27 @@ http_interactions:
127
127
  message: OK
128
128
  headers:
129
129
  Date:
130
- - Sat, 19 Apr 2014 18:41:00 GMT
131
- Transfer-Encoding:
132
- - chunked
130
+ - Fri, 23 May 2014 04:53:05 GMT
133
131
  Server:
134
132
  - Apache-Coyote/1.1
135
- Set-Cookie:
136
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
137
- - TCSESSIONID=2D0D4CEE351A71D1F54A8B9BA03FF383; Path=/; HttpOnly
138
- Content-Type:
139
- - application/json
133
+ Cache-Control:
134
+ - no-cache
135
+ - no-store
140
136
  Pragma:
141
137
  - no-cache
138
+ Transfer-Encoding:
139
+ - chunked
140
+ Content-Type:
141
+ - application/json
142
+ Set-Cookie:
143
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
144
+ - TCSESSIONID=01435E3280857A160FBD66A679562DAC; Path=/; HttpOnly
142
145
  Expires:
143
146
  - Thu, 01 Jan 1970 00:00:00 GMT
144
- Cache-Control:
145
- - no-cache
146
- - no-store
147
147
  body:
148
148
  string: "{\"count\":0,\"vcs-root\":[]}"
149
149
  http_version:
150
- recorded_at: Sat, 19 Apr 2014 18:38:15 GMT
150
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
151
151
  - request:
152
152
  method: post
153
153
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects
@@ -164,32 +164,32 @@ http_interactions:
164
164
  message: OK
165
165
  headers:
166
166
  Date:
167
- - Sat, 19 Apr 2014 18:41:00 GMT
168
- Transfer-Encoding:
169
- - chunked
167
+ - Fri, 23 May 2014 04:53:05 GMT
170
168
  Server:
171
169
  - Apache-Coyote/1.1
172
- Set-Cookie:
173
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
174
- - TCSESSIONID=2D30507F7FC256266F0D403216151F58; Path=/; HttpOnly
175
- Content-Type:
176
- - application/json
170
+ Cache-Control:
171
+ - no-cache
172
+ - no-store
177
173
  Pragma:
178
174
  - no-cache
175
+ Transfer-Encoding:
176
+ - chunked
177
+ Content-Type:
178
+ - application/json
179
+ Set-Cookie:
180
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
181
+ - TCSESSIONID=63C630E870A3263412D74F5F3226D8FB; Path=/; HttpOnly
179
182
  Expires:
180
183
  - Thu, 01 Jan 1970 00:00:00 GMT
181
- Cache-Control:
182
- - no-cache
183
- - no-store
184
184
  body:
185
185
  string: "{\"id\":\"SampleProject\",\"name\":\"Sample Project\",\"href\":\"/httpAuth/app/rest/projects/id:SampleProject\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=SampleProject\",\"parentProjectId\":\"_Root\"}"
186
186
  http_version:
187
- recorded_at: Sat, 19 Apr 2014 18:38:15 GMT
187
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
188
188
  - request:
189
189
  method: post
190
190
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/vcs-roots
191
191
  body:
192
- string: "{\"name\":\"Sample VCS Root\",\"properties\":{\"property\":[]},\"projectLocator\":\"id:_Root\",\"vcsName\":\"jetbrains.git\"}"
192
+ string: "{\"projectLocator\":\"id:_Root\",\"properties\":{\"property\":[]},\"vcsName\":\"jetbrains.git\",\"name\":\"Sample VCS Root\"}"
193
193
  headers:
194
194
  Accept:
195
195
  - application/json
@@ -201,27 +201,27 @@ http_interactions:
201
201
  message: OK
202
202
  headers:
203
203
  Date:
204
- - Sat, 19 Apr 2014 18:41:00 GMT
205
- Transfer-Encoding:
206
- - chunked
204
+ - Fri, 23 May 2014 04:53:05 GMT
207
205
  Server:
208
206
  - Apache-Coyote/1.1
209
- Set-Cookie:
210
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
211
- - TCSESSIONID=DF482D553549308F6595FB1F6E095CC7; Path=/; HttpOnly
212
- Content-Type:
213
- - application/json
207
+ Cache-Control:
208
+ - no-cache
209
+ - no-store
214
210
  Pragma:
215
211
  - no-cache
212
+ Transfer-Encoding:
213
+ - chunked
214
+ Content-Type:
215
+ - application/json
216
+ Set-Cookie:
217
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
218
+ - TCSESSIONID=CB4F9B58EA734EA8199B8CE62BEDC2F4; Path=/; HttpOnly
216
219
  Expires:
217
220
  - Thu, 01 Jan 1970 00:00:00 GMT
218
- Cache-Control:
219
- - no-cache
220
- - no-store
221
221
  body:
222
- string: "{\"id\":\"Root_SampleVcsRoot\",\"name\":\"Sample VCS Root\",\"vcsName\":\"jetbrains.git\",\"status\":\"NOT_MONITORED\",\"lastChecked\":\"20140419T173243+0000\",\"href\":\"/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot\",\"project\":{\"id\":\"_Root\",\"name\":\"<Root project>\",\"href\":\"/httpAuth/app/rest/projects/id:_Root\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=_Root\"},\"properties\":{\"property\":[]},\"vcsRootInstances\":{\"href\":\"/httpAuth/app/rest/vcs-root-instances?locator=vcsRoot:(id:Root_SampleVcsRoot)\"}}"
222
+ string: "{\"id\":\"Root_SampleVcsRoot\",\"name\":\"Sample VCS Root\",\"vcsName\":\"jetbrains.git\",\"status\":\"NOT_MONITORED\",\"lastChecked\":\"20140523T040300+0000\",\"href\":\"/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot\",\"project\":{\"id\":\"_Root\",\"name\":\"<Root project>\",\"href\":\"/httpAuth/app/rest/projects/id:_Root\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=_Root\"},\"properties\":{\"property\":[]},\"vcsRootInstances\":{\"href\":\"/httpAuth/app/rest/vcs-root-instances?locator=vcsRoot:(id:Root_SampleVcsRoot)\"}}"
223
223
  http_version:
224
- recorded_at: Sat, 19 Apr 2014 18:38:16 GMT
224
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
225
225
  - request:
226
226
  method: post
227
227
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:SampleProject/buildTypes
@@ -238,27 +238,27 @@ http_interactions:
238
238
  message: OK
239
239
  headers:
240
240
  Date:
241
- - Sat, 19 Apr 2014 18:41:00 GMT
242
- Transfer-Encoding:
243
- - chunked
241
+ - Fri, 23 May 2014 04:53:05 GMT
244
242
  Server:
245
243
  - Apache-Coyote/1.1
246
- Set-Cookie:
247
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
248
- - TCSESSIONID=F2B898692AA1EC3BE998245A1F49FB4A; Path=/; HttpOnly
249
- Content-Type:
250
- - application/json
244
+ Cache-Control:
245
+ - no-cache
246
+ - no-store
251
247
  Pragma:
252
248
  - no-cache
249
+ Transfer-Encoding:
250
+ - chunked
251
+ Content-Type:
252
+ - application/json
253
+ Set-Cookie:
254
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
255
+ - TCSESSIONID=2AD2C8A3BD8C5A319C79F72BE4B769C2; Path=/; HttpOnly
253
256
  Expires:
254
257
  - Thu, 01 Jan 1970 00:00:00 GMT
255
- Cache-Control:
256
- - no-cache
257
- - no-store
258
258
  body:
259
259
  string: "{\"id\":\"SampleProject_SampleBuildConfiguration\",\"name\":\"Sample Build Configuration\",\"href\":\"/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration\",\"webUrl\":\"http://localhost:8111/viewType.html?buildTypeId=SampleProject_SampleBuildConfiguration\",\"paused\":false,\"project\":{\"id\":\"SampleProject\",\"name\":\"Sample Project\",\"href\":\"/httpAuth/app/rest/projects/id:SampleProject\",\"archived\":false,\"webUrl\":\"http://localhost:8111/project.html?projectId=SampleProject\",\"parentProjectId\":\"_Root\"},\"builds\":{\"href\":\"/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration/builds/\"},\"vcs-root-entries\":{\"vcs-root-entry\":[]},\"settings\":{\"property\":[{\"name\":\"allowExternalStatus\",\"value\":\"false\"},{\"name\":\"artifactRules\",\"value\":\"\"},{\"name\":\"buildNumberCounter\",\"value\":\"1\"},{\"name\":\"buildNumberPattern\",\"value\":\"%build.counter%\"},{\"name\":\"checkoutDirectory\"},{\"name\":\"checkoutMode\",\"value\":\"ON_SERVER\"},{\"name\":\"cleanBuild\",\"value\":\"false\"},{\"name\":\"enableHangingBuildsDetection\",\"value\":\"true\"},{\"name\":\"executionTimeoutMin\",\"value\":\"0\"},{\"name\":\"maximumNumberOfBuilds\",\"value\":\"0\"},{\"name\":\"shouldFailBuildIfTestsFailed\",\"value\":\"true\"},{\"name\":\"shouldFailBuildOnAnyErrorMessage\",\"value\":\"false\"},{\"name\":\"shouldFailBuildOnBadExitCode\",\"value\":\"true\"},{\"name\":\"shouldFailBuildOnOOMEOrCrash\",\"value\":\"true\"},{\"name\":\"showDependenciesChanges\",\"value\":\"false\"},{\"name\":\"vcsLabelingBranchFilter\",\"value\":\"+:<default>\"}]},\"parameters\":{\"property\":[]},\"steps\":{\"step\":[]},\"features\":{\"feature\":[]},\"triggers\":{\"trigger\":[]},\"snapshot-dependencies\":{\"snapshot-dependency\":[]},\"artifact-dependencies\":{\"artifact-dependency\":[]},\"agent-requirements\":{\"agent-requirement\":[]}}"
260
260
  http_version:
261
- recorded_at: Sat, 19 Apr 2014 18:38:16 GMT
261
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
262
262
  - request:
263
263
  method: post
264
264
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration/vcs-root-entries
@@ -275,27 +275,27 @@ http_interactions:
275
275
  message: OK
276
276
  headers:
277
277
  Date:
278
- - Sat, 19 Apr 2014 18:41:00 GMT
279
- Transfer-Encoding:
280
- - chunked
278
+ - Fri, 23 May 2014 04:53:05 GMT
281
279
  Server:
282
280
  - Apache-Coyote/1.1
283
- Set-Cookie:
284
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
285
- - TCSESSIONID=27F45AEB3DE9FF7873A7410C77ED1521; Path=/; HttpOnly
286
- Content-Type:
287
- - application/json
281
+ Cache-Control:
282
+ - no-cache
283
+ - no-store
288
284
  Pragma:
289
285
  - no-cache
286
+ Transfer-Encoding:
287
+ - chunked
288
+ Content-Type:
289
+ - application/json
290
+ Set-Cookie:
291
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
292
+ - TCSESSIONID=3E2AB3A9A15B35F5403C6C05DBAE223F; Path=/; HttpOnly
290
293
  Expires:
291
294
  - Thu, 01 Jan 1970 00:00:00 GMT
292
- Cache-Control:
293
- - no-cache
294
- - no-store
295
295
  body:
296
296
  string: "{\"id\":\"Root_SampleVcsRoot\",\"vcs-root\":{\"id\":\"Root_SampleVcsRoot\",\"name\":\"Sample VCS Root\",\"href\":\"/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot\"},\"checkout-rules\":\"+:trunk => .\"}"
297
297
  http_version:
298
- recorded_at: Sat, 19 Apr 2014 18:38:16 GMT
298
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT
299
299
  - request:
300
300
  method: get
301
301
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration/vcs-root-entries
@@ -312,24 +312,24 @@ http_interactions:
312
312
  message: OK
313
313
  headers:
314
314
  Date:
315
- - Sat, 19 Apr 2014 18:41:00 GMT
316
- Transfer-Encoding:
317
- - chunked
315
+ - Fri, 23 May 2014 04:53:05 GMT
318
316
  Server:
319
317
  - Apache-Coyote/1.1
320
- Set-Cookie:
321
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
322
- - TCSESSIONID=6B7B50B2D55A1456B3BCF7BD44E9B98B; Path=/; HttpOnly
323
- Content-Type:
324
- - application/json
318
+ Cache-Control:
319
+ - no-cache
320
+ - no-store
325
321
  Pragma:
326
322
  - no-cache
323
+ Transfer-Encoding:
324
+ - chunked
325
+ Content-Type:
326
+ - application/json
327
+ Set-Cookie:
328
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
329
+ - TCSESSIONID=7A2C9D8466D50C780B1B09B967CFC69D; Path=/; HttpOnly
327
330
  Expires:
328
331
  - Thu, 01 Jan 1970 00:00:00 GMT
329
- Cache-Control:
330
- - no-cache
331
- - no-store
332
332
  body:
333
333
  string: "{\"vcs-root-entry\":[{\"id\":\"Root_SampleVcsRoot\",\"vcs-root\":{\"id\":\"Root_SampleVcsRoot\",\"name\":\"Sample VCS Root\",\"href\":\"/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot\"},\"checkout-rules\":\"+:trunk => .\"}]}"
334
334
  http_version:
335
- recorded_at: Sat, 19 Apr 2014 18:38:16 GMT
335
+ recorded_at: Fri, 23 May 2014 04:53:06 GMT