Kaydet (Commit) 04658a79 authored tarafından Daniel Bankston's avatar Daniel Bankston Kaydeden (comit) Kohei Yoshida

Add test for hard recalc

Change-Id: I0fdbac47d6049d4a8b0b100eb1ce0fdab3eed262
üst adaf0d9b
......@@ -106,6 +106,7 @@ public:
//ods, xls, xlsx filter tests
void testRangeNameXLS();
void testRangeNameXLSX();
void testHardRecalcODS();
void testFunctionsODS();
void testDatabaseRangesODS();
void testDatabaseRangesXLS();
......@@ -139,6 +140,7 @@ public:
CPPUNIT_TEST_SUITE(ScFiltersTest);
CPPUNIT_TEST(testRangeNameXLS);
CPPUNIT_TEST(testRangeNameXLSX);
CPPUNIT_TEST(testHardRecalcODS);
CPPUNIT_TEST(testFunctionsODS);
CPPUNIT_TEST(testDatabaseRangesODS);
CPPUNIT_TEST(testDatabaseRangesXLS);
......@@ -313,6 +315,24 @@ void ScFiltersTest::testRangeNameXLSX()
xDocSh->DoClose();
}
void ScFiltersTest::testHardRecalcODS()
{
const rtl::OUString aFileNameBase(RTL_CONSTASCII_USTRINGPARAM("hard-recalc."));
ScDocShellRef xDocSh = loadDoc( aFileNameBase, ODS );
xDocSh->DoHardRecalc(true);
CPPUNIT_ASSERT_MESSAGE("Failed to load functions.*", xDocSh.Is());
ScDocument* pDoc = xDocSh->GetDocument();
rtl::OUString aCSVFileName;
//test hard recalc: document has an incorrect cached formula result
//hard recalc should have updated to the correct result
createCSVPath(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("hard-recalc.")), aCSVFileName);
testFile(aCSVFileName, pDoc, 0);
xDocSh->DoClose();
}
void ScFiltersTest::testFunctionsODS()
{
const rtl::OUString aFileNameBase(RTL_CONSTASCII_USTRINGPARAM("functions."));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment