teamcity_ruby 0.0.5 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (21) hide show
  1. data/lib/teamcity_ruby/agent_pool.rb +1 -1
  2. data/lib/teamcity_ruby/resource.rb +3 -1
  3. data/lib/teamcity_ruby/vcs_root.rb +10 -3
  4. data/lib/teamcity_ruby/version.rb +1 -1
  5. data/spec/cassettes/TeamcityRuby_AgentPool/creates_an_agent_pool.yml +99 -99
  6. data/spec/cassettes/TeamcityRuby_BuildConfiguration/an_existing_build_configuration/has_a_build_step_added_to_it.yml +107 -107
  7. data/spec/cassettes/TeamcityRuby_BuildConfiguration/an_existing_build_configuration/has_a_build_trigger_added_to_it.yml +95 -95
  8. data/spec/cassettes/TeamcityRuby_BuildConfiguration/an_existing_build_configuration/has_a_vcs_root_attached_to_it_with_specific_checkout_rules.yml +142 -105
  9. data/spec/cassettes/TeamcityRuby_BuildConfiguration/an_existing_build_configuration/has_settings_definitions.yml +104 -104
  10. data/spec/cassettes/TeamcityRuby_BuildConfiguration/fetches_a_specific_build_configuration_by_id.yml +82 -82
  11. data/spec/cassettes/TeamcityRuby_BuildConfiguration/lists_all_build_configurations.yml +104 -104
  12. data/spec/cassettes/TeamcityRuby_Project/creates_a_project_copying_its_settings_from_a_source_project.yml +94 -94
  13. data/spec/cassettes/TeamcityRuby_Project/creates_a_project_with_a_parent_project.yml +49 -49
  14. data/spec/cassettes/TeamcityRuby_Project/destroys_a_specific_project.yml +68 -68
  15. data/spec/cassettes/TeamcityRuby_Project/fetches_a_specific_project_by_id_locator.yml +68 -68
  16. data/spec/cassettes/TeamcityRuby_Project/fetches_a_specific_project_by_name_locator.yml +58 -58
  17. data/spec/cassettes/TeamcityRuby_Project/lists_all_projects_including_root_built_in_on_TeamCity_.yml +70 -70
  18. data/spec/cassettes/TeamcityRuby_VcsRoot/lists_all_vcs_roots.yml +118 -44
  19. data/spec/teamcity_ruby/agent_pool_spec.rb +1 -1
  20. data/spec/teamcity_ruby/vcs_root_spec.rb +1 -0
  21. metadata +3 -3
@@ -14,7 +14,7 @@ module TeamcityRuby
14
14
  end
15
15
 
16
16
  def initialize(options = {})
17
- @teamcity_id = options["id"]
17
+ @teamcity_id = options["id"].to_s
18
18
  @name = options["name"]
19
19
  end
20
20
 
@@ -6,7 +6,7 @@ module TeamcityRuby
6
6
 
7
7
  def locator(options)
8
8
  raise(ArgumentError, "the Locator must be a Hash") unless options.is_a? Hash
9
- options.map { |key, value| "#{key}:#{URI.escape(value)}" }.join
9
+ options.map { |key, value| "#{key}:#{URI.escape(value.to_s)}" }.join
10
10
  end
11
11
 
12
12
  def url_path(url_path)
@@ -39,8 +39,10 @@ module TeamcityRuby
39
39
  end
40
40
  end
41
41
 
42
+
42
43
  def self.extended(base)
43
44
  base.send(:include, InstanceMethods)
44
45
  end
46
+
45
47
  end
46
48
  end
@@ -7,7 +7,7 @@ module TeamcityRuby
7
7
  DEFAULT_PROJECT = "_Root"
8
8
  DEFAULT_VCS_TYPE = "jetbrains.git"
9
9
 
10
- attr_reader :teamcity_id, :name, :parent_id, :vcs_type
10
+ attr_reader :teamcity_id, :name, :parent_id, :vcs_type, :properties
11
11
 
12
12
  url_path "/vcs-roots"
13
13
  resource_name "vcs-root"
@@ -24,23 +24,30 @@ module TeamcityRuby
24
24
  attributes = {
25
25
  "name" => options[:name],
26
26
  "vcsName" => vcs_type,
27
- "projectLocator" => "id:#{project_id}",
27
+ "projectLocator" => "id:#{project_id}"
28
28
  }
