diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-08-03 12:11:00 +0000 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-08-03 12:11:00 +0000 |
commit | cb474595bc41d345ca554ab9594efa640a5783bd (patch) | |
tree | ee7690649fd6c548432893bf0effd628cf133288 /TAO/tests/Bug_3701_Regression | |
parent | 839ce5c985fda709fbaa22e7ae23d9ae7d506718 (diff) | |
download | ATCD-cb474595bc41d345ca554ab9594efa640a5783bd.tar.gz |
Mon Aug 3 12:09:40 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl>
* bin/tao_orb_tests.lst:
* tests/Bug_3701_Regression/*:
Added test for bugzilla 3701
* tests/Timed_Buffered_Oneways/run_test.pl:
* tests/Single_Read/run_test.pl:
* tests/Server_Leaks/run_test.pl:
* tests/POA/Persistent_ID/run_test.pl:
* tests/Crash_On_Write/run_test.pl:
Check return value of spawn
Diffstat (limited to 'TAO/tests/Bug_3701_Regression')
-rw-r--r-- | TAO/tests/Bug_3701_Regression/Bug_3701_Regression.mpc | 9 | ||||
-rw-r--r-- | TAO/tests/Bug_3701_Regression/client.cpp | 26 | ||||
-rwxr-xr-x | TAO/tests/Bug_3701_Regression/run_test.pl | 22 |
3 files changed, 57 insertions, 0 deletions
diff --git a/TAO/tests/Bug_3701_Regression/Bug_3701_Regression.mpc b/TAO/tests/Bug_3701_Regression/Bug_3701_Regression.mpc new file mode 100644 index 00000000000..e9fa8a23ed9 --- /dev/null +++ b/TAO/tests/Bug_3701_Regression/Bug_3701_Regression.mpc @@ -0,0 +1,9 @@ +// -*- MPC -*- +// $Id$ + +project(*Client): taoclient { + Source_Files { + client.cpp + } +} + diff --git a/TAO/tests/Bug_3701_Regression/client.cpp b/TAO/tests/Bug_3701_Regression/client.cpp new file mode 100644 index 00000000000..bcaafc79f4a --- /dev/null +++ b/TAO/tests/Bug_3701_Regression/client.cpp @@ -0,0 +1,26 @@ +// $Id$ + +#include "tao/SystemException.h" + +ACE_RCSID(Hello, client, "$Id$") + +int +ACE_TMAIN(int, ACE_TCHAR *[]) +{ + int result = 0; + try + { + throw CORBA::BAD_PARAM (); + } + catch (const CORBA::BAD_PARAM&) + { + // Correct exception + } + catch (const CORBA::Exception& ex) + { + ex._tao_print_exception ("Incorrect exception caught:"); + ++result; + } + + return result; +} diff --git a/TAO/tests/Bug_3701_Regression/run_test.pl b/TAO/tests/Bug_3701_Regression/run_test.pl new file mode 100755 index 00000000000..2e0c5610736 --- /dev/null +++ b/TAO/tests/Bug_3701_Regression/run_test.pl @@ -0,0 +1,22 @@ +eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' + & eval 'exec perl -S $0 $argv:q' + if 0; + +# $Id$ +# -*- perl -*- + +use lib "$ENV{ACE_ROOT}/bin"; +use PerlACE::TestTarget; + +my $server = PerlACE::TestTarget::create_target (1) || die "Create target 1 failed\n"; + +$SV = $server->CreateProcess ("client"); + +$test = $SV->SpawnWaitKill ($server->ProcessStartWaitInterval()); + +if ($test != 0) { + print STDERR "ERROR: test returned $test\n"; + exit 1; +} + +exit 0; |