include/unotest/macros_test.hxx    |    2 -
 oox/qa/unit/export.cxx             |   64 +++++++++++++++++++++++--------------
 sd/qa/filter/eppt/eppt.cxx         |    6 ++-
 sd/qa/unit/export-tests-ooxml1.cxx |    4 +-
 sd/qa/unit/export-tests-ooxml3.cxx |    6 ++-
 sd/qa/unit/sdmodeltestbase.hxx     |    2 -
 sw/qa/inc/swmodeltestbase.hxx      |    2 -
 sw/qa/unit/swmodeltestbase.cxx     |   14 --------
 unotest/source/cpp/macros_test.cxx |    5 +-
 xmloff/qa/unit/draw.cxx            |   12 +++---
 xmloff/qa/unit/style.cxx           |   12 +++---
 xmloff/qa/unit/text.cxx            |   24 ++++++-------
 12 files changed, 79 insertions(+), 74 deletions(-)

New commits:
commit d40d64da771427423786dc62a2f4ad08cab53179
Author:     Xisco Fauli <xiscofa...@libreoffice.org>
AuthorDate: Thu Nov 3 09:55:06 2022 +0100
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Thu Nov 3 13:41:14 2022 +0100

    swmodeltestbase: remove duplicated code
    
    parseExportStream is already in MacrosTest
    
    Change-Id: Ibde88b176db1521966b6877bda90e06c278c397d
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142218
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/include/unotest/macros_test.hxx b/include/unotest/macros_test.hxx
index b2ac283e4f7d..e6c3ecce9683 100644
--- a/include/unotest/macros_test.hxx
+++ b/include/unotest/macros_test.hxx
@@ -92,7 +92,7 @@ public:
                     const css::uno::Sequence<css::beans::PropertyValue>& 
rPropertyValues);
 
     /// Opens rStreamName from rTempFile, assuming it's a ZIP storage.
-    static std::unique_ptr<SvStream> parseExportStream(const 
utl::TempFileNamed& rTempFile,
+    static std::unique_ptr<SvStream> parseExportStream(const OUString& url,
                                                        const OUString& 
rStreamName);
 
     void setUpNssGpg(const test::Directories& rDirectories, const OUString& 
rTestName);
diff --git a/oox/qa/unit/export.cxx b/oox/qa/unit/export.cxx
index de8385fbaf09..711b73922d91 100644
--- a/oox/qa/unit/export.cxx
+++ b/oox/qa/unit/export.cxx
@@ -45,7 +45,7 @@ CPPUNIT_TEST_FIXTURE(Test, testPolylineConnectorPosition)
     utl::TempFileNamed aTempFile = save("Office Open XML Text");
 
     // Then make sure polyline and connector have the correct position.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"word/document.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"word/document.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // For child elements of groups in Writer the position has to be adapted 
to be relative
@@ -75,7 +75,7 @@ CPPUNIT_TEST_FIXTURE(Test, testRotatedShapePosition)
     utl::TempFileNamed aTempFile = save("Office Open XML Text");
 
     // Then make sure the rotated child shape has the correct position.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"word/document.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"word/document.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // For a group itself and for shapes outside of groups, the position 
calculation is done in
@@ -99,7 +99,7 @@ CPPUNIT_TEST_FIXTURE(Test, testDmlGroupshapePolygon)
 
     // Then make sure that the group shape, the group shape's child size and 
the child shape's size
     // match:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"word/document.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"word/document.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//wpg:grpSpPr/a:xfrm/a:ext", "cx", "5328360");
     // Without the accompanying fix in place, this test would have failed, the 
<a:chExt> element was
@@ -120,7 +120,7 @@ CPPUNIT_TEST_FIXTURE(Test, testCustomShapeArrowExport)
     utl::TempFileNamed aTempFile = save("Office Open XML Text");
 
     // Then the shapes should retain their correct control values.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"word/document.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"word/document.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // Without the fix the output OOXML would have no <a:prstGeom> tags in it.
@@ -306,7 +306,8 @@ CPPUNIT_TEST_FIXTURE(Test, testCameraRevolutionGrabBag)
     // When saving that document:
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Then make sure the revolution is exported without a problem:
     // First shape textbox:
@@ -332,7 +333,8 @@ CPPUNIT_TEST_FIXTURE(Test, testReferToTheme)
     // When saving that document:
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Then make sure the shape text color is a scheme color:
     // Without the accompanying fix in place, this test would have failed with:
@@ -380,7 +382,8 @@ CPPUNIT_TEST_FIXTURE(Test, testReferToThemeShapeFill)
     // - Actual  : 0
     // i.e. the <a:schemeClr> element was not written. Note that this was 
already working from PPTX
     // files via grab-bags, so this test intentionally uses an ODP file as 
input.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//p:sp[1]/p:spPr/a:solidFill/a:schemeClr", "val", 
"accent1");
     // Without the accompanying fix in place, this test would have failed with:
@@ -398,7 +401,8 @@ CPPUNIT_TEST_FIXTURE(Test, 
testTdf146690_endParagraphRunPropertiesNewLinesTextSi
     // When saving that document:
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Make sure the text size is exported correctly:
     // Without the accompanying fix in place, this test would have failed with:
@@ -418,7 +422,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_endsubpath)
     // When saving that document:
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Then make sure the pathLst has two child elements,
     // Without the accompanying fix in place, only one element a:path was 
exported.
@@ -436,7 +441,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_commandA)
     // When saving that document:
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Then make sure the path has a child element arcTo. Prior to the fix 
that part of the curve was
     // not exported at all. In odp it is a command A. Such does not exist in 
OOXML and is therefore
@@ -459,7 +465,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_commandT)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // File has draw:viewBox="0 0 216 216"
     assertXPath(pXmlDoc, "//a:pathLst/a:path", "w", "216");
@@ -489,7 +496,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_commandXY)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // File has draw:viewBox="0 0 10 10"
     assertXPath(pXmlDoc, "//a:pathLst/a:path[1]", "w", "10");
@@ -524,7 +532,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_commandHIJK)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // File has draw:viewBox="0 0 80 80"
     assertXPath(pXmlDoc, "//a:pathLst/a:path[1]", "w", "80");
@@ -547,7 +556,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf147978_subpath)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // File should have four subpaths with increasing path size
     assertXPath(pXmlDoc, "//a:pathLst/a:path[1]", "w", "10");
@@ -568,7 +578,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf100391TextAreaRect)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup. Without fix the values were l="l", t="t", r="r", 
b="b"
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//a:custGeom/a:rect", "l", "textAreaLeft");
     assertXPath(pXmlDoc, "//a:custGeom/a:rect", "t", "textAreaTop");
@@ -594,7 +605,7 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf109169_OctagonBevel)
     utl::TempFileNamed aTempFile = save("Office Open XML Text");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"word/document.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"word/document.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // File should have six subpaths, one with stroke and five with fill
     assertXPath(pXmlDoc, "//a:pathLst/a:path[1]", "stroke", "0");
@@ -616,7 +627,8 @@ CPPUNIT_TEST_FIXTURE(Test, testFaultyPathCommandsAWT)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // First child of a:path should be a moveTo in all four shapes.
     assertXPath(pXmlDoc, 
"//p:spTree/p:sp[1]/p:spPr/a:custGeom/a:pathLst/a:path/a:moveTo");
@@ -635,7 +647,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf148784StretchXY)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // x-position of last segment should be same as path width. It was 21600 
without fix.
@@ -672,7 +685,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf148784StretchCommandQ)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // x-position of second quadBezTo control should be same as path width. It 
was 21600 without fix.
@@ -712,7 +726,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf148784StretchCommandVW)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
 
     // wR of first ArcTo in first shape should be same as path width/2. It was 
10800 without fix.
@@ -747,7 +762,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf149551VertPadding)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup. The values must be the same as in the original file.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     for (sal_Int32 i = 1; i <= 2; i++)
     {
@@ -770,7 +786,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf149538upright)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Verify the markup. The values must be the same as in the original file.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//p:spTree/p:sp/p:txBody/a:bodyPr", "upright", "1");
     assertXPathNoAttribute(pXmlDoc, "//p:spTree/p:sp/p:txBody/a:bodyPr", 
"rot");
@@ -780,7 +797,8 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf151008VertAnchor)
 {
     loadFromURL(u"tdf151008_eaVertAnchor.pptx");
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // The order of the shapes in the file is by name "Right", "Center", 
"Left", "RightMiddle",
     // "CenterMiddle" and "LeftMiddle". I access the shapes here by index, 
because the XPath is
diff --git a/sd/qa/filter/eppt/eppt.cxx b/sd/qa/filter/eppt/eppt.cxx
index 9b853b058044..eddc93a36668 100644
--- a/sd/qa/filter/eppt/eppt.cxx
+++ b/sd/qa/filter/eppt/eppt.cxx
@@ -83,7 +83,8 @@ CPPUNIT_TEST_FIXTURE(Test, testThemeExport)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Then verify that this color is not lost:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/theme/theme1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/theme/theme1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//a:clrScheme/a:lt1/a:srgbClr", "val", "000002");
     // Without the fix in place, this test would have failed with:
@@ -102,7 +103,8 @@ CPPUNIT_TEST_FIXTURE(Test, testLoopingFromAnimation)
     utl::TempFileNamed aTempFile = save("Impress Office Open XML");
 
     // Then make sure that the "infinite" repeat count is written:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"ppt/slides/slide1.xml");
+    std::unique_ptr<SvStream> pStream
+        = parseExportStream(aTempFile.GetURL(), "ppt/slides/slide1.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the fix in place, this test would have failed with:
     // - Expected: 1
diff --git a/sd/qa/unit/export-tests-ooxml1.cxx 
b/sd/qa/unit/export-tests-ooxml1.cxx
index a9bec3abfd8e..1ca36d3d07af 100644
--- a/sd/qa/unit/export-tests-ooxml1.cxx
+++ b/sd/qa/unit/export-tests-ooxml1.cxx
@@ -1306,7 +1306,7 @@ void SdOOXMLExportTest1::testCustomXml()
     assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']", 
"Target",
                 "itemProps1.xml");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(tempFile, 
"ddp/ddpfile.xen");
+    std::unique_ptr<SvStream> pStream = parseExportStream(tempFile.GetURL(), 
"ddp/ddpfile.xen");
     CPPUNIT_ASSERT(pStream);
 }
 
@@ -1641,7 +1641,7 @@ void SdOOXMLExportTest1::testNarrationMimeType()
     // Something like ppt/media/image2.png.
     OUString aImageRelName;
     CPPUNIT_ASSERT(aImageAbsName.startsWith("file:///", &aImageRelName));
-    std::unique_ptr<SvStream> pImageStream = parseExportStream(aTempFile, 
aImageRelName);
+    std::unique_ptr<SvStream> pImageStream = 
parseExportStream(aTempFile.GetURL(), aImageRelName);
     vcl::PngImageReader aReader(*pImageStream);
     BitmapEx aBitmapEx = aReader.read();
     // Without the accompanying fix in place, this test would have failed with:
diff --git a/sd/qa/unit/export-tests-ooxml3.cxx 
b/sd/qa/unit/export-tests-ooxml3.cxx
index 2f2576ed1ce6..7e76cfb9fe49 100644
--- a/sd/qa/unit/export-tests-ooxml3.cxx
+++ b/sd/qa/unit/export-tests-ooxml3.cxx
@@ -1072,10 +1072,12 @@ void SdOOXMLExportTest3::testTdf44223()
     loadFromURL(u"pptx/tdf44223.pptx");
     utl::TempFileNamed tempFile = save("Impress Office Open XML");
 
