summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2016-05-13 14:56:01 +0200
committerDavid Tardon <dtardon@redhat.com>2016-05-13 19:15:15 +0000
commit1d2091b91e91b50eb98f41c7659746a47cb70c73 (patch)
tree30737f2a76b118a487048b8226b0df272c4b9f6f /sc
parentc767b5534eaea688138a49653f51df7bc321181e (diff)
Resolves: tdf#99730 lower the barrier for inferior systems, cripple the test
(cherry picked from commit b35b601d9e3b43eaedb8576b70d10b657f625d6e) Conflicts: sc/qa/unit/ucalc_formula.cxx Change-Id: Ifdb9330a0614800831d2e0b673d975e6304738e5 Reviewed-on: https://gerrit.libreoffice.org/24971 Reviewed-by: David Tardon <dtardon@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'sc')
-rw-r--r--sc/qa/unit/ucalc_formula.cxx12
1 files changed, 9 insertions, 3 deletions
diff --git a/sc/qa/unit/ucalc_formula.cxx b/sc/qa/unit/ucalc_formula.cxx
index ac203e1c3c6c..b693615982f9 100644
--- a/sc/qa/unit/ucalc_formula.cxx
+++ b/sc/qa/unit/ucalc_formula.cxx
@@ -6829,16 +6829,22 @@ void Test::testFuncMDETERM()
aFormulaBuffer[13] = static_cast<sal_Unicode>( '0' + nSize );
m_pDoc->SetString(aPos, aFormulaBuffer.toString());
+#if SAL_TYPES_SIZEOFPOINTER == 4
// On crappy 32-bit targets, presumably without extended precision on
// interim results or optimization not catching it, this test fails
// when comparing to 0.0, so have a narrow error margin. See also
// commit message of 8140309d636d4a870875f2dd75ed3dfff2c0fbaf
-#if SAL_TYPES_SIZEOFPOINTER == 4
CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of MDETERM incorrect for singular integer matrix",
0.0, m_pDoc->GetValue(aPos), 1e-12);
#else
- CPPUNIT_ASSERT_EQUAL_MESSAGE("Calculation of MDETERM incorrect for singular integer matrix",
- 0.0, m_pDoc->GetValue(aPos));
+ // Even on one (and only one) x86_64 target the result was
+ // 6.34413156928661e-17 instead of 0.0 (tdf#99730) so lower the bar to
+ // 10e-14.
+ // Then again on aarch64, ppc64* and s390x it also fails.
+ // Sigh.. why do we even test this? The original complaint in tdf#32834
+ // was about -9.51712667007776E-016
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of MDETERM incorrect for singular integer matrix",
+ 0.0, m_pDoc->GetValue(aPos), 1e-14);
#endif
}