From 208ff30c076d16db2e2b6fc3f0d635b3197e7ca4 Mon Sep 17 00:00:00 2001 From: nahi Date: Mon, 20 Oct 2003 15:37:11 +0000 Subject: * test/soap/calc/*, test/soap/helloworld/*: catch the exception from test server thread and recover. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4816 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/soap/calc/test_calc2.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/soap/calc/test_calc2.rb') diff --git a/test/soap/calc/test_calc2.rb b/test/soap/calc/test_calc2.rb index 25e686b244..4675d0316b 100644 --- a/test/soap/calc/test_calc2.rb +++ b/test/soap/calc/test_calc2.rb @@ -18,10 +18,15 @@ class TestCalc2 < Test::Unit::TestCase @server = CalcServer2.new('CalcServer', 'http://tempuri.org/calcService', '0.0.0.0', Port) @server.level = Logger::Severity::FATAL @t = Thread.new { + Thread.current.abort_on_exception = true @server.start } while @server.server.nil? or @server.server.status != :Running sleep 0.1 + unless @t.alive? + @t.join + raise + end end @var = SOAP::RPC::Driver.new("http://localhost:#{Port}/", 'http://tempuri.org/calcService') @var.add_method('set', 'newValue') @@ -35,6 +40,7 @@ class TestCalc2 < Test::Unit::TestCase def teardown @server.server.shutdown @t.kill + @t.join end def test_calc2 -- cgit v1.2.3