diff options
author | Matúš Kukan <matus.kukan@gmail.com> | 2012-09-27 22:07:53 +0200 |
---|---|---|
committer | Matúš Kukan <matus.kukan@gmail.com> | 2012-09-27 22:31:50 +0200 |
commit | 4917f0ceb2a7b1bb3ba878373f71f38d156278af (patch) | |
tree | dbb58a06294aca75a4a1def7399c67be31a1bf0b /tubes | |
parent | c563ca3843387a2cc5a7a667856154ae2f13985b (diff) |
tubes: catch exception to get more info
Also add timeout as a first thing to not loop forever if something else
goes wrong.
Change-Id: I3c752f74bfd32c1a0a6d1ce85408271a530fb379
Diffstat (limited to 'tubes')
-rw-r--r-- | tubes/qa/test_manager.cxx | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/tubes/qa/test_manager.cxx b/tubes/qa/test_manager.cxx index 545947de159e..2ccbe329ef34 100644 --- a/tubes/qa/test_manager.cxx +++ b/tubes/qa/test_manager.cxx @@ -107,9 +107,18 @@ static gboolean timed_out( void * ) void TestTeleTubes::testInitialize() { - utl::LocalFileHelper::ConvertPhysicalNameToURL( - OUString::createFromAscii( getenv("SRCDIR") ) + "/tubes/qa/test-config.ini", - maTestConfigIniURL ); + g_timeout_add_seconds (10, timed_out, NULL); + try + { + utl::LocalFileHelper::ConvertPhysicalNameToURL( + OUString::createFromAscii( getenv("SRCDIR") ) + "/tubes/qa/test-config.ini", + maTestConfigIniURL ); + } + catch (const com::sun::star::uno::Exception& e) + { + CPPUNIT_ASSERT_MESSAGE( OUStringToOString( "Exception while getting config.ini url: " + + e.Message, RTL_TEXTENCODING_UTF8).getStr(), false); + } rtl::Bootstrap aTestConfig( maTestConfigIniURL ); TeleManager::addSuffixToNames( "TeleTest"); @@ -124,7 +133,6 @@ void TestTeleTubes::testInitialize() aTestConfig.getFrom("accepter", aAccepterIdentifier)); maAccepterIdentifier = OUStringToOString( aAccepterIdentifier, RTL_TEXTENCODING_UTF8); - g_timeout_add_seconds (10, timed_out, NULL); mpCollaboration1 = new TestCollaboration(); mpCollaboration2 = new TestCollaboration(); } |