parallel_tests 2.4.1 → 2.5.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: 768e593b46ba4be5ffbb617578277395eac75094
4
- data.tar.gz: 852e844e9007dc8fa39bdfa502cee2e18faf1851
3
+ metadata.gz: 6ed42ec93713ac6a2e11731be0eddc4039dbda87
4
+ data.tar.gz: f763b44b7989ebcf6178a7b07e14a10c7f4fd45d
5
5
  SHA512:
6
- metadata.gz: d8b4b3d18a2eff045af6a6c3a5eb68499aac4d0840924df39c1a64efb0a0306d14e2fafc8d87dd2804ae4e420268f3ea5940f393e8f991eccdfd0e033c244d9e
7
- data.tar.gz: d27dd85a89f310c63492c51ee2c0fa2dd43eb7a6b185d1eb5f42446d47a9da619c38db29b7b0cbd04f6a695ce4f166384506c5057ea2973c7847fffac81a0161
6
+ metadata.gz: d5fbb7f7ba5db2052cffdb5479c55b317b40089b726de24931b3c73a94b376cbcdfb80f743d5f649ed7b860b22956e6d59d7cc330f34fbd9eb4b81ba5b726312
7
+ data.tar.gz: b54a91287e99b49546bb5fa0bfdaef98aa2842259f9829fd39b7313e93806f54cbcec1c7972b556edb1b4a60f44026b3272cdac22b1831fa6d85d58a789473d6
@@ -3,19 +3,21 @@ require "parallel_tests/gherkin/runner"
3
3
  module ParallelTests
4
4
  module Cucumber
5
5
  class Runner < ParallelTests::Gherkin::Runner
6
+ FAILED_SCENARIO_REGEX = /^cucumber features\/.+:\d+/
7
+
6
8
  class << self
7
9
  def name
8
10
  'cucumber'
9
11
  end
10
12
 
11
13
  def line_is_result?(line)
12
- super or line =~ failing_scenario_regex
14
+ super || line =~ FAILED_SCENARIO_REGEX
13
15
  end
14
16
 
15
17
  def summarize_results(results)
16
18
  output = []
17
19
 
18
- failing_scenarios = results.grep(failing_scenario_regex)
20
+ failing_scenarios = results.grep(FAILED_SCENARIO_REGEX)
19
21
  if failing_scenarios.any?
20
22
  failing_scenarios.unshift("Failing Scenarios:")
21
23
  output << failing_scenarios.join("\n")
@@ -30,12 +32,6 @@ module ParallelTests
30
32
  cmd = cmd.sub(/\s--order random(:\d*)?/, '')
31
33
  "#{cmd} --order random:#{seed}"
32
34
  end
33
-
34
- private
35
-
36
- def failing_scenario_regex
37
- /^cucumber features\/.+:\d+/
38
- end
39
35
  end
40
36
  end
41
37
  end
@@ -30,9 +30,9 @@ module ParallelTests
30
30
  execute_command(cmd, process_number, num_processes, options)
31
31
  end
32
32
 
33
+ # ignores other commands runner noise
33
34
  def line_is_result?(line)
34
- line.gsub!(/[.F*]/,'')
35
- line =~ /\d+ failure/
35
+ line =~ /\d+ failure(?!:)/
36
36
  end
37
37
 
38
38
  # --- usually used by other runners
@@ -101,11 +101,11 @@ module ParallelTests
101
101
  end
102
102
 
103
103
  def find_results(test_output)
104
- test_output.split("\n").map {|line|
105
- line.gsub!(/\e\[\d+m/,'')
104
+ test_output.split("\n").map do |line|
105
+ line.gsub!(/\e\[\d+m/, '') # remove color coding
106
106
  next unless line_is_result?(line)
107
107
  line
108
- }.compact
108
+ end.compact
109
109
  end
110
110
 
111
111
  def test_env_number(process_number, options={})
@@ -1,3 +1,3 @@
1
1
  module ParallelTests
2
- VERSION = Version = '2.4.1'
2
+ VERSION = Version = '2.5.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.4.1
4
+ version: 2.5.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-02-24 00:00:00.000000000 Z
11
+ date: 2016-03-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parallel