[Libreoffice-commits] core.git: sc/qa

Xisco Fauli (via logerrit) logerrit at kemper.freedesktop.org
Sun Sep 6 14:56:29 UTC 2020


 sc/qa/unit/data/ods/tdf118561.ods          |binary
 sc/qa/unit/data/ods/tdf118561_external.ods |binary
 sc/qa/unit/subsequent_filters-test.cxx     |   21 +++++++++++++++++++++
 3 files changed, 21 insertions(+)

New commits:
commit a36455c8d1aba28ca593a90f2957078934ea5700
Author:     Xisco Fauli <xiscofauli at libreoffice.org>
AuthorDate: Sun Sep 6 14:34:28 2020 +0200
Commit:     Xisco Fauli <xiscofauli at libreoffice.org>
CommitDate: Sun Sep 6 16:55:47 2020 +0200

    tdf#118561: sc_subsequent_filters_test: Add unittest
    
    Change-Id: Ia1edcdb2931db0dd7b9174a697711c6d79ff9a13
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102103
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>

diff --git a/sc/qa/unit/data/ods/tdf118561.ods b/sc/qa/unit/data/ods/tdf118561.ods
new file mode 100644
index 000000000000..ba445f45a250
Binary files /dev/null and b/sc/qa/unit/data/ods/tdf118561.ods differ
diff --git a/sc/qa/unit/data/ods/tdf118561_external.ods b/sc/qa/unit/data/ods/tdf118561_external.ods
new file mode 100644
index 000000000000..c70025980043
Binary files /dev/null and b/sc/qa/unit/data/ods/tdf118561_external.ods differ
diff --git a/sc/qa/unit/subsequent_filters-test.cxx b/sc/qa/unit/subsequent_filters-test.cxx
index 463944a61d4c..a09bb1b33676 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -230,6 +230,7 @@ public:
     void testTdf103734();
     void testTdf98844();
     void testTdf100458();
+    void testTdf118561();
     void testTdf134455();
     void testTdf119533();
     void testTdf127982();
@@ -395,6 +396,7 @@ public:
     CPPUNIT_TEST(testTdf103734);
     CPPUNIT_TEST(testTdf98844);
     CPPUNIT_TEST(testTdf100458);
+    CPPUNIT_TEST(testTdf118561);
     CPPUNIT_TEST(testTdf134455);
     CPPUNIT_TEST(testTdf119533);
     CPPUNIT_TEST(testTdf127982);
@@ -3822,6 +3824,25 @@ void ScFiltersTest::testTdf100458()
     xDocSh->DoClose();
 }
 
+void ScFiltersTest::testTdf118561()
+{
+    ScDocShellRef xDocSh = loadDoc("tdf118561.", FORMAT_ODS);
+    CPPUNIT_ASSERT_MESSAGE("Failed to open doc", xDocSh.is());
+    ScDocument& rDoc = xDocSh->GetDocument();
+
+    //Without the fix in place, it would have failed with
+    //- Expected: apple
+    //- Actual  : Err:502
+    CPPUNIT_ASSERT_EQUAL(OUString("apple"), rDoc.GetString(ScAddress(1,1,1)));
+    CPPUNIT_ASSERT_EQUAL(OUString("apple"), rDoc.GetString(ScAddress(2,1,1)));
+    CPPUNIT_ASSERT_EQUAL(OUString("TRUE"), rDoc.GetString(ScAddress(3,1,1)));
+    CPPUNIT_ASSERT_EQUAL(OUString("fruits"), rDoc.GetString(ScAddress(4,1,1)));
+    CPPUNIT_ASSERT_EQUAL(OUString("apple"), rDoc.GetString(ScAddress(5,1,1)));
+    CPPUNIT_ASSERT_EQUAL(OUString("hat"), rDoc.GetString(ScAddress(6,1,1)));
+
+    xDocSh->DoClose();
+}
+
 void ScFiltersTest::testTdf134455()
 {
     ScDocShellRef xDocSh = loadDoc("tdf134455.", FORMAT_XLSX);


More information about the Libreoffice-commits mailing list