ci-queue 0.13.2 → 0.13.3

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: bd4b0acc1207d9dce9e921e59a3a268fb0685e61705bddcc9a3ae2c80fed8b8c
4
- data.tar.gz: 18fdda51bbb0395ddd202190c5018c1efdefd40aaf9b44184800e75c2e093d57
3
+ metadata.gz: 382aec3675b3ce7db16188d59a277916634e3c84779faedd79c1a3c89ef89d17
4
+ data.tar.gz: a62b3004eec89334191a8c1086bb95cab2b6c6abfc5305a18ac44cbb6b7f34d9
5
5
  SHA512:
6
- metadata.gz: 2de2fee376ba08c94d600806ed6a118434b630f456b9ee3bca9872abc4dbbb070d04ba10a95f8fe414d92ab2668084653a2c5346215aa3e4cdd6385edb59e9e3
7
- data.tar.gz: 844bd71433b29754e01e8e9740ab9b676e51f2b1358adadafd1e59fc28fbb61c61c70b41e4770e0ae7fa2fe625171b64a5aab982fedd9a2dbd7700d1c6400862
6
+ metadata.gz: d53bdaf3c81a5046b5cf583206d189433a8f4977c60f67cdf0bbdfeb0d95f39b1ac37629ce15c6c603d07f108288bf63fa5c5280301ce307584fc2ba09eee494
7
+ data.tar.gz: e881fd1040688d7bfcfe88ffbfb63f87af067347d61da653a7caa8e6dcbead2660751264bb1be7dc5687d964d926a2c6dace6422026d3060f997de8850618313
@@ -1,6 +1,6 @@
1
1
  module CI
2
2
  module Queue
3
- VERSION = '0.13.2'
3
+ VERSION = '0.13.3'
4
4
  DEV_SCRIPTS_ROOT = ::File.expand_path('../../../../../redis', __FILE__)
5
5
  RELEASE_SCRIPTS_ROOT = ::File.expand_path('../redis', __FILE__)
6
6
  end
data/lib/rspec/queue.rb CHANGED
@@ -18,6 +18,10 @@ module RSpec
18
18
  configuration.queue_url || ENV['CI_QUEUE_URL']
19
19
  end
20
20
 
21
+ def retrying
22
+ configuration.retrying
23
+ end
24
+
21
25
  def invalid_usage!(message)
22
26
  reopen_previous_step
23
27
  puts red(message)
@@ -48,10 +52,11 @@ module RSpec
48
52
  end
49
53
 
50
54
  Core::Configuration.add_setting(:queue_url)
55
+ Core::Configuration.add_setting(:retrying)
51
56
  Core::Configuration.prepend(ConfigurationExtension)
52
57
 
53
58
  module ConfigurationOptionsExtension
54
- attr_accessor :queue_url
59
+ attr_accessor :queue_url, :retrying
55
60
  end
56
61
  Core::ConfigurationOptions.prepend(ConfigurationOptionsExtension)
57
62
 
@@ -73,11 +78,21 @@ module RSpec
73
78
  options[:queue_url] = url
74
79
  end
75
80
 
81
+ help = split_heredoc(<<-EOS)
82
+ Wait for all workers to complete and summarize the test failures.
83
+ EOS
76
84
  parser.on('--report', *help) do |url|
77
85
  options[:report] = true
78
86
  options[:runner] = RSpec::Queue::ReportRunner.new
79
87
  end
80
88
 
89
+ help = split_heredoc(<<-EOS)
90
+ Replays a previous run in the same order.
91
+ EOS
92
+ parser.on('--retry', *help) do |url|
93
+ options[:retrying] = true
94
+ end
95
+
81
96
  help = split_heredoc(<<-EOS)
82
97
  Unique identifier for the workload. All workers working on the same suite of tests must have the same build identifier.
83
98
  If the build is tried again, or another revision is built, this value must be different.
@@ -359,6 +374,7 @@ module RSpec
359
374
  end
360
375
 
361
376
  queue = CI::Queue.from_uri(queue_url, RSpec::Queue.config)
377
+ queue = queue.retry_queue if retrying
362
378
  BuildStatusRecorder.build = queue.build
363
379
  queue.populate(examples, random: ordering_seed, &:id)
364
380
  examples_count = examples.size # TODO: figure out which stub value would be best
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ci-queue
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.2
4
+ version: 0.13.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jean Boussier
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-05-29 00:00:00.000000000 Z
11
+ date: 2018-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ansi