ci-queue 0.29.0 → 0.31.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/dev.yml +1 -1
- data/lib/ci/queue/version.rb +1 -1
- data/lib/minitest/queue/local_requeue_reporter.rb +1 -1
- data/lib/minitest/queue/runner.rb +36 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fdd7b371fdadda905994e7b736eddac19265db401483fad83612c3bfb5b054bb
|
4
|
+
data.tar.gz: 8e49ed6b35ece9ba9aa7c4876e75512f1bfa05375aa6d976a7813eb5cb304502
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee4e5d450227ff962c4606e759e5d15272f5c808ff690b77dfb7ff403a989c4ffd860af75fb18e15a14354523ae96b66f6b67d5035b14880e3342ee63f254f5b
|
7
|
+
data.tar.gz: ca3c985d44043f4348708bf43b789c3b24d988dc74aeac710bf1a6f58fb8bfb309288b0a58b98dab8ece480713e73c443dae30e2118a29e19514094d3fc17959
|
data/dev.yml
CHANGED
data/lib/ci/queue/version.rb
CHANGED
@@ -68,7 +68,7 @@ module Minitest
|
|
68
68
|
set_load_path
|
69
69
|
Minitest.queue = queue
|
70
70
|
reporters = [
|
71
|
-
LocalRequeueReporter.new,
|
71
|
+
LocalRequeueReporter.new(verbose: verbose),
|
72
72
|
BuildStatusRecorder.new(build: queue.build),
|
73
73
|
JUnitReporter.new,
|
74
74
|
TestDataReporter.new(namespace: queue_config&.namespace),
|
@@ -88,9 +88,36 @@ module Minitest
|
|
88
88
|
load_tests
|
89
89
|
populate_queue
|
90
90
|
end
|
91
|
+
|
92
|
+
at_exit {
|
93
|
+
verify_reporters!(reporters)
|
94
|
+
}
|
91
95
|
# Let minitest's at_exit hook trigger
|
92
96
|
end
|
93
97
|
|
98
|
+
def verify_reporters!(reporters)
|
99
|
+
return unless reporters.any? { |r| !Minitest::Reporters.reporters.include?(r) }
|
100
|
+
|
101
|
+
warn <<~WARNING
|
102
|
+
WARNING!
|
103
|
+
|
104
|
+
ci-queue requires several custom minitest reporters.
|
105
|
+
Please do not overwrite them.
|
106
|
+
If you have a statement in your test suite like this
|
107
|
+
|
108
|
+
Minitest::Reporters.use!(SomeReporter.new)
|
109
|
+
|
110
|
+
you should only run it when other reporters have not been configured
|
111
|
+
to avoid breaking ci-queue's functionality and getting false test summaries.
|
112
|
+
|
113
|
+
Use something like this:
|
114
|
+
|
115
|
+
if Minitest::Reporters.reporters.nil?
|
116
|
+
Minitest::Reporters.use!(SomeReporter.new)
|
117
|
+
end
|
118
|
+
WARNING
|
119
|
+
end
|
120
|
+
|
94
121
|
def release_command
|
95
122
|
require_worker_id!
|
96
123
|
queue.release!
|
@@ -177,6 +204,8 @@ module Minitest
|
|
177
204
|
puts
|
178
205
|
puts "cat <<EOF |\n#{failing_order.to_a.map(&:id).join("\n")}\nEOF\n#{command.join(' ')}"
|
179
206
|
puts
|
207
|
+
|
208
|
+
File.write('log/test_order.log', failing_order.to_a.map(&:id).join("\n"))
|
180
209
|
exit! 0
|
181
210
|
end
|
182
211
|
end
|
@@ -255,7 +284,7 @@ module Minitest
|
|
255
284
|
private
|
256
285
|
|
257
286
|
attr_reader :queue_config, :options, :command, :argv
|
258
|
-
attr_accessor :queue, :queue_url, :grind_list, :grind_count, :load_paths
|
287
|
+
attr_accessor :queue, :queue_url, :grind_list, :grind_count, :load_paths, :verbose
|
259
288
|
|
260
289
|
def require_worker_id!
|
261
290
|
if queue.distributed?
|
@@ -419,7 +448,7 @@ module Minitest
|
|
419
448
|
EOS
|
420
449
|
opts.separator ""
|
421
450
|
opts.on('-IPATHS', help) do |paths|
|
422
|
-
self.load_paths = paths
|
451
|
+
self.load_paths = [load_paths, paths].compact.join(':')
|
423
452
|
end
|
424
453
|
|
425
454
|
help = <<~EOS
|
@@ -545,6 +574,10 @@ module Minitest
|
|
545
574
|
queue.config.redis_ttl = time
|
546
575
|
end
|
547
576
|
|
577
|
+
opts.on("-v", "--verbose", "Verbose. Show progress processing files.") do
|
578
|
+
self.verbose = true
|
579
|
+
end
|
580
|
+
|
548
581
|
opts.separator ""
|
549
582
|
opts.separator " retry: Replays a previous run in the same order."
|
550
583
|
|
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.
|
4
|
+
version: 0.31.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jean Boussier
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-06-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|