summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkerem <hallackerem@gmail.com>2016-12-31 13:26:37 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-01-04 01:48:38 +0000
commit9fb55f7b1de8be1c3f86a4ae540f648574d3ed45 (patch)
tree88f6e450bbac7bce66ca8e6003119746d7d32de1
parent0ab8a27244e74e1c0916b3737f15c6c949aead78 (diff)
tdf#90290 use custom asserter in filters-test.cxx
Change-Id: Ia5fb43c8f5398659a08982700dbece72959af19c Reviewed-on: https://gerrit.libreoffice.org/32529 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r--sc/qa/unit/filters-test.cxx26
1 files changed, 7 insertions, 19 deletions
diff --git a/sc/qa/unit/filters-test.cxx b/sc/qa/unit/filters-test.cxx
index ff0b8f44c6a2..13b323906b56 100644
--- a/sc/qa/unit/filters-test.cxx
+++ b/sc/qa/unit/filters-test.cxx
@@ -358,28 +358,16 @@ void ScFiltersTest::testSharedFormulaXLS()
ScDocument& rDoc2 = xDocSh->GetDocument();
rDoc2.CalcAll();
- if (!checkFormula(rDoc2, ScAddress(1,0,0), "A1*20"))
- CPPUNIT_FAIL("Wrong formula.");
-
- if (!checkFormula(rDoc2, ScAddress(1,1,0), "A2*20"))
- CPPUNIT_FAIL("Wrong formula.");
-
- if (!checkFormula(rDoc2, ScAddress(1,2,0), "A3*20"))
- CPPUNIT_FAIL("Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,0,0), "A1*20", "Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,1,0), "A2*20", "Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,2,0), "A3*20", "Wrong formula.");
// There is an intentional gap at row 4.
- if (!checkFormula(rDoc2, ScAddress(1,4,0), "A5*20"))
- CPPUNIT_FAIL("Wrong formula.");
-
- if (!checkFormula(rDoc2, ScAddress(1,5,0), "A6*20"))
- CPPUNIT_FAIL("Wrong formula.");
-
- if (!checkFormula(rDoc2, ScAddress(1,6,0), "A7*20"))
- CPPUNIT_FAIL("Wrong formula.");
-
- if (!checkFormula(rDoc2, ScAddress(1,7,0), "A8*20"))
- CPPUNIT_FAIL("Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,4,0), "A5*20", "Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,5,0), "A6*20", "Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,6,0), "A7*20", "Wrong formula.");
+ ASSERT_FORMULA_EQUAL(rDoc2, ScAddress(1,7,0), "A8*20", "Wrong formula.");
// We re-group formula cells on load. Let's check that as well.