29
29
 
30
30
  builder = TeamCity::ElementBuilder.new(attributes, &block)
31
31
 
32
32
  response = client.post("/vcs-roots", :body => builder.to_request_body)
33
- VcsRoot.new(response)
33
+ VcsRoot.find(:id => response["id"])
34
34
  end
35
35
 
36
36
  def initialize(options = {})
37
37
  @teamcity_id = options["id"]
38
38
  @name = options["name"]
39
39
  @vcs_type = options["vcsName"]
40
+ @properties = flat_properties(options["properties"]) if options["properties"]
40
41
  end
41
42
 
42
43
  def destroy!
43
44
  client.delete("/vcs-roots/id:#{self.teamcity_id}")
44
45
  end
46
+
47
+ def flat_properties(properties)
48
+ properties.delete("property").map do |p|
49
+ { p["name"] => p["value"] }
50
+ end
51
+ end
45
52
  end
46
53
  end
@@ -1,3 +1,3 @@
1
1
  module TeamcityRuby
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
@@ -15,31 +15,31 @@ http_interactions:
15
15
  code: 200
16
16
  message: OK
17
17
  headers:
18
- Server:
19
- - Apache-Coyote/1.1
20
- Transfer-Encoding:
21
- - chunked
22
- Cache-Control:
23
- - no-cache
24
- - no-store
25
- Pragma:
26
- - no-cache
27
18
  Content-Type:
28
19
  - application/json
29
20
  Expires:
30
21
  - Thu, 01 Jan 1970 00:00:00 GMT
22
+ Pragma:
23
+ - no-cache
31
24
  Date:
32
- - Fri, 23 May 2014 07:28:31 GMT
25
+ - Fri, 23 May 2014 15:05:35 GMT
33
26
  Set-Cookie:
34
27
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
35
- - TCSESSIONID=7EDCAEB88F5E5CCC8FA95E3B3A81F019; Path=/; HttpOnly
28
+ - TCSESSIONID=993462B69AD936795F2DEF2F37DFC7AD; Path=/; HttpOnly
29
+ Transfer-Encoding:
30
+ - chunked
31
+ Server:
32
+ - Apache-Coyote/1.1
33
+ Cache-Control:
34
+ - no-cache
35
+ - no-store
36
36
  body:
37
- string: "{\"count\":2,\"agentPool\":[{\"id\":59,\"name\":\"Linux\",\"href\":\"/httpAuth/app/rest/agentPools/id:59\"},{\"id\":0,\"name\":\"Default\",\"href\":\"/httpAuth/app/rest/agentPools/id:0\"}]}"
37
+ string: "{\"count\":2,\"agentPool\":[{\"id\":100,\"name\":\"Linux\",\"href\":\"/httpAuth/app/rest/agentPools/id:100\"},{\"id\":0,\"name\":\"Default\",\"href\":\"/httpAuth/app/rest/agentPools/id:0\"}]}"
38
38
  http_version:
39
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
39
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
40
40
  - request:
41
41
  method: delete
42
- uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools/id:59
42
+ uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools/id:100
43
43
  body:
44
44
  string: ""
45
45
  headers:
@@ -52,24 +52,24 @@ http_interactions:
52
52
  code: 204
53
53
  message: No Content
54
54
  headers:
55
- Server:
56
- - Apache-Coyote/1.1
57
- Cache-Control:
58
- - no-cache
59
- - no-store
60
- Pragma:
61
- - no-cache
62
55
  Expires:
63
56
  - Thu, 01 Jan 1970 00:00:00 GMT
57
+ Pragma:
58
+ - no-cache
64
59
  Date:
65
- - Fri, 23 May 2014 07:28:31 GMT
60
+ - Fri, 23 May 2014 15:05:35 GMT
66
61
  Set-Cookie:
67
62
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
68
- - TCSESSIONID=433462B82682429156224F4B667A4049; Path=/; HttpOnly
63
+ - TCSESSIONID=257FCB921034195CDB27DBA0F65B4998; Path=/; HttpOnly
64
+ Server:
65
+ - Apache-Coyote/1.1
66
+ Cache-Control:
67
+ - no-cache
68
+ - no-store
69
69
  body:
70
70
  string: ""
