diff options
author | Noel Power <noel.power@suse.com> | 2013-03-06 16:34:44 +0000 |
---|---|---|
committer | Noel Power <noel.power@suse.com> | 2013-03-07 09:21:32 +0000 |
commit | 5eb1628b67c11d32158c2e4a63dc2f1614be4c7c (patch) | |
tree | 03b6c216f46c227e9495bd0477c062e65edaf7fa /sc | |
parent | 895898596c72fd14db2abec3aeaab74d583769e5 (diff) |
enable bag load of excel specific VBA api tests
Note: some of the test documents have some tests disabled in order to run
without errors, these are identified by the following lines
Rem [#FIXME disabled 3.6 ] in the macro source.
note: some of these errors are expected and were always happening, some
errors e.g. those pastespecial specific ones in
qa/unit/data/xls/TestCalc_Rangetest2.xls
seem to be to do with problems with the test harness.
note: there are some others ( e.g. in Window.xls & windows2.xls ) that seem
to be related to hard sizes and screen resolution ( these should be adjusted
sensibly )
Change-Id: I07a43a2802d4e1794ac2f8c648f666b5bcd13a04
Diffstat (limited to 'sc')
19 files changed, 76 insertions, 1 deletions
diff --git a/sc/CppunitTest_sc_macros_test.mk b/sc/CppunitTest_sc_macros_test.mk index f989dcf5f851..e5ca56cb61dc 100644 --- a/sc/CppunitTest_sc_macros_test.mk +++ b/sc/CppunitTest_sc_macros_test.mk @@ -112,6 +112,7 @@ $(eval $(call gb_CppunitTest_use_components,sc_macros_test,\ sot/util/sot \ svl/source/fsstor/fsstorage \ svtools/util/svt \ + svx/util/svx \ toolkit/util/tk \ ucb/source/core/ucb1 \ ucb/source/ucp/file/ucpfile1 \ @@ -120,6 +121,8 @@ $(eval $(call gb_CppunitTest_use_components,sc_macros_test,\ unoxml/source/rdf/unordf \ unoxml/source/service/unoxml \ xmloff/util/xo \ + eventattacher/source/evtatt \ + i18npool/source/search/i18nsearch \ )) $(eval $(call gb_CppunitTest_use_configuration,sc_macros_test)) diff --git a/sc/qa/extras/macros-test.cxx b/sc/qa/extras/macros-test.cxx index 244c61accb86..389ddc1cc346 100644 --- a/sc/qa/extras/macros-test.cxx +++ b/sc/qa/extras/macros-test.cxx @@ -115,7 +115,77 @@ void ScMacrosTest::testVba() { rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vba.")), rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.Modul1.Modul1?language=Basic&location=document")), - } + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MiscRangeTests.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("bytearraystring.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacro.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AutoFilter.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CalcFont.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TestIntersection.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TestUnion.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("range-4.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Ranges-3.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TestCalc_Rangetest.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TestCalc_Rangetest2.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Ranges-2.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("pagesetup.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Window.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("window2.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PageBreaks.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Shapes.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, +#if VBA_TEST_WORKING + { + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Ranges.")), + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.Star.script:VBAProject.testMacros.test?language=Basic&location=document")) + }, +#endif }; for ( sal_uInt32 i=0; i<SAL_N_ELEMENTS( testInfo ); ++i ) @@ -135,6 +205,8 @@ void ScMacrosTest::testVba() SfxObjectShell* pFoundShell = SfxObjectShell::GetShellFromComponent(xComponent); CPPUNIT_ASSERT_MESSAGE("Failed to access document shell", pFoundShell); + std::cout << "about to invoke vba test in " << rtl::OUStringToOString( aFileName, RTL_TEXTENCODING_UTF8 ).getStr() << std::endl; + pFoundShell->CallXScript(xComponent, sUrl, aParams, aRet, aOutParamIndex,aOutParam); rtl::OUString aStringRes; aRet >>= aStringRes; diff --git a/sc/qa/extras/testdocuments/AutoFilter.xls b/sc/qa/extras/testdocuments/AutoFilter.xls Binary files differnew file mode 100644 index 000000000000..75efd8ddc609 --- /dev/null +++ b/sc/qa/extras/testdocuments/AutoFilter.xls diff --git a/sc/qa/extras/testdocuments/CalcFont.xls b/sc/qa/extras/testdocuments/CalcFont.xls Binary files differnew file mode 100644 index 000000000000..86304063c45a --- /dev/null +++ b/sc/qa/extras/testdocuments/CalcFont.xls diff --git a/sc/qa/extras/testdocuments/MiscRangeTests.xls b/sc/qa/extras/testdocuments/MiscRangeTests.xls Binary files differnew file mode 100644 index 000000000000..c6dffd475442 --- /dev/null +++ b/sc/qa/extras/testdocuments/MiscRangeTests.xls diff --git a/sc/qa/extras/testdocuments/PageBreaks.xls b/sc/qa/extras/testdocuments/PageBreaks.xls Binary files differnew file mode 100644 index 000000000000..2affd99ffda1 --- /dev/null +++ b/sc/qa/extras/testdocuments/PageBreaks.xls diff --git a/sc/qa/extras/testdocuments/Ranges-2.xls b/sc/qa/extras/testdocuments/Ranges-2.xls Binary files differnew file mode 100644 index 000000000000..84fdc45c0dfb --- /dev/null +++ b/sc/qa/extras/testdocuments/Ranges-2.xls diff --git a/sc/qa/extras/testdocuments/Ranges-3.xls b/sc/qa/extras/testdocuments/Ranges-3.xls Binary files differnew file mode 100644 index 000000000000..e68f6a84d6d9 --- /dev/null +++ b/sc/qa/extras/testdocuments/Ranges-3.xls diff --git a/sc/qa/extras/testdocuments/Ranges.xls b/sc/qa/extras/testdocuments/Ranges.xls Binary files differnew file mode 100644 index 000000000000..cc12d3fa6787 --- /dev/null +++ b/sc/qa/extras/testdocuments/Ranges.xls diff --git a/sc/qa/extras/testdocuments/Shapes.xls b/sc/qa/extras/testdocuments/Shapes.xls Binary files differnew file mode 100644 index 000000000000..ff15272f8f87 --- /dev/null +++ b/sc/qa/extras/testdocuments/Shapes.xls diff --git a/sc/qa/extras/testdocuments/TestCalc_Rangetest.xls b/sc/qa/extras/testdocuments/TestCalc_Rangetest.xls Binary files differnew file mode 100644 index 000000000000..9c00f5522c80 --- /dev/null +++ b/sc/qa/extras/testdocuments/TestCalc_Rangetest.xls diff --git a/sc/qa/extras/testdocuments/TestCalc_Rangetest2.xls b/sc/qa/extras/testdocuments/TestCalc_Rangetest2.xls Binary files differnew file mode 100644 index 000000000000..409459df646f --- /dev/null +++ b/sc/qa/extras/testdocuments/TestCalc_Rangetest2.xls diff --git a/sc/qa/extras/testdocuments/TestIntersection.xls b/sc/qa/extras/testdocuments/TestIntersection.xls Binary files differnew file mode 100644 index 000000000000..5872be7ca1ba --- /dev/null +++ b/sc/qa/extras/testdocuments/TestIntersection.xls diff --git a/sc/qa/extras/testdocuments/TestUnion.xls b/sc/qa/extras/testdocuments/TestUnion.xls Binary files differnew file mode 100644 index 000000000000..bde207e7462d --- /dev/null +++ b/sc/qa/extras/testdocuments/TestUnion.xls diff --git a/sc/qa/extras/testdocuments/Window.xls b/sc/qa/extras/testdocuments/Window.xls Binary files differnew file mode 100644 index 000000000000..3daebfb99b95 --- /dev/null +++ b/sc/qa/extras/testdocuments/Window.xls diff --git a/sc/qa/extras/testdocuments/bytearraystring.xls b/sc/qa/extras/testdocuments/bytearraystring.xls Binary files differnew file mode 100644 index 000000000000..22da6de48408 --- /dev/null +++ b/sc/qa/extras/testdocuments/bytearraystring.xls diff --git a/sc/qa/extras/testdocuments/pagesetup.xls b/sc/qa/extras/testdocuments/pagesetup.xls Binary files differnew file mode 100644 index 000000000000..b1f0b9cba008 --- /dev/null +++ b/sc/qa/extras/testdocuments/pagesetup.xls diff --git a/sc/qa/extras/testdocuments/range-4.xls b/sc/qa/extras/testdocuments/range-4.xls Binary files differnew file mode 100644 index 000000000000..67d1ad7aa69a --- /dev/null +++ b/sc/qa/extras/testdocuments/range-4.xls diff --git a/sc/qa/extras/testdocuments/window2.xls b/sc/qa/extras/testdocuments/window2.xls Binary files differnew file mode 100644 index 000000000000..1c84a13d6804 --- /dev/null +++ b/sc/qa/extras/testdocuments/window2.xls |