diff options
Diffstat (limited to 'TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl')
-rwxr-xr-x | TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl | 57 |
1 files changed, 42 insertions, 15 deletions
diff --git a/TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl b/TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl index 4f9cc2d3ffb..14a803c62c3 100755 --- a/TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl +++ b/TAO/CIAO/tests/RTCCM/Priority_Test/descriptors/basic_test.pl @@ -40,6 +40,24 @@ unlink $daemon_ior; unlink $am_ior; unlink $cookie; +$test_deploy = 0; +$no_daemon = 0; + +# Parse command line argument +while ( $#ARGV >= 0) +{ + if ($ARGV[0] =~ m/^-test_deploy/i) { + $test_deploy = 1; + } + elsif ($ARGV[0] =~ m/^-no_daemon/i) { + $no_daemon = 1; + } + else { + die "Invalid flag: $ARGV[0]\n"; + } + + shift; +} # CIAO Daemon command line arguments $daemon_args1 = "-ORBEndpoint iiop://localhost:10000 -o $daemon_ior -i CIAO_Installation_Data.ini -n $CIAO_ROOT/tools/ComponentServer/ComponentServer"; @@ -54,12 +72,14 @@ $ad_teardown = " -k file://$am_ior -d $cookie -x"; $DS = new PerlACE::Process ("$CIAO_ROOT/tools/Daemon/CIAO_Daemon", "$daemon_args1"); +if ($no_daemon == 0) { ## Starting up the CIAO daemon -$DS->Spawn (); -if (PerlACE::waitforfile_timed ($daemon_ior, 15) == -1) { - print STDERR "ERROR: Could not find daemon ior file <$daemon_ior>\n"; - $DS->Kill (); - exit 1; + $DS->Spawn (); + if (PerlACE::waitforfile_timed ($daemon_ior, 15) == -1) { + print STDERR "ERROR: Could not find daemon ior file <$daemon_ior>\n"; + $DS->Kill (); + exit 1; + } } ## Starting up the CIAO Assembly Manager @@ -91,23 +111,30 @@ if (PerlACE::waitforfile_timed ($controller_ior, 15) == -1) { exit 1; } -for ($work = $start_work; $work < $end_work; $work += $work_step) -{ - printf "Test work: $work\n"; +# Don't start the test +if ($test_deploy == 0) { + for ($work = $start_work; $work < $end_work; $work += $work_step) + { + printf "Test work: $work\n"; #Start the client to send the trigger message - $CL = new PerlACE::Process ("../Controllers/client", - "-k file://$controller_ior -w $work"); - $CL->SpawnWaitKill(60); + $CL = new PerlACE::Process ("../Controllers/client", + "-k file://$controller_ior -w $work"); + $CL->SpawnWaitKill(60); ## Now wait for the test to complete. Need to figure out a way to ## detect this. - sleep ($run_time); + sleep ($run_time); #Start the client to send the trigger message - $CL = new PerlACE::Process ("../Controllers/client", - "-k file://$controller_ior -f"); - $CL->SpawnWaitKill(60); + $CL = new PerlACE::Process ("../Controllers/client", + "-k file://$controller_ior -f"); + $CL->SpawnWaitKill(60); + } +} +else { + print "Test deploying the application -=-=- Not invoking client\n"; + sleep (1); } ## Now teardown the application |