parallelized_specs 0.4.71 → 0.4.72
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -1
- data/lib/parallelized_specs/slow_spec_logger.rb +4 -8
- data/parallelized_specs.gemspec +1 -1
- metadata +1 -1
data/Rakefile
CHANGED
@@ -12,7 +12,7 @@ begin
|
|
12
12
|
gem.email = "jake@instructure.com"
|
13
13
|
gem.homepage = "http://github.com/jakesorce/#{gem.name}"
|
14
14
|
gem.authors = "Jake Sorce, Bryan Madsen, Shawn Meredith"
|
15
|
-
gem.version = "0.4.
|
15
|
+
gem.version = "0.4.72"
|
16
16
|
end
|
17
17
|
Jeweler::GemcutterTasks.new
|
18
18
|
rescue LoadError
|
@@ -3,11 +3,8 @@ require 'parallelized_specs'
|
|
3
3
|
module RSpec
|
4
4
|
class ParallelizedSpecs::SlowestSpecLogger < ParallelizedSpecs::SpecLoggerBase
|
5
5
|
|
6
|
-
def initialize(*args)
|
7
|
-
@example_times = []
|
8
|
-
end
|
9
|
-
|
10
6
|
def example_started(example)
|
7
|
+
@example_times||[]
|
11
8
|
@spec_start_time = Time.now
|
12
9
|
end
|
13
10
|
|
@@ -20,15 +17,14 @@ module RSpec
|
|
20
17
|
end
|
21
18
|
|
22
19
|
def dump_summary(*args)
|
23
|
-
|
24
|
-
@example_times.each { |
|
20
|
+
File.open("#{Rails.root}/tmp/parallel_log/slowest_specs.log", 'a+') do |f|
|
21
|
+
@example_times.each { | example_details | f.puts "#{example_details}" }
|
25
22
|
end
|
26
|
-
@output.flush
|
27
23
|
end
|
28
24
|
|
29
25
|
def add_total_spec_time(example)
|
30
26
|
total_time = Time.now - @spec_start_time
|
31
|
-
@example_times << "#{total_time}*#{example.description}*#{example_group.location.match(/.*rb/)}"
|
27
|
+
@example_times << "#{total_time}*#{example.description}*#{example_group.location.match(/.*rb/).to_s}"
|
32
28
|
end
|
33
29
|
end
|
34
30
|
end
|
data/parallelized_specs.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "parallelized_specs"
|
8
|
-
s.version = "0.4.
|
8
|
+
s.version = "0.4.72"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Jake Sorce, Bryan Madsen, Shawn Meredith"]
|