Revision 5f7fd34c
Added by Lukas Zapletal over 8 years ago
test/util_test.rb | ||
---|---|---|
end
|
||
|
||
def test_commandtask_with_exit_0
|
||
t = Proxy::Util::CommandTask.new('true')
|
||
t = Proxy::Util::CommandTask.new('true').start
|
||
assert_equal t.join, 0
|
||
end
|
||
|
||
def test_commandtask_with_exit_1
|
||
t = Proxy::Util::CommandTask.new('false')
|
||
t = Proxy::Util::CommandTask.new('false').start
|
||
# In Ruby 1.8, the return code is always 0
|
||
assert_equal t.join, RUBY_VERSION =~ /^1\.8/ ? 0 : 1
|
||
end
|
Also available in: Unified diff
Fixes #11318 - HttpDownloads.start_download returns instance
instead of `true`. Allows to join processes, useful for discovery image
plugin.