Revert "Minor modernization of DynamicAny code"
[ACE_TAO.git] / TAO / tests / Time_Policy_Custom / run_test_dyn.pl
blob0d951f123dda8a245555bad4725b73d3c088c2f2
1 eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
2 & eval 'exec perl -S $0 $argv:q'
3 if 0;
5 # -*- perl -*-
7 use lib "$ENV{ACE_ROOT}/bin";
8 use PerlACE::TestTarget;
10 my $server = PerlACE::TestTarget::create_target (1) || die "Create target 1 failed\n";
12 $server_conf_base = "custom_time$PerlACE::svcconf_ext";
13 $server_conf = $server->LocalFile ($server_conf_base);
14 if ($server->PutFile ($server_conf_base) == -1) {
15 print STDERR "ERROR: cannot set file <$server_conf>\n";
16 exit 1;
19 $server_debug_level = '0';
21 foreach $i (@ARGV) {
22 if ($i eq '-debug') {
23 $server_debug_level = '10';
27 $SV = $server->CreateProcess ("test", "-ORBsvcconf $server_conf -ORBdebuglevel $server_debug_level");
29 $server_status = $SV->Spawn ();
31 if ($server_status != 0) {
32 print STDERR "ERROR: server returned $server_status\n";
33 exit 1;
36 $server_status = $SV->WaitKill ($server->ProcessStopWaitInterval()*2);
38 if ($server_status != 0) {
39 print STDERR "ERROR: server returned $server_status\n";
40 $status = 1;
43 exit $status;