teamcity-ruby-client 0.3.0 → 0.4.0
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.
- checksums.yaml +8 -8
- data/CHANGELOG.md +13 -1
- data/README.md +2 -1
- data/lib/teamcity/client/build_types.rb +9 -0
- data/lib/teamcity/client/builds.rb +42 -0
- data/lib/teamcity/version.rb +1 -1
- data/spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_get_investigation_details.yml +48 -0
- data/spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_return_nil_if_no_one_is_investigating.yml +44 -0
- data/spec/cassettes/Builds/DELETE/_unpin_build/should_unpin_a_build.yml +38 -0
- data/spec/cassettes/Builds/GET/_build_statistics/should_return_an_empty_string_for_a_build_with_no_statistics.yml +44 -0
- data/spec/cassettes/Builds/GET/_build_statistics/should_return_statistics_for_a_build.yml +44 -0
- data/spec/cassettes/Builds/PUT/_pin_build/should_pin_a_build.yml +40 -0
- data/spec/teamcity/client/builds_spec.rb +63 -0
- data/spec/teamcity/client/buildtypes_spec.rb +14 -0
- metadata +14 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
NzU1YTc3MWEyYzhmZTVjMDRiMGI4MTBlMzg5NmNiODEwM2NmOWY5ZA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YWE3NzczNzUxMmI5ZjJiODRiYjg5M2RjNzNkOTdjYzIzNzc5NzMyNQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
OThjYzE5Y2RmYzk2OWFiYjJhZmMzMGU5Zjk2NWQ1MGM2Zjg4ZjU1NTc2M2Ni
|
10
|
+
ZDM0NzVjMDI2OWZjYWEwZjVmMDZkYTg2NmY0MjJkNGIyYmUyZmJiYTU3ODY4
|
11
|
+
OTkwNDk5MzlmYzZiMzY0OWZhNzc5MjRjNWQ2MTk1Y2YyMjEzMGE=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NjJlZWZhNzkwZjk2YjZmNDUxNmEzZTQ3OWFlNjU1YjM0ZjY2MzgyYTM0NDQ5
|
14
|
+
MTA0YmQyMDY3ZjcxODQxOTVkMzE0NDI0ODM5ZTg4YTU5ZmRkMDZiZTE0M2Iw
|
15
|
+
N2UyNTkzZmQ2YTk4YzE5YWM5NTZkYTViZjliNzEyNGYxMWJhMzc=
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,15 @@
|
|
1
|
+
## 0.4.0 (Jun 15, 2013)
|
2
|
+
|
3
|
+
* Added ```pin_build``` and ```unpin_build``` (Provides the ability to pin and unbuild a build respectively)
|
4
|
+
* Added ```build_statistics``` (Provides the ability to fetch build [statistics](http://confluence.jetbrains.com/display/TCD8/Custom+Chart#CustomChart-listOfDefaultStatisticValues))
|
5
|
+
* Added ```buildtype_investigations``` (Provides the ability to fetch build investigation details)
|
6
|
+
|
7
|
+
## 0.3.0 (May 23, 2013)
|
8
|
+
|
9
|
+
* Loosen up dependency requirement on the version of builder (Conflicted with transitive dependencies of rails 3.2.13)
|
10
|
+
* Added ```delete_buildtype``` to the API (Provides the ability to delete a build configuration)
|
11
|
+
* Added ```set_build_step_field``` to the API (Provides the ability to set a build step field, i.e. enable/disable a build step)
|
12
|
+
|
1
13
|
## 0.2.0 (May 7, 2013)
|
2
14
|
|
3
15
|
- added support for httpAuth
|
@@ -10,4 +22,4 @@ Features:
|
|
10
22
|
|
11
23
|
- added GET support for projects
|
12
24
|
- added GET support for build types (build configurations)
|
13
|
-
- added GET support for builds
|
25
|
+
- added GET support for builds
|
data/README.md
CHANGED
@@ -1,4 +1,5 @@
|
|
1
|
-
# The TeamCity Ruby Gem
|
1
|
+
# The TeamCity Ruby Gem
|
2
|
+
[](http://travis-ci.org/jperry/teamcity-ruby-client) [](https://codeclimate.com/github/jperry/teamcity-ruby-client) [](https://gemnasium.com/jperry/teamcity-ruby-client)
|
2
3
|
|
3
4
|
Ruby wrapper for the TeamCity Rest API
|
4
5
|
|
@@ -52,6 +52,15 @@ module TeamCity
|
|
52
52
|
response['property']
|
53
53
|
end
|
54
54
|
|
55
|
+
# Get investigation info for build configuration
|
56
|
+
#
|
57
|
+
# @param buildtype_id [String] the buildtype id
|
58
|
+
# @return [Array<Hashie::Mash>] of build investigation info
|
59
|
+
def buildtype_investigations(buildtype_id)
|
60
|
+
response = get("buildTypes/#{buildtype_id}/investigations")
|
61
|
+
response['investigation']
|
62
|
+
end
|
63
|
+
|
55
64
|
# Get template associated with build configuration
|
56
65
|
#
|
57
66
|
# @param (see #buildtype)
|
@@ -24,13 +24,55 @@ module TeamCity
|
|
24
24
|
get("builds/#{locator(options)}")
|
25
25
|
end
|
26
26
|
|
27
|
+
# Get the build tags
|
28
|
+
#
|
29
|
+
# @param options [Hash] option keys, :id => build_id
|
30
|
+
# @return [Array<Hashie::Mash>, nil] nil if build has not tags
|
27
31
|
def build_tags(options={})
|
28
32
|
assert_options(options)
|
29
33
|
response = get("builds/#{locator(options)}/tags")
|
30
34
|
response['tag']
|
31
35
|
end
|
32
36
|
|
37
|
+
# Get build statistics
|
38
|
+
#
|
39
|
+
# @param build_id [String]
|
40
|
+
# @return [Array<Hashie::Mash>, nil] returns nil if there are no statistics
|
41
|
+
def build_statistics(build_id)
|
42
|
+
response = get("builds/#{build_id}/statistics")
|
43
|
+
response['property']
|
44
|
+
end
|
45
|
+
|
46
|
+
# TODO: Will need to create a Faraday middleware for this
|
47
|
+
# since the response returns a string not a json object
|
48
|
+
#def build_pinned?(id)
|
49
|
+
# path = "builds/#{id}/pin"
|
50
|
+
# get(path) do |req|
|
51
|
+
# req.headers['Accept'] = 'text/plain'
|
52
|
+
# end
|
53
|
+
#end
|
54
|
+
|
55
|
+
# HTTP PUT
|
56
|
+
|
57
|
+
# Pin a build
|
58
|
+
#
|
59
|
+
# @param id [String] build to pin
|
60
|
+
# @param comment [String] provide a comment to the pin
|
61
|
+
# @return [nil]
|
62
|
+
def pin_build(id, comment='')
|
63
|
+
path = "builds/#{id}/pin"
|
64
|
+
put_text_request(path, comment)
|
65
|
+
end
|
66
|
+
|
67
|
+
# HTTP DELETE
|
33
68
|
|
69
|
+
# Unpin a build
|
70
|
+
#
|
71
|
+
# @param id [String] build to unpin
|
72
|
+
# @return [nil]
|
73
|
+
def unpin_build(id)
|
74
|
+
delete("builds/#{id}/pin")
|
75
|
+
end
|
34
76
|
end
|
35
77
|
end
|
36
78
|
end
|
data/lib/teamcity/version.rb
CHANGED
data/spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_get_investigation_details.yml
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/buildTypes/bt9/investigations
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.4.0
|
14
|
+
Accept-Encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: OK
|
20
|
+
headers:
|
21
|
+
Server:
|
22
|
+
- Apache-Coyote/1.1
|
23
|
+
Set-Cookie:
|
24
|
+
- JSESSIONID=C0D703BE6F2B721CAEC44900B99042EC; Path=/; HttpOnly
|
25
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
26
|
+
Pragma:
|
27
|
+
- no-cache
|
28
|
+
Expires:
|
29
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
+
Cache-Control:
|
31
|
+
- no-cache
|
32
|
+
- no-store
|
33
|
+
Content-Type:
|
34
|
+
- application/json
|
35
|
+
Transfer-Encoding:
|
36
|
+
- chunked
|
37
|
+
Date:
|
38
|
+
- Mon, 15 Jul 2013 15:30:24 GMT
|
39
|
+
body:
|
40
|
+
encoding: US-ASCII
|
41
|
+
string: ! '{"investigation":[{"id":"bt9","state":"TAKEN","responsible":{"href":"/httpAuth/app/rest/7.0/users/id:1","id":1,"name":"Jay
|
42
|
+
Perry","username":"jperry"},"assignment":{"user":{"href":"/httpAuth/app/rest/7.0/users/id:1","id":1,"name":"Jay
|
43
|
+
Perry","username":"jperry"},"timestamp":"20130715T112831-0400","text":""},"scope":{"buildType":{"id":"bt9","name":"investigation
|
44
|
+
test","href":"/httpAuth/app/rest/7.0/buildTypes/id:bt9","projectName":"Project
|
45
|
+
C","projectId":"project4","webUrl":"http://localhost:8111/viewType.html?buildTypeId=bt9"}}}]}'
|
46
|
+
http_version:
|
47
|
+
recorded_at: Mon, 15 Jul 2013 15:30:24 GMT
|
48
|
+
recorded_with: VCR 2.4.0
|
@@ -0,0 +1,44 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/buildTypes/bt9/investigations
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.4.0
|
14
|
+
Accept-Encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: OK
|
20
|
+
headers:
|
21
|
+
Server:
|
22
|
+
- Apache-Coyote/1.1
|
23
|
+
Set-Cookie:
|
24
|
+
- JSESSIONID=368C88AD5958AA847BFFE03DBC24887F; Path=/; HttpOnly
|
25
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
26
|
+
Pragma:
|
27
|
+
- no-cache
|
28
|
+
Expires:
|
29
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
+
Cache-Control:
|
31
|
+
- no-cache
|
32
|
+
- no-store
|
33
|
+
Content-Type:
|
34
|
+
- application/json
|
35
|
+
Transfer-Encoding:
|
36
|
+
- chunked
|
37
|
+
Date:
|
38
|
+
- Mon, 15 Jul 2013 15:27:10 GMT
|
39
|
+
body:
|
40
|
+
encoding: US-ASCII
|
41
|
+
string: 'null'
|
42
|
+
http_version:
|
43
|
+
recorded_at: Mon, 15 Jul 2013 15:27:10 GMT
|
44
|
+
recorded_with: VCR 2.4.0
|
@@ -0,0 +1,38 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: delete
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/builds/27/pin
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.3.0
|
14
|
+
response:
|
15
|
+
status:
|
16
|
+
code: 204
|
17
|
+
message: No Content
|
18
|
+
headers:
|
19
|
+
Server:
|
20
|
+
- Apache-Coyote/1.1
|
21
|
+
Set-Cookie:
|
22
|
+
- JSESSIONID=ECEF901E911DFA5B320740401E61BB02; Path=/; HttpOnly
|
23
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
24
|
+
Pragma:
|
25
|
+
- no-cache
|
26
|
+
Expires:
|
27
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
28
|
+
Cache-Control:
|
29
|
+
- no-cache
|
30
|
+
- no-store
|
31
|
+
Date:
|
32
|
+
- Mon, 01 Jul 2013 15:30:11 GMT
|
33
|
+
body:
|
34
|
+
encoding: US-ASCII
|
35
|
+
string: ''
|
36
|
+
http_version:
|
37
|
+
recorded_at: Mon, 01 Jul 2013 15:30:12 GMT
|
38
|
+
recorded_with: VCR 2.4.0
|
@@ -0,0 +1,44 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/builds/28/statistics
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.4.0
|
14
|
+
Accept-Encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: OK
|
20
|
+
headers:
|
21
|
+
Server:
|
22
|
+
- Apache-Coyote/1.1
|
23
|
+
Set-Cookie:
|
24
|
+
- JSESSIONID=2F14B66EA7269D04A62E630448B297D9; Path=/; HttpOnly
|
25
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
26
|
+
Pragma:
|
27
|
+
- no-cache
|
28
|
+
Expires:
|
29
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
+
Cache-Control:
|
31
|
+
- no-cache
|
32
|
+
- no-store
|
33
|
+
Content-Type:
|
34
|
+
- application/json
|
35
|
+
Transfer-Encoding:
|
36
|
+
- chunked
|
37
|
+
Date:
|
38
|
+
- Mon, 15 Jul 2013 15:44:26 GMT
|
39
|
+
body:
|
40
|
+
encoding: US-ASCII
|
41
|
+
string: 'null'
|
42
|
+
http_version:
|
43
|
+
recorded_at: Mon, 15 Jul 2013 15:44:27 GMT
|
44
|
+
recorded_with: VCR 2.4.0
|
@@ -0,0 +1,44 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/builds/30/statistics
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.4.0
|
14
|
+
Accept-Encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: OK
|
20
|
+
headers:
|
21
|
+
Server:
|
22
|
+
- Apache-Coyote/1.1
|
23
|
+
Set-Cookie:
|
24
|
+
- JSESSIONID=D061BE729428A47FE5021979536DE57F; Path=/; HttpOnly
|
25
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
26
|
+
Pragma:
|
27
|
+
- no-cache
|
28
|
+
Expires:
|
29
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
+
Cache-Control:
|
31
|
+
- no-cache
|
32
|
+
- no-store
|
33
|
+
Content-Type:
|
34
|
+
- application/json
|
35
|
+
Transfer-Encoding:
|
36
|
+
- chunked
|
37
|
+
Date:
|
38
|
+
- Mon, 15 Jul 2013 15:44:26 GMT
|
39
|
+
body:
|
40
|
+
encoding: US-ASCII
|
41
|
+
string: ! '{"property":[{"name":"ArtifactsSize","value":"4411"},{"name":"BuildDuration","value":"6639"},{"name":"BuildDurationNetTime","value":"6639"},{"name":"SuccessRate","value":"0"},{"name":"TimeSpentInQueue","value":"37"}]}'
|
42
|
+
http_version:
|
43
|
+
recorded_at: Mon, 15 Jul 2013 15:44:27 GMT
|
44
|
+
recorded_with: VCR 2.4.0
|
@@ -0,0 +1,40 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: put
|
5
|
+
uri: http://teamcity-ruby-client:teamcity@localhost:8111/httpAuth/app/rest/7.0/builds/27/pin
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: this will add a comment
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json; charset=utf-8
|
12
|
+
User-Agent:
|
13
|
+
- TeamCity Ruby Client 0.3.0
|
14
|
+
Content-Type:
|
15
|
+
- text/plain
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 204
|
19
|
+
message: No Content
|
20
|
+
headers:
|
21
|
+
Server:
|
22
|
+
- Apache-Coyote/1.1
|
23
|
+
Set-Cookie:
|
24
|
+
- JSESSIONID=5B042EB6A7307BE68D8A28A860107A95; Path=/; HttpOnly
|
25
|
+
- RememberMe=""; Expires=Thu, 01-Jan-1970 00:00:10 GMT; Path=/; HttpOnly
|
26
|
+
Pragma:
|
27
|
+
- no-cache
|
28
|
+
Expires:
|
29
|
+
- Thu, 01 Jan 1970 00:00:00 GMT
|
30
|
+
Cache-Control:
|
31
|
+
- no-cache
|
32
|
+
- no-store
|
33
|
+
Date:
|
34
|
+
- Mon, 01 Jul 2013 15:27:57 GMT
|
35
|
+
body:
|
36
|
+
encoding: US-ASCII
|
37
|
+
string: ''
|
38
|
+
http_version:
|
39
|
+
recorded_at: Mon, 01 Jul 2013 15:27:58 GMT
|
40
|
+
recorded_with: VCR 2.4.0
|
@@ -58,5 +58,68 @@ describe 'Builds' do
|
|
58
58
|
@tc.build_tags(id: 1).should be_nil
|
59
59
|
end
|
60
60
|
end
|
61
|
+
|
62
|
+
describe '.build_pinned?', :vcr do
|
63
|
+
before(:all) do
|
64
|
+
configure_client_with_authentication
|
65
|
+
end
|
66
|
+
|
67
|
+
it 'should return true when a build is pinned' do
|
68
|
+
pending
|
69
|
+
@tc.pin_build('27')
|
70
|
+
@tc.build_pinned?('27').should be_true
|
71
|
+
end
|
72
|
+
|
73
|
+
it 'should return false when a build is not pinned' do
|
74
|
+
pending
|
75
|
+
@tc.unpin_build('27')
|
76
|
+
@tc.build_pinned?('27').should be_false
|
77
|
+
end
|
78
|
+
end
|
79
|
+
|
80
|
+
describe '.build_statistics' do
|
81
|
+
before(:all) do
|
82
|
+
configure_client_with_authentication
|
83
|
+
end
|
84
|
+
|
85
|
+
it 'should return statistics for a build' do
|
86
|
+
result = @tc.build_statistics('30')
|
87
|
+
result.first.name.should_not be_empty
|
88
|
+
result.first.value.should_not be_empty
|
89
|
+
end
|
90
|
+
|
91
|
+
it 'should return an empty string for a build with no statistics' do
|
92
|
+
@tc.build_statistics('28').should be_nil
|
93
|
+
end
|
94
|
+
end
|
95
|
+
end
|
96
|
+
|
97
|
+
describe 'PUT', :vcr do
|
98
|
+
|
99
|
+
before(:all) do
|
100
|
+
configure_client_with_authentication
|
101
|
+
end
|
102
|
+
|
103
|
+
describe '.pin_build' do
|
104
|
+
it 'should pin a build' do
|
105
|
+
id = '27'
|
106
|
+
comment = 'this will add a comment'
|
107
|
+
@tc.pin_build(id, comment).should be_nil
|
108
|
+
end
|
109
|
+
end
|
110
|
+
end
|
111
|
+
|
112
|
+
describe 'DELETE', :vcr do
|
113
|
+
|
114
|
+
before(:all) do
|
115
|
+
configure_client_with_authentication
|
116
|
+
end
|
117
|
+
|
118
|
+
describe '.unpin_build' do
|
119
|
+
it 'should unpin a build' do
|
120
|
+
id = '27'
|
121
|
+
@tc.unpin_build(id).should be_nil
|
122
|
+
end
|
123
|
+
end
|
61
124
|
end
|
62
125
|
end
|
@@ -106,6 +106,20 @@ describe 'BuildTypes' do
|
|
106
106
|
end
|
107
107
|
end
|
108
108
|
end
|
109
|
+
|
110
|
+
describe '.buildtype_investigations' do
|
111
|
+
before(:all) do
|
112
|
+
configure_client_with_authentication
|
113
|
+
end
|
114
|
+
|
115
|
+
it 'should get investigation details' do
|
116
|
+
@tc.buildtype_investigations('bt9').should_not be_nil
|
117
|
+
end
|
118
|
+
|
119
|
+
it 'should return nil if no one is investigating' do
|
120
|
+
@tc.buildtype_investigations('bt9').should be_nil
|
121
|
+
end
|
122
|
+
end
|
109
123
|
end
|
110
124
|
|
111
125
|
describe 'PUT', :vcr do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: teamcity-ruby-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jason Perry
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-07-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -219,6 +219,8 @@ files:
|
|
219
219
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_fetch_the_build_configuration_features_for_a_buildtype.yml
|
220
220
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_return_an_array.yml
|
221
221
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_return_nil_if_there_are_no_features_defined.yml
|
222
|
+
- spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_get_investigation_details.yml
|
223
|
+
- spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_return_nil_if_no_one_is_investigating.yml
|
222
224
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_fetch_the_build_configuration_parameters_for_a_buildtype.yml
|
223
225
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_return_an_array.yml
|
224
226
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_return_nil_if_there_are_no_parameters_defined.yml
|
@@ -248,14 +250,18 @@ files:
|
|
248
250
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_field/should_set_a_projects_description.yml
|
249
251
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_field/should_set_the_buildtype_name.yml
|
250
252
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_parameter/should_set_a_buildtype_parameter.yml
|
253
|
+
- spec/cassettes/Builds/DELETE/_unpin_build/should_unpin_a_build.yml
|
251
254
|
- spec/cassettes/Builds/GET/_build/should_fetch_the_build_details.yml
|
252
255
|
- spec/cassettes/Builds/GET/_build/should_raise_an_error_if_the_build_does_not_exist.yml
|
256
|
+
- spec/cassettes/Builds/GET/_build_statistics/should_return_an_empty_string_for_a_build_with_no_statistics.yml
|
257
|
+
- spec/cassettes/Builds/GET/_build_statistics/should_return_statistics_for_a_build.yml
|
253
258
|
- spec/cassettes/Builds/GET/_build_tags/should_fetch_the_build_tags.yml
|
254
259
|
- spec/cassettes/Builds/GET/_build_tags/should_return_nil_if_there_are_no_build_tags_defined_for_a_build.yml
|
255
260
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_filter_by_multiple_build_locators.yml
|
256
261
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_filter_results_by_build_locators.yml
|
257
262
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_search_by_locator.yml
|
258
263
|
- spec/cassettes/Builds/GET/_builds/should_fetch_all_the_builds.yml
|
264
|
+
- spec/cassettes/Builds/PUT/_pin_build/should_pin_a_build.yml
|
259
265
|
- spec/cassettes/Projects/DELETE/_delete_project/should_delete_a_project.yml
|
260
266
|
- spec/cassettes/Projects/DELETE/_delete_project_parameter/should_delete_a_project_parameter.yml
|
261
267
|
- spec/cassettes/Projects/GET/_project/should_fetch_a_single_project_by_id.yml
|
@@ -328,6 +334,8 @@ test_files:
|
|
328
334
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_fetch_the_build_configuration_features_for_a_buildtype.yml
|
329
335
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_return_an_array.yml
|
330
336
|
- spec/cassettes/BuildTypes/GET/_buildtype_features/should_return_nil_if_there_are_no_features_defined.yml
|
337
|
+
- spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_get_investigation_details.yml
|
338
|
+
- spec/cassettes/BuildTypes/GET/_buildtype_investigations/should_return_nil_if_no_one_is_investigating.yml
|
331
339
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_fetch_the_build_configuration_parameters_for_a_buildtype.yml
|
332
340
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_return_an_array.yml
|
333
341
|
- spec/cassettes/BuildTypes/GET/_buildtype_parameters/should_return_nil_if_there_are_no_parameters_defined.yml
|
@@ -357,14 +365,18 @@ test_files:
|
|
357
365
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_field/should_set_a_projects_description.yml
|
358
366
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_field/should_set_the_buildtype_name.yml
|
359
367
|
- spec/cassettes/BuildTypes/PUT/_set_buildtype_parameter/should_set_a_buildtype_parameter.yml
|
368
|
+
- spec/cassettes/Builds/DELETE/_unpin_build/should_unpin_a_build.yml
|
360
369
|
- spec/cassettes/Builds/GET/_build/should_fetch_the_build_details.yml
|
361
370
|
- spec/cassettes/Builds/GET/_build/should_raise_an_error_if_the_build_does_not_exist.yml
|
371
|
+
- spec/cassettes/Builds/GET/_build_statistics/should_return_an_empty_string_for_a_build_with_no_statistics.yml
|
372
|
+
- spec/cassettes/Builds/GET/_build_statistics/should_return_statistics_for_a_build.yml
|
362
373
|
- spec/cassettes/Builds/GET/_build_tags/should_fetch_the_build_tags.yml
|
363
374
|
- spec/cassettes/Builds/GET/_build_tags/should_return_nil_if_there_are_no_build_tags_defined_for_a_build.yml
|
364
375
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_filter_by_multiple_build_locators.yml
|
365
376
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_filter_results_by_build_locators.yml
|
366
377
|
- spec/cassettes/Builds/GET/_builds/should_allow_you_to_search_by_locator.yml
|
367
378
|
- spec/cassettes/Builds/GET/_builds/should_fetch_all_the_builds.yml
|
379
|
+
- spec/cassettes/Builds/PUT/_pin_build/should_pin_a_build.yml
|
368
380
|
- spec/cassettes/Projects/DELETE/_delete_project/should_delete_a_project.yml
|
369
381
|
- spec/cassettes/Projects/DELETE/_delete_project_parameter/should_delete_a_project_parameter.yml
|
370
382
|
- spec/cassettes/Projects/GET/_project/should_fetch_a_single_project_by_id.yml
|