summaryrefslogtreecommitdiff
path: root/unotest
diff options
context:
space:
mode:
Diffstat (limited to 'unotest')
-rw-r--r--unotest/source/cpp/getargument.cxx5
-rw-r--r--unotest/source/cpp/getargument.hxx41
-rw-r--r--unotest/source/cpp/gettestargument.cxx5
-rw-r--r--unotest/source/cpp/officeconnection.cxx9
4 files changed, 8 insertions, 52 deletions
diff --git a/unotest/source/cpp/getargument.cxx b/unotest/source/cpp/getargument.cxx
index 5c40a0a324b4..22cd39fc5960 100644
--- a/unotest/source/cpp/getargument.cxx
+++ b/unotest/source/cpp/getargument.cxx
@@ -22,10 +22,9 @@
#include <osl/diagnose.h>
#include <rtl/bootstrap.hxx>
#include <rtl/ustring.hxx>
+#include <unotest/getargument.hxx>
-#include "getargument.hxx"
-
-namespace test::detail
+namespace test
{
bool getArgument(std::u16string_view name, OUString* value)
{
diff --git a/unotest/source/cpp/getargument.hxx b/unotest/source/cpp/getargument.hxx
deleted file mode 100644
index 1a95e487b39b..000000000000
--- a/unotest/source/cpp/getargument.hxx
+++ /dev/null
@@ -1,41 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#pragma once
-
-#include <sal/config.h>
-
-#include <string_view>
-
-#include <rtl/ustring.hxx>
-
-namespace test {
-
-namespace detail {
-
-// Obtain the value of an argument tunneled in via an "arg-<name>" bootstrap
-// variable:
-bool getArgument(
- std::u16string_view name, OUString * value);
-
-}
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/unotest/source/cpp/gettestargument.cxx b/unotest/source/cpp/gettestargument.cxx
index 915ea5690e82..4423ec3a6bb2 100644
--- a/unotest/source/cpp/gettestargument.cxx
+++ b/unotest/source/cpp/gettestargument.cxx
@@ -20,15 +20,14 @@
#include <sal/config.h>
#include <rtl/ustring.hxx>
+#include <unotest/getargument.hxx>
#include <unotest/gettestargument.hxx>
-#include "getargument.hxx"
-
namespace test
{
bool getTestArgument(std::u16string_view name, OUString* value)
{
- return detail::getArgument(OUString(OUString::Concat("testarg.") + name), value);
+ return getArgument(OUString(OUString::Concat("testarg.") + name), value);
}
}
diff --git a/unotest/source/cpp/officeconnection.cxx b/unotest/source/cpp/officeconnection.cxx
index 55525736f346..649d636d0fa6 100644
--- a/unotest/source/cpp/officeconnection.cxx
+++ b/unotest/source/cpp/officeconnection.cxx
@@ -30,11 +30,10 @@
#include <osl/test/uniquepipename.hxx>
#include <osl/time.h>
#include <sal/macros.h>
+#include <unotest/getargument.hxx>
#include <unotest/officeconnection.hxx>
#include <unotest/toabsolutefileurl.hxx>
-#include "getargument.hxx"
-
namespace test {
OfficeConnection::OfficeConnection(): process_(nullptr) {}
@@ -48,7 +47,7 @@ void OfficeConnection::setUp() {
OUString desc;
OUString argSoffice;
CPPUNIT_ASSERT(
- detail::getArgument(
+ getArgument(
u"soffice",
&argSoffice));
if (argSoffice.match("path:")) {
@@ -62,7 +61,7 @@ void OfficeConnection::setUp() {
OUString acceptArg("--accept=" + desc + ";urp");
OUString argUser;
CPPUNIT_ASSERT(
- detail::getArgument(u"user", &argUser));
+ getArgument(u"user", &argUser));
OUString userArg("-env:UserInstallation=" + toAbsoluteFileUrl(argUser));
OUString jreArg(
"-env:UNO_JAVA_JFW_ENV_JREHOME=true");
@@ -72,7 +71,7 @@ void OfficeConnection::setUp() {
jreArg.pData };
rtl_uString ** envs = nullptr;
OUString argEnv;
- if (detail::getArgument(u"env", &argEnv))
+ if (getArgument(u"env", &argEnv))
{
envs = &argEnv.pData;
}