71
71
  http_version:
72
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
72
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
73
73
  - request:
74
74
  method: delete
75
75
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools/id:0
@@ -85,33 +85,33 @@ http_interactions:
85
85
  code: 500
86
86
  message: Internal Server Error
87
87
  headers:
88
- Server:
89
- - Apache-Coyote/1.1
90
- Transfer-Encoding:
91
- - chunked
92
- Cache-Control:
93
- - no-cache
94
- - no-store
95
- Pragma:
96
- - no-cache
97
88
  Content-Type:
98
89
  - text/plain
99
- Connection:
100
- - close
101
90
  Expires:
102
91
  - Thu, 01 Jan 1970 00:00:00 GMT
92
+ Pragma:
93
+ - no-cache
103
94
  Date:
104
- - Fri, 23 May 2014 07:28:31 GMT
95
+ - Fri, 23 May 2014 15:05:35 GMT
105
96
  Set-Cookie:
106
97
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
107
- - TCSESSIONID=75BC9F858DB316C838B3AB0231CDC7CE; Path=/; HttpOnly
98
+ - TCSESSIONID=9AE2E4EF257A8DCEF2B465D5ECAA1A87; Path=/; HttpOnly
99
+ Connection:
100
+ - close
101
+ Transfer-Encoding:
102
+ - chunked
103
+ Server:
104
+ - Apache-Coyote/1.1
105
+ Cache-Control:
106
+ - no-cache
107
+ - no-store
108
108
  body:
109
109
  string: |-
110
110
  Error has occurred during request processing (Internal Server Error).
111
111
  Error: java.lang.IllegalStateException: Cannot delete agent pool with id '0'., caused by: jetbrains.buildServer.serverSide.agentPools.AgentPoolCannotBeDeletedException: Default agent pool cannot be deleted
112
112
  Error occurred while processing this request.
113
113
  http_version:
114
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
114
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
115
115
  - request:
116
116
  method: get
117
117
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects
@@ -127,28 +127,28 @@ http_interactions:
127
127
  code: 200
128
128
  message: OK
129
129
  headers:
130
- Server:
131
- - Apache-Coyote/1.1
132
- Transfer-Encoding:
133
- - chunked
134
- Cache-Control:
135
- - no-cache
136
- - no-store
137
- Pragma:
138
- - no-cache
139
130
  Content-Type:
140
131
  - application/json
141
132
  Expires:
142
133
  - Thu, 01 Jan 1970 00:00:00 GMT
134
+ Pragma:
135
+ - no-cache
143
136
  Date:
144
- - Fri, 23 May 2014 07:28:31 GMT
137
+ - Fri, 23 May 2014 15:05:35 GMT
145
138
  Set-Cookie:
146
139
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
147
- - TCSESSIONID=9655A1860983E225ECCD34082B9C9EB5; Path=/; HttpOnly
140
+ - TCSESSIONID=E1888B6BB2A09A117D7C29A0A09C1144; Path=/; HttpOnly
141
+ Transfer-Encoding:
142
+ - chunked
143
+ Server:
144
+ - Apache-Coyote/1.1
145
+ Cache-Control:
146
+ - no-cache
147
+ - no-store
148
148
  body:
149
149
  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\"}]}"
150
150
  http_version:
151
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
151
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
152
152
  - request:
153
153
  method: delete
154
154
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:_Root
@@ -164,31 +164,31 @@ http_interactions:
164
164
  code: 403
165
165
  message: Forbidden
166
166
  headers:
167
- Server:
168
- - Apache-Coyote/1.1
169
- Transfer-Encoding:
170
- - chunked
171
- Cache-Control:
172
- - no-cache
173
- - no-store
174
- Pragma:
175
- - no-cache
176
167
  Content-Type:
177
168
  - text/plain
178
169
  Expires:
179
170
  - Thu, 01 Jan 1970 00:00:00 GMT
171
+ Pragma:
172
+ - no-cache
180
173
  Date:
181
- - Fri, 23 May 2014 07:28:31 GMT
174
+ - Fri, 23 May 2014 15:05:35 GMT
182
175
  Set-Cookie:
