diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2024-01-03 11:49:02 +0600 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2024-01-03 07:51:28 +0100 |
commit | a01a642ebbdb8c16f1b54b4634c277b9f665192f (patch) | |
tree | e0c598848fbb375ddbe9e1cf4db42df1e27746a9 /sc/qa | |
parent | 8ecd20b447ab5e58fa77c19fce09c0f239d1fafc (diff) |
UnoApiTest::loadFromURL -> UnoApiTest::loadFromFile
The old name was misleading (it doesn't take an URL, but a filename);
also, now it's easier to grep for it - doesn't get mixed with
vcl::graphic::loadFromURL.
Change-Id: Ib88d2194200a6a54d2326971e0306ba39f0c7025
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161578
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sc/qa')
29 files changed, 106 insertions, 106 deletions
diff --git a/sc/qa/extras/htmlexporttest.cxx b/sc/qa/extras/htmlexporttest.cxx index 774f75078a85..4e83e51139b2 100644 --- a/sc/qa/extras/htmlexporttest.cxx +++ b/sc/qa/extras/htmlexporttest.cxx @@ -33,7 +33,7 @@ public: void testHtmlSkipImage() { - loadFromURL(u"BaseForHTMLExport.ods"); + loadFromFile(u"BaseForHTMLExport.ods"); save("HTML (StarCalc)"); htmlDocUniquePtr pDoc = parseHtml(maTempFile); CPPUNIT_ASSERT (pDoc); @@ -52,7 +52,7 @@ public: void testTdf155244() { - loadFromURL(u"default-styles.ods"); + loadFromFile(u"default-styles.ods"); save("XHTML Calc File"); xmlDocUniquePtr pXmlDoc = parseXml(maTempFile); diff --git a/sc/qa/extras/macros-test.cxx b/sc/qa/extras/macros-test.cxx index c483a05c9300..4494f3f65bee 100644 --- a/sc/qa/extras/macros-test.cxx +++ b/sc/qa/extras/macros-test.cxx @@ -781,7 +781,7 @@ CPPUNIT_TEST_FIXTURE(ScMacrosTest, testShapeLayerId) CPPUNIT_TEST_FIXTURE(ScMacrosTest, testFunctionAccessIndirect) { - OUString aFileName = loadFromURL(u"tdf120161.ods"); // just some document with known values in cells + OUString aFileName = loadFromFile(u"tdf120161.ods"); // just some document with known values in cells const OUString aReference = "'" + aFileName + "'#$Sheet1.A1"; diff --git a/sc/qa/extras/new_cond_format.cxx b/sc/qa/extras/new_cond_format.cxx index 9cab2bdd1edc..9749d639c6cc 100644 --- a/sc/qa/extras/new_cond_format.cxx +++ b/sc/qa/extras/new_cond_format.cxx @@ -434,7 +434,7 @@ void ScConditionalFormatTest::setUp() { UnoApiTest::setUp(); // get the test file - loadFromURL(u"new_cond_format_api.ods"); + loadFromFile(u"new_cond_format_api.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScConditionalFormatTest); diff --git a/sc/qa/extras/scannotationobj.cxx b/sc/qa/extras/scannotationobj.cxx index 4498ff5ad743..fe092e019892 100644 --- a/sc/qa/extras/scannotationobj.cxx +++ b/sc/qa/extras/scannotationobj.cxx @@ -123,7 +123,7 @@ void ScAnnontationObj::setUp() UnoApiTest::setUp(); // get the test file - loadFromURL(u"ScAnnotationObj.ods"); + loadFromFile(u"ScAnnotationObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScAnnontationObj); diff --git a/sc/qa/extras/scannotationsobj.cxx b/sc/qa/extras/scannotationsobj.cxx index 8e711f8e9362..b81107e0571a 100644 --- a/sc/qa/extras/scannotationsobj.cxx +++ b/sc/qa/extras/scannotationsobj.cxx @@ -99,7 +99,7 @@ void ScAnnontationsObj::setUp() UnoApiTest::setUp(); // get the test file - loadFromURL(u"ScAnnotationObj.ods"); + loadFromFile(u"ScAnnotationObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScAnnontationsObj); diff --git a/sc/qa/extras/sccellcursorobj.cxx b/sc/qa/extras/sccellcursorobj.cxx index de237299275b..c2b861ccd1b5 100644 --- a/sc/qa/extras/sccellcursorobj.cxx +++ b/sc/qa/extras/sccellcursorobj.cxx @@ -202,7 +202,7 @@ void ScCellCursorObj::setUp() { UnoApiTest::setUp(); - loadFromURL(u"ScCellCursorObj.ods"); + loadFromFile(u"ScCellCursorObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScCellCursorObj); diff --git a/sc/qa/extras/sccellrangeobj.cxx b/sc/qa/extras/sccellrangeobj.cxx index c7635cb21022..5470ae757906 100644 --- a/sc/qa/extras/sccellrangeobj.cxx +++ b/sc/qa/extras/sccellrangeobj.cxx @@ -245,7 +245,7 @@ void ScCellRangeObj::setUp() { UnoApiTest::setUp(); - loadFromURL(u"xcellrangesquery.ods"); + loadFromFile(u"xcellrangesquery.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScCellRangeObj); diff --git a/sc/qa/extras/scdatabaserangeobj.cxx b/sc/qa/extras/scdatabaserangeobj.cxx index 178ce8e680b6..4ddc137e4b25 100644 --- a/sc/qa/extras/scdatabaserangeobj.cxx +++ b/sc/qa/extras/scdatabaserangeobj.cxx @@ -97,7 +97,7 @@ void ScDatabaseRangeObj::setUp() { UnoApiTest::setUp(); - loadFromURL(u"ScDatabaseRangeObj.ods"); + loadFromFile(u"ScDatabaseRangeObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScDatabaseRangeObj); diff --git a/sc/qa/extras/scdatapilotfieldobj.cxx b/sc/qa/extras/scdatapilotfieldobj.cxx index f7ead7940576..789bc5a5baab 100644 --- a/sc/qa/extras/scdatapilotfieldobj.cxx +++ b/sc/qa/extras/scdatapilotfieldobj.cxx @@ -109,7 +109,7 @@ void ScDataPilotFieldObj::setUp() { UnoApiTest::setUp(); - loadFromURL(u"scdatapilotfieldobj.ods"); + loadFromFile(u"scdatapilotfieldobj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotFieldObj); diff --git a/sc/qa/extras/scdatapilottableobj.cxx b/sc/qa/extras/scdatapilottableobj.cxx index 2a6bfa08ddd2..e0c66269f5f5 100644 --- a/sc/qa/extras/scdatapilottableobj.cxx +++ b/sc/qa/extras/scdatapilottableobj.cxx @@ -131,7 +131,7 @@ void ScDataPilotTableObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"ScDataPilotTableObj.ods"); + loadFromFile(u"ScDataPilotTableObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotTableObj); diff --git a/sc/qa/extras/scmodelobj.cxx b/sc/qa/extras/scmodelobj.cxx index 1c2d9c615f1c..1c57effa3a2d 100644 --- a/sc/qa/extras/scmodelobj.cxx +++ b/sc/qa/extras/scmodelobj.cxx @@ -105,7 +105,7 @@ void ScModelObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"ScModelObj.ods"); + loadFromFile(u"ScModelObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScModelObj); diff --git a/sc/qa/extras/scnamedrangeobj.cxx b/sc/qa/extras/scnamedrangeobj.cxx index 7bbd5e510b57..95cbf1c42fcd 100644 --- a/sc/qa/extras/scnamedrangeobj.cxx +++ b/sc/qa/extras/scnamedrangeobj.cxx @@ -92,7 +92,7 @@ void ScNamedRangeObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"ScNamedRangeObj.ods"); + loadFromFile(u"ScNamedRangeObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScNamedRangeObj); diff --git a/sc/qa/extras/scnamedrangesobj.cxx b/sc/qa/extras/scnamedrangesobj.cxx index f5415a0b914c..5ae53f42e07c 100644 --- a/sc/qa/extras/scnamedrangesobj.cxx +++ b/sc/qa/extras/scnamedrangesobj.cxx @@ -134,7 +134,7 @@ void ScNamedRangesObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"ScNamedRangeObj.ods"); + loadFromFile(u"ScNamedRangeObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScNamedRangesObj); diff --git a/sc/qa/extras/scoutlineobj.cxx b/sc/qa/extras/scoutlineobj.cxx index 4e20a9214760..fd442599850b 100644 --- a/sc/qa/extras/scoutlineobj.cxx +++ b/sc/qa/extras/scoutlineobj.cxx @@ -62,7 +62,7 @@ void ScOutlineObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"ScOutlineObj.ods"); + loadFromFile(u"ScOutlineObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScOutlineObj); diff --git a/sc/qa/extras/scpdfexport.cxx b/sc/qa/extras/scpdfexport.cxx index ca4a7b762f63..bcca563ec9b3 100644 --- a/sc/qa/extras/scpdfexport.cxx +++ b/sc/qa/extras/scpdfexport.cxx @@ -345,7 +345,7 @@ void ScPDFExportTest::testExportFitToPage_Tdf103516() void ScPDFExportTest::testUnoCommands_Tdf120161() { - loadFromURL(u"tdf120161.ods"); + loadFromFile(u"tdf120161.ods"); // A1:G1 { @@ -374,7 +374,7 @@ void ScPDFExportTest::testUnoCommands_Tdf120161() void ScPDFExportTest::testTdf64703_hiddenPageBreak() { - loadFromURL(u"tdf64703_hiddenPageBreak.ods"); + loadFromFile(u"tdf64703_hiddenPageBreak.ods"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); @@ -396,7 +396,7 @@ void ScPDFExportTest::testTdf143978() return; } - loadFromURL(u"tdf143978.ods"); + loadFromFile(u"tdf143978.ods"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); // A1:A2 @@ -504,7 +504,7 @@ void ScPDFExportTest::testTdf84012() return; } - loadFromURL(u"tdf84012.ods"); + loadFromFile(u"tdf84012.ods"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); // A1 @@ -539,7 +539,7 @@ void ScPDFExportTest::testTdf78897() return; } - loadFromURL(u"tdf78897.xls"); + loadFromFile(u"tdf78897.xls"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); // C3:D3 @@ -569,7 +569,7 @@ void ScPDFExportTest::testTdf78897() // just needs to not crash on export to pdf void ScPDFExportTest::testForcepoint97() { - loadFromURL(u"forcepoint97.xlsx"); + loadFromFile(u"forcepoint97.xlsx"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); // A1:H81 diff --git a/sc/qa/extras/screcordchanges.cxx b/sc/qa/extras/screcordchanges.cxx index 50774a8a0cb2..9e95e37d78da 100644 --- a/sc/qa/extras/screcordchanges.cxx +++ b/sc/qa/extras/screcordchanges.cxx @@ -62,7 +62,7 @@ void ScRecordChangesTest::testSetRecordChanges() void ScRecordChangesTest::testCheckRecordChangesProtection() { // test with protected changes - loadFromURL(u"RecordChangesProtected.ods"); + loadFromFile(u"RecordChangesProtected.ods"); uno::Reference<sheet::XSpreadsheetDocument> xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference<beans::XPropertySet> xDocSettingsPropSet(xDoc, UNO_QUERY_THROW); diff --git a/sc/qa/extras/sctablesheetobj.cxx b/sc/qa/extras/sctablesheetobj.cxx index 8b5b3dbaa056..1c4543af959d 100644 --- a/sc/qa/extras/sctablesheetobj.cxx +++ b/sc/qa/extras/sctablesheetobj.cxx @@ -354,7 +354,7 @@ OUString ScTableSheetObj::getFileURL() void ScTableSheetObj::setUp() { UnoApiTest::setUp(); - maFileURL = loadFromURL(u"ScTableSheetObj.ods"); + maFileURL = loadFromFile(u"ScTableSheetObj.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScTableSheetObj); diff --git a/sc/qa/extras/sctablesheetsobj.cxx b/sc/qa/extras/sctablesheetsobj.cxx index 59146a3e4b36..9fcd6d31e14a 100644 --- a/sc/qa/extras/sctablesheetsobj.cxx +++ b/sc/qa/extras/sctablesheetsobj.cxx @@ -141,7 +141,7 @@ void ScTableSheetsObj::setUp() { UnoApiTest::setUp(); // create a calc document - loadFromURL(u"rangenamessrc.ods"); + loadFromFile(u"rangenamessrc.ods"); } CPPUNIT_TEST_SUITE_REGISTRATION(ScTableSheetsObj); diff --git a/sc/qa/extras/vba-macro-test.cxx b/sc/qa/extras/vba-macro-test.cxx index 570d6520a92c..5dc6157b4304 100644 --- a/sc/qa/extras/vba-macro-test.cxx +++ b/sc/qa/extras/vba-macro-test.cxx @@ -56,7 +56,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSimpleCopyAndPaste) // Range(Cells(4, 3), Cells(6, 3)).Copy // Cells(4, 2).Activate // ActiveCell.PasteSpecial xlValues - loadFromURL(u"SimpleCopyPaste.xlsm"); + loadFromFile(u"SimpleCopyPaste.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -101,7 +101,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testMultiDocumentCopyAndPaste) // Cells(2, 2).Activate // ActiveCell.PasteSpecial xlValues // ... - loadFromURL(u"MultiDocumentCopyPaste.xlsm"); + loadFromFile(u"MultiDocumentCopyPaste.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -122,7 +122,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testMultiDocumentCopyAndPaste) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSheetAndColumnSelectAndHide) { - loadFromURL(u"SheetAndColumnSelectAndHide.xlsm"); + loadFromFile(u"SheetAndColumnSelectAndHide.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -185,7 +185,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testPrintArea) { // Sets the print area to A1:B5 // ActiveSheet.PageSetup.PrintArea = "$A$1:$B$5" - loadFromURL(u"VariousTestMacros.xlsm"); + loadFromFile(u"VariousTestMacros.xlsm"); uno::Reference<sheet::XSpreadsheetDocument> xDoc(mxComponent, uno::UNO_QUERY_THROW); uno::Reference<container::XIndexAccess> xIndex(xDoc->getSheets(), uno::UNO_QUERY_THROW); @@ -210,7 +210,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSelectAllChaged) { // Columns("A:A").Select // Range(Selection, Selection.End(xlToRight)).Select - loadFromURL(u"VariousTestMacros.xlsm"); + loadFromFile(u"VariousTestMacros.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); @@ -232,7 +232,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testRangeSelect) { // Range("B2").Select // Range(Selection, Selection.End(xlToRight)).Select - loadFromURL(u"VariousTestMacros.xlsm"); + loadFromFile(u"VariousTestMacros.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); @@ -255,7 +255,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testWindowState) // Application.WindowState = xlMinimized // Application.WindowState = xlMaximized // Application.WindowState = xlNormal - loadFromURL(u"VariousTestMacros.xlsm"); + loadFromFile(u"VariousTestMacros.xlsm"); executeMacro("vnd.sun.Star.script:VBAProject.ThisWorkbook.testWindowState?language=Basic&" "location=document"); @@ -266,7 +266,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testScroll) // ActiveWindow.ScrollColumn = 30 // ActiveWindow.ScrollRow = 100 - loadFromURL(u"VariousTestMacros.xlsm"); + loadFromFile(u"VariousTestMacros.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); @@ -292,7 +292,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testMacroKeyBinding) { // key_U() -> CTRL+U // key_T() -> CTRL+T - loadFromURL(u"KeyShortcut.xlsm"); + loadFromFile(u"KeyShortcut.xlsm"); uno::Reference<frame::XModel> xModel(mxComponent, uno::UNO_QUERY); CPPUNIT_ASSERT(xModel.is()); @@ -430,7 +430,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testVba) uno::Sequence<uno::Any> aParams; for (const auto& rTestInfo : testInfo) { - OUString aFileName = loadFromURL(rTestInfo.sFileBaseName); + OUString aFileName = loadFromFile(rTestInfo.sFileBaseName); // process all events such as OnLoad events etc. otherwise they tend // to arrive later at a random time - while processing other StarBasic @@ -551,7 +551,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testVbaRangeSort) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf107885) { - loadFromURL(u"tdf107885.xlsm"); + loadFromFile(u"tdf107885.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -586,7 +586,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf107885) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf131562) { - loadFromURL(u"tdf131562.xlsm"); + loadFromFile(u"tdf131562.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -607,7 +607,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf131562) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf52602) { - loadFromURL(u"tdf52602.xls"); + loadFromFile(u"tdf52602.xls"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -635,7 +635,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf52602) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf107902) { - loadFromURL(u"tdf107902.xlsm"); + loadFromFile(u"tdf107902.xlsm"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -663,7 +663,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf107902) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf90278) { - loadFromURL(u"tdf90278.xls"); + loadFromFile(u"tdf90278.xls"); // Without the fix in place, changing the border weight // would cause a Basic exception/error in the following script. @@ -678,7 +678,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf90278) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf149531) { - loadFromURL(u"tdf149531.xls"); + loadFromFile(u"tdf149531.xls"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -701,7 +701,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf149531) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testTdf118247) { - loadFromURL(u"tdf118247.xlsm"); + loadFromFile(u"tdf118247.xlsm"); uno::Any aRet = executeMacro( "vnd.sun.Star.script:VBAProject.Module1.testXlSpecialCellsValuesConstantsEmpty?" @@ -830,7 +830,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testVbaPDFExport) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testForEachInSelection) { - loadFromURL(u"ForEachInSelection.ods"); + loadFromFile(u"ForEachInSelection.ods"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); @@ -857,7 +857,7 @@ CPPUNIT_TEST_FIXTURE(VBAMacroTest, testForEachInSelection) CPPUNIT_TEST_FIXTURE(VBAMacroTest, testNonAsciiMacroIRI) { - loadFromURL(u"ForEachInSelection.ods"); + loadFromFile(u"ForEachInSelection.ods"); SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); diff --git a/sc/qa/perf/scperfobj.cxx b/sc/qa/perf/scperfobj.cxx index 00984eded77e..2cb0f6a3175d 100644 --- a/sc/qa/perf/scperfobj.cxx +++ b/sc/qa/perf/scperfobj.cxx @@ -106,7 +106,7 @@ ScPerfObj::ScPerfObj() void ScPerfObj::testSheetFindAll() { - loadFromURL(u"scBigFile.ods"); + loadFromFile(u"scBigFile.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); // get sheet @@ -160,7 +160,7 @@ void ScPerfObj::testSheetFindAll() void ScPerfObj::testSheetNamedRanges() { - loadFromURL(u"scBigFile.ods"); + loadFromFile(u"scBigFile.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); // get NamedRanges @@ -202,7 +202,7 @@ void ScPerfObj::testSheetNamedRanges() void ScPerfObj::testSheets() { - loadFromURL(u"scBigFile.ods"); + loadFromFile(u"scBigFile.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); // get getSheets @@ -228,7 +228,7 @@ void ScPerfObj::testSheets() void ScPerfObj::testSum() { - loadFromURL(u"scMathFunctions.ods"); + loadFromFile(u"scMathFunctions.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -267,7 +267,7 @@ void ScPerfObj::testSum() void ScPerfObj::testFTest() { - loadFromURL(u"scMathFunctions.ods"); + loadFromFile(u"scMathFunctions.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -291,7 +291,7 @@ void ScPerfObj::testFTest() void ScPerfObj::testChiTest() { - loadFromURL(u"scMathFunctions.ods"); + loadFromFile(u"scMathFunctions.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -315,7 +315,7 @@ void ScPerfObj::testChiTest() void ScPerfObj::testSumX2PY2Test() { - loadFromURL(u"scMathFunctions2.ods"); + loadFromFile(u"scMathFunctions2.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -339,7 +339,7 @@ void ScPerfObj::testSumX2PY2Test() void ScPerfObj::testTTest() { - loadFromURL(u"scMathFunctions2.ods"); + loadFromFile(u"scMathFunctions2.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -363,7 +363,7 @@ void ScPerfObj::testTTest() void ScPerfObj::testLcm() { - loadFromURL(u"scMathFunctions2.ods"); + loadFromFile(u"scMathFunctions2.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -387,7 +387,7 @@ void ScPerfObj::testLcm() void ScPerfObj::testGcd() { - loadFromURL(u"scMathFunctions2.ods"); + loadFromFile(u"scMathFunctions2.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -411,7 +411,7 @@ void ScPerfObj::testGcd() void ScPerfObj::testPearson() { - loadFromURL(u"scMathFunctions2.ods"); + loadFromFile(u"scMathFunctions2.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -435,7 +435,7 @@ void ScPerfObj::testPearson() void ScPerfObj::testSubTotalWithFormulas() { - loadFromURL(u"scBigSingleSheet200.ods"); + loadFromFile(u"scBigSingleSheet200.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -467,7 +467,7 @@ void ScPerfObj::testSubTotalWithFormulas() void ScPerfObj::testSubTotalWithoutFormulas() { - loadFromURL(u"scBigSingleSheet200.ods"); + loadFromFile(u"scBigSingleSheet200.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -500,7 +500,7 @@ void ScPerfObj::testSubTotalWithoutFormulas() void ScPerfObj::testLoadingFileWithSingleBigSheet() { callgrindStart(); - loadFromURL(u"scBigSingleSheet2000.ods"); + loadFromFile(u"scBigSingleSheet2000.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc1(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable1(xDoc1, UNO_QUERY_THROW); callgrindDump("sc:loadingFileWithSingleBigSheetdoSubTotal_2000lines"); @@ -534,7 +534,7 @@ namespace { void ScPerfObj::testFixedSum() { - loadFromURL(u"scMathFunctions3.ods"); + loadFromFile(u"scMathFunctions3.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -558,7 +558,7 @@ void ScPerfObj::testFixedSum() void ScPerfObj::testMatConcatSmall() { - loadFromURL(u"empty.ods"); + loadFromFile(u"empty.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); @@ -586,7 +586,7 @@ void ScPerfObj::testMatConcatSmall() void ScPerfObj::testMatConcatLarge() { - loadFromURL(u"empty.ods"); + loadFromFile(u"empty.ods"); uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW); uno::Reference< sheet::XCalculatable > xCalculatable(xDoc, UNO_QUERY_THROW); diff --git a/sc/qa/unit/SparklineImportExportTest.cxx b/sc/qa/unit/SparklineImportExportTest.cxx index 63f7867bc7fc..67b139052c82 100644 --- a/sc/qa/unit/SparklineImportExportTest.cxx +++ b/sc/qa/unit/SparklineImportExportTest.cxx @@ -147,7 +147,7 @@ void checkSparklines(ScDocument& rDocument) void SparklineImportExportTest::testSparklinesRoundtripXLSX() { - loadFromURL(u"xlsx/Sparklines.xlsx"); + loadFromFile(u"xlsx/Sparklines.xlsx"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -163,7 +163,7 @@ void SparklineImportExportTest::testSparklinesRoundtripXLSX() void SparklineImportExportTest::testSparklinesExportODS() { // Load the document containing sparklines - loadFromURL(u"xlsx/Sparklines.xlsx"); + loadFromFile(u"xlsx/Sparklines.xlsx"); // Save as ODS and check content.xml with XPath save("calc8"); @@ -213,7 +213,7 @@ void SparklineImportExportTest::testSparklinesExportODS() void SparklineImportExportTest::testSparklinesRoundtripODS() { - loadFromURL(u"xlsx/Sparklines.xlsx"); + loadFromFile(u"xlsx/Sparklines.xlsx"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -233,7 +233,7 @@ void SparklineImportExportTest::testNoSparklinesInDocumentXLSX() // Check no sparkline elements are written when there are none in the document // Load the document containing NO sparklines - loadFromURL(u"xlsx/empty.xlsx"); + loadFromFile(u"xlsx/empty.xlsx"); save("Calc Office Open XML"); xmlDocUniquePtr pXmlDoc = parseExport("xl/worksheets/sheet1.xml"); @@ -277,7 +277,7 @@ void checkSparklineThemeColors(ScDocument& rDocument) void SparklineImportExportTest::testSparklinesRoundtripThemeColorsODS() { - loadFromURL(u"fods/Sparklines.fods"); + loadFromFile(u"fods/Sparklines.fods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -292,7 +292,7 @@ void SparklineImportExportTest::testSparklinesRoundtripThemeColorsODS() void SparklineImportExportTest::testSparklinesRoundtripThemeColorsOOXML() { - loadFromURL(u"fods/Sparklines.fods"); + loadFromFile(u"fods/Sparklines.fods"); saveAndReload("Calc Office Open XML"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); diff --git a/sc/qa/unit/ThemeImportExportTest.cxx b/sc/qa/unit/ThemeImportExportTest.cxx index d8c7c468c368..9beb19ce2ee7 100644 --- a/sc/qa/unit/ThemeImportExportTest.cxx +++ b/sc/qa/unit/ThemeImportExportTest.cxx @@ -113,7 +113,7 @@ CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testThemeExportAndImport) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testThemeExportOOXML) { - loadFromURL(u"xlsx/CalcThemeTest.xlsx"); + loadFromFile(u"xlsx/CalcThemeTest.xlsx"); save("Calc Office Open XML"); @@ -219,7 +219,7 @@ void checkCellBackgroundThemeColor(ScDocument* pDoc) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBackgroundThemeColorOOXML) { - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); checkCellBackgroundThemeColor(getScDoc()); saveAndReload("Calc Office Open XML"); checkCellBackgroundThemeColor(getScDoc()); @@ -228,7 +228,7 @@ CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBackgroundThemeColorOOXML) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBackgroundThemeColorODF) { // Open the OOXML source - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); // Save as ODF and load again - checks import / export cycle saveAndReload("calc8"); // Check the values and show that the document is unchanged and all the data preserved @@ -290,7 +290,7 @@ void checkCellTextThemeColor(ScDocument* pDoc) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellTextThemeColor) { - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); checkCellTextThemeColor(getScDoc()); saveAndReload("Calc Office Open XML"); checkCellTextThemeColor(getScDoc()); @@ -299,7 +299,7 @@ CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellTextThemeColor) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellTextThemeColorODF) { // Open the OOXML source - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); // Save as ODF and load again - checks import / export cycle saveAndReload("calc8"); // Check the values and show that the document is unchanged and all the data preserved @@ -419,7 +419,7 @@ void checkCellBorderThemeColor(ScDocument* pDoc) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBorderThemeColor) { - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); checkCellBorderThemeColor(getScDoc()); saveAndReload("Calc Office Open XML"); checkCellBorderThemeColor(getScDoc()); @@ -428,7 +428,7 @@ CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBorderThemeColor) CPPUNIT_TEST_FIXTURE(ThemeImportExportTest, testCellBorderThemeColorODF) { // Open the OOXML source - loadFromURL(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); + loadFromFile(u"xlsx/Test_ThemeColor_Text_Background_Border.xlsx"); // Save as ODF and load again - checks import / export cycle saveAndReload("calc8"); // Check the values and show that the document is unchanged and all the data preserved diff --git a/sc/qa/unit/anchor.cxx b/sc/qa/unit/anchor.cxx index 789b6d777181..18daecd23aa1 100644 --- a/sc/qa/unit/anchor.cxx +++ b/sc/qa/unit/anchor.cxx @@ -65,7 +65,7 @@ ScAnchorTest::ScAnchorTest() void ScAnchorTest::testUndoAnchor() { - loadFromURL(u"document_with_linked_graphic.ods"); + loadFromFile(u"document_with_linked_graphic.ods"); // Get the document model SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -191,7 +191,7 @@ void ScAnchorTest::testTdf76183() void ScAnchorTest::testODFAnchorTypes() { - loadFromURL(u"3AnchorTypes.ods"); + loadFromFile(u"3AnchorTypes.ods"); // Get the document model SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -230,7 +230,7 @@ void ScAnchorTest::testODFAnchorTypes() /// Test that copying a column with an image anchored to it also copies the image void ScAnchorTest::testCopyColumnWithImages() { - loadFromURL(u"3AnchorTypes.ods"); + loadFromFile(u"3AnchorTypes.ods"); // Get the document model SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(mxComponent); @@ -296,7 +296,7 @@ void ScAnchorTest::testCopyColumnWithImages() void ScAnchorTest::testCutWithImages() { - loadFromURL(u"3AnchorTypes.ods"); + loadFromFile(u"3AnchorTypes.ods"); // open the document with graphic included // Get the document model @@ -350,7 +350,7 @@ void ScAnchorTest::testCutWithImages() void ScAnchorTest::testTdf121963() { - loadFromURL(u"tdf121963.ods"); + loadFromFile(u"tdf121963.ods"); // Without the accompanying fix in place, this test would have never returned due to an infinite // invalidation loop, where ScGridWindow::Paint() invalidated itself. @@ -359,7 +359,7 @@ void ScAnchorTest::testTdf121963() void ScAnchorTest::testTdf129552() { - loadFromURL(u"tdf129552.fods"); + loadFromFile(u"tdf129552.fods"); // Without the accompanying fix in place, this test would have never returned due to an infinite // invalidation loop, where ScGridWindow::Paint() invalidated itself. @@ -368,7 +368,7 @@ void ScAnchorTest::testTdf129552() void ScAnchorTest::testTdf130556() { - loadFromURL(u"tdf130556.ods"); + loadFromFile(u"tdf130556.ods"); // Without the accompanying fix in place, this test would have never returned due to an infinite // invalidation loop, where ScGridWindow::Paint() invalidated itself. @@ -377,7 +377,7 @@ void ScAnchorTest::testTdf130556() void ScAnchorTest::testTdf134161() { - loadFromURL(u"tdf134161.ods"); + loadFromFile(u"tdf134161.ods"); // Without the accompanying fix in place, this test would have never returned due to an infinite // invalidation loop diff --git a/sc/qa/unit/cond_format_merge.cxx b/sc/qa/unit/cond_format_merge.cxx index 5a33cccdbe01..ed6a938bb472 100644 --- a/sc/qa/unit/cond_format_merge.cxx +++ b/sc/qa/unit/cond_format_merge.cxx @@ -41,7 +41,7 @@ ScCondFormatMergeTest::ScCondFormatMergeTest() void ScCondFormatMergeTest::testCondFormatMerge() { - loadFromURL(u"cond_format_merge.ods"); + loadFromFile(u"cond_format_merge.ods"); // get the first sheet uno::Reference<sheet::XSpreadsheetDocument> xDoc(mxComponent, uno::UNO_QUERY_THROW); diff --git a/sc/qa/unit/copy_paste_test.cxx b/sc/qa/unit/copy_paste_test.cxx index 879c01844ba3..7ee2b1a72cc8 100644 --- a/sc/qa/unit/copy_paste_test.cxx +++ b/sc/qa/unit/copy_paste_test.cxx @@ -75,7 +75,7 @@ private: // tdf#83366 void ScCopyPasteTest::testCopyPasteXLS() { - loadFromURL(u"xls/chartx2.xls"); + loadFromFile(u"xls/chartx2.xls"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -315,7 +315,7 @@ static ScAddress lcl_getMergeSizeOfCell(const ScDocument& rDoc, SCCOL nCol, SCRO void ScCopyPasteTest::testTdf53431_fillOnAutofilter() { - loadFromURL(u"ods/tdf53431_autofilterFilldown.ods"); + loadFromFile(u"ods/tdf53431_autofilterFilldown.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -376,7 +376,7 @@ void ScCopyPasteTest::testTdf53431_fillOnAutofilter() void ScCopyPasteTest::testTdf40993_fillMergedCells() { - loadFromURL(u"ods/tdf40993_fillMergedCells.ods"); + loadFromFile(u"ods/tdf40993_fillMergedCells.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -464,7 +464,7 @@ static void lcl_clickAndCheckCurrentArea(SCCOL nCol, SCROW nRow, SCCOL nCol2, SC void ScCopyPasteTest::testTdf43958_clickSelectOnMergedCells() { - loadFromURL(u"ods/tdf40993_fillMergedCells.ods"); + loadFromFile(u"ods/tdf40993_fillMergedCells.ods"); // select cell (e.g. by clicking on it) and check what is selected [but not marked]: // if it is the top left cell of a merged area, the selection is enlarged to the area @@ -485,7 +485,7 @@ void ScCopyPasteTest::testTdf43958_clickSelectOnMergedCells() void ScCopyPasteTest::testTdf88782_autofillLinearNumbersInMergedCells() { - loadFromURL(u"ods/tdf88782_AutofillLinearNumbersInMergedCells.ods"); + loadFromFile(u"ods/tdf88782_AutofillLinearNumbersInMergedCells.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -547,7 +547,7 @@ void ScCopyPasteTest::testTdf88782_autofillLinearNumbersInMergedCells() void ScCopyPasteTest::tdf137621_autofillMergedBool() { - loadFromURL(u"ods/tdf137621_autofillMergedBool.ods"); + loadFromFile(u"ods/tdf137621_autofillMergedBool.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -580,7 +580,7 @@ void ScCopyPasteTest::tdf137621_autofillMergedBool() void ScCopyPasteTest::tdf137205_autofillDatesInMergedCells() { - loadFromURL(u"ods/tdf137205_AutofillDatesInMergedCells.ods"); + loadFromFile(u"ods/tdf137205_AutofillDatesInMergedCells.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -618,7 +618,7 @@ void ScCopyPasteTest::addToUserList(const OUString& rStr) void ScCopyPasteTest::tdf137653_137654_autofillUserlist() { - loadFromURL(u"ods/tdf137653_137654_autofillUserlist.ods"); + loadFromFile(u"ods/tdf137653_137654_autofillUserlist.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -678,7 +678,7 @@ void ScCopyPasteTest::tdf137653_137654_autofillUserlist() void ScCopyPasteTest::tdf113500_autofillMixed() { - loadFromURL(u"ods/tdf113500_autofillMixed.ods"); + loadFromFile(u"ods/tdf113500_autofillMixed.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -728,7 +728,7 @@ void ScCopyPasteTest::tdf113500_autofillMixed() void ScCopyPasteTest::tdf137625_autofillMergedUserlist() { - loadFromURL(u"ods/tdf137625_autofillMergedUserlist.ods"); + loadFromFile(u"ods/tdf137625_autofillMergedUserlist.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); @@ -788,7 +788,7 @@ void ScCopyPasteTest::tdf137625_autofillMergedUserlist() void ScCopyPasteTest::tdf137624_autofillMergedMixed() { - loadFromURL(u"ods/tdf137624_autofillMergedMixed.ods"); + loadFromFile(u"ods/tdf137624_autofillMergedMixed.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); ScDocument* pDoc = pModelObj->GetDocument(); diff --git a/sc/qa/unit/helper/qahelper.cxx b/sc/qa/unit/helper/qahelper.cxx index 23ddf5271fc4..4dc09a65de6e 100644 --- a/sc/qa/unit/helper/qahelper.cxx +++ b/sc/qa/unit/helper/qahelper.cxx @@ -574,7 +574,7 @@ void ScModelTestBase::createScDoc(const char* pName, const char* pPassword, bool if (!pName) load("private:factory/scalc"); else - loadFromURL(OUString::createFromAscii(pName), pPassword); + loadFromFile(OUString::createFromAscii(pName), pPassword); uno::Reference<lang::XServiceInfo> xServiceInfo(mxComponent, uno::UNO_QUERY_THROW); CPPUNIT_ASSERT(xServiceInfo->supportsService("com.sun.star.sheet.SpreadsheetDocument")); @@ -620,7 +620,7 @@ void ScModelTestBase::miscRowHeightsTest( TestParam const * aTestValues, unsigne { const std::u16string_view sFileName = aTestValues[ index ].sTestDoc; const OUString sExportType = aTestValues[ index ].sExportType; - loadFromURL(sFileName); + loadFromFile(sFileName); if ( !sExportType.isEmpty() ) saveAndReload(sExportType); diff --git a/sc/qa/unit/jumbosheets-test.cxx b/sc/qa/unit/jumbosheets-test.cxx index e3bba0717a86..d4cdb18678b1 100644 --- a/sc/qa/unit/jumbosheets-test.cxx +++ b/sc/qa/unit/jumbosheets-test.cxx @@ -86,7 +86,7 @@ void ScJumboSheetsTest::testRoundtripColumn2000Xlsx() void ScJumboSheetsTest::testRoundtripColumn2000(std::u16string_view name, const char* format) { - loadFromURL(name); + loadFromFile(name); { ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -116,7 +116,7 @@ void ScJumboSheetsTest::testRoundtripColumn2000(std::u16string_view name, const void ScJumboSheetsTest::testRoundtripColumnRangeOds() { - loadFromURL(u"ods/sum-whole-column-row.ods"); + loadFromFile(u"ods/sum-whole-column-row.ods"); { ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -150,7 +150,7 @@ void ScJumboSheetsTest::testRoundtripColumnRangeOds() void ScJumboSheetsTest::testRoundtripColumnRangeXlsx() { - loadFromURL(u"ods/sum-whole-column-row.ods"); + loadFromFile(u"ods/sum-whole-column-row.ods"); saveAndReload("Calc Office Open XML"); { ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); @@ -170,7 +170,7 @@ void ScJumboSheetsTest::testRoundtripColumnRangeXlsx() void ScJumboSheetsTest::testRoundtripNamedRanges(std::u16string_view name, const char* format) { - loadFromURL(name); + loadFromFile(name); std::pair<OUString, OUString> ranges[] = { { "CELLBXX1", "$Sheet1.$BXX$1" }, { "CELLSA4_AMJ4", "$Sheet1.$A$4:$AMJ$4" }, @@ -220,7 +220,7 @@ void ScJumboSheetsTest::testNamedRangeNameConflict() { // The document contains named ranges named 'num1' and 'num2', that should be still treated // as named references even though with 16k columns those are normally NUM1 and NUM2 cells. - loadFromURL(u"ods/named-range-conflict.ods"); + loadFromFile(u"ods/named-range-conflict.ods"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -242,7 +242,7 @@ void ScJumboSheetsTest::testNamedRangeNameConflict() void ScJumboSheetsTest::testTdf134553() { - loadFromURL(u"xlsx/tdf134553.xlsx"); + loadFromFile(u"xlsx/tdf134553.xlsx"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -292,7 +292,7 @@ void ScJumboSheetsTest::testTdf134553() void ScJumboSheetsTest::testTdf134392() { // Without the fix in place, the file would have crashed - loadFromURL(u"xlsx/tdf134392.xlsx"); + loadFromFile(u"xlsx/tdf134392.xlsx"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -343,7 +343,7 @@ void ScJumboSheetsTest::testTdf133033() void ScJumboSheetsTest::testTdf109061() { // Without the fix in place, the file would have crashed - loadFromURL(u"xlsx/tdf109061.xlsx"); + loadFromFile(u"xlsx/tdf109061.xlsx"); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); diff --git a/sc/qa/unit/subsequent_filters_test2.cxx b/sc/qa/unit/subsequent_filters_test2.cxx index 31dae9282166..b0042d9878d6 100644 --- a/sc/qa/unit/subsequent_filters_test2.cxx +++ b/sc/qa/unit/subsequent_filters_test2.cxx @@ -1253,7 +1253,7 @@ CPPUNIT_TEST_FIXTURE(ScFiltersTest2, testUnicodeFileNameGnumeric) { return; } - loadFromURL(u"gnumeric/t\u00E4\u00DFt.gnumeric"); + loadFromFile(u"gnumeric/t\u00E4\u00DFt.gnumeric"); } CPPUNIT_TEST_FIXTURE(ScFiltersTest2, testMergedCellsXLSXML) diff --git a/sc/qa/unit/tiledrendering/tiledrendering.cxx b/sc/qa/unit/tiledrendering/tiledrendering.cxx index 8446f07fc3b9..5548dc06fbdf 100644 --- a/sc/qa/unit/tiledrendering/tiledrendering.cxx +++ b/sc/qa/unit/tiledrendering/tiledrendering.cxx @@ -113,7 +113,7 @@ void ScTiledRenderingTest::tearDown() ScModelObj* ScTiledRenderingTest::createDoc(const char* pName) { - loadFromURL(OUString::createFromAscii(pName)); + loadFromFile(OUString::createFromAscii(pName)); ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>(mxComponent); CPPUNIT_ASSERT(pModelObj); @@ -2831,7 +2831,7 @@ CPPUNIT_TEST_FIXTURE(ScTiledRenderingTest, testCommentCellCopyPaste) CPPUNIT_TEST_FIXTURE(ScTiledRenderingTest, testInvalidEntrySave) { - loadFromURL(u"validity.xlsx"); + loadFromFile(u"validity.xlsx"); // .uno:Save modifies the original file, make a copy first saveAndReload("Calc Office Open XML"); |