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

Xisco Fauli (via logerrit) logerrit at kemper.freedesktop.org
Wed Jul 1 13:27:31 UTC 2020


 sc/qa/unit/data/xlsx/tdf131424.xlsx    |binary
 sc/qa/unit/subsequent_filters-test.cxx |   17 +++++++++++++++++
 2 files changed, 17 insertions(+)

New commits:
commit c131d6c6b935617fa84286a9e441c1c791520445
Author:     Xisco Fauli <xiscofauli at libreoffice.org>
AuthorDate: Wed Jul 1 10:31:07 2020 +0200
Commit:     Xisco Fauli <xiscofauli at libreoffice.org>
CommitDate: Wed Jul 1 15:26:53 2020 +0200

    tdf#131424: sc: Add unittest
    
    Change-Id: Ida3df74d44ca027de68f9b5f96a352452d747bfd
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97595
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>

diff --git a/sc/qa/unit/data/xlsx/tdf131424.xlsx b/sc/qa/unit/data/xlsx/tdf131424.xlsx
new file mode 100644
index 000000000000..e48f007dc68e
Binary files /dev/null and b/sc/qa/unit/data/xlsx/tdf131424.xlsx differ
diff --git a/sc/qa/unit/subsequent_filters-test.cxx b/sc/qa/unit/subsequent_filters-test.cxx
index a1027fd06d03..0c332f605f58 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -230,6 +230,7 @@ public:
     void testTdf98844();
     void testTdf100458();
     void testTdf127982();
+    void testTdf131424();
     void testTdf100709XLSX();
     void testTdf97598XLSX();
     void testTdf110440XLSX();
@@ -388,6 +389,7 @@ public:
     CPPUNIT_TEST(testTdf98844);
     CPPUNIT_TEST(testTdf100458);
     CPPUNIT_TEST(testTdf127982);
+    CPPUNIT_TEST(testTdf131424);
     CPPUNIT_TEST(testTdf100709XLSX);
     CPPUNIT_TEST(testTdf97598XLSX);
     CPPUNIT_TEST(testTdf110440XLSX);
@@ -3815,6 +3817,21 @@ void ScFiltersTest::testTdf127982()
     xDocSh->DoClose();
 }
 
+void ScFiltersTest::testTdf131424()
+{
+    ScDocShellRef xDocSh = loadDoc("tdf131424.", FORMAT_XLSX);
+    CPPUNIT_ASSERT_MESSAGE("Failed to open doc", xDocSh.is());
+    ScDocument& rDoc = xDocSh->GetDocument();
+
+    // Without the fix in place, table reference would have failed
+    CPPUNIT_ASSERT_EQUAL(35.0, rDoc.GetValue(ScAddress(2,1,0)));
+    CPPUNIT_ASSERT_EQUAL(58.0, rDoc.GetValue(ScAddress(2,2,0)));
+    CPPUNIT_ASSERT_EQUAL(81.0, rDoc.GetValue(ScAddress(2,3,0)));
+    CPPUNIT_ASSERT_EQUAL(104.0, rDoc.GetValue(ScAddress(2,4,0)));
+
+    xDocSh->DoClose();
+}
+
 void ScFiltersTest::testTdf100709XLSX()
 {
     ScDocShellRef xDocSh = ScBootstrapFixture::loadDoc("tdf100709.", FORMAT_XLSX);


More information about the Libreoffice-commits mailing list