diff options
author | Philipp Hofer <philipp.hofer@protonmail.com> | 2020-11-12 13:24:41 +0100 |
---|---|---|
committer | Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> | 2020-11-18 12:30:50 +0100 |
commit | afb92ffc62ba140ee1366ac5ecd526706e3d8a74 (patch) | |
tree | 9100ee207ea754c6abd6202c0a01359e7f6c8d23 /unotest/source/cpp/directories.cxx | |
parent | 0ce86801128b0955dd46aca5e5b5add4b719df0a (diff) |
tdf#123936 Formatting files in module unotest with clang-format
Change-Id: Ic67aedc492e3382eeea92f5bda0b4e7ab7e2857c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105725
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Diffstat (limited to 'unotest/source/cpp/directories.cxx')
-rw-r--r-- | unotest/source/cpp/directories.cxx | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/unotest/source/cpp/directories.cxx b/unotest/source/cpp/directories.cxx index 6635fafa030f..54f106b212d6 100644 --- a/unotest/source/cpp/directories.cxx +++ b/unotest/source/cpp/directories.cxx @@ -13,31 +13,33 @@ #include <osl/file.hxx> #include <unotest/directories.hxx> -namespace { - -OUString getFileURLFromSystemPath(OUString const & path) { +namespace +{ +OUString getFileURLFromSystemPath(OUString const& path) +{ OUString url; osl::FileBase::RC e = osl::FileBase::getFileURLFromSystemPath(path, url); CPPUNIT_ASSERT_EQUAL(osl::FileBase::E_None, e); - if (!url.endsWith("/")) { + if (!url.endsWith("/")) + { url += "/"; } return url; } - } -test::Directories::Directories() { - const char* pSrcRoot = getenv( "SRC_ROOT" ); +test::Directories::Directories() +{ + const char* pSrcRoot = getenv("SRC_ROOT"); CPPUNIT_ASSERT_MESSAGE("SRC_ROOT env variable not set", pSrcRoot != nullptr); CPPUNIT_ASSERT_MESSAGE("SRC_ROOT env variable not set", pSrcRoot[0] != 0); - const char* pWorkdirRoot = getenv( "WORKDIR_FOR_BUILD" ); + const char* pWorkdirRoot = getenv("WORKDIR_FOR_BUILD"); CPPUNIT_ASSERT_MESSAGE("$WORKDIR_FOR_BUILD env variable not set", pWorkdirRoot != nullptr); CPPUNIT_ASSERT_MESSAGE("$WORKDIR_FOR_BUILD env variable not set", pWorkdirRoot[0] != 0); - m_aSrcRootPath = OUString::createFromAscii( pSrcRoot ); + m_aSrcRootPath = OUString::createFromAscii(pSrcRoot); m_aSrcRootURL = getFileURLFromSystemPath(m_aSrcRootPath); - m_aWorkdirRootPath = OUString::createFromAscii( pWorkdirRoot ); + m_aWorkdirRootPath = OUString::createFromAscii(pWorkdirRoot); m_aWorkdirRootURL = getFileURLFromSystemPath(m_aWorkdirRootPath); } |