diff options
author | Eike Rathke <erack@redhat.com> | 2016-10-07 20:36:19 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-10-07 20:37:10 +0200 |
commit | 21d8c021b3b0a8cdb946daf9116be64a497fdb91 (patch) | |
tree | 77885f368d0c957b4d6bbb8a010ec736559556db /sc | |
parent | 18537bead90d87bc50230c746c42638125f02812 (diff) |
unit test for tdf#101562
Change-Id: I4cf35e541875e89928d43b1f7e8392908c3ffb0b
Diffstat (limited to 'sc')
-rw-r--r-- | sc/qa/unit/ucalc.cxx | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx index f103f7d10306..f1d705ff401b 100644 --- a/sc/qa/unit/ucalc.cxx +++ b/sc/qa/unit/ucalc.cxx @@ -4094,6 +4094,23 @@ void Test::testUpdateReference() m_pDoc->DeleteTab(2); m_pDoc->DeleteTab(1); m_pDoc->DeleteTab(0); + + // Test positional update and invalidation of lookup cache for insertion + // and deletion within entire column reference. + m_pDoc->InsertTab(0, "Sheet1"); + m_pDoc->InsertTab(1, "Sheet2"); + m_pDoc->SetString(0,1,0, "s1"); + m_pDoc->SetString(0,0,1, "=MATCH(\"s1\";Sheet1.A:A;0)"); + m_pDoc->GetValue(0,0,1, aValue); + ASSERT_DOUBLES_EQUAL_MESSAGE("unexpected MATCH result", 2, aValue); + m_pDoc->InsertRow(0,0,MAXCOL,0,0,1); // insert 1 row before row 1 in Sheet1 + m_pDoc->GetValue(0,0,1, aValue); + ASSERT_DOUBLES_EQUAL_MESSAGE("unexpected MATCH result", 3, aValue); + m_pDoc->DeleteRow(0,0,MAXCOL,0,0,1); // delete row 1 in Sheet1 + m_pDoc->GetValue(0,0,1, aValue); + ASSERT_DOUBLES_EQUAL_MESSAGE("unexpected MATCH result", 2, aValue); + m_pDoc->DeleteTab(1); + m_pDoc->DeleteTab(0); } void Test::testSearchCells() |