2010-01-27 16:38:11 +00:00
|
|
|
require File.join(File.dirname(__FILE__), 'helper')
|
|
|
|
|
|
|
|
class TestRunner < Test::Unit::TestCase
|
|
|
|
context "a test runner" do
|
|
|
|
setup do
|
|
|
|
@pipe = Hydra::Pipe.new
|
|
|
|
Process.fork do
|
|
|
|
@pipe.identify_as_child
|
|
|
|
Hydra::Runner.new(@pipe)
|
|
|
|
end
|
|
|
|
@pipe.identify_as_parent
|
|
|
|
end
|
|
|
|
should "request a file on boot" do
|
2010-01-27 20:47:50 +00:00
|
|
|
assert @pipe.gets.is_a?(Hydra::Messages::RunnerRequestsFile)
|
2010-01-27 16:38:11 +00:00
|
|
|
end
|
2010-01-27 20:19:48 +00:00
|
|
|
should "return a result message after processing a file" do
|
|
|
|
|
|
|
|
end
|
2010-01-27 16:38:11 +00:00
|
|
|
should "terminate when sent a shutdown message"
|
|
|
|
end
|
|
|
|
end
|