summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorƁukasz Hryniuk <lukasz.hryniuk@wp.pl>2015-08-13 23:52:25 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2015-08-26 01:43:02 +0000
commit8580f4428dbe368acea5d4adfea2cb7b399dfae4 (patch)
tree0a8836aef46b9d80b14ac3184fae4882eb886f73
parentb2363e98af7b0281279617e43b8fec5b898b9120 (diff)
tdf#89387 add some strings to FTEST test
Strings should be omitted by the algorithm, so such test cases are important (were missed before). Change-Id: I2e77b2087e398bf27ac71ba4da0b26c66cc08311 Reviewed-on: https://gerrit.libreoffice.org/18001 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r--sc/qa/unit/ucalc_formula.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/sc/qa/unit/ucalc_formula.cxx b/sc/qa/unit/ucalc_formula.cxx
index 3d60fdf5178f..52ccb9aca804 100644
--- a/sc/qa/unit/ucalc_formula.cxx
+++ b/sc/qa/unit/ucalc_formula.cxx
@@ -5573,6 +5573,17 @@ void Test::testFuncFTEST()
m_pDoc->SetValue(2, 2, 0, 13.0); // C3
CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0422, m_pDoc->GetValue(aPos), 10e-4);
+ m_pDoc->SetString(0, 2, 0, "a"); // A3
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0334, m_pDoc->GetValue(aPos), 10e-4);
+ m_pDoc->SetString(2, 0, 0, "b"); // C1
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0261, m_pDoc->GetValue(aPos), 10e-4);
+ m_pDoc->SetString(5, 1, 0, "c"); // F2
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0219, m_pDoc->GetValue(aPos), 10e-4);
+ m_pDoc->SetString(4, 2, 0, "d"); // E3
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0161, m_pDoc->GetValue(aPos), 10e-4);
+ m_pDoc->SetString(3, 2, 0, "e"); // D3
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE("Calculation of FTEST failed", 0.0110, m_pDoc->GetValue(aPos), 10e-4);
+
m_pDoc->DeleteTab(0);
}