summaryrefslogtreecommitdiff
path: root/include/test
diff options
context:
space:
mode:
authorJens Carl <j.carl43@gmx.de>2019-03-12 22:55:34 +0000
committerJens Carl <j.carl43@gmx.de>2019-03-13 06:38:53 +0100
commit4ad3b5cdf416a8541a7188f67c7ab7fc0a93b94e (patch)
tree26e3cf35eba65ef44e28b59083b1377b85f17f7b /include/test
parentbea44e5c1b982d05314b72452b94fe288071a496 (diff)
tdf#45904 Move XNameReplace Java tests to C++
Move XNameReplace Java tests to C++ for ScStyleFamilyObj. Fixes i#23594 by creating a new "com.sun.star.style.CellStyle" rather then using an existing one. Change-Id: Ie42e627020aff475173af5bc014bc28d7a11ec56 Reviewed-on: https://gerrit.libreoffice.org/69140 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
Diffstat (limited to 'include/test')
-rw-r--r--include/test/container/xnamereplace.hxx36
1 files changed, 23 insertions, 13 deletions
diff --git a/include/test/container/xnamereplace.hxx b/include/test/container/xnamereplace.hxx
index 2d52fc2037eb..e10d198794ff 100644
--- a/include/test/container/xnamereplace.hxx
+++ b/include/test/container/xnamereplace.hxx
@@ -1,4 +1,4 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
/*
* This file is part of the LibreOffice project.
*
@@ -11,32 +11,42 @@
#define INCLUDED_TEST_CONTAINER_XNAMEREPLACE_HXX
#include <rtl/ustring.hxx>
-#include <com/sun/star/uno/Reference.hxx>
#include <test/testdllapi.hxx>
-#include <com/sun/star/uno/Any.hxx>
-namespace apitest {
+#include <com/sun/star/uno/XInterface.hpp>
+
+#include <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/uno/Any.hxx>
+namespace apitest
+{
class OOO_DLLPUBLIC_TEST XNameReplace
{
public:
- XNameReplace(const OUString& rName): maTestReplacementName(rName) {}
-
- virtual css::uno::Reference< css::uno::XInterface > init() = 0;
+ XNameReplace(const OUString& rName)
+ : m_aReplacementName(rName)
+ {
+ }
+ virtual css::uno::Reference<css::uno::XInterface> init() = 0;
void testReplaceByName();
- virtual css::uno::Any getAnyElementForNameReplace() = 0;
+ void setReplacmentElement(const css::uno::Any& rElement)
+ {
+ m_aReplacementElement = rElement;
+ }
- virtual ~XNameReplace() {}
-private:
- OUString const maTestReplacementName;
+protected:
+ ~XNameReplace() {}
+private:
+ OUString const m_aReplacementName;
+ css::uno::Any m_aReplacementElement;
};
-}
+} // namespace apitest
#endif // INCLUDED_TEST_CONTAINER_XNAMEREPLACE_HXX
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */