1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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/.
12 #include "wpftqahelperdllapi.h"
14 #include <string_view>
15 #include <unordered_map>
17 #include <com/sun/star/uno/Reference.hxx>
19 #include <rtl/ustring.hxx>
21 #include <unotest/filters-test.hxx>
23 #include "WpftFilterFixture.hxx"
39 namespace writerperfect
43 typedef std::unordered_map
<OUString
, bool> WpftOptionalMap_t
;
45 class WPFTQAHELPER_DLLPUBLIC WpftFilterTestBase
: public ::test::FiltersTest
,
46 public WpftFilterFixture
49 explicit WpftFilterTestBase(const OUString
& rFactoryURL
);
52 void doTest(const OUString
& rFilter
, std::u16string_view rPath
);
53 void doTest(const OUString
& rFilter
, std::u16string_view rPath
,
54 const WpftOptionalMap_t
& rOptionalMap
);
57 virtual bool load(const OUString
&, const OUString
& rURL
, const OUString
&, SfxFilterFlags
,
58 SotClipboardFormatId
, unsigned int) override
;
61 const OUString m_aFactoryURL
;
62 css::uno::Reference
<css::document::XFilter
> m_xFilter
;
63 const WpftOptionalMap_t
* m_pOptionalMap
;
68 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */