From 585c40ad01f9e3a7cec86cf9b9ec3b27a50eddd1 Mon Sep 17 00:00:00 2001 From: Nick Gauthier Date: Wed, 9 Jun 2010 08:43:15 -0400 Subject: [PATCH] fixed worker test to recognize the worker boot message --- test/worker_test.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/worker_test.rb b/test/worker_test.rb index aaab7c5..36a930d 100644 --- a/test/worker_test.rb +++ b/test/worker_test.rb @@ -41,8 +41,10 @@ class WorkerTest < Test::Unit::TestCase def request_a_file_and_verify_completion(pipe, num_runners) pipe.identify_as_parent + pipe.gets # grab the WorkerBegin num_runners.times do - assert pipe.gets.is_a?(Hydra::Messages::Worker::RequestFile) + response = pipe.gets # grab the RequestFile + assert response.is_a?(Hydra::Messages::Worker::RequestFile), "Expected RequestFile but got #{response.class.to_s}" end pipe.write(Hydra::Messages::Master::RunFile.new(:file => test_file))