183
176
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
184
- - TCSESSIONID=F903F5A1556A724D4F662C9496C3BBB3; Path=/; HttpOnly
177
+ - TCSESSIONID=B05F31A5D42250C797F31F94A0419E17; Path=/; HttpOnly
178
+ Transfer-Encoding:
179
+ - chunked
180
+ Server:
181
+ - Apache-Coyote/1.1
182
+ Cache-Control:
183
+ - no-cache
184
+ - no-store
185
185
  body:
186
186
  string: |-
187
187
  Error has occurred during request processing (Forbidden).
188
188
  Error: jetbrains.buildServer.serverSide.auth.AccessDeniedException: Root project cannot be removed
189
189
  Access denied. Check the user has enough permissions to perform the operation.
190
190
  http_version:
191
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
191
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
192
192
  - request:
193
193
  method: delete
194
194
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:SampleProject
@@ -204,24 +204,24 @@ http_interactions:
204
204
  code: 204
205
205
  message: No Content
206
206
  headers:
207
- Server:
208
- - Apache-Coyote/1.1
209
- Cache-Control:
210
- - no-cache
211
- - no-store
212
- Pragma:
213
- - no-cache
214
207
  Expires:
215
208
  - Thu, 01 Jan 1970 00:00:00 GMT
209
+ Pragma:
210
+ - no-cache
216
211
  Date:
217
- - Fri, 23 May 2014 07:28:31 GMT
212
+ - Fri, 23 May 2014 15:05:35 GMT
218
213
  Set-Cookie:
219
214
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
220
- - TCSESSIONID=DA17A7E9FDEAC7EB55B83EF2F180A3E8; Path=/; HttpOnly
215
+ - TCSESSIONID=CCB9ACDAE23DC494BFAA17A321D0674B; Path=/; HttpOnly
216
+ Server:
217
+ - Apache-Coyote/1.1
218
+ Cache-Control:
219
+ - no-cache
220
+ - no-store
221
221
  body:
222
222
  string: ""
223
223
  http_version:
224
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
224
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
225
225
  - request:
226
226
  method: post
227
227
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools
@@ -237,31 +237,31 @@ http_interactions:
237
237
  code: 200
238
238
  message: OK
239
239
  headers:
240
- Server:
241
- - Apache-Coyote/1.1
242
- Transfer-Encoding:
243
- - chunked
244
- Cache-Control:
245
- - no-cache
246
- - no-store
247
- Pragma:
248
- - no-cache
249
240
  Content-Type:
250
241
  - application/json
251
242
  Expires:
252
243
  - Thu, 01 Jan 1970 00:00:00 GMT
244
+ Pragma:
245
+ - no-cache
253
246
  Date:
254
- - Fri, 23 May 2014 07:28:31 GMT
247
+ - Fri, 23 May 2014 15:05:35 GMT
255
248
  Set-Cookie:
256
249
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
257
- - TCSESSIONID=3757C202E2DF7DD6C9B144646C311E2B; Path=/; HttpOnly
250
+ - TCSESSIONID=16FC0BAC98AF6DE4E511F80A643DC3CE; Path=/; HttpOnly
251
+ Transfer-Encoding:
252
+ - chunked
253
+ Server:
254
+ - Apache-Coyote/1.1
255
+ Cache-Control:
256
+ - no-cache
257
+ - no-store
258
258
  body:
259
- string: "{\"href\":\"/httpAuth/app/rest/agentPools/id:60\",\"id\":60,\"name\":\"Linux\",\"projects\":{\"project\":[]},\"agents\":{\"count\":0,\"agent\":[]}}"
259
+ string: "{\"href\":\"/httpAuth/app/rest/agentPools/id:101\",\"id\":101,\"name\":\"Linux\",\"projects\":{\"project\":[]},\"agents\":{\"count\":0,\"agent\":[]}}"
260
260
  http_version:
261
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
261
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
262
262
  - request:
263
263
  method: get
264
- uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools/id:60
264
+ uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/agentPools/id:101
265
265
  body:
266
266
  string: ""
267
267
  headers:
@@ -274,26 +274,26 @@ http_interactions:
274
274
  code: 200
275
275
  message: OK
276
276
  headers:
277
- Server:
278
- - Apache-Coyote/1.1
279
- Transfer-Encoding:
280
- - chunked
281
- Cache-Control:
282
- - no-cache
283
- - no-store
284
- Pragma:
285
- - no-cache
286
277
  Content-Type:
287
278
  - application/json
288
279
  Expires:
289
280
  - Thu, 01 Jan 1970 00:00:00 GMT
281
+ Pragma:
282
+ - no-cache
290
283
  Date:
291
- - Fri, 23 May 2014 07:28:31 GMT
284
+ - Fri, 23 May 2014 15:05:35 GMT
292
285
  Set-Cookie:
293
286
  - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
294
- - TCSESSIONID=96404C821CC716899CD608E900E66C33; Path=/; HttpOnly
287
+ - TCSESSIONID=623B15FEB71E9879BB46A9AA87C4AC61; Path=/; HttpOnly
288
+ Transfer-Encoding:
289
+ - chunked
290
+ Server:
291
+ - Apache-Coyote/1.1
292
+ Cache-Control:
293
+ - no-cache
294
+ - no-store
295
295
  body:
296
- string: "{\"href\":\"/httpAuth/app/rest/agentPools/id:60\",\"id\":60,\"name\":\"Linux\",\"projects\":{\"project\":[]},\"agents\":{\"count\":0,\"agent\":[]}}"
296
+ string: "{\"href\":\"/httpAuth/app/rest/agentPools/id:101\",\"id\":101,\"name\":\"Linux\",\"projects\":{\"project\":[]},\"agents\":{\"count\":0,\"agent\":[]}}"
297
297
  http_version:
298
- recorded_at: Fri, 23 May 2014 07:28:31 GMT
298
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
299
299
  recorded_with: VCR 2.4.0
@@ -6,67 +6,67 @@ http_interactions:
6
6
  body:
7
7
  string: ""
8
8
  headers:
9
- Accept:
10
- - application/json
11
9
  Content-Type:
12
10
  - application/json
11
+ Accept:
12
+ - application/json
13
13
  response:
14
14
  status:
15
15
  code: 200
16
16
  message: OK
17
17
  headers:
18
- Set-Cookie:
19
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
20
- - TCSESSIONID=3BC4A203EAE28CB990B2A7DA6DCE8B03; Path=/; HttpOnly
21
- Pragma:
22
- - no-cache
23
18
  Content-Type:
24
19
  - application/json
25
- Server:
26
- - Apache-Coyote/1.1
27
- Date:
28
- - Fri, 23 May 2014 07:28:36 GMT
29
20
  Expires:
30
21
  - Thu, 01 Jan 1970 00:00:00 GMT
22
+ Pragma:
23
+ - no-cache
24
+ Date:
25
+ - Fri, 23 May 2014 15:05:35 GMT
26
+ Set-Cookie:
27
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
28
+ - TCSESSIONID=01196933DC74130ED24C0D40ED1E7D29; Path=/; HttpOnly
31
29
  Transfer-Encoding:
32
30
  - chunked
31
+ Server:
32
+ - Apache-Coyote/1.1
33
33
  Cache-Control:
34
34
  - no-cache
35
35
  - no-store
36
36
  body:
37
37
  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\"}]}"
38
38
  http_version:
39
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
39
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
40
40
  - request:
41
41
  method: delete
42
42
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:_Root
43
43
  body:
44
44
  string: ""
45
45
  headers:
46
- Accept:
47
- - application/json
48
46
  Content-Type:
49
47
  - application/json
48
+ Accept:
49
+ - application/json
50
50
  response:
51
51
  status:
52
52
  code: 403
53
53
  message: Forbidden
54
54
  headers:
55
- Set-Cookie:
56
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
57
- - TCSESSIONID=87B51635EFA504BA0025AE807E296459; Path=/; HttpOnly
58
- Pragma:
59
- - no-cache
60
55
  Content-Type:
61
56
  - text/plain
62
- Server:
63
- - Apache-Coyote/1.1
64
- Date:
65
- - Fri, 23 May 2014 07:28:36 GMT
66
57
  Expires:
67
58
  - Thu, 01 Jan 1970 00:00:00 GMT
59
+ Pragma:
60
+ - no-cache
61
+ Date:
62
+ - Fri, 23 May 2014 15:05:35 GMT
63
+ Set-Cookie:
64
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
65
+ - TCSESSIONID=5C723419223CD419EBBDFD3C9908D075; Path=/; HttpOnly
68
66
  Transfer-Encoding:
69
67
  - chunked
68
+ Server:
69
+ - Apache-Coyote/1.1
70
70
  Cache-Control:
71
71
  - no-cache
72
72
  - no-store
@@ -76,256 +76,256 @@ http_interactions:
76
76
  Error: jetbrains.buildServer.serverSide.auth.AccessDeniedException: Root project cannot be removed
77
77
  Access denied. Check the user has enough permissions to perform the operation.
78
78
  http_version:
79
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
79
+ recorded_at: Fri, 23 May 2014 15:05:36 GMT
80
80
  - request:
81
81
  method: delete
82
82
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:SampleProject
83
83
  body:
84
84
  string: ""
85
85
  headers:
86
- Accept:
87
- - application/json
88
86
  Content-Type:
89
87
  - application/json
88
+ Accept:
89
+ - application/json
90
90
  response:
91
91
  status:
92
92
  code: 204
93
93
  message: No Content
94
94
  headers:
95
- Set-Cookie:
96
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
97
- - TCSESSIONID=A99E150CEC6455C3128AEE8A6015FE88; Path=/; HttpOnly
95
+ Expires:
96
+ - Thu, 01 Jan 1970 00:00:00 GMT
98
97
  Pragma:
99
98
  - no-cache
99
+ Date:
100
+ - Fri, 23 May 2014 15:05:36 GMT
101
+ Set-Cookie:
102
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
103
+ - TCSESSIONID=38C5BB94E2B9B3A68025DAECC678139F; Path=/; HttpOnly
100
104
  Server:
101
105
  - Apache-Coyote/1.1
102
- Date:
103
- - Fri, 23 May 2014 07:28:36 GMT
104
- Expires:
105
- - Thu, 01 Jan 1970 00:00:00 GMT
106
106
  Cache-Control:
107
107
  - no-cache
108
108
  - no-store
109
109
  body:
110
110
  string: ""
111
111
  http_version:
112
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
112
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
113
113
  - request:
114
114
  method: get
115
115
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/vcs-roots
116
116
  body:
117
117
  string: ""
118
118
  headers:
119
- Accept:
120
- - application/json
121
119
  Content-Type:
122
120
  - application/json
121
+ Accept:
122
+ - application/json
123
123
  response:
124
124
  status:
125
125
  code: 200
126
126
  message: OK
127
127
  headers:
128
- Set-Cookie:
129
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
130
- - TCSESSIONID=C8FB723BC05CB4EE3B6D55E0236D6F70; Path=/; HttpOnly
131
- Pragma:
132
- - no-cache
133
128
  Content-Type:
134
129
  - application/json
135
- Server:
136
- - Apache-Coyote/1.1
137
- Date:
138
- - Fri, 23 May 2014 07:28:36 GMT
139
130
  Expires:
140
131
  - Thu, 01 Jan 1970 00:00:00 GMT
132
+ Pragma:
133
+ - no-cache
134
+ Date:
135
+ - Fri, 23 May 2014 15:05:36 GMT
136
+ Set-Cookie:
137
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
138
+ - TCSESSIONID=93FF6AD40C51991CD3D1ABFBCF28A14D; Path=/; HttpOnly
141
139
  Transfer-Encoding:
142
140
  - chunked
141
+ Server:
142
+ - Apache-Coyote/1.1
143
143
  Cache-Control:
144
144
  - no-cache
145
145
  - no-store
146
146
  body:
147
147
  string: "{\"count\":1,\"vcs-root\":[{\"id\":\"Root_SampleVcsRoot\",\"name\":\"Sample VCS Root\",\"href\":\"/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot\"}]}"
148
148
  http_version:
149
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
149
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
150
150
  - request:
151
151
  method: delete
152
152
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/vcs-roots/id:Root_SampleVcsRoot
153
153
  body:
154
154
  string: ""
155
155
  headers:
156
- Accept:
157
- - application/json
158
156
  Content-Type:
159
157
  - application/json
158
+ Accept:
159
+ - application/json
160
160
  response:
161
161
  status:
162
162
  code: 204
163
163
  message: No Content
164
164
  headers:
165
- Set-Cookie:
166
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
167
- - TCSESSIONID=B1D9A292576EC4F0BE7EDB4558FD387C; Path=/; HttpOnly
165
+ Expires:
166
+ - Thu, 01 Jan 1970 00:00:00 GMT
168
167
  Pragma:
