tork 18.1.0 → 18.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/HISTORY.markdown +20 -1
- data/LICENSE +2 -0
- data/README.markdown +1 -1
- data/bin/tork +1 -1
- data/bin/tork-driver +1 -1
- data/bin/tork-engine +1 -1
- data/bin/tork-herald +1 -1
- data/bin/tork-master +1 -1
- data/lib/tork/driver.rb +6 -1
- data/lib/tork/engine.rb +16 -4
- data/lib/tork/master.rb +9 -18
- data/lib/tork/version.rb +1 -1
- data/man/man1/tork-driver.1 +1 -1
- data/man/man1/tork-engine.1 +1 -1
- data/man/man1/tork-herald.1 +1 -1
- data/man/man1/tork-master.1 +1 -1
- data/man/man1/tork.1 +1 -1
- metadata +16 -16
data/HISTORY.markdown
CHANGED
@@ -1,4 +1,23 @@
|
|
1
|
-
## Version 18.
|
1
|
+
## Version 18.2.0 (2012-03-27)
|
2
|
+
|
3
|
+
Minor:
|
4
|
+
|
5
|
+
* Emit warnings when commands cannot be performed. This improves the user
|
6
|
+
experience by giving them immediate feedback. For example, if you issue
|
7
|
+
the "rerun_failed_tests" command and no tests have failed yet, you will
|
8
|
+
now see a warning message that explains the situation. Thanks to
|
9
|
+
NagaChaitanya Vellanki (@chaitanyav) for suggesting this change.
|
10
|
+
|
11
|
+
Patch:
|
12
|
+
|
13
|
+
* GH-32: Restore support for Selenium and Capybara by replacing the global
|
14
|
+
SIGCHLD handler in tork-master(1) with individual threads, one per forked
|
15
|
+
worker process. Thanks to Bjørn Trondsen (@Sharagoz) for reporting this
|
16
|
+
issue and verifying the fix.
|
17
|
+
|
18
|
+
* README: Recommend a newer fork of the "memory_test_fix" Rails plugin.
|
19
|
+
|
20
|
+
## Version 18.1.0 (2012-02-26)
|
2
21
|
|
3
22
|
Minor:
|
4
23
|
|
data/LICENSE
CHANGED
@@ -15,6 +15,8 @@ Thanks to 2012 Mark Hayes <mark@deployfx.com>
|
|
15
15
|
Thanks to 2012 Gumaro Melendez <cloudernew@gmail.com>
|
16
16
|
Thanks to 2012 Scott Radcliff <radcliffsc@gmail.com>
|
17
17
|
Thanks to 2012 David Burrows <david@imergent.com>
|
18
|
+
Thanks to 2012 Bjørn Trondsen <contact@sharagoz.com>
|
19
|
+
Thanks to 2012 NagaChaitanya Vellanki <me@chaitanyavellanki.com>
|
18
20
|
|
19
21
|
Permission to use, copy, modify, and/or distribute this software for any
|
20
22
|
purpose with or without fee is hereby granted, provided that the above
|
data/README.markdown
CHANGED
@@ -408,7 +408,7 @@ For example, to see some real values:
|
|
408
408
|
Released under the ISC license. See the LICENSE file for details.
|
409
409
|
|
410
410
|
[factory_girl]: https://github.com/thoughtbot/factory_girl
|
411
|
-
[memory_test_fix]: https://github.com/
|
411
|
+
[memory_test_fix]: https://github.com/stepahn/memory_test_fix
|
412
412
|
[parallel_tests]: https://github.com/grosser/parallel_tests
|
413
413
|
[Ruby on Rails]: http://rubyonrails.org
|
414
414
|
[Cucumber]: https://cukes.info
|
data/bin/tork
CHANGED
data/bin/tork-driver
CHANGED
data/bin/tork-engine
CHANGED
data/bin/tork-herald
CHANGED
data/bin/tork-master
CHANGED
data/lib/tork/driver.rb
CHANGED
@@ -44,7 +44,12 @@ class Driver < Engine
|
|
44
44
|
end
|
45
45
|
|
46
46
|
def run_all_test_files
|
47
|
-
|
47
|
+
all_test_files = Dir[*Config.all_test_file_globs]
|
48
|
+
if all_test_files.empty?
|
49
|
+
warn "#{$0}: There are no test files to run."
|
50
|
+
else
|
51
|
+
run_test_files all_test_files
|
52
|
+
end
|
48
53
|
end
|
49
54
|
|
50
55
|
def reabsorb_overhead_files
|
data/lib/tork/engine.rb
CHANGED
@@ -37,16 +37,28 @@ class Engine < Server
|
|
37
37
|
end
|
38
38
|
|
39
39
|
def stop_running_test_files
|
40
|
-
@
|
41
|
-
|
40
|
+
if @running_test_files.empty?
|
41
|
+
warn "#{$0}: There are no running test files to stop."
|
42
|
+
else
|
43
|
+
@master.send [:stop]
|
44
|
+
@running_test_files.clear
|
45
|
+
end
|
42
46
|
end
|
43
47
|
|
44
48
|
def rerun_passed_test_files
|
45
|
-
|
49
|
+
if @passed_test_files.empty?
|
50
|
+
warn "#{$0}: There are no passed test files to re-run."
|
51
|
+
else
|
52
|
+
run_test_files @passed_test_files
|
53
|
+
end
|
46
54
|
end
|
47
55
|
|
48
56
|
def rerun_failed_test_files
|
49
|
-
|
57
|
+
if @failed_test_files.empty?
|
58
|
+
warn "#{$0}: There are no failed test files to re-run."
|
59
|
+
else
|
60
|
+
run_test_files @failed_test_files
|
61
|
+
end
|
50
62
|
end
|
51
63
|
|
52
64
|
protected
|
data/lib/tork/master.rb
CHANGED
@@ -9,24 +9,6 @@ class Master < Server
|
|
9
9
|
|
10
10
|
@worker_number_pool = (0 ... Config.max_forked_workers).to_a
|
11
11
|
@command_by_worker_pid = {}
|
12
|
-
|
13
|
-
# process exited child processes and report finished workers to client
|
14
|
-
trap :SIGCHLD do
|
15
|
-
begin
|
16
|
-
while wait2_array = Process.wait2(-1, Process::WNOHANG)
|
17
|
-
child_pid, child_status = wait2_array
|
18
|
-
if command = @command_by_worker_pid.delete(child_pid)
|
19
|
-
@worker_number_pool.push command.last
|
20
|
-
command[0] = if child_status.success? then :pass else :fail end
|
21
|
-
@client.send command.push(child_status.to_i, child_status.inspect)
|
22
|
-
else
|
23
|
-
warn "tork-master: unknown child exited: #{wait2_array.inspect}"
|
24
|
-
end
|
25
|
-
end
|
26
|
-
rescue SystemCallError
|
27
|
-
# raised by wait2() when there are currently no child processes
|
28
|
-
end
|
29
|
-
end
|
30
12
|
end
|
31
13
|
|
32
14
|
def load paths, files
|
@@ -81,6 +63,15 @@ class Master < Server
|
|
81
63
|
|
82
64
|
@command_by_worker_pid[worker_pid] = @command.push(log_file, worker_number)
|
83
65
|
@client.send @command
|
66
|
+
|
67
|
+
# wait for the worker to finish and report its status to the client
|
68
|
+
Thread.new do
|
69
|
+
worker_status = Process.wait2(worker_pid).last
|
70
|
+
command = @command_by_worker_pid.delete(worker_pid)
|
71
|
+
@worker_number_pool.push command.last
|
72
|
+
command[0] = if worker_status.success? then :pass else :fail end
|
73
|
+
@client.send command.push(worker_status.to_i, worker_status.inspect)
|
74
|
+
end
|
84
75
|
end
|
85
76
|
|
86
77
|
def stop
|
data/lib/tork/version.rb
CHANGED
data/man/man1/tork-driver.1
CHANGED
data/man/man1/tork-engine.1
CHANGED
data/man/man1/tork-herald.1
CHANGED
data/man/man1/tork-master.1
CHANGED
data/man/man1/tork.1
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tork
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 18.
|
4
|
+
version: 18.2.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,11 +10,11 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2012-
|
13
|
+
date: 2012-03-28 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: binman
|
17
|
-
requirement: &
|
17
|
+
requirement: &19368900 !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ~>
|
@@ -22,10 +22,10 @@ dependencies:
|
|
22
22
|
version: '3'
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
|
-
version_requirements: *
|
25
|
+
version_requirements: *19368900
|
26
26
|
- !ruby/object:Gem::Dependency
|
27
27
|
name: json
|
28
|
-
requirement: &
|
28
|
+
requirement: &19454480 !ruby/object:Gem::Requirement
|
29
29
|
none: false
|
30
30
|
requirements:
|
31
31
|
- - ! '>='
|
@@ -36,10 +36,10 @@ dependencies:
|
|
36
36
|
version: '2'
|
37
37
|
type: :runtime
|
38
38
|
prerelease: false
|
39
|
-
version_requirements: *
|
39
|
+
version_requirements: *19454480
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: guard
|
42
|
-
requirement: &
|
42
|
+
requirement: &19538720 !ruby/object:Gem::Requirement
|
43
43
|
none: false
|
44
44
|
requirements:
|
45
45
|
- - ~>
|
@@ -47,10 +47,10 @@ dependencies:
|
|
47
47
|
version: '1'
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
|
-
version_requirements: *
|
50
|
+
version_requirements: *19538720
|
51
51
|
- !ruby/object:Gem::Dependency
|
52
52
|
name: diff-lcs
|
53
|
-
requirement: &
|
53
|
+
requirement: &19538220 !ruby/object:Gem::Requirement
|
54
54
|
none: false
|
55
55
|
requirements:
|
56
56
|
- - ! '>='
|
@@ -61,10 +61,10 @@ dependencies:
|
|
61
61
|
version: '2'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
|
-
version_requirements: *
|
64
|
+
version_requirements: *19538220
|
65
65
|
- !ruby/object:Gem::Dependency
|
66
66
|
name: md2man
|
67
|
-
requirement: &
|
67
|
+
requirement: &19537320 !ruby/object:Gem::Requirement
|
68
68
|
none: false
|
69
69
|
requirements:
|
70
70
|
- - ~>
|
@@ -72,10 +72,10 @@ dependencies:
|
|
72
72
|
version: '1'
|
73
73
|
type: :development
|
74
74
|
prerelease: false
|
75
|
-
version_requirements: *
|
75
|
+
version_requirements: *19537320
|
76
76
|
- !ruby/object:Gem::Dependency
|
77
77
|
name: rake
|
78
|
-
requirement: &
|
78
|
+
requirement: &19536620 !ruby/object:Gem::Requirement
|
79
79
|
none: false
|
80
80
|
requirements:
|
81
81
|
- - ! '>='
|
@@ -86,7 +86,7 @@ dependencies:
|
|
86
86
|
version: '1'
|
87
87
|
type: :development
|
88
88
|
prerelease: false
|
89
|
-
version_requirements: *
|
89
|
+
version_requirements: *19536620
|
90
90
|
description: Runs your tests as they change, in parallel.
|
91
91
|
email:
|
92
92
|
- sunaku@gmail.com
|
@@ -146,7 +146,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
146
146
|
version: '0'
|
147
147
|
segments:
|
148
148
|
- 0
|
149
|
-
hash:
|
149
|
+
hash: 2543701647607658307
|
150
150
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
151
151
|
none: false
|
152
152
|
requirements:
|
@@ -155,7 +155,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
155
155
|
version: '0'
|
156
156
|
segments:
|
157
157
|
- 0
|
158
|
-
hash:
|
158
|
+
hash: 2543701647607658307
|
159
159
|
requirements: []
|
160
160
|
rubyforge_project:
|
161
161
|
rubygems_version: 1.8.11
|