3 eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
4 & eval 'exec perl -S $0 $argv:q'
7 use lib
"$ENV{ACE_ROOT}/bin";
8 use PerlACE
::TestTarget
;
19 $server = PerlACE
::TestTarget
::create_target
(1) || die "Create target 1 failed\n";
20 $client = PerlACE
::TestTarget
::create_target
(2) || die "Create target 2 failed\n";
23 $iorbase = "server.ior";
24 $server_iorfile = $server->LocalFile($iorbase);
25 $client_iorfile = $client->LocalFile($iorbase);
27 $server->DeleteFile($iorbase);
28 $client->DeleteFile($iorbase);
30 $SV = $server->CreateProcess ("server", "-ORBDebuglevel $debug_level -ORBid AMI_Forward_server -o $server_iorfile");
31 $CL = $client->CreateProcess ("client", "-ORBdebuglevel $debug_level -ORBid AMI_Forward_client -k file://$client_iorfile");
35 if ($server->WaitForFileTimed ($iorbase,
36 $server->ProcessStartWaitInterval()) == -1) {
37 print STDERR
"ERROR: cannot find file <$server_iorfile>\n";
38 $SV->Kill (); $SV->TimedWait (1);
42 $client_status = $CL->SpawnWaitKill ($client->ProcessStartWaitInterval());
43 $server_status = $SV->Kill ();
45 if ($client_status != 0) {
46 print STDERR
"ERROR: client returned $client_status\n";
50 if ($server_status != 0) {
51 print STDERR
"ERROR: server returned $server_status\n";
55 $server->DeleteFile($iorbase);
56 $client->DeleteFile($iorbase);