parallel_tests 2.11.0 → 2.12.0

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: c698774063cf365ab657b0fda5f8ff791d08a5e3
4
- data.tar.gz: 6f09e57121be15de5172a2503b458e4c045d4a21
3
+ metadata.gz: d1c6f6ab148c204b15f5c6e5c6762438622d9587
4
+ data.tar.gz: 989f590bbd92bfbf7f485755f0c37df3e2985626
5
5
  SHA512:
6
- metadata.gz: 4e3af2ade6a79b80babbe78426450e2b8ca5ca8ad6da942939b71b0e87f5ee6976aca3634f692b8b0b9af5c99afaea7685b539184df6e1ca70c303441b6c0a39
7
- data.tar.gz: a47ed561002b35cb792ab850b14b10a4581e435fac46481bb4f3cde0ac85d5e7ef6cfb6cdcb5c89159987f955913e16287cbc40e7652aa29d3bdf25893e6249a
6
+ metadata.gz: 53f224685a44607225d7c12acea0415e2548559ab4c15b4ca5a52073a228633b9473f56e18b394049ea1cb8d884f7a65bea3989f36f130c6c08ca0fc91e8390d
7
+ data.tar.gz: 95e3759003ef26063f6f050410fdc1fdd2771ccef6579fea108d2cac7b83b9d5db7d72606f5a7258e3037d7f8c73ac2c4efae53e4c95cabab6586754e932fb24
data/Readme.md CHANGED
@@ -98,17 +98,13 @@ end
98
98
 
99
99
  ```
100
100
 
101
- Loggers
102
- ===================
103
-
104
101
  Even test group run-times
105
- -------------------------
102
+ =========================
106
103
 
107
- ### RSpec
104
+ Test groups are often not balanced and will run for different times, making everything wait for the slowest group.
105
+ Use these loggers to record test runtime and then use the recorded runtime to balance test groups more evenly.
108
106
 
109
- Add the `RuntimeLogger` to log how long each test takes to run.
110
- This log file will be loaded on the next test run, and the tests will be grouped
111
- so that each process should finish around the same time.
107
+ ### RSpec
112
108
 
113
109
  Rspec: Add to your `.rspec_parallel` (or `.rspec`) :
114
110
 
@@ -125,6 +121,9 @@ require 'parallel_tests/test/runtime_logger' if ENV['RECORD_RUNTIME']
125
121
  results will be logged to tmp/parallel_runtime_test.log when `RECORD_RUNTIME` is set,
126
122
  so it is not always required or overwritten.
127
123
 
124
+ Loggers
125
+ =======
126
+
128
127
  RSpec: SummaryLogger
129
128
  --------------------
130
129
 
@@ -75,21 +75,23 @@ end
75
75
 
76
76
  if defined?(Minitest::Runnable) # Minitest 5
77
77
  class << Minitest::Runnable
78
- alias_method :run_without_runtime_log, :run
79
- def run(*args)
80
- ParallelTests::Test::RuntimeLogger.log_test_run(self) do
81
- run_without_runtime_log(*args)
78
+ prepend(Module.new do
79
+ def run(*)
80
+ ParallelTests::Test::RuntimeLogger.log_test_run(self) do
81
+ super
82
+ end
82
83
  end
83
- end
84
+ end)
84
85
  end
85
86
 
86
87
  class << Minitest
87
- alias_method :run_without_runtime_log, :run
88
- def run(*args)
89
- result = run_without_runtime_log(*args)
90
- ParallelTests::Test::RuntimeLogger.unique_log
91
- result
92
- end
88
+ prepend(Module.new do
89
+ def run(*args)
90
+ result = super
91
+ ParallelTests::Test::RuntimeLogger.unique_log
92
+ result
93
+ end
94
+ end)
93
95
  end
94
96
  elsif defined?(MiniTest::Unit) # Minitest 4
95
97
  MiniTest::Unit.class_eval do
@@ -1,3 +1,3 @@
1
1
  module ParallelTests
2
- VERSION = Version = '2.11.0'
2
+ VERSION = Version = '2.12.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parallel_tests
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.11.0
4
+ version: 2.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-17 00:00:00.000000000 Z
11
+ date: 2016-12-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parallel