[Libreoffice-commits] core.git: 2 commits - sw/qa

Stephan Bergmann sbergman at redhat.com
Wed Mar 28 14:16:56 UTC 2018


 sw/qa/extras/rtfimport/rtfimport.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 98246996f79452e294ddbc2041a9c1d8007d2099
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Wed Mar 28 11:35:16 2018 +0200

    Pasted-in document need only be opened for reading
    
    Otherwise, if SRCDIR is a read-only tree, CppunitTest_sw_rtfimport would fail
    with the
    
      CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, pStream->GetError());
    
    from <https://gerrit.libreoffice.org/#/c/51992/> "Check successful stream
    creation".  (And before that, it would have more obscurely failed with the
    
      CPPUNIT_ASSERT_EQUAL(2, getParagraphs());
    
    in testTdf90260Par failing with 1 vs. 2.)
    
    Change-Id: I55fcc932c66e6a4b84cd391f8821257a0de2abb8
    Reviewed-on: https://gerrit.libreoffice.org/51993
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index e2b32a450ed7..a99ba78d5aa9 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -70,7 +70,7 @@ protected:
         aDescriptor[0].Name = "InputStream";
         SvStream* pStream = utl::UcbStreamHelper::CreateStream(
             m_directories.getURLFromSrc("/sw/qa/extras/rtfimport/data/") + aFilename,
-            StreamMode::WRITE);
+            StreamMode::STD_READ);
         CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, pStream->GetError());
         uno::Reference<io::XStream> xStream(new utl::OStreamWrapper(*pStream));
         aDescriptor[0].Value <<= xStream;
commit e4082f29b95ecbef5758e8419a9b00a074e0bfb0
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Wed Mar 28 11:39:30 2018 +0200

    Check successful filter operation
    
    Change-Id: I220905486cc2287f2157f57b537c0df0b325bd36
    Reviewed-on: https://gerrit.libreoffice.org/51994
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index 9153a8747aa2..e2b32a450ed7 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -81,7 +81,7 @@ protected:
             aDescriptor[2].Name = "TextInsertModeRange";
             aDescriptor[2].Value <<= xTextRange;
         }
-        xFilter->filter(aDescriptor);
+        CPPUNIT_ASSERT(xFilter->filter(aDescriptor));
     }
     AllSettings m_aSavedSettings;
 };


More information about the Libreoffice-commits mailing list