-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #324 from jwillemsen/jwi-defaultannotation
First test for default annotation (not supported yet)
- Loading branch information
Showing
5 changed files
with
128 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/** | ||
* @file client.cpp | ||
* @author Johnny Willemsen | ||
* | ||
* @brief CORBA C++11 client application | ||
* | ||
* @copyright Copyright (c) Remedy IT Expertise BV | ||
*/ | ||
|
||
#include "testC.h" | ||
#include "testlib/taox11_testlog.h" | ||
|
||
int main (int /*argc*/, char* /*argv*/[]) | ||
{ | ||
int retval {}; | ||
bar mybar; | ||
|
||
// Just compilation test | ||
TAOX11_TEST_INFO << "mybar: " << mybar << std::endl; | ||
|
||
if (mybar.short_no_default() != 0) | ||
{ | ||
TAOX11_TEST_ERROR << "mybar.short_no_default() not 0 but: " << mybar.short_no_default() << std::endl; | ||
++retval; | ||
} | ||
if (mybar.short_5() != 5) | ||
{ | ||
TAOX11_TEST_ERROR << "mybar.short_5() not 5 but: " << mybar.short_5() << std::endl; | ||
++retval; | ||
} | ||
if (mybar.short_8() != 8) | ||
{ | ||
TAOX11_TEST_ERROR << "mybar.short_8() not 8 but: " << mybar.short_8() << std::endl; | ||
++retval; | ||
} | ||
if (mybar.typedef_short_8() != 8) | ||
{ | ||
TAOX11_TEST_ERROR << "mybar.typedef_short_8() not 8 but: " << mybar.typedef_short_8() << std::endl; | ||
++retval; | ||
} | ||
if (mybar.typedef_short_9() != 9) | ||
{ | ||
TAOX11_TEST_ERROR << "mybar.typedef_short_9() not 9 but: " << mybar.typedef_short_9() << std::endl; | ||
++retval; | ||
} | ||
|
||
return retval; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
#--------------------------------------------------------------------- | ||
# @file run_test.pl | ||
# @author Marcel Smit | ||
# | ||
# @copyright Copyright (c) Remedy IT Expertise BV | ||
#--------------------------------------------------------------------- | ||
eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' | ||
& eval 'exec perl -S $0 $argv:q' | ||
if 0; | ||
|
||
# -*- perl -*- | ||
|
||
use lib "$ENV{ACE_ROOT}/bin"; | ||
use PerlACE::TestTarget; | ||
|
||
my $target = PerlACE::TestTarget::create_target(2) || die "Create target 2 failed\n"; | ||
|
||
$status = 0; | ||
|
||
$SV = $target->CreateProcess ("client"); | ||
|
||
$server = $SV->SpawnWaitKill ($target->ProcessStartWaitInterval()); | ||
|
||
if ($server != 0) { | ||
print STDERR "ERROR: const returned $server\n"; | ||
$status = 1; | ||
} | ||
|
||
$target->GetStderrLog(); | ||
|
||
exit $status; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* @file test.idl | ||
* @author Johnny Willemsen | ||
* | ||
* @copyright Copyright (c) Remedy IT Expertise BV | ||
*/ | ||
|
||
@default(8) typedef short short_type_8; | ||
typedef short_type_8 typedef_short_type_8; | ||
|
||
struct bar | ||
{ | ||
short short_no_default; | ||
@default(5) short short_5; | ||
short_type_8 short_8; | ||
typedef_short_type_8 typedef_short_8; | ||
@default(9) typedef_short_type_8 typedef_short_9; | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// -*- MPC -*- | ||
|
||
project(*default_gen_idl): ridl_ostream_defaults { | ||
IDL_Files { | ||
test.idl | ||
idlflags += --idl-version=4 | ||
} | ||
custom_only = 1 | ||
} | ||
|
||
project(*default_client): taox11_client { | ||
after += *default_gen_idl | ||
Source_Files { | ||
client.cpp | ||
} | ||
Source_Files { | ||
testC.cpp | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters