summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2014-04-08 21:09:13 +0200
committerEike Rathke <erack@redhat.com>2014-04-08 21:15:41 +0200
commit6d658afd403d40071206f7e83cd7bd68d826a65b (patch)
tree2fa2f4276e4ba68c14cbf8c9db990edb51e8a920 /sc
parent54f2d50360e596914deb80370e9d4671e16ba388 (diff)
add non-editable test for descriptor
Change-Id: I0a40e9e26e09e970023a749b7fd0a67ac29d1bc1
Diffstat (limited to 'sc')
-rw-r--r--sc/qa/unit/data/xls/enhanced-protection.xlsbin25600 -> 26112 bytes
-rw-r--r--sc/qa/unit/filters-test.cxx2
2 files changed, 2 insertions, 0 deletions
diff --git a/sc/qa/unit/data/xls/enhanced-protection.xls b/sc/qa/unit/data/xls/enhanced-protection.xls
index 00cc6e6a3248..26e23273b4df 100644
--- a/sc/qa/unit/data/xls/enhanced-protection.xls
+++ b/sc/qa/unit/data/xls/enhanced-protection.xls
Binary files differ
diff --git a/sc/qa/unit/filters-test.cxx b/sc/qa/unit/filters-test.cxx
index b6d7d760fcec..00724123d596 100644
--- a/sc/qa/unit/filters-test.cxx
+++ b/sc/qa/unit/filters-test.cxx
@@ -511,6 +511,8 @@ void ScFiltersTest::testEnhancedProtectionXLS()
CPPUNIT_ASSERT( pProt->isBlockEditable( ScRange( 0, 1, 0, 0, 1, 0))); // editable without password
CPPUNIT_ASSERT( pProt->isBlockEditable( ScRange( 0, 2, 0, 0, 2, 0))); // editable without password
CPPUNIT_ASSERT( !pProt->isBlockEditable( ScRange( 0, 3, 0, 0, 3, 0))); // editable with password "foo"
+ CPPUNIT_ASSERT( !pProt->isBlockEditable( ScRange( 0, 4, 0, 0, 4, 0))); // editable with descriptor
+ CPPUNIT_ASSERT( !pProt->isBlockEditable( ScRange( 0, 5, 0, 0, 5, 0))); // editable with descriptor and password "foo"
CPPUNIT_ASSERT( pProt->isBlockEditable( ScRange( 0, 1, 0, 0, 2, 0))); // union of two different editables
CPPUNIT_ASSERT( !pProt->isBlockEditable( ScRange( 0, 0, 0, 0, 1, 0))); // union of locked and editable
CPPUNIT_ASSERT( !pProt->isBlockEditable( ScRange( 0, 2, 0, 0, 3, 0))); // union of editable and password editable