diff options
Diffstat (limited to 'cpp/test/Ice/enums/Client.cpp')
-rw-r--r-- | cpp/test/Ice/enums/Client.cpp | 45 |
1 files changed, 14 insertions, 31 deletions
diff --git a/cpp/test/Ice/enums/Client.cpp b/cpp/test/Ice/enums/Client.cpp index f1184a24501..31388a38fe0 100644 --- a/cpp/test/Ice/enums/Client.cpp +++ b/cpp/test/Ice/enums/Client.cpp @@ -8,43 +8,26 @@ // ********************************************************************** #include <Ice/Ice.h> -#include <TestCommon.h> +#include <TestHelper.h> #include <Test.h> -DEFINE_TEST("client") - using namespace std; using namespace Test; -int -run(int, char**, const Ice::CommunicatorPtr& communicator) +class Client : public Test::TestHelper { - TestIntfPrxPtr allTests(const Ice::CommunicatorPtr&); - TestIntfPrxPtr t = allTests(communicator); - t->shutdown(); - return EXIT_SUCCESS; -} +public: -int -main(int argc, char* argv[]) -{ -#ifdef ICE_STATIC_LIBS - Ice::registerIceSSL(false); - Ice::registerIceWS(true); -# ifdef ICE_HAS_BT - Ice::registerIceBT(false); -# endif -#endif + void run(int, char**); +}; - try - { - Ice::InitializationData initData = getTestInitData(argc, argv); - Ice::CommunicatorHolder ich(argc, argv, initData); - return run(argc, argv, ich.communicator()); - } - catch(const Ice::Exception& ex) - { - cerr << ex << endl; - return EXIT_FAILURE; - } +void +Client::run(int argc, char** argv) +{ + Ice::CommunicatorHolder communicator = initialize(argc, argv); + TestIntfPrxPtr allTests(Test::TestHelper*); + TestIntfPrxPtr t = allTests(this); + t->shutdown(); } + +DEFINE_TEST(Client) |