-    std::unique_ptr<SvStream> const pStream1(parseExportStream(tempFile, 
"ppt/media/audio1.wav"));
+    std::unique_ptr<SvStream> const pStream1(
+        parseExportStream(tempFile.GetURL(), "ppt/media/audio1.wav"));
     CPPUNIT_ASSERT_EQUAL(sal_uInt64(11140), pStream1->remainingSize());
 
-    std::unique_ptr<SvStream> const pStream2(parseExportStream(tempFile, 
"ppt/media/audio2.wav"));
+    std::unique_ptr<SvStream> const pStream2(
+        parseExportStream(tempFile.GetURL(), "ppt/media/audio2.wav"));
     CPPUNIT_ASSERT_EQUAL(sal_uInt64(28074), pStream2->remainingSize());
 
     xmlDocUniquePtr pXmlContentType = parseExport(tempFile, 
"[Content_Types].xml");
diff --git a/sd/qa/unit/sdmodeltestbase.hxx b/sd/qa/unit/sdmodeltestbase.hxx
index 191c56e52eec..094521e70bff 100644
--- a/sd/qa/unit/sdmodeltestbase.hxx
+++ b/sd/qa/unit/sdmodeltestbase.hxx
@@ -153,7 +153,7 @@ public:
 
     xmlDocUniquePtr parseExport(utl::TempFileNamed const& rTempFile, OUString 
const& rStreamName)
     {
-        std::unique_ptr<SvStream> const pStream(parseExportStream(rTempFile, 
rStreamName));
+        std::unique_ptr<SvStream> const 
pStream(parseExportStream(rTempFile.GetURL(), rStreamName));
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         return pXmlDoc;
     }
diff --git a/sw/qa/inc/swmodeltestbase.hxx b/sw/qa/inc/swmodeltestbase.hxx
index ccf8d8ac6ae6..c0bf9ec9e58e 100644
--- a/sw/qa/inc/swmodeltestbase.hxx
+++ b/sw/qa/inc/swmodeltestbase.hxx
@@ -369,8 +369,6 @@ protected:
      */
     xmlDocUniquePtr parseExportedFile();
 
