summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2021-04-26 16:30:28 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2021-04-27 09:18:14 +0200
commitbde131ad18620dea03531c59893c99be09e3ce4e (patch)
tree2beab4563305b983257852e2fcd9a2ed18727f71
parenta3843f1cb0095e843bc4ee7ed20802147f63c7ba (diff)
tdf#141914: sc_bugfix: Add unittest
Change-Id: I937b973fde43b7840e01d8ba4ce37f8e15274a89 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114673 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
-rw-r--r--sc/qa/unit/bugfix-test.cxx13
-rw-r--r--sc/qa/unit/data/ods/tdf141914.odsbin0 -> 21832 bytes
2 files changed, 13 insertions, 0 deletions
diff --git a/sc/qa/unit/bugfix-test.cxx b/sc/qa/unit/bugfix-test.cxx
index 384591fe1a10..ae77ccc99c64 100644
--- a/sc/qa/unit/bugfix-test.cxx
+++ b/sc/qa/unit/bugfix-test.cxx
@@ -56,6 +56,7 @@ public:
void testRhbz1390776();
void testTdf104310();
void testTdf31231();
+ void testTdf141914();
void testTdf128951();
void testTdf129789();
void testTdf130725();
@@ -79,6 +80,7 @@ public:
CPPUNIT_TEST(testRhbz1390776);
CPPUNIT_TEST(testTdf104310);
CPPUNIT_TEST(testTdf31231);
+ CPPUNIT_TEST(testTdf141914);
CPPUNIT_TEST(testTdf128951);
CPPUNIT_TEST(testTdf129789);
CPPUNIT_TEST(testTdf130725);
@@ -533,6 +535,17 @@ void ScFiltersTest::testTdf31231()
xDocSh->DoClose();
}
+void ScFiltersTest::testTdf141914()
+{
+ // We must open it read-write to allow setting modified flag
+ ScDocShellRef xDocSh = loadDoc(u"tdf141914.", FORMAT_ODS, true);
+
+ CPPUNIT_ASSERT_MESSAGE("The spreadsheet must be allowed to set modified state", xDocSh->IsEnableSetModified());
+ CPPUNIT_ASSERT_MESSAGE("The spreadsheet must not be modified on open", !xDocSh->IsModified());
+
+ xDocSh->DoClose();
+}
+
void ScFiltersTest::testTdf128951()
{
css::uno::Reference<css::frame::XDesktop2> xDesktop
diff --git a/sc/qa/unit/data/ods/tdf141914.ods b/sc/qa/unit/data/ods/tdf141914.ods
new file mode 100644
index 000000000000..2370213cec3c
--- /dev/null
+++ b/sc/qa/unit/data/ods/tdf141914.ods
Binary files differ