1 // **********************************************************************
3 // Copyright (c) 2003-2011 ZeroC, Inc. All rights reserved.
5 // This copy of Ice is licensed to you under the terms described in the
6 // ICE_LICENSE file included in this distribution.
8 // **********************************************************************
11 #include <TestCommon.h>
19 allTests(const CommunicatorPtr
& communicator
)
21 cout
<< "testing stringToProxy... " << flush
;
22 ObjectPrx base
= communicator
->stringToProxy("test:default -p 12010");
26 cout
<< "testing checked cast... " << flush
;
27 TestIntfPrx obj
= TestIntfPrx::checkedCast(base
);
33 cout
<< "creating/destroying/recreating object adapter... " << flush
;
34 ObjectAdapterPtr adapter
=
35 communicator
->createObjectAdapterWithEndpoints("TransientTestAdapter", "default");
38 communicator
->createObjectAdapterWithEndpoints("TransientTestAdapter", "default");
41 catch(const AlreadyRegisteredException
&)
47 // Use a different port than the first adapter to avoid an "address already in use" error.
49 adapter
= communicator
->createObjectAdapterWithEndpoints("TransientTestAdapter", "default");
54 cout
<< "creating/activating/deactivating object adapter in one operation... " << flush
;
58 cout
<< "deactivating object adapter in the server... " << flush
;
62 cout
<< "testing whether server is gone... " << flush
;
68 catch(const LocalException
&)