summaryrefslogtreecommitdiff
path: root/sc/qa/unit/bugfix-test.cxx
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2016-03-24 14:06:09 +0100
committerJan Holesovsky <kendy@collabora.com>2016-03-24 14:42:11 +0100
commit5d644eff8f593358f9f9d21949faa630d94e5665 (patch)
tree2e9756613fdf4302fdbddaf9ec95d8151c3e018d /sc/qa/unit/bugfix-test.cxx
parent856038857f566269d8b21fc1c86aa4b5eb7ae048 (diff)
tdf#98657: Fix a corner case when NaN's were added to ScFullMatrix.
Change-Id: Id3befb82c39f9caacc908d664d42365ce6996054
Diffstat (limited to 'sc/qa/unit/bugfix-test.cxx')
-rw-r--r--sc/qa/unit/bugfix-test.cxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/sc/qa/unit/bugfix-test.cxx b/sc/qa/unit/bugfix-test.cxx
index f5459532f33f..02969755d823 100644
--- a/sc/qa/unit/bugfix-test.cxx
+++ b/sc/qa/unit/bugfix-test.cxx
@@ -86,6 +86,7 @@ public:
void testTdf43534();
void testTdf91979();
// void testTdf40110();
+ void testTdf98657();
CPPUNIT_TEST_SUITE(ScFiltersTest);
CPPUNIT_TEST(testTdf64229);
@@ -94,6 +95,7 @@ public:
CPPUNIT_TEST(testTdf43534);
CPPUNIT_TEST(testTdf91979);
// CPPUNIT_TEST(testTdf40110);
+ CPPUNIT_TEST(testTdf98657);
CPPUNIT_TEST_SUITE_END();
private:
uno::Reference<uno::XInterface> m_xCalcComponent;
@@ -230,6 +232,17 @@ void ScFiltersTest::testTdf40110()
}
*/
+void ScFiltersTest::testTdf98657()
+{
+ ScDocShellRef xDocSh = loadDoc("tdf98657.", FORMAT_ODS);
+ ScDocument& rDoc = xDocSh->GetDocument();
+
+ xDocSh->DoHardRecalc(true);
+
+ // this was a NaN before the fix
+ CPPUNIT_ASSERT_EQUAL(double(285.0), rDoc.GetValue(ScAddress(1, 1, 0)));
+}
+
ScFiltersTest::ScFiltersTest()
: ScBootstrapFixture( "/sc/qa/unit/data" )