169
168
  - no-cache
169
+ Date:
170
+ - Fri, 23 May 2014 15:05:36 GMT
171
+ Set-Cookie:
172
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
173
+ - TCSESSIONID=107F1C9D061C183A22D97784494B2D2A; Path=/; HttpOnly
170
174
  Server:
171
175
  - Apache-Coyote/1.1
172
- Date:
173
- - Fri, 23 May 2014 07:28:36 GMT
174
- Expires:
175
- - Thu, 01 Jan 1970 00:00:00 GMT
176
176
  Cache-Control:
177
177
  - no-cache
178
178
  - no-store
179
179
  body:
180
180
  string: ""
181
181
  http_version:
182
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
182
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
183
183
  - request:
184
184
  method: post
185
185
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects
186
186
  body:
187
187
  string: "{\"name\":\"Sample Project\"}"
188
188
  headers:
189
- Accept:
190
- - application/json
191
189
  Content-Type:
192
190
  - application/json
191
+ Accept:
192
+ - application/json
193
193
  response:
194
194
  status:
195
195
  code: 200
196
196
  message: OK
197
197
  headers:
198
- Set-Cookie:
199
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
200
- - TCSESSIONID=73E6A92395144703EBD26F84D064D2DE; Path=/; HttpOnly
201
- Pragma:
202
- - no-cache
203
198
  Content-Type:
204
199
  - application/json
205
- Server:
206
- - Apache-Coyote/1.1
207
- Date:
208
- - Fri, 23 May 2014 07:28:36 GMT
209
200
  Expires:
210
201
  - Thu, 01 Jan 1970 00:00:00 GMT
202
+ Pragma:
203
+ - no-cache
204
+ Date:
205
+ - Fri, 23 May 2014 15:05:36 GMT
206
+ Set-Cookie:
207
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
208
+ - TCSESSIONID=18858DCB45B310867F0C4007CB887F7A; Path=/; HttpOnly
211
209
  Transfer-Encoding:
212
210
  - chunked
211
+ Server:
212
+ - Apache-Coyote/1.1
213
213
  Cache-Control:
214
214
  - no-cache
215
215
  - no-store
216
216
  body:
217
217
  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\"}"
218
218
  http_version:
219
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
219
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
220
220
  - request:
221
221
  method: post
222
222
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/projects/id:SampleProject/buildTypes
223
223
  body:
224
224
  string: "{\"name\":\"Sample Build Configuration\"}"
225
225
  headers:
226
- Accept:
227
- - application/json
228
226
  Content-Type:
229
227
  - application/json
228
+ Accept:
229
+ - application/json
230
230
  response:
231
231
  status:
232
232
  code: 200
233
233
  message: OK
234
234
  headers:
235
- Set-Cookie:
236
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
237
- - TCSESSIONID=E5E1429674C7485F4D0E858538F5FC9A; Path=/; HttpOnly
238
- Pragma:
239
- - no-cache
240
235
  Content-Type:
241
236
  - application/json
242
- Server:
243
- - Apache-Coyote/1.1
244
- Date:
245
- - Fri, 23 May 2014 07:28:36 GMT
246
237
  Expires:
247
238
  - Thu, 01 Jan 1970 00:00:00 GMT
239
+ Pragma:
240
+ - no-cache
241
+ Date:
242
+ - Fri, 23 May 2014 15:05:36 GMT
243
+ Set-Cookie:
244
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
245
+ - TCSESSIONID=91BC4E5271DC796D21740B1E649D6B6C; Path=/; HttpOnly
248
246
  Transfer-Encoding:
249
247
  - chunked
248
+ Server:
249
+ - Apache-Coyote/1.1
250
250
  Cache-Control:
251
251
  - no-cache
252
252
  - no-store
253
253
  body:
254
254
  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\":[]}}"
255
255
  http_version:
256
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
256
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
257
257
  - request:
258
258
  method: post
259
259
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration/steps
260
260
  body:
261
- string: "{\"type\":\"Maven\",\"name\":\"Sample Step\",\"properties\":{\"property\":[{\"value\":\"verify\",\"name\":\"goals\"}]}}"
261
+ string: "{\"name\":\"Sample Step\",\"properties\":{\"property\":[{\"value\":\"verify\",\"name\":\"goals\"}]},\"type\":\"Maven\"}"
262
262
  headers:
263
- Accept:
264
- - application/json
265
263
  Content-Type:
266
264
  - application/json
265
+ Accept:
266
+ - application/json
267
267
  response:
268
268
  status:
269
269
  code: 200
270
270
  message: OK
271
271
  headers:
272
- Set-Cookie:
273
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
274
- - TCSESSIONID=D911D1606BF27ECF012623092D58A8A9; Path=/; HttpOnly
275
- Pragma:
276
- - no-cache
277
272
  Content-Type:
278
273
  - application/json
279
- Server:
280
- - Apache-Coyote/1.1
281
- Date:
282
- - Fri, 23 May 2014 07:28:36 GMT
283
274
  Expires:
284
275
  - Thu, 01 Jan 1970 00:00:00 GMT
276
+ Pragma:
277
+ - no-cache
278
+ Date:
279
+ - Fri, 23 May 2014 15:05:36 GMT
280
+ Set-Cookie:
281
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
282
+ - TCSESSIONID=1A6B013F78E77A2FE6952FAE4661A64B; Path=/; HttpOnly
285
283
  Transfer-Encoding:
286
284
  - chunked
285
+ Server:
286
+ - Apache-Coyote/1.1
287
287
  Cache-Control:
288
288
  - no-cache
289
289
  - no-store
290
290
  body:
291
- string: "{\"id\":\"RUNNER_49\",\"name\":\"Sample Step\",\"type\":\"Maven\",\"properties\":{\"property\":[{\"name\":\"goals\",\"value\":\"verify\"}]}}"
291
+ string: "{\"id\":\"RUNNER_52\",\"name\":\"Sample Step\",\"type\":\"Maven\",\"properties\":{\"property\":[{\"name\":\"goals\",\"value\":\"verify\"}]}}"
292
292
  http_version:
293
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
293
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
294
294
  - request:
295
295
  method: get
296
296
  uri: http://teamcity:teamcity@localhost:8111/httpAuth/app/rest/buildTypes/id:SampleProject_SampleBuildConfiguration/steps
297
297
  body:
298
298
  string: ""
299
299
  headers:
300
- Accept:
301
- - application/json
302
300
  Content-Type:
303
301
  - application/json
302
+ Accept:
303
+ - application/json
304
304
  response:
305
305
  status:
306
306
  code: 200
307
307
  message: OK
308
308
  headers:
309
- Set-Cookie:
310
- - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
311
- - TCSESSIONID=B82FE7F7075485AE5EEA8AE5D3F6D6E0; Path=/; HttpOnly
312
- Pragma:
313
- - no-cache
314
309
  Content-Type:
315
310
  - application/json
316
- Server:
317
- - Apache-Coyote/1.1
318
- Date:
319
- - Fri, 23 May 2014 07:28:36 GMT
320
311
  Expires:
321
312
  - Thu, 01 Jan 1970 00:00:00 GMT
313
+ Pragma:
314
+ - no-cache
315
+ Date:
316
+ - Fri, 23 May 2014 15:05:36 GMT
317
+ Set-Cookie:
318
+ - RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
319
+ - TCSESSIONID=6DF21B2A80025F0960D54F5B70D28544; Path=/; HttpOnly
322
320
  Transfer-Encoding:
323
321
  - chunked
322
+ Server:
323
+ - Apache-Coyote/1.1
324
324
  Cache-Control:
325
325
  - no-cache
326
326
  - no-store
327
327
  body:
328
- string: "{\"step\":[{\"id\":\"RUNNER_49\",\"name\":\"Sample Step\",\"type\":\"Maven\",\"properties\":{\"property\":[{\"name\":\"goals\",\"value\":\"verify\"}]}}]}"
328
+ string: "{\"step\":[{\"id\":\"RUNNER_52\",\"name\":\"Sample Step\",\"type\":\"Maven\",\"properties\":{\"property\":[{\"name\":\"goals\",\"value\":\"verify\"}]}}]}"
329
329
  http_version:
330
- recorded_at: Fri, 23 May 2014 07:28:37 GMT
330
+ recorded_at: Fri, 23 May 2014 15:05:37 GMT
331
331
  recorded_with: VCR 2.4.0