/*************************************************************************** * Copyright (C) 2004 by Intra2net AG * * info@intra2net.com * * * ***************************************************************************/ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #ifdef HAVE_CONFIG_H #include #endif using namespace std; using namespace libt2n; using namespace CppUnit; class testme : public command_client { public: testme(client_connection &x, long long a, long long b) : command_client(x,100000,10000) { } void helloworld(const std::string& text) { std::cout << "Hello world, " << text << std::endl; } }; typedef T2nSingletonWrapper wraptype; template<> std::auto_ptr wraptype::SingletonObject = std::auto_ptr(); template<> std::auto_ptr wraptype::WrappedConnection = std::auto_ptr(); class test_wrapper : public TestFixture { CPPUNIT_TEST_SUITE(test_wrapper); CPPUNIT_TEST(simple_wrap); CPPUNIT_TEST_SUITE_END(); public: void setUp() { } void tearDown() { } void simple_wrap() { // t2n_exec(&testme::helloworld)("gurke"); CPPUNIT_ASSERT_EQUAL(true,true); } }; CPPUNIT_TEST_SUITE_REGISTRATION(test_wrapper);