-    std::unique_ptr<SvStream> parseExportStream(const OUString& url, const 
OUString& rStreamName);
-
     xmlDocUniquePtr parseExportInternal(const OUString& url, const OUString& 
rStreamName);
 
     /**
diff --git a/sw/qa/unit/swmodeltestbase.cxx b/sw/qa/unit/swmodeltestbase.cxx
index a526f4901331..ab5ed2fcbe52 100644
--- a/sw/qa/unit/swmodeltestbase.cxx
+++ b/sw/qa/unit/swmodeltestbase.cxx
@@ -694,20 +694,6 @@ xmlDocUniquePtr SwModelTestBase::parseExportedFile()
     return parseXmlStream(&stream);
 }
 
-std::unique_ptr<SvStream> SwModelTestBase::parseExportStream(const OUString& 
url,
-                                                             const OUString& 
rStreamName)
-{
-    // Read the stream we're interested in.
-    uno::Reference<packages::zip::XZipFileAccess2> xNameAccess
-        = 
packages::zip::ZipFileAccess::createWithURL(comphelper::getComponentContext(m_xSFactory),
-                                                      url);
-    uno::Reference<io::XInputStream> 
xInputStream(xNameAccess->getByName(rStreamName),
-                                                  uno::UNO_QUERY);
-    CPPUNIT_ASSERT(xInputStream.is());
-    std::unique_ptr<SvStream> 
pStream(utl::UcbStreamHelper::CreateStream(xInputStream, true));
-    return pStream;
-}
-
 xmlDocUniquePtr SwModelTestBase::parseExportInternal(const OUString& url,
                                                      const OUString& 
rStreamName)
 {
diff --git a/unotest/source/cpp/macros_test.cxx 
b/unotest/source/cpp/macros_test.cxx
index 55c34fed20e3..a8b8f6bdf572 100644
--- a/unotest/source/cpp/macros_test.cxx
+++ b/unotest/source/cpp/macros_test.cxx
@@ -92,14 +92,13 @@ void MacrosTest::dispatchCommand(const 
uno::Reference<lang::XComponent>& xCompon
     xDispatchHelper->executeDispatch(xFrame, rCommand, OUString(), 0, 
rPropertyValues);
 }
 
-std::unique_ptr<SvStream> MacrosTest::parseExportStream(const 
utl::TempFileNamed& rTempFile,
+std::unique_ptr<SvStream> MacrosTest::parseExportStream(const OUString& url,
                                                         const OUString& 
rStreamName)
 {
-    const OUString aUrl = rTempFile.GetURL();
     uno::Reference<uno::XComponentContext> xComponentContext
         = comphelper::getProcessComponentContext();
     uno::Reference<packages::zip::XZipFileAccess2> const xZipNames(
-        packages::zip::ZipFileAccess::createWithURL(xComponentContext, aUrl));
+        packages::zip::ZipFileAccess::createWithURL(xComponentContext, url));
     uno::Reference<io::XInputStream> const 
xInputStream(xZipNames->getByName(rStreamName),
                                                         uno::UNO_QUERY);
     std::unique_ptr<SvStream> 
pStream(utl::UcbStreamHelper::CreateStream(xInputStream, true));
diff --git a/xmloff/qa/unit/draw.cxx b/xmloff/qa/unit/draw.cxx
index b13109900a41..d5c5ab0bdced 100644
--- a/xmloff/qa/unit/draw.cxx
+++ b/xmloff/qa/unit/draw.cxx
@@ -125,7 +125,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, testThemeExport)
     utl::TempFileNamed aTempFile = save("impress8");
 
     // Check if the 12 colors are written in the XML:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"styles.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"styles.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - Expected: 12
@@ -164,7 +164,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, testVideoSnapshot)
     // Execute ODP export:
     utl::TempFileNamed aTempFile = save("impress8");
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Check that the preview was exported:
     // Without the accompanying fix in place, this test would have failed with:
@@ -207,7 +207,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, testReferToTheme)
     utl::TempFileNamed aTempFile = save("impress8");
 
     // Make sure the export result has the theme reference:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - XPath '//style:style[@style:name='T1']/style:text-properties' no 
attribute 'theme-color' exist
@@ -318,7 +318,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, 
testExtrusionMetalTypeExtended)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // assert XML.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//draw:enhanced-geometry", "extrusion-metal", 
"true");
     assertXPath(pXmlDoc,
@@ -342,7 +342,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, 
testExtrusionMetalTypeStrict)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // assert XML.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//draw:enhanced-geometry", "extrusion-metal", 
"true");
     assertXPath(pXmlDoc, 
"//draw:enhanced-geometry[@loext:extrusion-metal-type]", 0);
@@ -381,7 +381,7 @@ CPPUNIT_TEST_FIXTURE(XmloffDrawTest, 
testExtrusionSpecularityExtended)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // assert XML.
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, 
"//draw:enhanced-geometry[@draw:extrusion-specularity='100%']");
     assertXPath(pXmlDoc,
diff --git a/xmloff/qa/unit/style.cxx b/xmloff/qa/unit/style.cxx
index 016c5d6bb5ed..aeaf9f20866f 100644
--- a/xmloff/qa/unit/style.cxx
+++ b/xmloff/qa/unit/style.cxx
@@ -191,7 +191,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testWritingModeBTLR)
         utl::TempFileNamed aTempFile = save("writer8");
 
         // With applied fix for tdf150407 still loext:writing-mode="bt-lr" has 
to be written.
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"styles.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "styles.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPath(pXmlDoc,
                     
"/office:document-styles/office:styles/style:style[@style:name='FrameBTLR']/"
@@ -213,7 +213,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testWritingModeBTLR)
 
         // Without the fix an faulty 'writing-mode="bt-lr"' attribute was 
written in productive build.
         // A debug build fails assertion in SvXMLNamespaceMap::GetQNameByKey().
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"styles.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "styles.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPathNoAttribute(pXmlDoc,
                                "/office:document-styles/office:styles/"
@@ -247,7 +247,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testPosRelBottomMargin)
 
         // With applied fix for tdf150407 still 
loext:vertical-rel="page-content-bottom" has to be
         // written.
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "content.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPath(
             pXmlDoc,
@@ -271,7 +271,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testPosRelBottomMargin)
 
         // Without the fix an faulty 'vertical-rel="page-content-bottom"' 
attribute was written in
         // productive build. A debug build fails assertion in 
SvXMLNamespaceMap::GetQNameByKey().
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "content.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPathNoAttribute(pXmlDoc,
                                
"/office:document-content/office:automatic-styles/"
@@ -305,7 +305,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testPosRelTopMargin)
 
         // With applied fix for tdf150407 still 
loext:vertical-rel="page-content-top has to be
         // written.
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "content.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPath(
             pXmlDoc,
@@ -329,7 +329,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testPosRelTopMargin)
 
         // Without the fix an faulty 'vertical-rel="page-content-top"' 
attribute was written in
         // productive build. A debug build fails assertion in 
SvXMLNamespaceMap::GetQNameByKey().
-        std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+        std::unique_ptr<SvStream> pStream = 
parseExportStream(aTempFile.GetURL(), "content.xml");
         xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
         assertXPathNoAttribute(pXmlDoc,
                                
"/office:document-content/office:automatic-styles/"
diff --git a/xmloff/qa/unit/text.cxx b/xmloff/qa/unit/text.cxx
index 99bb4c1a2910..bb86c8df35d4 100644
--- a/xmloff/qa/unit/text.cxx
+++ b/xmloff/qa/unit/text.cxx
@@ -216,7 +216,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testListId)
     xStorable->storeToURL(aTempFile.GetURL(), aStoreProps);
 
     // Then make sure that unreferenced xml:id="..." attributes are not 
written:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - XPath '//text:list' unexpected 'id' attribute
@@ -244,7 +244,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testClearingBreakExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - XPath '//text:line-break' number of nodes is incorrect
@@ -318,7 +318,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testRelativeWidth)
     aTempFile.EnableKillingFile();
     xStorable->storeToURL(aTempFile.GetURL(), aStoreProps);
 
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - Expected: 3.1492in (8cm)
@@ -356,7 +356,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testScaleWidthAndHeight)
     xStorable->storeToURL(aTempFile.GetURL(), aStoreProps);
 
     // Then make sure that we still export a non-zero size:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - Expected: 0.7874in
@@ -386,7 +386,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - XPath '//loext:content-control' number of nodes is incorrect
@@ -449,7 +449,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testCheckboxContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     assertXPath(pXmlDoc, "//loext:content-control", "checkbox", "true");
     assertXPath(pXmlDoc, "//loext:content-control", "checked", "true");
@@ -536,7 +536,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testDropdownContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this failed with:
     // - Expected: 1
@@ -621,7 +621,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testPictureContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - XPath '//loext:content-control' no attribute 'picture' exist
@@ -680,7 +680,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testDateContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     // Without the accompanying fix in place, this test would have failed with:
     // - XPath '//loext:content-control' no attribute 'date' exist
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
@@ -747,7 +747,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testPlainTextContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - XPath '//loext:content-control' no attribute 'plain-text' exist
@@ -803,7 +803,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testComboBoxContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - XPath '//loext:content-control' no attribute 'combobox' exist
@@ -833,7 +833,7 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, 
testAliasContentControlExport)
     utl::TempFileNamed aTempFile = save("writer8");
 
     // Then make sure the expected markup is used:
-    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile, 
"content.xml");
+    std::unique_ptr<SvStream> pStream = parseExportStream(aTempFile.GetURL(), 
"content.xml");
     xmlDocUniquePtr pXmlDoc = parseXmlStream(pStream.get());
     // Without the accompanying fix in place, this test would have failed with:
     // - Expression: prop

Reply via email to