Merge pull request #2301 from sonndinh/remove-dup-reactor-functions
[ACE_TAO.git] / TAO / tests / Bug_2084_Regression / run_test.pl
blobc16508245c13f2ee85ec25ff3c26126cdfbfbba4
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 $status = 0;
11 $debug_level = '0';
13 foreach $i (@ARGV) {
14 if ($i eq '-debug') {
15 $debug_level = '10';
19 my $server = PerlACE::TestTarget::create_target (1) || die "Create target 1 failed\n";
21 my $iorbase = "server.ior";
22 my $server_iorfile = $server->LocalFile ($iorbase);
23 $server->DeleteFile($iorbase);
25 $SV = $server->CreateProcess ("server");
27 print STDERR "======== Running in Default Mode\n";
28 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile " .
29 "-ORBdebuglevel $debug_level");
30 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
32 if ($server_status != 0) {
33 print STDERR "ERROR: server returned $server_status\n";
34 exit 1;
37 $server->DeleteFile($iorbase);
39 print STDERR "======== Running with per-orb\n";
40 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile " .
41 "-ORBdebuglevel $debug_level -ORBCollocation per-orb");
42 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
44 if ($server_status != 0) {
45 print STDERR "ERROR: server returned $server_status\n";
46 exit 1;
49 $server->DeleteFile($iorbase);
51 print STDERR "======== Running with no collocation\n";
52 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile " .
53 "-ORBdebuglevel $debug_level -ORBCollocation no");
54 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
56 if ($server_status != 0) {
57 print STDERR "ERROR: server returned $server_status\n";
58 exit 1;
61 $server->DeleteFile($iorbase);
63 print STDERR "======== Running in default mode and two ORBS\n";
64 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile -n " .
65 "-ORBdebuglevel $debug_level");
66 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
68 if ($server_status != 0) {
69 print STDERR "ERROR: server returned $server_status\n";
70 exit 1;
73 $server->DeleteFile($iorbase);
75 print STDERR "======== Running in per-orb mode and two ORBS\n";
76 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile -n " .
77 "-ORBdebuglevel $debug_level -ORBCollocation per-orb");
78 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
80 if ($server_status != 0) {
81 print STDERR "ERROR: server returned $server_status\n";
82 exit 1;
85 $server->DeleteFile($iorbase);
87 print STDERR "======== Running in no collocation mode and two ORBS\n";
88 $SV->Arguments ("-o $server_iorfile -k file://$server_iorfile -n " .
89 "-ORBdebuglevel $debug_level -ORBCollocation no");
90 $server_status = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval());
92 if ($server_status != 0) {
93 print STDERR "ERROR: server returned $server_status\n";
94 exit 1;
97 $server->DeleteFile($iorbase);
99 exit $status;