nss: upgrade to release 3.73
[LibreOffice.git] / svtools / qa / unit / svtools-dialogs-test.cxx
blob2dc921a7bb8e820484cc59378baf7d66d7e8962b
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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 */
10 #include <sal/config.h>
11 #include <test/screenshot_test.hxx>
12 #include <vcl/abstdlg.hxx>
13 #include <vcl/scheduler.hxx>
14 #include <vcl/wrkwin.hxx>
15 #include <svtools/valueset.hxx>
17 using namespace ::com::sun::star;
19 /// Test opening a dialog in svtools
20 class SvtoolsDialogsTest : public ScreenshotTest
22 private:
23 /// helper method to populate KnownDialogs, called in setUp(). Needs to be
24 /// written and has to add entries to KnownDialogs
25 virtual void registerKnownDialogsByID(mapType& rKnownDialogs) override;
27 /// dialog creation for known dialogs by ID. Has to be implemented for
28 /// each registered known dialog
29 virtual VclPtr<VclAbstractDialog> createDialogByID(sal_uInt32 nID) override;
31 public:
32 SvtoolsDialogsTest();
34 // try to open a dialog
35 void openAnyDialog();
37 CPPUNIT_TEST_SUITE(SvtoolsDialogsTest);
38 CPPUNIT_TEST(openAnyDialog);
39 CPPUNIT_TEST_SUITE_END();
42 SvtoolsDialogsTest::SvtoolsDialogsTest() {}
44 void SvtoolsDialogsTest::registerKnownDialogsByID(mapType& /*rKnownDialogs*/)
46 // fill map of known dialogs
49 VclPtr<VclAbstractDialog> SvtoolsDialogsTest::createDialogByID(sal_uInt32 /*nID*/)
51 return nullptr;
54 void SvtoolsDialogsTest::openAnyDialog()
56 /// process input file containing the UXMLDescriptions of the dialogs to dump
57 processDialogBatchFile("svtools/qa/unit/data/svtools-dialogs-test.txt");
60 CPPUNIT_TEST_SUITE_REGISTRATION(SvtoolsDialogsTest);
62 CPPUNIT_PLUGIN_IMPLEMENT();
64 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */