hive-messages 1.0.5 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8f62d17bd371bd60c4627507bf6322a88ea8908c
4
- data.tar.gz: 3f313c6fa3f508a599fc7df83771b5f5c49e4301
3
+ metadata.gz: 49f2f3e6d56e4a3a64d6076a12d8c6cb919f957f
4
+ data.tar.gz: 3a822853076057e155bb5ae22e87bc2eb791e34c
5
5
  SHA512:
6
- metadata.gz: e7615aa966fadd8cb5cb35437eaee8afd598bc5ff153fa9e731b26f77823a77519ee0bfe06d7ba00e53f1fafefdd133ef314731728c4f28d2f079d3da89fa38c
7
- data.tar.gz: 3baa638a8c6ac953fecfb1c417d616ca674388c264d48499b1f7d8f910b7b0a4212f026e56dc1a5fe54d3ae173efe06b05ccc95f9b6abd6435225a96c3745143
6
+ metadata.gz: 540d225e37d8e2aa524c4e91f09f84ca7192c71e1d5ad1f752db3714165ecc4dc1d529ce7aef629010903bb74666c6ac7e35ede238fd2d45db44d761218f045a
7
+ data.tar.gz: c1f7e28fec9ffd14e15e9c6983f607461356e62bc742ef7d9ac43d7744c8c21cf3190aa4f9474621601808d9e26b7e409673cac55ee51805a10bb2f6ea718147
@@ -0,0 +1,130 @@
1
+ # Change Log
2
+
3
+ ## [v1.0.4](https://github.com/bbc/hive-messages/tree/v1.0.4) (2016-02-09)
4
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/v1.0.3...v1.0.4)
5
+
6
+ **Closed issues:**
7
+
8
+ - Support build downloads [\#29](https://github.com/bbc/hive-messages/issues/29)
9
+
10
+ **Merged pull requests:**
11
+
12
+ - Add test\_results to the job message [\#31](https://github.com/bbc/hive-messages/pull/31) ([jrmhaig](https://github.com/jrmhaig))
13
+
14
+ ## [v1.0.3](https://github.com/bbc/hive-messages/tree/v1.0.3) (2015-12-09)
15
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/v1.0.2...v1.0.3)
16
+
17
+ **Merged pull requests:**
18
+
19
+ - Fetch build without curl [\#30](https://github.com/bbc/hive-messages/pull/30) ([Asimk21](https://github.com/Asimk21))
20
+
21
+ ## [v1.0.2](https://github.com/bbc/hive-messages/tree/v1.0.2) (2015-10-21)
22
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/1.0.1...v1.0.2)
23
+
24
+ **Merged pull requests:**
25
+
26
+ - Activesupport version [\#27](https://github.com/bbc/hive-messages/pull/27) ([jrmhaig](https://github.com/jrmhaig))
27
+ - Fix version numbers of dependencies [\#26](https://github.com/bbc/hive-messages/pull/26) ([jrmhaig](https://github.com/jrmhaig))
28
+ - Fix some broken tests [\#25](https://github.com/bbc/hive-messages/pull/25) ([jrmhaig](https://github.com/jrmhaig))
29
+
30
+ ## [1.0.1](https://github.com/bbc/hive-messages/tree/1.0.1) (2015-10-05)
31
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/1.0.0...1.0.1)
32
+
33
+ **Merged pull requests:**
34
+
35
+ - Support more detailed test results [\#23](https://github.com/bbc/hive-messages/pull/23) ([davidbuckhurst](https://github.com/davidbuckhurst))
36
+ - Add dependency for multi\_json [\#22](https://github.com/bbc/hive-messages/pull/22) ([jrmhaig](https://github.com/jrmhaig))
37
+ - Changed the gemspec to require at least version 1.0.0 of Roar [\#21](https://github.com/bbc/hive-messages/pull/21) ([jrmhaig](https://github.com/jrmhaig))
38
+ - Changed the gemspec to require at least version 1.0.0 of Roar [\#20](https://github.com/bbc/hive-messages/pull/20) ([jonpwilson](https://github.com/jonpwilson))
39
+
40
+ ## [1.0.0](https://github.com/bbc/hive-messages/tree/1.0.0) (2015-03-03)
41
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.8...1.0.0)
42
+
43
+ **Merged pull requests:**
44
+
45
+ - Better results [\#19](https://github.com/bbc/hive-messages/pull/19) ([davidbuckhurst](https://github.com/davidbuckhurst))
46
+
47
+ ## [0.2.8](https://github.com/bbc/hive-messages/tree/0.2.8) (2015-01-16)
48
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.7...0.2.8)
49
+
50
+ **Merged pull requests:**
51
+
52
+ - Reduce required field in base message [\#17](https://github.com/bbc/hive-messages/pull/17) ([jrmhaig](https://github.com/jrmhaig))
53
+
54
+ ## [0.2.7](https://github.com/bbc/hive-messages/tree/0.2.7) (2014-10-03)
55
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.6...0.2.7)
56
+
57
+ **Merged pull requests:**
58
+
59
+ - Messages::Job.reserve returns nil when no jobs available for reservation [\#16](https://github.com/bbc/hive-messages/pull/16) ([paulccarey](https://github.com/paulccarey))
60
+
61
+ ## [0.2.6](https://github.com/bbc/hive-messages/tree/0.2.6) (2014-10-01)
62
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.5...0.2.6)
63
+
64
+ **Merged pull requests:**
65
+
66
+ - Use ssl when https upload url [\#15](https://github.com/bbc/hive-messages/pull/15) ([davidbuckhurst](https://github.com/davidbuckhurst))
67
+ - Mimetype default [\#14](https://github.com/bbc/hive-messages/pull/14) ([davidbuckhurst](https://github.com/davidbuckhurst))
68
+ - amend copyright to BBC [\#13](https://github.com/bbc/hive-messages/pull/13) ([paulccarey](https://github.com/paulccarey))
69
+
70
+ ## [0.2.5](https://github.com/bbc/hive-messages/tree/0.2.5) (2014-09-15)
71
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.5b...0.2.5)
72
+
73
+ **Merged pull requests:**
74
+
75
+ - Implements an Artifact Message and Representer [\#12](https://github.com/bbc/hive-messages/pull/12) ([paulccarey](https://github.com/paulccarey))
76
+
77
+ ## [0.2.5b](https://github.com/bbc/hive-messages/tree/0.2.5b) (2014-09-13)
78
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.5a...0.2.5b)
79
+
80
+ ## [0.2.5a](https://github.com/bbc/hive-messages/tree/0.2.5a) (2014-09-13)
81
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.4...0.2.5a)
82
+
83
+ ## [0.2.4](https://github.com/bbc/hive-messages/tree/0.2.4) (2014-09-08)
84
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.3...0.2.4)
85
+
86
+ **Merged pull requests:**
87
+
88
+ - fix type cast of ssl verify mode in configuration object [\#11](https://github.com/bbc/hive-messages/pull/11) ([paulccarey](https://github.com/paulccarey))
89
+
90
+ ## [0.2.3](https://github.com/bbc/hive-messages/tree/0.2.3) (2014-09-04)
91
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.2...0.2.3)
92
+
93
+ **Merged pull requests:**
94
+
95
+ - Feature/233 client certs [\#10](https://github.com/bbc/hive-messages/pull/10) ([paulccarey](https://github.com/paulccarey))
96
+
97
+ ## [0.2.2](https://github.com/bbc/hive-messages/tree/0.2.2) (2014-09-03)
98
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.1...0.2.2)
99
+
100
+ **Merged pull requests:**
101
+
102
+ - Feature/233 rename update counts to update results [\#9](https://github.com/bbc/hive-messages/pull/9) ([paulccarey](https://github.com/paulccarey))
103
+
104
+ ## [0.2.1](https://github.com/bbc/hive-messages/tree/0.2.1) (2014-09-03)
105
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.2.0...0.2.1)
106
+
107
+ **Merged pull requests:**
108
+
109
+ - Feature/233 add job state [\#8](https://github.com/bbc/hive-messages/pull/8) ([paulccarey](https://github.com/paulccarey))
110
+
111
+ ## [0.2.0](https://github.com/bbc/hive-messages/tree/0.2.0) (2014-09-02)
112
+ [Full Changelog](https://github.com/bbc/hive-messages/compare/0.1.1...0.2.0)
113
+
114
+ **Merged pull requests:**
115
+
116
+ - Feature/233 report job artifacts [\#7](https://github.com/bbc/hive-messages/pull/7) ([paulccarey](https://github.com/paulccarey))
117
+ - Feature/233 update roar and version [\#6](https://github.com/bbc/hive-messages/pull/6) ([paulccarey](https://github.com/paulccarey))
118
+ - Feature/233 job errored end point [\#5](https://github.com/bbc/hive-messages/pull/5) ([paulccarey](https://github.com/paulccarey))
119
+
120
+ ## [0.1.1](https://github.com/bbc/hive-messages/tree/0.1.1) (2014-09-02)
121
+ **Merged pull requests:**
122
+
123
+ - Feature/233 update end point [\#4](https://github.com/bbc/hive-messages/pull/4) ([paulccarey](https://github.com/paulccarey))
124
+ - Feature/end job end point [\#3](https://github.com/bbc/hive-messages/pull/3) ([paulccarey](https://github.com/paulccarey))
125
+ - Fix AcitveSupport require for older versions [\#2](https://github.com/bbc/hive-messages/pull/2) ([paulccarey](https://github.com/paulccarey))
126
+ - Feature/233 reserve and start calls [\#1](https://github.com/bbc/hive-messages/pull/1) ([paulccarey](https://github.com/paulccarey))
127
+
128
+
129
+
130
+ \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = "hive-messages"
7
- spec.version = '1.0.5'
7
+ spec.version = '1.0.6'
8
8
  spec.authors = ["David Buckhurst", "Paul Carey"]
9
9
  spec.email = ["david.buckhurst@bbc.co.uk"]
10
10
  spec.summary = %q{Hive communication library.}
@@ -8,6 +8,7 @@ module Hive
8
8
  attribute :command, String
9
9
  attribute :job_id, Integer
10
10
  attribute :repository, String
11
+ attribute :branch, String
11
12
  attribute :execution_directory, String
12
13
  attribute :target, Hash
13
14
  attribute :execution_variables, ExecutionVariables
@@ -6,6 +6,7 @@ module Hive
6
6
  property :command
7
7
  property :job_id
8
8
  property :repository
9
+ property :branch
9
10
  property :execution_directory
10
11
  property :target
11
12
  property :execution_variables
@@ -107,25 +107,39 @@ describe Hive::Messages::Job, type: :model do
107
107
  Hive::Messages.configure { |config| config.base_path = base_path }
108
108
  end
109
109
 
110
- describe "#start" do
110
+ describe "#prepare" do
111
111
  let(:device_id) { 33 }
112
112
 
113
113
  let!(:stubbed_request) do
114
- stub_request(:patch, Hive::Paths::Jobs.start_url(job_id))
114
+ stub_request(:patch, Hive::Paths::Jobs.prepare_url(job_id))
115
115
  .with( body: {job_id: job_id, device_id: device_id}.to_json, headers: { "Content-Type" => "application/json" } )
116
116
  .to_return( body: remote_job.to_json )
117
117
  end
118
118
 
119
119
  before(:each) do
120
- pending "Behaviour of start has changed"
121
- local_job.start(device_id)
120
+ local_job.prepare(device_id)
122
121
  end
123
122
 
124
- it "made the request to start the job" do
123
+ it "made the request to prepare the job" do
125
124
  expect(stubbed_request).to have_been_requested
126
125
  end
127
126
  end
128
127
 
128
+ describe "#start" do
129
+ let!(:stubbed_request) do
130
+ stub_request(:patch, Hive::Paths::Jobs.start_url(job_id))
131
+ .with( body: {job_id: job_id}.to_json, headers: { "Content-Type" => "application/json" } )
132
+ .to_return( body: remote_job.to_json )
133
+ end
134
+
135
+ before(:each) do
136
+ local_job.start
137
+ end
138
+
139
+ it "made the request to start the job" do
140
+ expect(stubbed_request).to have_been_requested
141
+ end
142
+ end
129
143
 
130
144
  describe "#update_results" do
131
145
 
@@ -198,16 +212,32 @@ describe Hive::Messages::Job, type: :model do
198
212
 
199
213
  let!(:stubbed_request) do
200
214
  stub_request(:patch, Hive::Paths::Jobs.end_url(job_id))
215
+ .with( body: {job_id: job_id, exit_value: 0}.to_json, headers: { "Content-Type" => "application/json" } )
216
+ .to_return( body: remote_job.to_json )
217
+ end
218
+
219
+ before(:each) do
220
+ Hive::Messages::Job.new(job_id: job_id).end 0
221
+ end
222
+
223
+ it "made the request to end the job" do
224
+ expect(stubbed_request).to have_been_requested
225
+ end
226
+ end
227
+
228
+ describe "#complete" do
229
+
230
+ let!(:stubbed_request) do
231
+ stub_request(:patch, Hive::Paths::Jobs.complete_url(job_id))
201
232
  .with( body: {job_id: job_id}.to_json, headers: { "Content-Type" => "application/json" } )
202
233
  .to_return( body: remote_job.to_json )
203
234
  end
204
235
 
205
236
  before(:each) do
206
- pending "Behaviour of new has changed"
207
- Hive::Messages::Job.new(job_id: job_id).end
237
+ Hive::Messages::Job.new(job_id: job_id).complete
208
238
  end
209
239
 
210
- it "made the request to start the job" do
240
+ it "made the request to complete the job" do
211
241
  expect(stubbed_request).to have_been_requested
212
242
  end
213
243
  end
@@ -216,13 +246,12 @@ describe Hive::Messages::Job, type: :model do
216
246
 
217
247
  let!(:stubbed_request) do
218
248
  stub_request(:patch, Hive::Paths::Jobs.error_url(job_id))
219
- .with( body: {job_id: job_id}.to_json, headers: { "Content-Type" => "application/json" } )
249
+ .with( body: {job_id: job_id, message: 'Test error message'}.to_json, headers: { "Content-Type" => "application/json" } )
220
250
  .to_return( body: remote_job.to_json )
221
251
  end
222
252
 
223
253
  before(:each) do
224
- pending "Behaviour of new has changed"
225
- Hive::Messages::Job.new(job_id: job_id).error
254
+ Hive::Messages::Job.new(job_id: job_id).error 'Test error message'
226
255
  end
227
256
 
228
257
  it "made the request to start the job" do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hive-messages
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Buckhurst
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-09-26 00:00:00.000000000 Z
12
+ date: 2016-11-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: virtus
@@ -199,6 +199,7 @@ extensions: []
199
199
  extra_rdoc_files: []
200
200
  files:
201
201
  - ".gitignore"
202
+ - CHANGELOG.md
202
203
  - Gemfile
203
204
  - LICENSE.txt
204
205
  - README.md
@@ -255,7 +256,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
255
256
  version: '0'
256
257
  requirements: []
257
258
  rubyforge_project:
258
- rubygems_version: 2.5.0
259
+ rubygems_version: 2.5.1
259
260
  signing_key:
260
261
  specification_version: 4
261
262
  summary: Hive communication library.