sc/qa/unit/data/ods/tdf35636.ods |binary sc/qa/unit/subsequent_filters-test.cxx | 16 ++++++++++++++++ 2 files changed, 16 insertions(+)
New commits: commit 3d79ac71d18566e0bd697eae119d6202dc01b494 Author: Xisco Fauli <xiscofa...@libreoffice.org> AuthorDate: Fri Jul 3 13:50:20 2020 +0200 Commit: Xisco Fauli <xiscofa...@libreoffice.org> CommitDate: Fri Jul 3 18:06:04 2020 +0200 tdf#35636: sc: Add unittest Change-Id: I79eee92015b4a4eafd57702e2ac1bf7fe1682f0b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97840 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org> diff --git a/sc/qa/unit/data/ods/tdf35636.ods b/sc/qa/unit/data/ods/tdf35636.ods new file mode 100644 index 000000000000..4ac33ccb4608 Binary files /dev/null and b/sc/qa/unit/data/ods/tdf35636.ods differ diff --git a/sc/qa/unit/subsequent_filters-test.cxx b/sc/qa/unit/subsequent_filters-test.cxx index 0c332f605f58..8c8f4f292862 100644 --- a/sc/qa/unit/subsequent_filters-test.cxx +++ b/sc/qa/unit/subsequent_filters-test.cxx @@ -263,6 +263,7 @@ public: void testColumnWidthRowHeightXLSXML(); void testCharacterSetXLSXML(); void testTdf62268(); + void testTdf35636(); void testVBAMacroFunctionODS(); void testAutoheight2Rows(); void testXLSDefColWidth(); @@ -421,6 +422,7 @@ public: CPPUNIT_TEST(testCharacterSetXLSXML); CPPUNIT_TEST(testCondFormatFormulaListenerXLSX); CPPUNIT_TEST(testTdf62268); + CPPUNIT_TEST(testTdf35636); CPPUNIT_TEST(testVBAMacroFunctionODS); CPPUNIT_TEST(testAutoheight2Rows); CPPUNIT_TEST(testXLSDefColWidth); @@ -4554,6 +4556,20 @@ void ScFiltersTest::testTdf62268() xDocSh->DoClose(); } +void ScFiltersTest::testTdf35636() +{ + ScDocShellRef xDocSh = loadDoc("tdf35636.", FORMAT_ODS); + CPPUNIT_ASSERT_MESSAGE("Failed to open doc", xDocSh.is()); + + ScDocument& rDoc = xDocSh->GetDocument(); + + // Without the fix in place, SUMIF would have returned 0.0 + // with empty cells in the criteria + CPPUNIT_ASSERT_EQUAL(50.0, rDoc.GetValue(ScAddress(1,4,0))); + + xDocSh->DoClose(); +} + void ScFiltersTest::testVBAMacroFunctionODS() { ScDocShellRef xDocSh = loadDoc("vba_macro_functions.", FORMAT_ODS); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits