parallel_tests 0.4.14 → 0.4.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/lib/parallel_specs/spec_runtime_logger.rb +5 -2
- data/lib/parallel_tests.rb +1 -1
- data/parallel_tests.gemspec +1 -1
- data/spec/spec_helper.rb +1 -0
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.4.
|
1
|
+
0.4.15
|
@@ -15,11 +15,11 @@ class ParallelSpecs::SpecRuntimeLogger < ParallelSpecs::SpecRuntimeLoggerBase
|
|
15
15
|
|
16
16
|
if String === output
|
17
17
|
FileUtils.mkdir_p(File.dirname(output))
|
18
|
-
File.open(output,'w')
|
19
|
-
@output = File.open(output, 'a+') #append so that multiple processes can write at once
|
18
|
+
@output = File.open(output, 'w')
|
20
19
|
else
|
21
20
|
@output = output
|
22
21
|
end
|
22
|
+
|
23
23
|
@example_times = Hash.new(0)
|
24
24
|
@failed_examples = [] # only needed for rspec 2
|
25
25
|
end
|
@@ -47,6 +47,9 @@ class ParallelSpecs::SpecRuntimeLogger < ParallelSpecs::SpecRuntimeLoggerBase
|
|
47
47
|
def example_pending(*args)
|
48
48
|
end
|
49
49
|
|
50
|
+
def example_failed(*args)
|
51
|
+
end
|
52
|
+
|
50
53
|
def dump_summary(*args)
|
51
54
|
end
|
52
55
|
|
data/lib/parallel_tests.rb
CHANGED
@@ -88,7 +88,7 @@ class ParallelTests
|
|
88
88
|
|
89
89
|
def self.tests_with_runtime(root)
|
90
90
|
tests = find_tests(root)
|
91
|
-
lines = File.read(
|
91
|
+
lines = File.read("#{root}/../tmp/parallel_profile.log").split("\n") rescue []
|
92
92
|
|
93
93
|
# use recorded test runtime if we got enough data
|
94
94
|
if lines.size * 1.5 > tests.size
|
data/parallel_tests.gemspec
CHANGED
data/spec/spec_helper.rb
CHANGED
@@ -86,6 +86,7 @@ def test_tests_in_groups(klass, folder, suffix)
|
|
86
86
|
end
|
87
87
|
|
88
88
|
it "partitions by runtime when runtime-data is available" do
|
89
|
+
klass.stub!(:puts)
|
89
90
|
File.open(@log,'w') do |f|
|
90
91
|
@files[1..-1].each{|file| f.puts "#{file}:#{@files.index(file)}"}
|
91
92
|
f.puts "#{@files[0]}:10"
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: parallel_tests
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 17
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 4
|
9
|
-
-
|
10
|
-
version: 0.4.
|
9
|
+
- 15
|
10
|
+
version: 0.4.15
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Michael Grosser
|