onc_certification_g10_test_kit 3.7.0 → 3.7.1

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
  SHA256:
3
- metadata.gz: b93ef6f9961fac5bf26fba0ba18e8a67d8f5399e8dbdb7e2fd9fa73099d49592
4
- data.tar.gz: 42c2e1b9ee25f29e36b2b700e7251a5db4b88cf2861dbc7fc82785a418523db6
3
+ metadata.gz: a217709dc49a228fae0a2a23ea7eb38cbf22462dde7e652f49e2f0cac99107a4
4
+ data.tar.gz: ad6a5a07a6090d411314b51e12e553f977512cb58f2a38170d9896df1b1e28b8
5
5
  SHA512:
6
- metadata.gz: 264e96462f811d278b10533198b20abb7c466ca7c3f588fbd94ffb54d375cf66876dae8c71273a03f3e01a286e349695fdae108f8a43bf142c97ed9721eed4e0
7
- data.tar.gz: 8340fafaa42fe18013f1cf568fdd8d78830a90386999a064600f621f70f491df510c2bfa6452741a569282a0bb9475050e8ec76cc4e977ba62458dadda20f47e
6
+ metadata.gz: 29269e887ab0936ee2719095d60bbf860d81a33105562e01f03133769a26a45a0337eff87501bd34637ff693065f0adf7a1f8d605a265c1b3ab3f54cae7685ab
7
+ data.tar.gz: a48a791c47d1ef1051c81e84c193af00c8fa6d791a6cbba6a9ceecc919d02dd4b5b237483ae22a2bc9a050d9fa5018b970ed7f3c54fb075ef0ffe9e02c2be4a5
@@ -200,6 +200,7 @@ module ONCCertificationG10TestKit
200
200
 
201
201
  wait_time = 1
202
202
  start = Time.now
203
+ used_time = 0
203
204
 
204
205
  loop do
205
206
  get(polling_url, headers: { authorization: "Bearer #{bearer_token}", accept: 'application/json' })
@@ -208,14 +209,21 @@ module ONCCertificationG10TestKit
208
209
 
209
210
  wait_time = retry_after_val.positive? ? retry_after_val : wait_time *= 2
210
211
 
211
- seconds_used = Time.now - start + wait_time
212
+ used_time = Time.now - start
212
213
 
213
- break if response[:status] != 202 || seconds_used > timeout
214
+ total_time_to_next_poll = Time.now - start + wait_time
215
+
216
+ break if response[:status] != 202 || total_time_to_next_poll > timeout
214
217
 
215
218
  sleep wait_time
216
219
  end
217
220
 
218
- skip "Server took more than #{timeout} seconds to process the request." if response[:status] == 202
221
+ if response[:status] == 202
222
+ skip "Server already used #{used_time} seconds processing this request, " \
223
+ "and next poll is #{wait_time} seconds after. " \
224
+ "The total wait time for next poll is more than #{timeout} seconds time out setting."
225
+ end
226
+
219
227
  assert_response_status(200)
220
228
 
221
229
  assert request.response_header('content-type')&.value&.include?('application/json'),
@@ -1,3 +1,3 @@
1
1
  module ONCCertificationG10TestKit
2
- VERSION = '3.7.0'.freeze
2
+ VERSION = '3.7.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: onc_certification_g10_test_kit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.7.0
4
+ version: 3.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen MacVicar
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-04-10 00:00:00.000000000 Z
11
+ date: 2023-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bloomer