parallel_tests 0.16.12 → 0.16.13

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: 667c12d9dea9a32a5161e7223857b9552839dbbf
4
- data.tar.gz: 21ff75e3bd5c576141af1ebd4a9a8fc1a2c4379d
3
+ metadata.gz: c7160ffdecbfaac64c6328cb2981afd2dc746510
4
+ data.tar.gz: c1f7abb0e43ab0b321f212a36493cd0e8af50b08
5
5
  SHA512:
6
- metadata.gz: 24c6aad5498a6cc1b32a49a4fe003d1b9b11cba67678fcbd25a7fbf025c1dbb14af0d29557594560618a7360517e31238b14ef042d1ce1d133999e3cd1698e58
7
- data.tar.gz: e35c86efb57eb8577d147bb73e626ed2f3b612ea48616971aa54e530acaf8cfc5594075e928518292241e30f69824a16d88613b1943354db963c8b70f8c4d930
6
+ metadata.gz: 7d3df0755815c4badd85f7e4f673a142de61d9d7fd6e39d1d82061ddbc0e2766580f23f0cbfe803258904d93b6f441a6afe8768996db3031cd4ad676f0452007
7
+ data.tar.gz: 02b347317976bb7449ec760f82741e024b47d75a5a717614e008d1e3c5f996e5403dcde6133f15c906edad89d5f50bd5ea42b4356604ea9f2af5f2dc6b1297b0
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- parallel_tests (0.16.12)
4
+ parallel_tests (0.16.13)
5
5
  parallel
6
6
 
7
7
  GEM
@@ -4,8 +4,9 @@ require "parallel_tests/railtie" if defined? Rails::Railtie
4
4
  require "rbconfig"
5
5
 
6
6
  module ParallelTests
7
+ WINDOWS = (RbConfig::CONFIG['host_os'] =~ /cygwin|mswin|mingw|bccwin|wince|emx/)
7
8
  GREP_PROCESSES_COMMAND = \
8
- if RbConfig::CONFIG['host_os'] =~ /win32/
9
+ if WINDOWS
9
10
  "wmic process get commandline | findstr TEST_ENV_NUMBER 2>&1"
10
11
  else
11
12
  "ps -ef | grep [T]EST_ENV_NUMBER= 2>&1"
@@ -7,8 +7,7 @@ module ParallelTests
7
7
 
8
8
  class << self
9
9
  def run_tests(test_files, process_number, num_processes, options)
10
- windows = (RbConfig::CONFIG['host_os'] =~ /cygwin|mswin|mingw|bccwin|wince|emx/) #Shellwords doesn't work for windows
11
- sanitized_test_files = test_files.map { |val| windows ? "\"#{val}\"" : Shellwords.escape(val) }
10
+ sanitized_test_files = test_files.map { |val| WINDOWS ? "\"#{val}\"" : Shellwords.escape(val) }
12
11
 
13
12
  options = options.merge(:env => {"AUTOTEST" => "1"}) if $stdout.tty? # display color when we are in a terminal
14
13
  cmd = [
@@ -3,7 +3,7 @@ require "parallel_tests/test/runner"
3
3
  module ParallelTests
4
4
  module RSpec
5
5
  class Runner < ParallelTests::Test::Runner
6
- DEV_NULL = (RbConfig::CONFIG['host_os'] =~ /win32/ ? "NUL" : "/dev/null")
6
+ DEV_NULL = (WINDOWS ? "NUL" : "/dev/null")
7
7
  NAME = 'RSpec'
8
8
 
9
9
  class << self
@@ -147,7 +147,7 @@ namespace :parallel do
147
147
  "-n #{count} " \
148
148
  "--pattern '#{pattern}' " \
149
149
  "--test-options '#{options}'"
150
- if RbConfig::CONFIG['host_os'] =~ /cygwin|mswin|mingw|bccwin|wince|emx/
150
+ if ParallelTests::WINDOWS
151
151
  ruby_binary = File.join(RbConfig::CONFIG['bindir'], RbConfig::CONFIG['ruby_install_name'])
152
152
  command = "#{ruby_binary} #{command}"
153
153
  end
@@ -62,10 +62,9 @@ module ParallelTests
62
62
 
63
63
  def execute_command_and_capture_output(env, cmd, silence)
64
64
  # make processes descriptive / visible in ps -ef
65
- windows = RbConfig::CONFIG['host_os'] =~ /cygwin|mswin|mingw|bccwin|wince|emx/
66
- separator = windows ? ' & ' : ';'
65
+ separator = (WINDOWS ? ' & ' : ';')
67
66
  exports = env.map do |k,v|
68
- if windows
67
+ if WINDOWS
69
68
  "(SET \"#{k}=#{v}\")"
70
69
  else
71
70
  "#{k}=#{v};export #{k}"
@@ -1,3 +1,3 @@
1
1
  module ParallelTests
2
- VERSION = Version = '0.16.12'
2
+ VERSION = Version = '0.16.13'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parallel_tests
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.16.12
4
+ version: 0.16.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser