LCOV - code coverage report
Current view: top level - dbaccess/qa/extras - macros-test.cxx (source / functions) Hit Total Coverage
Test: commit 0e63ca4fde4e446f346e35849c756a30ca294aab Lines: 16 16 100.0 %
Date: 2014-04-11 Functions: 10 11 90.9 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  */
       9             : 
      10             : #include <sal/config.h>
      11             : #include <test/unoapi_test.hxx>
      12             : #include <rtl/strbuf.hxx>
      13             : #include <osl/file.hxx>
      14             : 
      15             : #include <sfx2/app.hxx>
      16             : #include <sfx2/docfilt.hxx>
      17             : #include <sfx2/docfile.hxx>
      18             : #include <sfx2/sfxmodelfactory.hxx>
      19             : #include <svl/intitem.hxx>
      20             : 
      21             : #include <basic/sbxdef.hxx>
      22             : 
      23             : using namespace ::com::sun::star;
      24             : using namespace ::com::sun::star::uno;
      25             : 
      26             : 
      27           2 : class DBAccessTest : public UnoApiTest
      28             : {
      29             : public:
      30             :     DBAccessTest();
      31             : 
      32             :     void test();
      33             : 
      34           2 :     CPPUNIT_TEST_SUITE(DBAccessTest);
      35             : #if !defined(MACOSX) && !defined(WNT)
      36           1 :     CPPUNIT_TEST(test);
      37             : #endif
      38           2 :     CPPUNIT_TEST_SUITE_END();
      39             : 
      40             : };
      41             : 
      42             : 
      43           1 : DBAccessTest::DBAccessTest()
      44           1 :       : UnoApiTest("/dbaccess/qa/extras/testdocuments")
      45             : {
      46           1 : }
      47             : 
      48           1 : void DBAccessTest::test()
      49             : {
      50           1 :     const OUString aFileNameBase("testdb.odb");
      51           2 :     OUString aFileName;
      52           1 :     createFileURL(aFileNameBase, aFileName);
      53           2 :     uno::Reference< lang::XComponent > xComponent = loadFromDesktop(aFileName);
      54           2 :     CPPUNIT_ASSERT(xComponent.is());
      55           1 : }
      56             : 
      57           1 : CPPUNIT_TEST_SUITE_REGISTRATION(DBAccessTest);
      58             : 
      59           4 : CPPUNIT_PLUGIN_IMPLEMENT();
      60             : 
      61             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10