summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Lange [tl] <tl@openoffice.org>2010-06-09 14:50:43 +0200
committerThomas Lange [tl] <tl@openoffice.org>2010-06-09 14:50:43 +0200
commit993e061ea4e17b9bda45ff4ce83d5892c24ba01b (patch)
tree0f5eabc2e1a106f3815a6c0fd7d5758db6bfbfc9
parent37f107ae85b6a289085ae821ae109ff7d10e44fb (diff)
parentc4e66fc76f75424f60c2adcdb31e509314c49b5b (diff)
cws tl74: merge with DEV300_m81
-rw-r--r--qadevOOo/prj/build.lst1
-rw-r--r--qadevOOo/qa/unoapi/Test.java51
-rwxr-xr-xqadevOOo/qa/unoapi/makefile.mk30
-rw-r--r--qadevOOo/runner/base/java_fat.java13
-rw-r--r--qadevOOo/runner/basicrunner/BasicTestCase.java5
-rw-r--r--qadevOOo/runner/convwatch/OfficePrint.java65
-rw-r--r--qadevOOo/runner/graphical/BuildID.java6
-rw-r--r--qadevOOo/runner/graphical/DirectoryHelper.java6
-rw-r--r--qadevOOo/runner/graphical/EnhancedComplexTestCase.java52
-rw-r--r--qadevOOo/runner/graphical/FileHelper.java30
-rw-r--r--qadevOOo/runner/graphical/GlobalLogWriter.java17
-rw-r--r--qadevOOo/runner/graphical/HTMLResult.java2
-rw-r--r--qadevOOo/runner/graphical/IDocument.java2
-rw-r--r--qadevOOo/runner/graphical/IniFile.java47
-rw-r--r--qadevOOo/runner/graphical/JPEGComparator.java482
-rw-r--r--qadevOOo/runner/graphical/JPEGCreator.java53
-rw-r--r--qadevOOo/runner/graphical/MSOfficePostscriptCreator.java95
-rw-r--r--qadevOOo/runner/graphical/Office.java1
-rw-r--r--qadevOOo/runner/graphical/OpenOfficeDatabaseReportExtractor.java180
-rw-r--r--qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java280
-rw-r--r--qadevOOo/runner/graphical/ParameterHelper.java16
-rw-r--r--qadevOOo/runner/graphical/PerformanceContainer.java18
-rw-r--r--qadevOOo/runner/graphical/PropertyName.java2
-rw-r--r--qadevOOo/runner/graphical/TimeHelper.java45
-rw-r--r--qadevOOo/runner/graphical/Tolerance.java23
-rw-r--r--qadevOOo/runner/graphical/makefile.mk3
-rw-r--r--qadevOOo/runner/helper/ClParser.java4
-rw-r--r--qadevOOo/runner/helper/OfficeProvider.java30
-rw-r--r--qadevOOo/runner/lib/TestCase.java20
-rw-r--r--qadevOOo/runner/lib/TestEnvironment.java8
-rw-r--r--qadevOOo/runner/org/openoffice/Runner.java12
-rw-r--r--qadevOOo/runner/util/AccessibilityTools.java13
-rw-r--r--qadevOOo/runner/util/UITools.java20
-rw-r--r--qadevOOo/runner/util/utils.java69
-rw-r--r--qadevOOo/tests/java/ifc/accessibility/_XAccessibleComponent.java39
-rw-r--r--qadevOOo/tests/java/ifc/accessibility/_XAccessibleContext.java3
-rw-r--r--qadevOOo/tests/java/ifc/awt/_XMessageBoxFactory.java136
-rw-r--r--qadevOOo/tests/java/ifc/awt/_XSystemChildFactory.java40
-rw-r--r--qadevOOo/tests/java/ifc/awt/_XToolkit.java5
-rw-r--r--qadevOOo/tests/java/ifc/beans/_XMultiPropertyStates.java7
-rw-r--r--qadevOOo/tests/java/ifc/beans/_XPropertySet.java17
-rw-r--r--qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java19
-rw-r--r--qadevOOo/tests/java/ifc/sheet/_XRangeSelection.java6
-rw-r--r--qadevOOo/tests/java/mod/_basctl/AccessibleShape.java20
-rw-r--r--qadevOOo/tests/java/mod/_dbaccess/ConnectionLineAccessibility.java10
-rw-r--r--qadevOOo/tests/java/mod/_dbaccess/JoinViewAccessibility.java10
-rw-r--r--qadevOOo/tests/java/mod/_dbaccess/ORowSet.java2
-rw-r--r--qadevOOo/tests/java/mod/_dbaccess/TableWindowAccessibility.java10
-rw-r--r--qadevOOo/tests/java/mod/_forms/ODatabaseForm.java2
-rwxr-xr-xqadevOOo/tests/java/mod/_fwk/ModuleUIConfigurationManager.java23
-rw-r--r--qadevOOo/tests/java/mod/_sd/DrawController_DrawView.java26
-rw-r--r--qadevOOo/tests/java/mod/_sfx/StandaloneDocumentInfo.java2
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBox.java15
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderBar.java14
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderCell.java15
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTable.java16
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTableCell.java20
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleTabBar.java17
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBox.java16
-rw-r--r--qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBoxEntry.java16
-rwxr-xr-xqadevOOo/tests/java/mod/_sw/CharacterStyle.java6
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleFixedText.java9
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleMenu.java20
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleMenuBar.java24
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleMenuSeparator.java21
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleStatusBar.java29
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/AccessibleToolBox.java16
-rw-r--r--qadevOOo/tests/java/mod/_toolkit/UnoTreeControl.java22
-rwxr-xr-xsmoketestoo_native/config.pl83
-rwxr-xr-xsmoketestoo_native/data/TestExtension.oxtbin4210 -> 0 bytes
-rw-r--r--smoketestoo_native/data/dbgsv.ini42
-rwxr-xr-xsmoketestoo_native/data/scripts/Global.xba739
-rwxr-xr-xsmoketestoo_native/data/scripts/Test_10er.xba907
-rwxr-xr-xsmoketestoo_native/data/scripts/Test_DB.xba135
-rwxr-xr-xsmoketestoo_native/data/scripts/Test_Ext.xba95
-rwxr-xr-xsmoketestoo_native/data/scripts/script.xlb8
-rwxr-xr-xsmoketestoo_native/data/smoketestdoc.sxwbin35157 -> 35550 bytes
-rw-r--r--smoketestoo_native/data/solaris/sparc/admin6
-rwxr-xr-xsmoketestoo_native/data/solaris/sparc/getuid.sobin4108 -> 0 bytes
-rw-r--r--smoketestoo_native/data/solaris/x86/admin6
-rwxr-xr-xsmoketestoo_native/data/solaris/x86/getuid.sobin3796 -> 0 bytes
-rw-r--r--smoketestoo_native/makefile.mk60
-rw-r--r--smoketestoo_native/prj/build.lst2
-rw-r--r--smoketestoo_native/smoketest.cxx169
-rwxr-xr-xsmoketestoo_native/smoketest.pl1279
-rwxr-xr-xsmoketestoo_native/testlog.pl286
-rw-r--r--smoketestoo_native/version.map (renamed from testtools/source/bridgetest/component.map)6
-rw-r--r--test/inc/makefile.mk (renamed from testshl2/util/makefile.mk)24
-rw-r--r--test/inc/pch/precompiled_test.cxx26
-rw-r--r--test/inc/pch/precompiled_test.hxx30
-rw-r--r--test/inc/test/detail/testdllapi.hxx39
-rw-r--r--test/inc/test/getargument.hxx44
-rw-r--r--test/inc/test/officeconnection.hxx65
-rw-r--r--test/inc/test/oustringostreaminserter.hxx48
-rw-r--r--test/inc/test/toabsolutefileurl.hxx44
-rw-r--r--test/prj/build.lst4
-rw-r--r--test/prj/d.lst12
-rw-r--r--test/source/cpp/getargument.cxx42
-rw-r--r--test/source/cpp/makefile.mk (renamed from testshl2/workben/skeleton/makefile.mk)48
-rw-r--r--test/source/cpp/officeconnection.cxx173
-rw-r--r--test/source/cpp/toabsolutefileurl.cxx83
-rw-r--r--test/source/java/OfficeConnection.java221
-rw-r--r--test/source/java/makefile.mk (renamed from testshl2/workben/codegen/makefile.mk)38
-rwxr-xr-x[-rw-r--r--]testautomation/chart2/optional/includes/ch2_lvl1a.inc4
-rwxr-xr-x[-rw-r--r--]testautomation/chart2/tools/ch_tools_select.inc2
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/optional/includes/ctrl_Several1.inc2
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/optional/includes/ctrl_Several2.inc9
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/optional/includes/db_Relations.inc14
-rwxr-xr-xtestautomation/dbaccess/optional/includes/frm_FormFilter.inc6
-rwxr-xr-xtestautomation/dbaccess/optional/includes/wiz_DatabaseWizard.inc31
-rwxr-xr-xtestautomation/dbaccess/required/includes/MainApp.inc5
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/required/includes/Query.inc7
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/required/includes/Table.inc5
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/required/includes/TableDesign.inc5
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/tools/formtools.inc2
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/tools/reporttools.inc12
-rwxr-xr-x[-rw-r--r--]testautomation/dbaccess/tools/tabletools.inc9
-rwxr-xr-xtestautomation/extensions/optional/e_issues.bas55
-rw-r--r--testautomation/extensions/optional/e_taskpane.bas49
-rw-r--r--testautomation/extensions/optional/includes/e_taskpane.inc74
-rwxr-xr-xtestautomation/extensions/optional/includes/issue110083.inc79
-rwxr-xr-x[-rw-r--r--]testautomation/extensions/optional/includes/platforms.inc2
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/build.xml72
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-impl.xml794
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-uno-impl.xml462
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/genfiles.properties8
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/config.properties0
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/private.properties6
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project-uno.properties18
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.properties67
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.xml14
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu23
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/Factories.xcu35
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/CentralRegistrationClass.java140
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/TaskPaneComponent.java116
-rwxr-xr-x[-rw-r--r--]testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanel.java (renamed from testshl2/workben/dlltest/onefunc.cxx)41
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanelUIElement.java153
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/description.xml5
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/toolpanels/TaskPaneComponentUI.xdl8
-rwxr-xr-xtestautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/uno-extension-manifest.xml9
-rwxr-xr-xtestautomation/extensions/optional/input/extensions/TaskPaneComponent/TaskPaneComponent.oxtbin0 -> 9884 bytes
-rwxr-xr-xtestautomation/extensions/optional/input/issues/Logging.xcu24
-rw-r--r--testautomation/extensions/optional/input/issues/LoggingOptions.xcs19
-rwxr-xr-xtestautomation/framework/optional/f_basic_vba-compat.bas10
-rwxr-xr-x[-rw-r--r--]testautomation/framework/optional/includes/CJK_CollationDialogue_1.inc16
-rwxr-xr-x[-rw-r--r--]testautomation/framework/optional/includes/CJK_RubyDialogueProposal_1.inc2
-rwxr-xr-x[-rw-r--r--]testautomation/framework/optional/includes/basic_gridcontrol.inc74
-rwxr-xr-x[-rw-r--r--]testautomation/framework/optional/includes/basic_issues.inc106
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_application-union.inc132
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_import_disabled.inc33
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_import_enabled.inc76
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_import_nothing.inc35
-rw-r--r--testautomation/framework/optional/includes/basic_vba-compat_security_check.inc105
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_thisworkbook.inc143
-rwxr-xr-xtestautomation/framework/optional/includes/basic_vba-compat_xlsm-xlsb.inc187
-rwxr-xr-x[-rw-r--r--]testautomation/framework/optional/includes/configuration.inc13
-rwxr-xr-xtestautomation/framework/optional/input/gridcontrol.odtbin11602 -> 12000 bytes
-rw-r--r--testautomation/framework/optional/input/vba-compat/Book1.xlsbin0 -> 18432 bytes
-rwxr-xr-xtestautomation/framework/optional/input/vba-compat/vba-application-union.xlsbin0 -> 31744 bytes
-rwxr-xr-xtestautomation/framework/optional/input/vba-compat/vba-project.xlsbbin0 -> 19603 bytes
-rwxr-xr-xtestautomation/framework/optional/input/vba-compat/vba-project.xlsmbin0 -> 20276 bytes
-rw-r--r--testautomation/framework/optional/input/vba-compat/vba-thisworkbook.xlsbin0 -> 39424 bytes
-rwxr-xr-x[-rw-r--r--]testautomation/framework/required/includes/printer_administration.inc42
-rwxr-xr-x[-rw-r--r--]testautomation/framework/tools/includes/CJK_tools.inc17
-rwxr-xr-xtestautomation/framework/tools/input/i18ndata.txt2
-rwxr-xr-xtestautomation/global/input/macros.txt45
-rw-r--r--testautomation/global/input/officeinfo.txt4
-rw-r--r--[-rwxr-xr-x]testautomation/global/sid/e_all.sid2
-rwxr-xr-xtestautomation/global/system/includes/iniinfo.inc24
-rwxr-xr-xtestautomation/global/system/includes/master.inc29
-rwxr-xr-x[-rw-r--r--]testautomation/global/system/includes/status.inc3
-rwxr-xr-x[-rw-r--r--]testautomation/global/tools/includes/optional/t_extension_manager_tools.inc4
-rwxr-xr-x[-rw-r--r--]testautomation/global/tools/includes/optional/t_locale_strings1.inc28
-rwxr-xr-x[-rw-r--r--]testautomation/global/tools/includes/optional/t_toolbar_tools1.inc17
-rwxr-xr-x[-rw-r--r--]testautomation/global/tools/includes/optional/t_treelist_tools.inc10
-rwxr-xr-x[-rw-r--r--]testautomation/global/tools/includes/required/t_doc2.inc22
-rwxr-xr-xtestautomation/global/win/dial_d_h.win6
-rwxr-xr-xtestautomation/global/win/dial_t_z.win4
-rwxr-xr-xtestautomation/global/win/edia_d_h.win4
-rw-r--r--testautomation/global/win/edia_p_s.win3
-rwxr-xr-xtestautomation/global/win/edia_t_z.win6
-rwxr-xr-xtestautomation/global/win/spadmin.win1
-rwxr-xr-xtestautomation/global/win/tab_a_d.win1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_accessability.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_convertto.bas145
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_crossfading.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_customshapes.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_group.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_line.bas2
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_ole.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/g_savepictureas.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/i_animation.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/i_saveloadlayout.bas6
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/i_slidecopy.bas1
-rw-r--r--[-rwxr-xr-x]testautomation/graphics/optional/includes/global/export_graphic_2.inc21
-rw-r--r--testautomation/graphics/optional/includes/global/g_accessability.inc29
-rw-r--r--testautomation/graphics/optional/includes/global/g_arrangealign.inc3
-rw-r--r--testautomation/graphics/optional/includes/global/g_autocorrection.inc6
-rw-r--r--testautomation/graphics/optional/includes/global/g_clipboard.inc1
-rw-r--r--testautomation/graphics/optional/includes/global/g_convertto.inc3
-rw-r--r--testautomation/graphics/optional/includes/global/g_crossfading.inc3
-rw-r--r--testautomation/graphics/optional/includes/global/g_customshapes.inc9
-rw-r--r--testautomation/graphics/optional/includes/global/g_demoguide.inc58
-rw-r--r--testautomation/graphics/optional/includes/global/g_edit.inc74
-rw-r--r--testautomation/graphics/optional/includes/global/g_find_replace.inc3
-rw-r--r--testautomation/graphics/optional/includes/global/g_format.inc5
-rw-r--r--testautomation/graphics/optional/includes/global/g_group.inc3
-rw-r--r--testautomation/graphics/optional/includes/global/g_line.inc1
-rw-r--r--testautomation/graphics/optional/includes/global/g_load_save.inc11
-rw-r--r--testautomation/graphics/optional/includes/global/g_mediaplayer.inc2
-rw-r--r--testautomation/graphics/optional/includes/global/g_ole.inc5
-rw-r--r--testautomation/graphics/optional/includes/global/g_savepictureas.inc4
-rw-r--r--testautomation/graphics/optional/includes/global/g_shaddow.inc1
-rw-r--r--testautomation/graphics/optional/includes/global/g_stylist.inc24
-rw-r--r--testautomation/graphics/optional/includes/global/g_tables.inc2
-rw-r--r--testautomation/graphics/optional/includes/global/gallery.inc5
-rw-r--r--testautomation/graphics/optional/includes/global/id_005.inc6
-rw-r--r--testautomation/graphics/optional/includes/impress/i_animation.inc3
-rw-r--r--testautomation/graphics/optional/includes/impress/i_pengine2.inc1
-rw-r--r--testautomation/graphics/optional/includes/impress/i_saveloadlayout.inc338
-rw-r--r--testautomation/graphics/optional/includes/impress/i_slidecopy.inc71
-rw-r--r--testautomation/graphics/optional/includes/impress/i_slidelayer.inc1
-rw-r--r--testautomation/graphics/optional/includes/impress/i_slideshow.inc6
-rw-r--r--testautomation/graphics/optional/includes/impress/i_slideshow2.inc6
-rw-r--r--testautomation/graphics/optional/includes/impress/i_slideshow3.inc2
-rw-r--r--testautomation/graphics/optional/includes/impress/i_us2_present.inc8
-rw-r--r--testautomation/graphics/optional/includes/impress/i_us_present.inc351
-rw-r--r--testautomation/graphics/required/includes/global/id_002.inc13
-rw-r--r--testautomation/graphics/required/includes/global/id_005.inc7
-rw-r--r--testautomation/graphics/required/includes/global/id_007.inc6
-rw-r--r--testautomation/graphics/required/includes/global/id_011.inc1
-rw-r--r--testautomation/graphics/required/includes/global/id_opt_1.inc2
-rw-r--r--testautomation/graphics/required/includes/impress/im_003_.inc2
-rw-r--r--testautomation/graphics/tools/id_tools.inc10
-rw-r--r--testautomation/graphics/tools/id_tools_2.inc15
-rwxr-xr-x[-rw-r--r--]testautomation/spreadsheet/optional/includes/arrayconstants/c_arrayconstants.inc12
-rwxr-xr-x[-rw-r--r--]testautomation/spreadsheet/optional/includes/solver/c_solver.inc0
-rwxr-xr-xtestautomation/spreadsheet/required/includes/c_upd_filemenu.inc6
-rwxr-xr-x[-rw-r--r--]testautomation/spreadsheet/required/includes/c_upd_formatmenu2.inc23
-rwxr-xr-x[-rw-r--r--]testautomation/spreadsheet/required/includes/c_upd_viewmenu.inc15
-rwxr-xr-x[-rw-r--r--]testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion1.inc38
-rwxr-xr-x[-rw-r--r--]testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion2.inc50
-rwxr-xr-xtestautomation/writer/optional/includes/regexp/search.inc7
-rwxr-xr-x[-rw-r--r--]testautomation/writer/optional/includes/stylist/w_stylist.inc510
-rwxr-xr-x[-rw-r--r--]testautomation/writer/optional/includes/undo/w_undo_history_1.inc2
-rwxr-xr-x[-rw-r--r--]testautomation/writer/optional/includes/undo/w_undo_history_2.inc4
-rwxr-xr-x[-rw-r--r--]testautomation/writer/required/includes/w_002_.inc28
-rwxr-xr-x[-rw-r--r--]testautomation/writer/required/includes/w_011_.inc8
-rwxr-xr-x[-rw-r--r--]testautomation/writer/tools/includes/w_locale_strings2.inc27
-rwxr-xr-x[-rw-r--r--]testautomation/writer/tools/includes/w_tool1.inc14
-rw-r--r--testgraphical/document-pool/demo/CurrentTime.odsbin0 -> 8299 bytes
-rw-r--r--testgraphical/document-pool/demo/knownissues.xcl8
-rw-r--r--testgraphical/document-pool/singletest/eis-test.odtbin0 -> 9623 bytes
-rw-r--r--testgraphical/prechecks/makefile.mk (renamed from testshl2/workben/codegen/w32/makefile.mk)29
-rw-r--r--testgraphical/prechecks/softwaretests.pl564
-rwxr-xr-xtestgraphical/prj/build.lst7
-rwxr-xr-xtestgraphical/prj/d.lst0
-rw-r--r--testgraphical/qa/graphical/Test.java113
-rw-r--r--testgraphical/qa/graphical/makefile.mk (renamed from testshl2/source/testshlrunner/makefile.mk)43
-rw-r--r--testgraphical/references/unxlngi/demo/CurrentTime.ods.pdfbin0 -> 13916 bytes
-rw-r--r--testgraphical/references/unxlngi/demo/CurrentTime.ods.ps576
-rw-r--r--testgraphical/references/unxlngi/singletest/eis-test.odt.pdfbin0 -> 14356 bytes
-rw-r--r--testgraphical/references/unxlngi/singletest/eis-test.odt.ps565
-rw-r--r--testgraphical/references/unxlngi/singletest/tolerance.ini_4
-rw-r--r--testgraphical/references/unxsoli/singletest/eis-test.odt.pdfbin0 -> 9162 bytes
-rw-r--r--testgraphical/references/wntmsci/demo/CurrentTime.ods.pdfbin0 -> 13916 bytes
-rw-r--r--testgraphical/references/wntmsci/demo/CurrentTime.ods.ps499
-rw-r--r--testgraphical/references/wntmsci/singletest/eis-test.odt.pdfbin0 -> 9142 bytes
-rw-r--r--testgraphical/references/wntmsci/singletest/eis-test.odt.ps1984
-rw-r--r--testgraphical/source/CallExternals.pm539
-rw-r--r--testgraphical/source/ConvwatchHelper.pm574
-rw-r--r--testgraphical/source/compare.pl408
-rw-r--r--testgraphical/source/cwstestresult.pl208
-rw-r--r--testgraphical/source/cwstestresulthelper.pm268
-rw-r--r--testgraphical/source/dbhelper.pm209
-rw-r--r--testgraphical/source/filehelper.pm358
-rw-r--r--testgraphical/source/fill_documents_loop.pl423
-rw-r--r--testgraphical/source/graphical_compare.pm586
-rw-r--r--testgraphical/source/loghelper.pm94
-rw-r--r--testgraphical/source/makefile.mk112
-rw-r--r--testgraphical/source/oshelper.pm110
-rw-r--r--[-rwxr-xr-x]testgraphical/source/solarenvhelper.pm (renamed from smoketestoo_native/check_setup.pl)66
-rw-r--r--testgraphical/source/stringhelper.pm69
-rw-r--r--testgraphical/source/timehelper.pm99
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/build.xml74
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/dist/ConvwatchGUIProject.jarbin0 -> 28271 bytes
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/makefile.mk (renamed from testshl2/source/cppunit/win32/makefile.mk)55
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/manifest.mf3
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/build-impl.xml805
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/genfiles.properties8
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/config.properties0
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.properties7
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.xml4
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.properties71
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.xml15
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.form286
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.java535
-rw-r--r--testgraphical/ui/java/ConvwatchGUIProject/src/IniFile.java718
-rw-r--r--testgraphical/ui/java/makefile.mk (renamed from testshl2/inc/makefile.mk)28
-rw-r--r--testgraphical/util/makefile.pmk (renamed from testtools/source/bridgetest/component.gcc3.map)16
-rw-r--r--testshl2/README8
-rw-r--r--testshl2/inc/pch/precompiled_testshl2.cxx29
-rw-r--r--testshl2/inc/pch/precompiled_testshl2.hxx32
-rw-r--r--testshl2/inc/testshl/additionalfunc.hxx61
-rw-r--r--testshl2/inc/testshl/autoregister/callbackstructure.h86
-rw-r--r--testshl2/inc/testshl/autoregister/htestresult.h6
-rw-r--r--testshl2/inc/testshl/autoregister/registerfunc.h47
-rw-r--r--testshl2/inc/testshl/autoregister/registertestfunction.h51
-rw-r--r--testshl2/inc/testshl/autoregister/testfunc.h44
-rw-r--r--testshl2/inc/testshl/autoregisterhelper.hxx62
-rw-r--r--testshl2/inc/testshl/checkboom.hxx37
-rw-r--r--testshl2/inc/testshl/cmdlinebits.hxx49
-rw-r--r--testshl2/inc/testshl/dynamicregister.hxx64
-rw-r--r--testshl2/inc/testshl/filehelper.hxx47
-rw-r--r--testshl2/inc/testshl/getopt.hxx332
-rw-r--r--testshl2/inc/testshl/joblist.hxx96
-rw-r--r--testshl2/inc/testshl/log.hxx113
-rw-r--r--testshl2/inc/testshl/nocopy.hxx13
-rw-r--r--testshl2/inc/testshl/result/SynchronizedObject.h82
-rw-r--r--testshl2/inc/testshl/result/TestListener.h62
-rw-r--r--testshl2/inc/testshl/result/TestResult.h123
-rw-r--r--testshl2/inc/testshl/result/TestResultCollector.h165
-rw-r--r--testshl2/inc/testshl/result/TestSucessListener.h40
-rw-r--r--testshl2/inc/testshl/result/TextTestResult.h62
-rw-r--r--testshl2/inc/testshl/result/callbackfunc.h25
-rw-r--r--testshl2/inc/testshl/result/emacsTestResult.hxx79
-rw-r--r--testshl2/inc/testshl/result/log.hxx103
-rw-r--r--testshl2/inc/testshl/result/optionhelper.hxx95
-rw-r--r--testshl2/inc/testshl/result/outputter.hxx82
-rw-r--r--testshl2/inc/testshl/result/testshlTestResult.h72
-rw-r--r--testshl2/inc/testshl/signaltest.h62
-rw-r--r--testshl2/inc/testshl/simpleheader.hxx43
-rw-r--r--testshl2/inc/testshl/stringhelper.hxx39
-rw-r--r--testshl2/inc/testshl/taghelper.hxx88
-rw-r--r--testshl2/inc/testshl/tresstatewrapper.h63
-rw-r--r--testshl2/inc/testshl/tresstatewrapper.hxx57
-rw-r--r--testshl2/inc/testshl/versionhelper.hxx84
-rw-r--r--testshl2/inc/testshl/winstuff.hxx40
-rw-r--r--testshl2/prj/build.lst9
-rw-r--r--testshl2/prj/d.lst29
-rw-r--r--testshl2/source/autoregisterhelper.cxx140
-rw-r--r--testshl2/source/codegen/codegen.pl601
-rw-r--r--testshl2/source/cppunit/cmdlinebits.cxx141
-rw-r--r--testshl2/source/cppunit/joblist.cxx221
-rw-r--r--testshl2/source/cppunit/makefile.mk99
-rw-r--r--testshl2/source/cppunit/registertestfunction.cxx57
-rw-r--r--testshl2/source/cppunit/result/SynchronizedObject.cpp38
-rw-r--r--testshl2/source/cppunit/result/TestResult.cpp264
-rw-r--r--testshl2/source/cppunit/result/TestResultCollector.cpp150
-rw-r--r--testshl2/source/cppunit/result/TestSucessListener.cpp50
-rw-r--r--testshl2/source/cppunit/result/TextTestResult.cpp194
-rw-r--r--testshl2/source/cppunit/result/emacsTestResult.cxx190
-rw-r--r--testshl2/source/cppunit/result/log.cxx122
-rw-r--r--testshl2/source/cppunit/result/makefile.mk79
-rw-r--r--testshl2/source/cppunit/result/optionhelper.cxx314
-rw-r--r--testshl2/source/cppunit/result/outputter.cxx103
-rw-r--r--testshl2/source/cppunit/result/signal.cxx996
-rw-r--r--testshl2/source/cppunit/result/signal.hxx39
-rw-r--r--testshl2/source/cppunit/result/testshlTestResult.cxx425
-rw-r--r--testshl2/source/cppunit/result/treswrapper.cxx259
-rw-r--r--testshl2/source/cppunit/signaltest.cxx89
-rw-r--r--testshl2/source/cppunit/t_print.cxx95
-rw-r--r--testshl2/source/cppunit/tresregister.cxx66
-rw-r--r--testshl2/source/cppunit/tresstatewrapper.cxx166
-rw-r--r--testshl2/source/cppunit/win32/winstuff.cxx140
-rw-r--r--testshl2/source/dynamicregister.cxx207
-rw-r--r--testshl2/source/file.cxx74
-rw-r--r--testshl2/source/filehelper.cxx228
-rw-r--r--testshl2/source/getopt.cxx919
-rw-r--r--testshl2/source/makefile.mk130
-rw-r--r--testshl2/source/terminate.cxx289
-rw-r--r--testshl2/source/testshl.cxx396
-rw-r--r--testshl2/source/testshlrunner/ProcessHandler.java355
-rw-r--r--testshl2/source/testshlrunner/TestShl2Runner.java937
-rw-r--r--testshl2/source/versioner.cxx117
-rw-r--r--testshl2/source/versionhelper.cxx124
-rw-r--r--testshl2/workben/codegen/README9
-rw-r--r--testshl2/workben/codegen/checkfile7
-rw-r--r--testshl2/workben/codegen/cleanup10
-rw-r--r--testshl2/workben/codegen/selftest49
-rw-r--r--testshl2/workben/codegen/test.job17
-rw-r--r--testshl2/workben/codegen/w32/checkfile.btm7
-rw-r--r--testshl2/workben/codegen/w32/cleanup.btm9
-rw-r--r--testshl2/workben/codegen/w32/selftest.btm47
-rw-r--r--testshl2/workben/codegen/w32/test.job17
-rw-r--r--testshl2/workben/dlltest/export.exp1
-rw-r--r--testshl2/workben/dlltest/makefile.mk126
-rw-r--r--testshl2/workben/dlltest/onefuncstarter.cxx140
-rw-r--r--testshl2/workben/dlltest/registerfunc.h41
-rw-r--r--testshl2/workben/examples/makefile.mk64
-rw-r--r--testshl2/workben/examples/testshl_test.cxx286
-rw-r--r--testshl2/workben/garbage_dump/float.cxx137
-rw-r--r--testshl2/workben/garbage_dump/nippondir.cxx316
-rw-r--r--testshl2/workben/garbage_dump/some_tips.cxx126
-rw-r--r--testshl2/workben/getopt/makefile.mk60
-rw-r--r--testshl2/workben/getopt/test_getopt.cxx140
-rw-r--r--testshl2/workben/makefile.mk126
-rw-r--r--testshl2/workben/runner/unxlngi4.config.file34
-rw-r--r--testshl2/workben/runner/unxsols3.config.file34
-rw-r--r--testshl2/workben/runner/wntmsci9.config.file46
-rw-r--r--testshl2/workben/selftest/README.txt30
-rw-r--r--testshl2/workben/selftest/delivertest.cxx61
-rw-r--r--testshl2/workben/selftest/export.map8
-rw-r--r--testshl2/workben/selftest/makefile.mk87
-rw-r--r--testshl2/workben/selftest/notdeliveredtest.cxx61
-rw-r--r--testshl2/workben/singleton.cxx49
-rw-r--r--testshl2/workben/skeleton/export.map7
-rw-r--r--testshl2/workben/skeleton/skeleton.cxx79
-rw-r--r--testshl2/workben/test_autoptr.cxx100
-rw-r--r--testshl2/workben/test_filter.cxx230
-rw-r--r--testshl2/workben/test_member.cxx97
-rw-r--r--testshl2/workben/test_ostringstream.cxx116
-rw-r--r--testshl2/workben/test_preproc.cxx55
-rw-r--r--testshl2/workben/test_printf.cxx60
-rw-r--r--testshl2/workben/test_string.cxx138
-rw-r--r--testshl2/workben/uno/export.exp1
-rwxr-xr-xtestshl2/workben/uno/export.map8
-rw-r--r--testshl2/workben/uno/makefile.mk79
-rw-r--r--testshl2/workben/uno/unotest.cxx114
-rw-r--r--testtools/source/bridgetest/makefile.mk26
-rw-r--r--testtools/source/bridgetest/pyuno/makefile.mk19
421 files changed, 17609 insertions, 21037 deletions
diff --git a/qadevOOo/prj/build.lst b/qadevOOo/prj/build.lst
index 73092cae2a5f..1594d5c59f57 100644
--- a/qadevOOo/prj/build.lst
+++ b/qadevOOo/prj/build.lst
@@ -2,3 +2,4 @@ qa qadevOOo : javaunohelper jurt ridljar unoil NULL
qa qadevOOo usr1 - all qa_mkout NULL
qa qadevOOo nmake - all qa_runner_ant_build NULL
qa qadevOOo\runner nmake - all qa_make_package qa_runner_ant_build NULL
+qa qadevOOo\qa\unoapi nmake - all qa_qa_unoapi NULL
diff --git a/qadevOOo/qa/unoapi/Test.java b/qadevOOo/qa/unoapi/Test.java
new file mode 100644
index 000000000000..e7921911d937
--- /dev/null
+++ b/qadevOOo/qa/unoapi/Test.java
@@ -0,0 +1,51 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+package org.openoffice.qadevOOo.qa.unoapi;
+
+import org.openoffice.Runner;
+import org.openoffice.test.OfficeConnection;
+import static org.junit.Assert.*;
+
+public final class Test {
+ @org.junit.Before public void setUp() throws Exception {
+ connection.setUp();
+ }
+
+ @org.junit.After public void tearDown()
+ throws InterruptedException, com.sun.star.uno.Exception
+ {
+ connection.tearDown();
+ }
+
+ @org.junit.Test public void test() {
+ assertTrue(
+ Runner.run(
+ "-sce", "qadevOOo.sce", "-xcl", "knownissues.xcl", "-cs",
+ connection.getDescription()));
+ }
+
+ private final OfficeConnection connection = new OfficeConnection();
+}
diff --git a/qadevOOo/qa/unoapi/makefile.mk b/qadevOOo/qa/unoapi/makefile.mk
index 61a2b81d60bf..d8d308c47d3b 100755
--- a/qadevOOo/qa/unoapi/makefile.mk
+++ b/qadevOOo/qa/unoapi/makefile.mk
@@ -1,7 +1,6 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,19 +21,28 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+#***********************************************************************/
-PRJ=..$/..
+.IF "$(OOO_SUBSEQUENT_TESTS)" == ""
+nothing .PHONY:
+.ELSE
-PRJNAME=qadevOOo
-TARGET=qa_unoapi
+PRJ = ../..
+PRJNAME = qadevOOo
+TARGET = qa_unoapi
-.INCLUDE: settings.mk
+.IF "$(OOO_JUNIT_JAR)" != ""
+PACKAGE = org/openoffice/qadevOOo/qa/unoapi
+JAVATESTFILES = Test.java
+JAVAFILES = $(JAVATESTFILES)
+JARFILES = OOoRunner.jar ridl.jar test.jar
+EXTRAJARFILES = $(OOO_JUNIT_JAR)
+.END
+.INCLUDE: settings.mk
.INCLUDE: target.mk
+.INCLUDE: installationtest.mk
-ALLTAR : UNOAPI_TEST
+ALLTAR : javatest
-UNOAPI_TEST:
- +$(SOLARENV)$/bin$/checkapi -sce qadevOOo.sce -xcl knownissues.xcl -tdoc $(PWD)$/testdocuments
+.END
diff --git a/qadevOOo/runner/base/java_fat.java b/qadevOOo/runner/base/java_fat.java
index 1d75c48ed43e..4dd3ad51a817 100644
--- a/qadevOOo/runner/base/java_fat.java
+++ b/qadevOOo/runner/base/java_fat.java
@@ -219,6 +219,7 @@ public class java_fat implements TestBase
{
closeExistingOffice();
tEnv = getEnv(entry, m_aParams);
+ tCase = tEnv.getTestCase();
}
// MultiMethodTest ifc = null;
@@ -251,6 +252,7 @@ public class java_fat implements TestBase
{
closeExistingOffice();
tEnv = getEnv(entry, m_aParams);
+ tCase = tEnv.getTestCase();
if (countInterfaceTestRun < 2)
{
finished = false;
@@ -313,6 +315,9 @@ public class java_fat implements TestBase
}
System.out.println(counter + " of " + entries.length + " tests failed");
+ if (counter != 0) {
+ retValue = false;
+ }
}
closeExistingOffice();
@@ -455,17 +460,16 @@ public class java_fat implements TestBase
log.initialize(entry, logging);
tCase.setLogWriter((PrintWriter) log);
- TestEnvironment tEnv = null;
-
try
{
tCase.initializeTestCase(param);
- tEnv = tCase.getTestEnvironment(param);
+ return tCase.getTestEnvironment(param);
}
catch (com.sun.star.lang.DisposedException de)
{
System.out.println("Office disposed");
closeExistingOffice();
+ throw de;
}
catch (lib.StatusException e)
{
@@ -475,9 +479,8 @@ public class java_fat implements TestBase
entry.ErrorMsg = e.getMessage();
entry.hasErrorMsg = true;
+ throw e;
}
-
- return tEnv;
}
private void closeExistingOffice()
diff --git a/qadevOOo/runner/basicrunner/BasicTestCase.java b/qadevOOo/runner/basicrunner/BasicTestCase.java
index a84e996cc09e..1356badc12d7 100644
--- a/qadevOOo/runner/basicrunner/BasicTestCase.java
+++ b/qadevOOo/runner/basicrunner/BasicTestCase.java
@@ -159,11 +159,6 @@ public class BasicTestCase extends TestCase {
return tEnv;
}
-
- protected void cleanupTestEnvironment(TestParameters tParam,
- TestEnvironment tEnv, LogWriter log) {
- }
-
/**
* BASIC is told to dispose the test object.
* @param tParam The test parameters.
diff --git a/qadevOOo/runner/convwatch/OfficePrint.java b/qadevOOo/runner/convwatch/OfficePrint.java
index 7f9b86f2f920..c9a656ac84b4 100644
--- a/qadevOOo/runner/convwatch/OfficePrint.java
+++ b/qadevOOo/runner/convwatch/OfficePrint.java
@@ -49,10 +49,10 @@ import com.sun.star.uno.AnyConverter;
import helper.URLHelper;
import helper.PropertyHelper;
import helper.OSHelper;
-import convwatch.FileHelper;
-import convwatch.MSOfficePrint;
-import convwatch.GraphicalTestArguments;
-import convwatch.ConvWatchCancelException;
+// import convwatch.FileHelper;
+// import convwatch.MSOfficePrint;
+// import convwatch.GraphicalTestArguments;
+// import convwatch.ConvWatchCancelException;
// import helper.Parameter;
@@ -118,7 +118,7 @@ public class OfficePrint {
*/
static String getDocumentType( XComponent _aDoc )
{
- XModel xModel = (XModel) UnoRuntime.queryInterface( XModel.class, _aDoc);
+ XModel xModel = UnoRuntime.queryInterface( XModel.class, _aDoc);
PropertyValue[] aArgs = xModel.getArgs();
for (int i=0;i<aArgs.length;i++)
{
@@ -145,6 +145,9 @@ public class OfficePrint {
* the GraphicalTestArguments must contain a living MultiServiceFactory object
* or we crash here.
* Be aware, the ownership of the document gets to you, you have to close it.
+ * @param _aGTA
+ * @param _sInputURL
+ * @return
*/
public static XComponent loadFromURL(GraphicalTestArguments _aGTA,
String _sInputURL)
@@ -158,7 +161,7 @@ public class OfficePrint {
return null;
}
Object oDsk = _aGTA.getMultiServiceFactory().createInstance("com.sun.star.frame.Desktop");
- XDesktop aDesktop = (XDesktop)UnoRuntime.queryInterface(XDesktop.class, oDsk);
+ XDesktop aDesktop = UnoRuntime.queryInterface(XDesktop.class, oDsk);
if (aDesktop != null)
{
@@ -172,7 +175,7 @@ public class OfficePrint {
// set here the loadComponentFromURL() properties
// at the moment only 'Hidden' is set, so no window is opened at work
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
// check which properties should set and count it.
// if (_aGTA.isHidden())
@@ -209,7 +212,7 @@ public class OfficePrint {
GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Load document");
// GlobalLogWriter.get().flush();
- XComponentLoader aCompLoader = (XComponentLoader) UnoRuntime.queryInterface( XComponentLoader.class, aDesktop);
+ XComponentLoader aCompLoader = UnoRuntime.queryInterface( XComponentLoader.class, aDesktop);
// XComponent aDoc = null;
@@ -251,11 +254,11 @@ public class OfficePrint {
static boolean exportToPDF(XComponent _xComponent, String _sDestinationName)
{
XServiceInfo xServiceInfo =
- (XServiceInfo) UnoRuntime.queryInterface(
+ UnoRuntime.queryInterface(
XServiceInfo.class, _xComponent
);
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
PropertyValue aFiltername = new PropertyValue();
aFiltername.Name = "FilterName";
aFiltername.Value = getFilterName_forPDF(xServiceInfo);
@@ -266,7 +269,7 @@ public class OfficePrint {
try
{
XStorable store =
- (XStorable) UnoRuntime.queryInterface(
+ UnoRuntime.queryInterface(
XStorable.class, _xComponent
);
store.storeToURL(_sDestinationName, PropertyHelper.createPropertyValueArrayFormArrayList(aPropertyList));
@@ -371,6 +374,10 @@ public class OfficePrint {
* Due to the fact we use a printer to convert the file to postscript, the default printer
* to create such postscript format must be installed, this is not tested here.
*
+ * @param _aGTA
+ * @param _sInputURL
+ * @param _sOutputURL
+ * @param _sPrintFileURL
* @return true, if print has been done.
* Be careful, true means only print returns with no errors, to be sure print is really done
* check existance of _sPrintFileURL
@@ -532,7 +539,7 @@ public class OfficePrint {
if (_aGTA.isStoreAllowed())
{
// store the document in an other directory
- XStorable aStorable = (XStorable) UnoRuntime.queryInterface( XStorable.class, _aDoc);
+ XStorable aStorable = UnoRuntime.queryInterface( XStorable.class, _aDoc);
if (aStorable != null)
{
PropertyValue [] szEmptyArgs = new PropertyValue [0];
@@ -571,7 +578,7 @@ public class OfficePrint {
// Change Pagesettings to DIN A4
GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Print document.");
- XPrintable aPrintable = (XPrintable) UnoRuntime.queryInterface( XPrintable.class, _aDoc);
+ XPrintable aPrintable = UnoRuntime.queryInterface( XPrintable.class, _aDoc);
if (aPrintable != null)
{
// System.out.println(" Set PaperFormat to DIN A4");
@@ -595,7 +602,7 @@ public class OfficePrint {
{
if (_aGTA.getPrinterName() != null)
{
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
// PropertyValue [] aPrintProps = new PropertyValue[1];
PropertyValue Arg = new PropertyValue();
Arg.Name = "Name";
@@ -619,20 +626,20 @@ public class OfficePrint {
// int nPropsCount = 0;
// If we are a SpreadSheet (calc), we need to set PrintAllSheets property to 'true'
- XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface( XServiceInfo.class, _aDoc );
+ XServiceInfo xServiceInfo = UnoRuntime.queryInterface( XServiceInfo.class, _aDoc );
if ( xServiceInfo.supportsService( "com.sun.star.sheet.SpreadsheetDocument" ) )
{
XMultiServiceFactory xMSF = _aGTA.getMultiServiceFactory();
Object aSettings = xMSF.createInstance( "com.sun.star.sheet.GlobalSheetSettings" );
if (aSettings != null)
{
- XPropertySet xPropSet = (XPropertySet) UnoRuntime.queryInterface( XPropertySet.class, aSettings );
+ XPropertySet xPropSet = UnoRuntime.queryInterface( XPropertySet.class, aSettings );
xPropSet.setPropertyValue( "PrintAllSheets", new Boolean( true ) );
GlobalLogWriter.get().println("PrintAllSheets := true");
}
}
- ArrayList aPrintProps = new ArrayList();
+ ArrayList<PropertyValue> aPrintProps = new ArrayList<PropertyValue>();
// GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
// PropertyValue [] aPrintProps = new PropertyValue[nProperties];
@@ -730,6 +737,9 @@ public class OfficePrint {
/**
+ * @param _aGTA
+ * @param _sAbsoluteOutputPath
+ * @param _sAbsoluteInputFile
* @return true, if the reference (*.prrn file) based on given output path and given input path exist.
* If OVERWRITE_REFERENCE is set, always return false.
*/
@@ -783,6 +793,11 @@ public class OfficePrint {
* if is null, print only near the Input file path
* _sPrintType ".prn" Print input file with StarOffice/OpenOffice.org and the default printer as PostScript
*
+ * @param _aGTA
+ * @param _sAbsoluteOutputPath
+ * @param _sAbsoluteInputFile
+ * @return
+ * @throws ConvWatchCancelException
*/
public static boolean buildReference(GraphicalTestArguments _aGTA,
String _sAbsoluteOutputPath,
@@ -933,7 +948,7 @@ public class OfficePrint {
try
{
Object oObj = _xMSF.createInstance("com.sun.star.document.TypeDetection");
- aTypeDetection = (XTypeDetection)UnoRuntime.queryInterface(XTypeDetection.class, oObj);
+ aTypeDetection = UnoRuntime.queryInterface(XTypeDetection.class, oObj);
}
catch(com.sun.star.uno.Exception e)
{
@@ -975,7 +990,7 @@ public class OfficePrint {
}
if (aObj != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aObj);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aObj);
if (aNameAccess != null)
{
@@ -1066,7 +1081,7 @@ public class OfficePrint {
}
if (aObj != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aObj);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aObj);
if (aNameAccess != null)
{
if (! aNameAccess.hasByName(_sFilterName))
@@ -1134,7 +1149,7 @@ public class OfficePrint {
try
{
Object oObj = _xMSF.createInstance("com.sun.star.document.TypeDetection");
- aTypeDetection = (XTypeDetection)UnoRuntime.queryInterface(XTypeDetection.class, oObj);
+ aTypeDetection =UnoRuntime.queryInterface(XTypeDetection.class, oObj);
}
catch(com.sun.star.uno.Exception e)
{
@@ -1143,7 +1158,7 @@ public class OfficePrint {
}
if (aTypeDetection != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aTypeDetection);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aTypeDetection);
if (aNameAccess != null)
{
@@ -1242,12 +1257,12 @@ public class OfficePrint {
// TODO: Do we need to wait?
TimeHelper.waitInSeconds(1, "wait after loadFromURL.");
- XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface( XServiceInfo.class, aDoc );
+ XServiceInfo xServiceInfo = UnoRuntime.queryInterface( XServiceInfo.class, aDoc );
// String sFilter = getFilterName_forExcel(xServiceInfo);
// System.out.println("Filter is " + sFilter);
// store the document in an other directory
- XStorable xStorable = (XStorable) UnoRuntime.queryInterface( XStorable.class, aDoc);
+ XStorable xStorable = UnoRuntime.queryInterface( XStorable.class, aDoc);
if (xStorable == null)
{
GlobalLogWriter.get().println("com.sun.star.frame.XStorable is null");
@@ -1266,7 +1281,7 @@ public class OfficePrint {
// initialize PropertyArray
// PropertyValue [] aStoreProps = new PropertyValue[ nPropertyCount ];
// int nPropertyIndex = 0;
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
String sExtension = "";
diff --git a/qadevOOo/runner/graphical/BuildID.java b/qadevOOo/runner/graphical/BuildID.java
index 4c5907ff34ad..cf9188d84a47 100644
--- a/qadevOOo/runner/graphical/BuildID.java
+++ b/qadevOOo/runner/graphical/BuildID.java
@@ -93,7 +93,7 @@ public class BuildID
}
else
{
- GlobalLogWriter.get().println("soffice executable not found.");
+ GlobalLogWriter.println("soffice executable not found.");
}
// int dummy = 0;
@@ -119,7 +119,7 @@ public class BuildID
}
else
{
- GlobalLogWriter.get().println("Property Build, can't open file '" + sOfficePath + "', please check.");
+ GlobalLogWriter.println("Property Build, can't open file '" + sOfficePath + "', please check.");
}
return sBuildID;
}
@@ -144,7 +144,7 @@ public class BuildID
}
else
{
- GlobalLogWriter.get().println("Property Build, can't open file '" + sOfficePath + "', please check.");
+ GlobalLogWriter.println("Property Build, can't open file '" + sOfficePath + "', please check.");
}
return sBuildID;
}
diff --git a/qadevOOo/runner/graphical/DirectoryHelper.java b/qadevOOo/runner/graphical/DirectoryHelper.java
index f3349da2800a..46930d19425f 100644
--- a/qadevOOo/runner/graphical/DirectoryHelper.java
+++ b/qadevOOo/runner/graphical/DirectoryHelper.java
@@ -38,7 +38,7 @@ import java.util.ArrayList;
*/
public class DirectoryHelper
{
- ArrayList m_aFileList = new ArrayList();
+ ArrayList<String> m_aFileList = new ArrayList<String>();
boolean m_bRecursiveIsAllowed = true;
void setRecursiveIsAllowed(boolean _bValue)
@@ -73,6 +73,10 @@ public class DirectoryHelper
* System.out.println(aEntry);
* }
*
+ * @param _sDirectory
+ * @param _aFileFilter
+ * @param _bRecursiveIsAllowed
+ * @return list of directories
*/
public static Object[] traverse( String _sDirectory, FileFilter _aFileFilter, boolean _bRecursiveIsAllowed )
{
diff --git a/qadevOOo/runner/graphical/EnhancedComplexTestCase.java b/qadevOOo/runner/graphical/EnhancedComplexTestCase.java
index b465437f578f..c3ec2b3e8336 100644
--- a/qadevOOo/runner/graphical/EnhancedComplexTestCase.java
+++ b/qadevOOo/runner/graphical/EnhancedComplexTestCase.java
@@ -44,8 +44,8 @@ abstract public class EnhancedComplexTestCase extends ComplexTestCase implements
private void callEntry(String _sEntry, ParameterHelper _aParam)
{
- log.println("- next file is: ------------------------------");
- log.println(_sEntry);
+ // log.println("- next file is: ------------------------------");
+ log.println("File: " + _sEntry);
// TODO: check if 'sEntry' is a guilty document.
File aFile = new File(_aParam.getInputPath());
String sPath = _aParam.getInputPath();
@@ -79,7 +79,8 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
// sNewDiffPath = FileHelper.appendPath(sNewDiffPath, sNewSubDir);
// }
}
- log.println("sEntry: " + _sEntry + " " /* + sNewReferencePath + " " */ + sNewOutputPath);
+ // log.println("sEntry: " + _sEntry + " " /* + sNewReferencePath + " " */ + sNewOutputPath);
+ log.println("Outputpath: " + sNewOutputPath);
// call interface with parameters
@@ -187,12 +188,34 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
}
else
{
- String sPath = FileHelper.getPath(sInputPath);
- String sBasename = FileHelper.getBasename(sInputPath);
+ String sInputPathWithPDF = sInputPath + ".pdf";
+ File aInputPathWithPDF = new File(sInputPathWithPDF);
- // there exist an index file, therefore we assume the given
- // file is already converted to postscript or pdf
- runThroughEveryReportInIndex(sPath, sBasename, _aParam);
+ if (aInputPathWithPDF.exists() &&
+ _aParam.getReferenceType().toLowerCase().equals("pdf"))
+ {
+ // create PDF only if a pdf file exists and creatortype is set to PDF
+ callEntry(sInputPathWithPDF, _aParam);
+ }
+ else
+ {
+ String sInputPathWithPS = sInputPath + ".ps";
+
+ File aInputPathWithPS = new File(sInputPathWithPS);
+ if (aInputPathWithPS.exists())
+ {
+ callEntry(sInputPathWithPS, _aParam);
+ }
+ else
+ {
+ String sPath = FileHelper.getPath(sInputPath);
+ String sBasename = FileHelper.getBasename(sInputPath);
+
+ // there exist an index file, therefore we assume the given
+ // file is already converted to postscript or pdf
+ runThroughEveryReportInIndex(sPath, sBasename, _aParam);
+ }
+ }
}
}
}
@@ -210,7 +233,7 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
{
// special case for odb files
int nFileCount = aIniFile.getIntValue(_sBasename, "reportcount", 0);
- ArrayList aList = new ArrayList();
+ ArrayList<String> aList = new ArrayList<String>();
for (int i=0;i<nFileCount;i++)
{
String sValue = aIniFile.getValue(_sBasename, "report" + i);
@@ -230,7 +253,7 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
// get the bad status and store it into the
for (int i=0;i<aList.size();i++)
{
- String sEntry = (String)aList.get(i);
+ String sEntry = aList.get(i);
callEntry(sEntry, _aParam);
// we want to know the current status of the run through
@@ -265,7 +288,12 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
}
}
}
+ else
+ {
+ assure("File '" + sIndexFile + "' doesn't exists.", aIndexFile.exists(), true);
+ }
}
+
private String getPSorPDFNameFromIniFile(IniFile _aIniFile, String _sName)
{
boolean bHasPostscriptOrPDF = false;
@@ -419,7 +447,7 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
{
// special case for odb files
int nFileCount = aIniFile.getIntValue(sBasename, "reportcount", 0);
- ArrayList aList = new ArrayList();
+ ArrayList<String> aList = new ArrayList<String>();
for (int i=0;i<nFileCount;i++)
{
String sValue = aIniFile.getValue(sBasename, "report" + i);
@@ -439,7 +467,7 @@ private void callEntry(String _sEntry, ParameterHelper _aParam)
for (int i=0;i<aList.size();i++)
{
- String sPSFile = (String)aList.get(i);
+ String sPSFile = aList.get(i);
// TODO: this information has to come out of the ini files
String sStatusRunThrough = "";
diff --git a/qadevOOo/runner/graphical/FileHelper.java b/qadevOOo/runner/graphical/FileHelper.java
index feb9e152e5d9..892f652567c1 100644
--- a/qadevOOo/runner/graphical/FileHelper.java
+++ b/qadevOOo/runner/graphical/FileHelper.java
@@ -50,9 +50,9 @@ public class FileHelper
String sOSArch = System.getProperty("os.arch");
String sOSVersion = System.getProperty("os.version");
- GlobalLogWriter.get().println(sOSName);
- GlobalLogWriter.get().println(sOSArch);
- GlobalLogWriter.get().println(sOSVersion);
+ GlobalLogWriter.println(sOSName);
+ GlobalLogWriter.println(sOSArch);
+ GlobalLogWriter.println(sOSVersion);
}
@@ -110,7 +110,7 @@ public class FileHelper
}
catch (NullPointerException e)
{
- GlobalLogWriter.get().println("Exception caught. FileHelper.isDir('" + _sDir + "')");
+ GlobalLogWriter.println("Exception caught. FileHelper.isDir('" + _sDir + "')");
e.printStackTrace();
}
return false;
@@ -258,7 +258,7 @@ public class FileHelper
}
catch (java.io.IOException e)
{
- GlobalLogWriter.get().println("Exception caught. FileHelper.makeDirectories('" + new_dir.getAbsolutePath() + "')");
+ GlobalLogWriter.println("Exception caught. FileHelper.makeDirectories('" + new_dir.getAbsolutePath() + "')");
}
}
}
@@ -361,9 +361,9 @@ public class FileHelper
{
if (m_bDebugTextShown == false)
{
- GlobalLogWriter.get().println("Found file: " + sName);
- GlobalLogWriter.get().println("Activate debug mode.");
- GlobalLogWriter.get().println("If debug mode is no longer necessary, remove the above file.");
+ GlobalLogWriter.println("Found file: " + sName);
+ GlobalLogWriter.println("Activate debug mode.");
+ GlobalLogWriter.println("If debug mode is no longer necessary, remove the above file.");
m_bDebugTextShown = true;
}
bDebug = true;
@@ -463,6 +463,16 @@ public class FileHelper
{
return false;
}
+ // leave out files starts with '.~lock.' these are OpenOffice.org lock files
+ if (pathname.getName().startsWith(".~lock."))
+ {
+ return false;
+ }
+ // leave out files ends with '#' these could be temp files
+ if (pathname.getName().endsWith("#"))
+ {
+ return false;
+ }
if (pathname.getName().endsWith(".prn"))
{
return false;
@@ -592,7 +602,7 @@ public class FileHelper
if (_sFile.startsWith("file://"))
{
sFilename = FileHelper.getSystemPathFromFileURL(_sFile);
- GlobalLogWriter.get().println("CreateInfoFile: '" + sFilename + "'" );
+ GlobalLogWriter.println("CreateInfoFile: '" + sFilename + "'" );
}
else
{
@@ -682,7 +692,7 @@ public class FileHelper
}
catch (java.io.IOException e)
{
- GlobalLogWriter.get().println("can't create Info file.");
+ GlobalLogWriter.println("can't create Info file.");
e.printStackTrace();
}
aIniFile.close();
diff --git a/qadevOOo/runner/graphical/GlobalLogWriter.java b/qadevOOo/runner/graphical/GlobalLogWriter.java
index a8deabfbce0a..478d3323abda 100644
--- a/qadevOOo/runner/graphical/GlobalLogWriter.java
+++ b/qadevOOo/runner/graphical/GlobalLogWriter.java
@@ -33,11 +33,22 @@ import stats.SimpleLogWriter;
public class GlobalLogWriter
{
private static LogWriter m_aGlobalLogWriter = null;
- public static synchronized void println(String _sMsg)
+
+ /**
+ * This is just a helper to get clearer code.
+ * use this GlobalLogWriter.println(...)
+ * @param _sMsg
+ */
+ protected static synchronized void println(String _sMsg)
{
get().println(_sMsg);
}
- public static synchronized LogWriter get()
+
+ /**
+ * @deprecated use GlobalLogWriter.println(...) direct
+ * @return
+ */
+ protected static synchronized LogWriter get()
{
if (m_aGlobalLogWriter == null)
{
@@ -52,7 +63,7 @@ public class GlobalLogWriter
// get().initialize(null, true);
// }
- public static synchronized void set(LogWriter _aLog)
+ protected static synchronized void set(LogWriter _aLog)
{
m_aGlobalLogWriter = _aLog;
}
diff --git a/qadevOOo/runner/graphical/HTMLResult.java b/qadevOOo/runner/graphical/HTMLResult.java
index 85ee0e88d356..af2a31a308ea 100644
--- a/qadevOOo/runner/graphical/HTMLResult.java
+++ b/qadevOOo/runner/graphical/HTMLResult.java
@@ -59,7 +59,7 @@ public class HTMLResult
catch (java.io.IOException e)
{
e.printStackTrace();
- GlobalLogWriter.get().println("ERROR: Can't create HTML Outputter");
+ GlobalLogWriter.println("ERROR: Can't create HTML Outputter");
// return null;
}
// m_sFilename = sFilename;
diff --git a/qadevOOo/runner/graphical/IDocument.java b/qadevOOo/runner/graphical/IDocument.java
index 3f724d5c5d9c..e23ddd4b91a1 100644
--- a/qadevOOo/runner/graphical/IDocument.java
+++ b/qadevOOo/runner/graphical/IDocument.java
@@ -40,7 +40,7 @@ public interface IDocument
* @param _sDocument
* @param _sResult
* @param _aParams
- * @throws graphical.DocumentLoaderException
+ * @throws OfficeException
*/
public void checkOneFile(String _sDocument, String _sResult, ParameterHelper _aParams) throws OfficeException;
}
diff --git a/qadevOOo/runner/graphical/IniFile.java b/qadevOOo/runner/graphical/IniFile.java
index 832aef795e71..bd54a66b65fd 100644
--- a/qadevOOo/runner/graphical/IniFile.java
+++ b/qadevOOo/runner/graphical/IniFile.java
@@ -26,7 +26,7 @@
************************************************************************/
package graphical;
-import java.io.BufferedReader;
+// import java.io.BufferedReader;
import java.io.File;
import java.io.RandomAccessFile;
import java.util.ArrayList;
@@ -44,7 +44,7 @@ public class IniFile implements Enumeration
* Problem, if ini file changed why other write something difference, we don't realise this.
*/
private String m_sFilename;
- private ArrayList m_aList;
+ private ArrayList<String> m_aList;
boolean m_bListContainUnsavedChanges = false;
private int m_aEnumerationPos = 0;
@@ -76,13 +76,13 @@ public class IniFile implements Enumeration
}
}
- private ArrayList loadLines()
+ private ArrayList<String> loadLines()
{
File aFile = new File(m_sFilename);
- ArrayList aLines = new ArrayList();
+ ArrayList<String> aLines = new ArrayList<String>();
if (!aFile.exists())
{
- GlobalLogWriter.get().println("couldn't find file '" + m_sFilename + "', will be created.");
+ // GlobalLogWriter.println("couldn't find file '" + m_sFilename + "', will be created.");
// DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
// m_bListContainUnsavedChanges = false;
return aLines;
@@ -104,14 +104,14 @@ public class IniFile implements Enumeration
}
catch (java.io.FileNotFoundException fne)
{
- GlobalLogWriter.get().println("couldn't open file " + m_sFilename);
- GlobalLogWriter.get().println("Message: " + fne.getMessage());
+ GlobalLogWriter.println("couldn't open file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + fne.getMessage());
// DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
}
catch (java.io.IOException ie)
{
- GlobalLogWriter.get().println("Exception occurs while reading from file " + m_sFilename);
- GlobalLogWriter.get().println("Message: " + ie.getMessage());
+ GlobalLogWriter.println("Exception occurs while reading from file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
// DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
}
try
@@ -120,8 +120,8 @@ public class IniFile implements Enumeration
}
catch (java.io.IOException ie)
{
- GlobalLogWriter.get().println("Couldn't close file " + m_sFilename);
- GlobalLogWriter.get().println("Message: " + ie.getMessage());
+ GlobalLogWriter.println("Couldn't close file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
// DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
}
return aLines;
@@ -165,7 +165,7 @@ public class IniFile implements Enumeration
private String getItem(int i)
{
- return (String) m_aList.get(i);
+ return m_aList.get(i);
}
private String buildSectionName(String _sSectionName)
@@ -380,7 +380,7 @@ public class IniFile implements Enumeration
}
catch (java.lang.NumberFormatException e)
{
- GlobalLogWriter.get().println("IniFile.getIntValue(): Caught a number format exception, return the default value.");
+ GlobalLogWriter.println("IniFile.getIntValue(): Caught a number format exception, return the default value.");
}
}
return nValue;
@@ -395,6 +395,8 @@ public class IniFile implements Enumeration
write back the ini file to the disk, only if there exist changes
* @deprecated use close() instead!
*/
+
+ // TODO: make private
public void store()
{
if (m_bListContainUnsavedChanges == false)
@@ -411,7 +413,7 @@ public class IniFile implements Enumeration
aFile.delete();
if (aFile.exists())
{
- GlobalLogWriter.get().println("Couldn't delete the file " + m_sFilename);
+ GlobalLogWriter.println("Couldn't delete the file " + m_sFilename);
return;
// DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, "Couldn't delete the file " + m_sFilename);
}
@@ -439,14 +441,14 @@ public class IniFile implements Enumeration
}
catch (java.io.FileNotFoundException fne)
{
- GlobalLogWriter.get().println("couldn't open file for writing " + m_sFilename);
- GlobalLogWriter.get().println("Message: " + fne.getMessage());
+ GlobalLogWriter.println("couldn't open file for writing " + m_sFilename);
+ GlobalLogWriter.println("Message: " + fne.getMessage());
// DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
}
catch (java.io.IOException ie)
{
- GlobalLogWriter.get().println("Exception occurs while writing to file " + m_sFilename);
- GlobalLogWriter.get().println("Message: " + ie.getMessage());
+ GlobalLogWriter.println("Exception occurs while writing to file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
// DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
}
}
@@ -467,7 +469,10 @@ public class IniFile implements Enumeration
1. section doesn't exist, goto end and insert a new section, insert a new key value pair
2. section exist but key not, search section, search key, if key is -1 get last known key position and insert new key value pair there
3. section exist and key exist, remove the old key and insert the key value pair at the same position
- */
+ * @param _sSection
+ * @param _sKey
+ * @param _sValue
+ */
public void insertValue(String _sSection, String _sKey, String _sValue)
{
int i = findSection(_sSection);
@@ -637,7 +642,7 @@ public class IniFile implements Enumeration
{
while (i < m_aList.size())
{
- String sLine = (String) m_aList.get(i);
+ String sLine = m_aList.get(i);
if (sLine.startsWith("["))
{
return i;
@@ -657,7 +662,7 @@ public class IniFile implements Enumeration
int nLineWithSection = findNextSection(m_aEnumerationPos);
if (nLineWithSection != -1)
{
- String sSection = (String) m_aList.get(nLineWithSection);
+ String sSection = m_aList.get(nLineWithSection);
m_aEnumerationPos = findNextSection(nLineWithSection + 1);
sSection = sectionToString(sSection);
return sSection;
diff --git a/qadevOOo/runner/graphical/JPEGComparator.java b/qadevOOo/runner/graphical/JPEGComparator.java
index ed3417e04c9c..a643b2b333c3 100644
--- a/qadevOOo/runner/graphical/JPEGComparator.java
+++ b/qadevOOo/runner/graphical/JPEGComparator.java
@@ -26,18 +26,19 @@
*
* ***********************************************************************
*/
-
package graphical;
import helper.OSHelper;
import helper.ProcessHandler;
import java.io.File;
+import java.io.IOException;
/**
* Helper class to interpret a jpg filename
*/
class NameDPIPage
{
+
String Name;
int DPI;
int Page;
@@ -69,20 +70,20 @@ class NameDPIPage
String sDPI = sNameNoSuffix.substring(nDPIStart + 1, sNameNoSuffix.length() - 8);
try
{
- nDPI = Integer.valueOf(sDPI).intValue();
+ nDPI = Integer.valueOf(sDPI).intValue();
}
- catch(java.lang.NumberFormatException e)
+ catch (java.lang.NumberFormatException e)
{
- GlobalLogWriter.get().println("DPI: Number format exception");
+ GlobalLogWriter.println("DPI: Number format exception");
}
String sPage = sNameNoSuffix.substring(sNameNoSuffix.length() - 4);
try
{
- nPage = Integer.valueOf(sPage).intValue();
+ nPage = Integer.valueOf(sPage).intValue();
}
- catch(java.lang.NumberFormatException e)
+ catch (java.lang.NumberFormatException e)
{
- GlobalLogWriter.get().println("Page: Number format exception");
+ GlobalLogWriter.println("Page: Number format exception");
}
}
}
@@ -95,6 +96,77 @@ class NameDPIPage
}
}
+class CountNotXXXPixelsFromImage extends Thread
+{
+
+ private String m_sFilename;
+ protected int m_nValue;
+
+ CountNotXXXPixelsFromImage(String _sFilename)
+ {
+ m_sFilename = _sFilename;
+ }
+
+ public int getValue()
+ {
+ return m_nValue;
+ }
+
+ protected void setValue(int _nValue)
+ {
+ m_nValue = _nValue;
+ }
+
+ protected String getFilename()
+ {
+ return m_sFilename;
+ }
+}
+
+class CountNotWhitePixelsFromImage extends CountNotXXXPixelsFromImage
+{
+
+ CountNotWhitePixelsFromImage(String _sFilename)
+ {
+ super(_sFilename);
+ }
+
+ public void run()
+ {
+ try
+ {
+ final int nNotWhiteCount = PixelCounter.countNotWhitePixelsFromImage(getFilename());
+ setValue(nNotWhiteCount);
+ }
+ catch (java.io.IOException e)
+ {
+ m_nValue = -1;
+ }
+ }
+}
+
+class CountNotBlackPixelsFromImage extends CountNotXXXPixelsFromImage
+{
+
+ CountNotBlackPixelsFromImage(String _sFilename)
+ {
+ super(_sFilename);
+ }
+
+ public void run()
+ {
+ try
+ {
+ final int nNotBlackCount = PixelCounter.countNotBlackPixelsFromImage(getFilename());
+ setValue(nNotBlackCount);
+ }
+ catch (java.io.IOException e)
+ {
+ m_nValue = -1;
+ }
+ }
+}
+
/**
*
* @author ll93751
@@ -102,10 +174,12 @@ class NameDPIPage
public class JPEGComparator extends EnhancedComplexTestCase
{
// @Override
+
public String[] getTestMethodNames()
{
return new String[]{"CompareJPEGvsJPEG"};
}
+ private Tolerance m_aTolerance;
/**
* test function.
@@ -121,8 +195,8 @@ public class JPEGComparator extends EnhancedComplexTestCase
public void checkOneFile(String _sDocumentName, String _sResult, ParameterHelper _aParams) throws OfficeException
{
- // private void callEveryPictureInIniFile(IniFile _aIniFile, String _sSectionName, ParameterHelper _aParam)
- // {
+ // private void callEveryPictureInIniFile(IniFile _aIniFile, String _sSectionName, ParameterHelper _aParam)
+ // {
String sPath = FileHelper.getPath(_sDocumentName);
String sSectionName = FileHelper.getBasename(_sDocumentName);
@@ -141,8 +215,9 @@ public class JPEGComparator extends EnhancedComplexTestCase
// only which has 'pages' has also pictures
int nPages = aIniFile.getIntValue(sSectionName, "pages", 0);
String sJPEGSchema = aIniFile.getValue(sSectionName, "jpegschema");
-
- for (int i=1 ; i<=nPages ; i++)
+ int nTolerance = aIniFile.getIntValue(sSectionName, "tolerance", 0);
+ m_aTolerance = new Tolerance(nTolerance);
+ for (int i = 1; i <= nPages; i++)
{
String sJPEGFilename = JPEGCreator.getFilenameForJPEGSchema(sJPEGSchema, i);
// String sPath = FileHelper.getPath(_aParam.getInputPath());
@@ -171,7 +246,6 @@ public class JPEGComparator extends EnhancedComplexTestCase
evaluateResult(sResultIniFile, _aParams);
}
-
private void evaluateResult(String _sDocument, ParameterHelper _aParams)
{
String sResultIniFile = _sDocument + ".ini";
@@ -185,7 +259,7 @@ public class JPEGComparator extends EnhancedComplexTestCase
IniFile aResultIniFile = new IniFile(sResultIniFile);
int nPages = aResultIniFile.getIntValue("global", "pages", 0);
- for (int i=0;i<nPages;i++)
+ for (int i = 0; i < nPages; i++)
{
String sCurrentPage = "page" + String.valueOf(i + 1);
int nPercent = aResultIniFile.getIntValue(sCurrentPage, "percent", -1);
@@ -195,13 +269,13 @@ public class JPEGComparator extends EnhancedComplexTestCase
}
else if (nPercent <= 5)
{
- bad ++;
- ok_status=2;
+ bad++;
+ ok_status = 2;
}
else
{
- ugly ++;
- ok_status=3;
+ ugly++;
+ ok_status = 3;
}
}
@@ -226,7 +300,7 @@ public class JPEGComparator extends EnhancedComplexTestCase
sBad = " bad:=" + bad;
sStatusMessage += sBad;
}
- if (ugly > 0)
+ if (ugly > 0)
{
sUgly = " ugly:=" + ugly;
sStatusMessage += sUgly;
@@ -263,53 +337,67 @@ public class JPEGComparator extends EnhancedComplexTestCase
_aParams.getTestParameters().put("current_ok_status", ok_status);
// if we have a ugly page, we must return this as a FAILED STATUS in Log file!
- // assure( "There exist pages marked as ugly.", ugly == 0)
+ assure("There exist pages marked as ugly.", ugly == 0);
}
private void checkOnePicture(String _sDocumentName, String _sResult, ParameterHelper _aParams)
{
GlobalLogWriter.println("JPEG: Compare difference between '" + _sDocumentName + "' and '" + _sResult + "'");
- File aResultFile = new File(_sResult);
- if (aResultFile.isDirectory())
- {
- // result is just a directory, so we search for the basename of the source and take this.
- String sBasename = FileHelper.getBasename(_sDocumentName);
- String sResultFilename = FileHelper.appendPath(_sResult, sBasename);
- aResultFile = new File(sResultFilename);
- if (aResultFile.exists())
- {
- // Original and Result exists
- String sInputPath = _aParams.getInputPath();
- if (sInputPath.toLowerCase().endsWith("index.ini"))
- {
- // special case
- // we want to get the buildid from the info file.
-
- }
-
- compareJPEG(_sDocumentName, sResultFilename, _aParams);
-
- }
- else
- {
- GlobalLogWriter.println("Warning: Result JPEG doesn't exists '" + sResultFilename + "'");
- }
- }
- else
- {
- // result is also a file
- if (aResultFile.exists())
- {
- compareJPEG(_sDocumentName, _sResult, _aParams);
- }
- else
- {
- GlobalLogWriter.println("Warning: Result JPEG doesn't exists '" + _sResult + "'");
- }
- }
- }
+ File aResultFile = new File(_sResult);
+ if (aResultFile.isDirectory())
+ {
+ // result is just a directory, so we search for the basename of the source and take this.
+ String sBasename = FileHelper.getBasename(_sDocumentName);
+ String sResultFilename = FileHelper.appendPath(_sResult, sBasename);
+ aResultFile = new File(sResultFilename);
+ if (aResultFile.exists())
+ {
+ // Original and Result exists
+ String sInputPath = _aParams.getInputPath();
+ if (sInputPath.toLowerCase().endsWith("index.ini"))
+ {
+ // special case
+ // we want to get the buildid from the info file.
+ }
+ compareJPEG(_sDocumentName, sResultFilename, _aParams);
+ }
+ else
+ {
+ String sResultFilenamePDF = util.utils.replaceAll13(sResultFilename, ".ps_", ".pdf_");
+ File aResultPDFFile = new File(sResultFilenamePDF);
+ if (aResultPDFFile.exists())
+ {
+ // Original and Result exists
+ String sInputPath = _aParams.getInputPath();
+ if (sInputPath.toLowerCase().endsWith("index.ini"))
+ {
+ // special case
+ // we want to get the buildid from the info file.
+ }
+
+ compareJPEG(_sDocumentName, sResultFilenamePDF, _aParams);
+ }
+ else
+ {
+ GlobalLogWriter.println("Warning: Result JPEG doesn't exists '" + sResultFilename + "'");
+ }
+ }
+ }
+ else
+ {
+ // result is also a file
+ if (aResultFile.exists())
+ {
+ compareJPEG(_sDocumentName, _sResult, _aParams);
+ }
+ else
+ {
+ GlobalLogWriter.println("Warning: Result JPEG doesn't exists '" + _sResult + "'");
+ }
+ }
+ }
/**
* compare 2 JPEGs, it is a need, that both _sDocumentName and _sResultFilename exist.
@@ -318,7 +406,6 @@ public class JPEGComparator extends EnhancedComplexTestCase
* @param _aParams
* @return 0=no difference !=0 both files differ
*/
-
private void compareJPEG(String _sDocumentName, String _sResult, ParameterHelper _aParams)
{
NameDPIPage aNameDPIPage = NameDPIPage.interpret(_sDocumentName);
@@ -328,7 +415,7 @@ public class JPEGComparator extends EnhancedComplexTestCase
String sDestinationBasename = FileHelper.getBasename(_sResult);
String sDestinationPath = FileHelper.getPath(_sResult);
- if (! sSourcePath.equals(sDestinationPath))
+ if (!sSourcePath.equals(sDestinationPath))
{
// we want to have all in one Directory, Original, Reference and the Difference result.
// copy the original file to the reference path
@@ -354,9 +441,23 @@ public class JPEGComparator extends EnhancedComplexTestCase
// this means, 1=only one color, no differences found.
int nResult = identify(sDifference);
int nPercentColorDiffer = 0;
- String sResult = "NO";
+
+ String sResult = "YES";
+
+ if (m_aTolerance != null)
+ {
+ final int nAcceptedTolerance = m_aTolerance.getAccept();
+ if (nResult <= nAcceptedTolerance)
+ {
+ nResult = 1;
+ sResult = "IN TOLERANCE";
+ GlobalLogWriter.println("The differences are in tolerance.");
+
+ }
+ }
if (nResult != 1)
{
+ sResult = "NO";
try
{
nPercentColorDiffer = estimateGfx(sSource, sDestination, sDifference);
@@ -366,10 +467,6 @@ public class JPEGComparator extends EnhancedComplexTestCase
GlobalLogWriter.println("Can't estimate the different colors. " + e.getMessage());
}
}
- else
- {
- sResult = "YES";
- }
// store the result in a result.ini file
String sResultFile = FileHelper.appendPath(sDestinationPath, aNameDPIPage.Name + ".ini");
@@ -380,14 +477,16 @@ public class JPEGComparator extends EnhancedComplexTestCase
}
IniFile aResultIni = new IniFile(sResultFile);
- String[] aComment = {
+ String[] aComment =
+ {
"; This file is automatically created by a graphical.JPEGComparator run",
"; ",
"; If you see this file in a browser you may have forgotten to set the follows in the property file",
"; " + PropertyName.DOC_COMPARATOR_HTML_OUTPUT_PREFIX + "=http://<computer>/gfxcmp_ui/cw.php?inifile=",
"; Please check the documentation if you got confused.",
"; ",
- "; "};
+ "; "
+ };
aResultIni.insertFirstComment(aComment);
// write down the global flags
@@ -396,7 +495,7 @@ public class JPEGComparator extends EnhancedComplexTestCase
// INIoutput.writeValue("buildid", _sBuildID);
// INIoutput.writeValue("refbuildid", _sRefBuildID);
- String sRefBuildId = (String)_aParams.getTestParameters().get("RefBuildId");
+ String sRefBuildId = (String) _aParams.getTestParameters().get("RefBuildId");
if (sRefBuildId == null)
{
sRefBuildId = "";
@@ -410,8 +509,8 @@ public class JPEGComparator extends EnhancedComplexTestCase
// write down flags for each page
String sSection = "page" + String.valueOf(nPage);
- aResultIni.insertValue(sSection, "oldgfx", sSource);
- aResultIni.insertValue(sSection, "newgfx", sDestination);
+ aResultIni.insertValue(sSection, "oldgfx", sSource);
+ aResultIni.insertValue(sSection, "newgfx", sDestination);
aResultIni.insertValue(sSection, "diffgfx", sDifference);
aResultIni.insertValue(sSection, "percent", nPercentColorDiffer);
aResultIni.insertValue(sSection, "BM", "false");
@@ -490,8 +589,6 @@ public class JPEGComparator extends EnhancedComplexTestCase
// INIoutput.close();
// return bResultIsOk;
// }
-
-
/**
* count how much pixel differ and between Old or New and the Difference graphics
*
@@ -517,75 +614,119 @@ public class JPEGComparator extends EnhancedComplexTestCase
* @return the count of different pixels
* @throws java.io.IOException if file access is not possible
*/
-
public static int estimateGfx(String _sOldGfx, String _sNewGfx, String _sDiffGfx)
- throws java.io.IOException
- {
- // new count pixels
- final int nNotWhiteCount_OldGraphic = PixelCounter.countNotWhitePixelsFromImage(_sOldGfx);
- final int nNotWhiteCount_NewGraphic = PixelCounter.countNotWhitePixelsFromImage(_sNewGfx);
- final int nNotBlackCount_DiffGraphic = PixelCounter.countNotBlackPixelsFromImage(_sDiffGfx);
+ throws java.io.IOException
+ {
+ TimeHelper a = new TimeHelper();
+ a.start();
+ // Count Pixels
+ final int nNotWhiteCount_OldGraphic = PixelCounter.countNotWhitePixelsFromImage(_sOldGfx);
+ final int nNotWhiteCount_NewGraphic = PixelCounter.countNotWhitePixelsFromImage(_sNewGfx);
+ final int nNotBlackCount_DiffGraphic = PixelCounter.countNotBlackPixelsFromImage(_sDiffGfx);
+
+ // Count Pixels in different threads
+// CountNotWhitePixelsFromImage t1 = new CountNotWhitePixelsFromImage(_sOldGfx);
+// CountNotWhitePixelsFromImage t2 = new CountNotWhitePixelsFromImage(_sNewGfx);
+// CountNotBlackPixelsFromImage t3 = new CountNotBlackPixelsFromImage(_sDiffGfx);
+// t1.start();
+// t2.start();
+// t3.start();
+// try
+// {
+// t1.join();
+// }
+// catch (InterruptedException ex)
+// {
+// GlobalLogWriter.get().println("Thread 1 failed: " + ex.getMessage());
+// }
+// try
+// {
+// t2.join();
+// }
+// catch (InterruptedException ex)
+// {
+// GlobalLogWriter.get().println("Thread 2 failed: " + ex.getMessage());
+// }
+// try
+// {
+// t3.join();
+// }
+// catch (InterruptedException ex)
+// {
+// GlobalLogWriter.get().println("Thread 3 failed: " + ex.getMessage());
+// }
+// final int nNotWhiteCount_OldGraphic = t1.getValue();
+// final int nNotWhiteCount_NewGraphic = t2.getValue();
+// final int nNotBlackCount_DiffGraphic = t3.getValue();
+
+ a.stop();
+ GlobalLogWriter.println("Thread Time is: " + a.getTime());
- int nMinNotWhiteCount = Math.min(nNotWhiteCount_NewGraphic, nNotWhiteCount_OldGraphic);
+ int nMinNotWhiteCount = Math.min(nNotWhiteCount_NewGraphic, nNotWhiteCount_OldGraphic);
- // check if not zero
+ // check if not zero
+ if (nMinNotWhiteCount == 0)
+ {
+ nMinNotWhiteCount = Math.max(nNotWhiteCount_NewGraphic, nNotWhiteCount_OldGraphic);
if (nMinNotWhiteCount == 0)
{
- nMinNotWhiteCount = Math.max(nNotWhiteCount_NewGraphic, nNotWhiteCount_OldGraphic);
- if (nMinNotWhiteCount == 0)
- {
- nMinNotWhiteCount = 1;
- }
+ nMinNotWhiteCount = 1;
}
-
- int nPercent = Math.abs(nNotBlackCount_DiffGraphic * 100 / nMinNotWhiteCount);
- GlobalLogWriter.get().println( "Graphics check, pixel based:" + String.valueOf(nPercent) + "% pixel differ ");
- return nPercent;
}
- private static int compareJPEG(String _sOldGfx, String _sNewGfx, String _sDiffGfx)
+ int nPercent = Math.abs(nNotBlackCount_DiffGraphic * 100 / nMinNotWhiteCount);
+ GlobalLogWriter.println("Graphics check, pixel based:" + String.valueOf(nPercent) + "% pixel differ ");
+ return nPercent;
+ }
+
+ private static int compareJPEG(String _sOldGfx, String _sNewGfx, String _sDiffGfx)
+ {
+ String sComposite = "composite";
+ if (OSHelper.isWindows())
{
- String sComposite = "composite";
- if (OSHelper.isWindows())
+ sComposite = "composite.exe";
+ String sIMPath = (String) param.get("imagemagick.path");
+ if (sIMPath != null)
{
- sComposite = "composite.exe";
+ sComposite = FileHelper.appendPath(sIMPath, sComposite);
}
+ }
- // String sCommand = sComposite + " -compose difference " +
- // StringHelper.doubleQuoteIfNeed(_sOldGfx) + " " +
- // StringHelper.doubleQuoteIfNeed(_sNewGfx) + " " +
- // StringHelper.doubleQuoteIfNeed(_sDiffGfx);
+ // String sCommand = sComposite + " -compose difference " +
+ // StringHelper.doubleQuoteIfNeed(_sOldGfx) + " " +
+ // StringHelper.doubleQuoteIfNeed(_sNewGfx) + " " +
+ // StringHelper.doubleQuoteIfNeed(_sDiffGfx);
- String[] sCommandArray =
- {
- sComposite,
- "-compose",
- "difference",
- _sOldGfx,
- _sNewGfx,
- _sDiffGfx
- };
-
- ProcessHandler aHandler = new ProcessHandler(sCommandArray);
- boolean bBackValue = aHandler.executeSynchronously();
- int nExitCode = aHandler.getExitCode();
- if (nExitCode != 0)
- {
- GlobalLogWriter.println("'" + sComposite + "' return with ");
- String sBack = aHandler.getOutputText();
- GlobalLogWriter.get().println("'" + sBack + "'");
- }
- else
+ String[] sCommandArray =
+ {
+ sComposite,
+ "-compose",
+ "difference",
+ _sOldGfx,
+ _sNewGfx,
+ _sDiffGfx
+ };
+
+ ProcessHandler aHandler = new ProcessHandler(sCommandArray);
+ boolean bBackValue = aHandler.executeSynchronously();
+ int nExitCode = aHandler.getExitCode();
+ if (nExitCode != 0)
+ {
+ GlobalLogWriter.println("'" + sComposite + "' return with ");
+ String sBack = aHandler.getOutputText();
+ GlobalLogWriter.println("'" + sBack + "'");
+ }
+ else
+ {
+ // creates an extra smaller difference picture
+ File aDiffFile = new File(_sDiffGfx);
+ if (aDiffFile.exists())
{
- // creates an extra smaller difference picture
- File aDiffFile = new File(_sDiffGfx);
- if (aDiffFile.exists())
- {
- JPEGCreator.convertToNearSameFileWithWidth340(_sDiffGfx);
- }
+ JPEGCreator.convertToNearSameFileWithWidth340(_sDiffGfx);
}
- return nExitCode;
}
+ return nExitCode;
+ }
/**
* wrapper for ImageMagick identify,
@@ -593,58 +734,60 @@ public class JPEGComparator extends EnhancedComplexTestCase
* if it's only one color (nResult==1), like background color, there is no difference.
*/
int identify(String _sDiffGfx)
+ {
+ int nResult = 0;
+ // would like to know what the meaning of %k is for ImageMagick's 'identify'
+ String sIM_Format = "%k";
+ // if (OSHelper.isWindows())
+ // {
+ // sIM_Format = "%%k";
+ // }
+
+ String sIdentify = "identify";
+ if (OSHelper.isWindows())
{
- int nResult = 0;
- // would like to know what the meaning of %k is for ImageMagick's 'identify'
- String sIM_Format = "%k";
- // if (OSHelper.isWindows())
- // {
- // sIM_Format = "%%k";
- // }
-
- String sIdentify = "identify";
- if (OSHelper.isWindows())
+ sIdentify = "identify.exe";
+ String sIMPath = (String) param.get("imagemagick.path");
+ if (sIMPath != null)
{
- sIdentify = "identify.exe";
+ sIdentify = FileHelper.appendPath(sIMPath, sIdentify);
}
+ }
- // String sCommand = sIdentify + " " + sIM_Format + " " + StringHelper.doubleQuoteIfNeed(_sDiffGfx);
-
- String[] sCommandArray =
- {
- sIdentify,
- "-format",
- sIM_Format,
- _sDiffGfx
- };
- ProcessHandler aHandler = new ProcessHandler(sCommandArray);
- boolean bBackValue = aHandler.executeSynchronously();
- int nExitCode = aHandler.getExitCode();
-
- String sBack = aHandler.getOutputText();
- GlobalLogWriter.get().println("'" + sBack + "'");
+ // String sCommand = sIdentify + " " + sIM_Format + " " + StringHelper.doubleQuoteIfNeed(_sDiffGfx);
- // try to interpret the result, which we get as a String
- try
- {
- int nIdx = sBack.indexOf("\n");
- if (nIdx > 0)
- {
- sBack = sBack.substring(0, nIdx);
- }
-
- nResult = Integer.valueOf(sBack).intValue();
- }
- catch(java.lang.NumberFormatException e)
+ String[] sCommandArray =
+ {
+ sIdentify,
+ "-format",
+ sIM_Format,
+ _sDiffGfx
+ };
+ ProcessHandler aHandler = new ProcessHandler(sCommandArray);
+ boolean bBackValue = aHandler.executeSynchronously();
+ int nExitCode = aHandler.getExitCode();
+
+ String sBack = aHandler.getOutputText();
+ GlobalLogWriter.println("'" + sBack + "'");
+
+ // try to interpret the result, which we get as a String
+ try
+ {
+ int nIdx = sBack.indexOf("\n");
+ if (nIdx > 0)
{
- GlobalLogWriter.get().println("identify(): Number format exception");
- nResult = 0;
+ sBack = sBack.substring(0, nIdx);
}
- return nResult;
- }
-
-
+ nResult = Integer.valueOf(sBack).intValue();
+ }
+ catch (java.lang.NumberFormatException e)
+ {
+ GlobalLogWriter.println("identify(): Number format exception");
+ nResult = 0;
+ }
+ return nResult;
+ }
// public static void main(String [] _args)
// {
//// give an index.ini file, ok
@@ -670,5 +813,4 @@ public class JPEGComparator extends EnhancedComplexTestCase
//
// org.openoffice.Runner.main(args);
// }
-
}
diff --git a/qadevOOo/runner/graphical/JPEGCreator.java b/qadevOOo/runner/graphical/JPEGCreator.java
index 5f6343d9780d..a4336229e448 100644
--- a/qadevOOo/runner/graphical/JPEGCreator.java
+++ b/qadevOOo/runner/graphical/JPEGCreator.java
@@ -75,18 +75,35 @@ public class JPEGCreator extends EnhancedComplexTestCase
{
createSmallPictures(sJPEGNameSchema);
+ // read out tolerance file
+ String sFileDir = FileHelper.getPath(_sDocumentName);
+ String sBasename = FileHelper.getBasename(_sDocumentName);
+ int nTolerance = 0;
+ String sToleranceFile = FileHelper.appendPath(sFileDir, "tolerance.ini");
+ File aToleranceFile = new File(sToleranceFile);
+ if (aToleranceFile.exists())
+ {
+ IniFile aIniFile = new IniFile(sToleranceFile);
+ nTolerance = aIniFile.getIntValue(sBasename, "accept", 0); // default for all pages
+ aIniFile.close();
+ }
+
String sIndexFile = FileHelper.appendPath(_sResult, "index.ini");
File aIndexFile = new File(sIndexFile);
if (aIndexFile.exists())
{
// store only if an index file exists
IniFile aIniFile = new IniFile(sIndexFile);
- String sBasename = FileHelper.getBasename(_sDocumentName);
aIniFile.insertValue(sBasename, "jpegschema", sJPEGNameSchema);
aIniFile.insertValue(sBasename, "pages", nPages);
+ aIniFile.insertValue(sBasename, "tolerance", nTolerance);
aIniFile.close();
}
}
+ else
+ {
+ assure("There are no pages in document:'" + _sDocumentName + "', maybe document currupt?", false, true);
+ }
}
/**
@@ -96,6 +113,12 @@ public class JPEGCreator extends EnhancedComplexTestCase
*/
public void createSmallPictures(String _sJPEGSchema)
{
+ ParameterHelper aParam = new ParameterHelper(param);
+ if (! aParam.createSmallPictures())
+ {
+ return;
+ }
+
int nPages = 0;
if (_sJPEGSchema.length() > 0)
{
@@ -124,6 +147,11 @@ public class JPEGCreator extends EnhancedComplexTestCase
*/
public static void convertToNearSameFileWithWidth340(String _sJPEGFilename)
{
+ ParameterHelper aParam = new ParameterHelper(param);
+ if (! aParam.createSmallPictures())
+ {
+ return;
+ }
String sJPEGFilename = _sJPEGFilename.replaceAll("\\\\", "/");
// if (OSHelper.isWindows())
// {
@@ -160,7 +188,13 @@ private static void convertToWidth340(String _sFrom, String _To)
{
// TODO!
// HACK Hard coded!
- sConvertEXE = "C:\\Programme\\ImageMagick-6.0.3-q8\\convert.exe";
+ // sConvertEXE = "C:\\Programme\\ImageMagick-6.0.3-q8\\convert.exe";
+ sConvertEXE = "convert.exe";
+ String sConvertPath = (String)param.get("imagemagick.path");
+ if (sConvertPath != null)
+ {
+ sConvertEXE = FileHelper.appendPath(sConvertPath, sConvertEXE);
+ }
}
String[] sCommandArray =
@@ -178,7 +212,7 @@ private static void convertToWidth340(String _sFrom, String _To)
String sBack = aHandler.getOutputText();
if (sBack.length() > 0)
{
- GlobalLogWriter.get().println("'" + sBack + "'");
+ GlobalLogWriter.println("'" + sBack + "'");
}
// try to interpret the result, which we get as a String
// try
@@ -223,7 +257,7 @@ private static void convertToWidth340(String _sFrom, String _To)
}
else
{
- GlobalLogWriter.get().println("File: '" + _sFile + "' doesn't exist.");
+ GlobalLogWriter.println("File: '" + _sFile + "' doesn't exist.");
return "";
}
String sFileDir = FileHelper.getPath(_sFile);
@@ -291,6 +325,16 @@ private static void convertToWidth340(String _sFrom, String _To)
if (OSHelper.isWindows())
{
sGhostscriptEXE = "gswin32c.exe";
+ String sGhostscriptEXE2 = (String)param.get("gs.exe");
+ if (sGhostscriptEXE2 != null)
+ {
+ sGhostscriptEXE = sGhostscriptEXE2;
+ }
+ String sGhostscriptPath = (String)param.get("gs.path");
+ if (sGhostscriptPath != null)
+ {
+ sGhostscriptEXE = FileHelper.appendPath(sGhostscriptPath, sGhostscriptEXE);
+ }
}
// String sCommand = sGhostscriptEXE + " -dNOPROMPT -dBATCH -sDEVICE=jpeg -r" + String.valueOf(_nResolutionInDPI) + " -dNOPAUSE -sOutputFile=" + StringHelper.doubleQuoteIfNeed(sJPGFilename) + " " + StringHelper.doubleQuoteIfNeed(sOriginalFile);
@@ -333,6 +377,7 @@ private static void convertToWidth340(String _sFrom, String _To)
{
// return only a valid schema name if there at least one page.
sJPEGNameSchema = "";
+ assure("Document '" + sPostscriptOrPDFFile + "' doesn't create pages.", false, true);
}
}
else
diff --git a/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java b/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
index 8a85c6b32afd..86eb28143ed2 100644
--- a/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
+++ b/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
@@ -88,14 +88,14 @@ public class MSOfficePostscriptCreator implements IOffice
if (! isMSOfficeDocumentFormat(m_sDocumentName))
{
- GlobalLogWriter.get().println("This document type is not recognized as MSOffice format, as default fallback StarOffice/OpenOffice.org instead is used.");
+ GlobalLogWriter.println("This document type is not recognized as MSOffice format, as default fallback StarOffice/OpenOffice.org instead is used.");
throw new OfficeException("This document type is not recognized as MSOffice format, as default fallback StarOffice/OpenOffice.org instead is used.");
}
}
public void storeAsPostscript() throws OfficeException
{
- GlobalLogWriter.get().println("USE MSOFFICE AS EXPORT FORMAT.");
+ GlobalLogWriter.println("USE MSOFFICE AS EXPORT FORMAT.");
try
{
String sDocumentName = m_sDocumentName + ".ps";
@@ -112,12 +112,12 @@ public class MSOfficePostscriptCreator implements IOffice
catch(OfficeException e)
{
e.printStackTrace();
- GlobalLogWriter.get().println(e.getMessage());
+ GlobalLogWriter.println(e.getMessage());
throw new OfficeException("Exception caught. Problem with MSOffice printer methods.");
}
catch(java.io.IOException e)
{
- GlobalLogWriter.get().println(e.getMessage());
+ GlobalLogWriter.println(e.getMessage());
throw new OfficeException("IOException caught. Problem with MSOffice printer methods.");
}
}
@@ -177,11 +177,11 @@ public class MSOfficePostscriptCreator implements IOffice
private boolean isMSOfficeDocumentFormat(String _sFile)
{
String sDocumentSuffix = FileHelper.getSuffix(_sFile);
- if (isWordDocument(sDocumentSuffix)) return true;
- if (isExcelDocument(sDocumentSuffix)) return true;
- if (isPowerPointDocument(sDocumentSuffix)) return true;
+ if (isWordDocument(sDocumentSuffix)) {return true;}
+ if (isExcelDocument(sDocumentSuffix)) {return true;}
+ if (isPowerPointDocument(sDocumentSuffix)) {return true;}
// if suffix is xml, return also true, but we can't decide if word or excel
- if (sDocumentSuffix.toLowerCase().endsWith(".xml")) return true;
+ if (sDocumentSuffix.toLowerCase().endsWith(".xml")) {return true;}
return false;
}
@@ -191,7 +191,7 @@ public class MSOfficePostscriptCreator implements IOffice
{
String sDocumentSuffix = FileHelper.getSuffix(_sInputFile);
String sFilterName = _aGTA.getExportFilterName();
- ArrayList aStartCommand = new ArrayList();
+ ArrayList<String> aStartCommand = new ArrayList<String>();
if (isWordDocument(sDocumentSuffix))
{
aStartCommand = createWordStoreHelper();
@@ -222,7 +222,7 @@ public class MSOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("No Microsoft Office document format found.");
+ GlobalLogWriter.println("No Microsoft Office document format found.");
throw new WrongSuffixException("No MS office document format found.");
}
@@ -249,6 +249,11 @@ public class MSOfficePostscriptCreator implements IOffice
// -----------------------------------------------------------------------------
/**
* print the given file (_sInputFile) to the file name (_sPrintFile)
+ * @param _aGTA
+ * @param _sInputFile
+ * @param _sPrintFilename
+ * @throws OfficeException
+ * @throws java.io.IOException
*/
public void printToFileWithMSOffice( ParameterHelper _aGTA,
String _sInputFile,
@@ -258,7 +263,7 @@ public class MSOfficePostscriptCreator implements IOffice
setPrinterName(_aGTA.getPrinterName());
- ArrayList aStartCommand = new ArrayList();
+ ArrayList<String> aStartCommand = new ArrayList<String>();
if (isWordDocument(sDocumentSuffix))
{
aStartCommand = createWordPrintHelper();
@@ -293,7 +298,7 @@ public class MSOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("No Microsoft Office document format found.");
+ GlobalLogWriter.println("No Microsoft Office document format found.");
// TODO: use a better Exception!!!
throw new WrongSuffixException("No Mircosoft Office document format found.");
}
@@ -368,7 +373,13 @@ public class MSOfficePostscriptCreator implements IOffice
}
- ArrayList createWordPrintHelper() throws java.io.IOException
+ private String getPerlExe()
+ {
+ final String sPerlExe = System.getProperty("perl.exe", "perl");
+ return sPerlExe;
+ }
+
+ ArrayList<String> createWordPrintHelper() throws java.io.IOException
{
// create a program in tmp file
String sTmpPath = util.utils.getUsersTempDir();
@@ -376,7 +387,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sPrintViaWord = "printViaWord.pl";
- ArrayList aList = searchLocalFile(sPrintViaWord);
+ ArrayList<String> aList = searchLocalFile(sPrintViaWord);
if (aList.isEmpty() == false)
{
return aList;
@@ -465,30 +476,30 @@ public class MSOfficePostscriptCreator implements IOffice
out.write( "}" + ls);
out.close();
- aList.add("perl");
+ aList.add(getPerlExe());
aList.add(sFileName);
return aList;
}
// TODO: Maybe give a possibility to say where search the script from outside
- ArrayList searchLocalFile(String _sScriptName)
+ ArrayList<String> searchLocalFile(String _sScriptName)
{
String userdir = System.getProperty("user.dir");
- ArrayList aList = new ArrayList();
+ ArrayList<String> aList = new ArrayList<String>();
String sFileName = FileHelper.appendPath(userdir, _sScriptName);
File aPerlScript = new File(sFileName);
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("Search for local existance of " + aPerlScript.getAbsolutePath());
+ GlobalLogWriter.println("Search for local existance of " + aPerlScript.getAbsolutePath());
}
if (aPerlScript.exists())
{
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("OK, found it, use this instead the internal one.");
+ GlobalLogWriter.println("OK, found it, use this instead the internal one.");
}
String sName = aPerlScript.getAbsolutePath();
@@ -501,7 +512,7 @@ public class MSOfficePostscriptCreator implements IOffice
return aList;
}
- ArrayList createWordStoreHelper() throws java.io.IOException
+ ArrayList<String> createWordStoreHelper() throws java.io.IOException
{
// create a program in tmp file
String sTmpPath = util.utils.getUsersTempDir();
@@ -510,7 +521,7 @@ public class MSOfficePostscriptCreator implements IOffice
// ArrayList aList = new ArrayList();
String sSaveViaWord = "saveViaWord.pl";
- ArrayList aList = searchLocalFile(sSaveViaWord);
+ ArrayList<String> aList = searchLocalFile(sSaveViaWord);
if (aList.isEmpty() == false)
{
return aList;
@@ -519,7 +530,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sName = FileHelper.appendPath(sTmpPath, sSaveViaWord);
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("No local found, create a perl script: " + sName);
+ GlobalLogWriter.println("No local found, create a perl script: " + sName);
}
File aFile = new File(sName);
@@ -577,13 +588,13 @@ public class MSOfficePostscriptCreator implements IOffice
out.write( "$Word->Quit(); " + ls );
out.close();
- aList.add("perl");
+ aList.add(getPerlExe());
aList.add(sName);
return aList;
}
- ArrayList createExcelPrintHelper() throws java.io.IOException
+ ArrayList<String> createExcelPrintHelper() throws java.io.IOException
{
// create a program in tmp file
String sTmpPath = util.utils.getUsersTempDir();
@@ -591,7 +602,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sPrintViaExcel = "printViaExcel.pl";
- ArrayList aList = searchLocalFile(sPrintViaExcel);
+ ArrayList<String> aList = searchLocalFile(sPrintViaExcel);
if (aList.isEmpty() == false)
{
return aList;
@@ -599,14 +610,20 @@ public class MSOfficePostscriptCreator implements IOffice
String sName = FileHelper.appendPath(sTmpPath, sPrintViaExcel);
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("No local found, create a perl script: " + sName);
+ GlobalLogWriter.println("No local found, create a perl script: " + sName);
}
File aFile = new File(sName);
FileWriter out = new FileWriter(aFile);
- out.write( "eval 'exec perl -wS $0 ${1+\"$@\"}' " + ls );
- out.write( " if 0; " + ls );
+ // out.write( "eval 'exec perl -wS $0 ${1+\"$@\"}' " + ls );
+ // out.write( " if 0; " + ls );
+ out.write("#BEGIN" + ls);
+ out.write("#{" + ls);
+ out.write("#" + ls);
+ out.write("# # insert HACK" + ls);
+ out.write("# unshift(@INC, '');" + ls);
+ out.write("#}" + ls);
out.write( "use strict; " + ls );
out.write( " " + ls );
out.write( "if ( $^O ne \"MSWin32\") " + ls );
@@ -675,12 +692,12 @@ public class MSOfficePostscriptCreator implements IOffice
out.write( "}" + ls);
out.close();
- aList.add("perl");
+ aList.add(getPerlExe());
aList.add(sName);
return aList;
}
- ArrayList createExcelStoreHelper() throws java.io.IOException
+ ArrayList<String> createExcelStoreHelper() throws java.io.IOException
{
// create a program in tmp file
String sTmpPath = util.utils.getUsersTempDir();
@@ -688,7 +705,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sSaveViaExcel = "saveViaExcel.pl";
- ArrayList aList = searchLocalFile(sSaveViaExcel);
+ ArrayList<String> aList = searchLocalFile(sSaveViaExcel);
if (aList.isEmpty() == false)
{
return aList;
@@ -696,7 +713,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sName = FileHelper.appendPath(sTmpPath, sSaveViaExcel);
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("No local found, create a script: " + sName);
+ GlobalLogWriter.println("No local found, create a script: " + sName);
}
File aFile = new File(sName);
@@ -764,12 +781,12 @@ public class MSOfficePostscriptCreator implements IOffice
out.write( "$Excel->Quit(); " + ls );
out.close();
- aList.add("perl");
+ aList.add(getPerlExe());
aList.add(sName);
return aList;
}
- ArrayList createPowerPointPrintHelper() throws java.io.IOException
+ ArrayList<String> createPowerPointPrintHelper() throws java.io.IOException
{
// create a program in tmp file
String sTmpPath = util.utils.getUsersTempDir();
@@ -777,7 +794,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sPrintViaPowerPoint = "printViaPowerPoint.pl";
- ArrayList aList = searchLocalFile(sPrintViaPowerPoint);
+ ArrayList<String> aList = searchLocalFile(sPrintViaPowerPoint);
if (aList.isEmpty() == false)
{
return aList;
@@ -785,7 +802,7 @@ public class MSOfficePostscriptCreator implements IOffice
String sName = FileHelper.appendPath(sTmpPath, sPrintViaPowerPoint);
if (FileHelper.isDebugEnabled())
{
- GlobalLogWriter.get().println("No local found, create a script: " + sName);
+ GlobalLogWriter.println("No local found, create a script: " + sName);
}
File aFile = new File(sName);
@@ -865,7 +882,7 @@ public class MSOfficePostscriptCreator implements IOffice
out.write( "}" + ls);
out.close();
- aList.add("perl");
+ aList.add(getPerlExe());
aList.add(sName);
return aList;
}
@@ -879,7 +896,7 @@ public class MSOfficePostscriptCreator implements IOffice
File aFile = new File(_sFilename);
if (! aFile.exists())
{
- GlobalLogWriter.get().println("couldn't find file " + _sFilename);
+ GlobalLogWriter.println("couldn't find file " + _sFilename);
return "";
}
RandomAccessFile aReader = null;
@@ -911,7 +928,7 @@ public class MSOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("Unknown/unsupported data file: " + aLine);
+ GlobalLogWriter.println("Unknown/unsupported data file: " + aLine);
}
}
}
diff --git a/qadevOOo/runner/graphical/Office.java b/qadevOOo/runner/graphical/Office.java
index 88aeebc6b049..8ecee36cc742 100644
--- a/qadevOOo/runner/graphical/Office.java
+++ b/qadevOOo/runner/graphical/Office.java
@@ -48,6 +48,7 @@ public class Office implements IOffice
m_sResult = _sResult;
if (_aParam.getReferenceType().toLowerCase().equals("ooo") ||
+ _aParam.getReferenceType().toLowerCase().equals("ps") ||
_aParam.getReferenceType().toLowerCase().equals("pdf"))
{
m_aOffice = new OpenOfficePostscriptCreator(_aParam, m_sResult);
diff --git a/qadevOOo/runner/graphical/OpenOfficeDatabaseReportExtractor.java b/qadevOOo/runner/graphical/OpenOfficeDatabaseReportExtractor.java
index a325ba5aaf0d..a0592d5ce143 100644
--- a/qadevOOo/runner/graphical/OpenOfficeDatabaseReportExtractor.java
+++ b/qadevOOo/runner/graphical/OpenOfficeDatabaseReportExtractor.java
@@ -64,7 +64,7 @@ class PropertySetHelper
XPropertySet m_xPropertySet;
public PropertySetHelper(Object _aObj)
{
- m_xPropertySet = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, _aObj);
+ m_xPropertySet = UnoRuntime.queryInterface(XPropertySet.class, _aObj);
}
/**
@@ -115,12 +115,12 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
try
{
XInterface xInterface = (XInterface) getMultiServiceFactory().createInstance( "com.sun.star.frame.Desktop" );
- m_xDesktop = (XDesktop) UnoRuntime.queryInterface(XDesktop.class, xInterface);
+ m_xDesktop = UnoRuntime.queryInterface(XDesktop.class, xInterface);
}
catch (com.sun.star.uno.Exception e)
{
- GlobalLogWriter.get().println("ERROR: uno.Exception caught");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: uno.Exception caught");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
}
return m_xDesktop;
@@ -149,7 +149,7 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
{
if (m_xMultiServiceFactory == null)
{
- m_xMultiServiceFactory = (XMultiServiceFactory)m_aParameterHelper.getMultiServiceFactory();
+ m_xMultiServiceFactory = m_aParameterHelper.getMultiServiceFactory();
}
return m_xMultiServiceFactory;
}
@@ -192,95 +192,11 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
/**
* This is the main test Function of current ReportDesignerTest
+ * @param _sDocument
+ * @return
*/
-// public void load(String _sDocumentName)
-// {
-// // convwatch.GlobalLogWriter.set(log);
-//
-// // GlobalLogWriter.get().println("Set office watcher");
-// // OfficeWatcher aWatcher = (OfficeWatcher)m_aParameterHelper.getTestParameters().get("Watcher");
-// // GlobalLogWriter.get().setWatcher(aWatcher);
-//
-// try
-// {
-//
-// // -------------------- preconditions, try to find an office --------------------
-//
-//// String sAppExecutionCommand = (String) m_aParameterHelper.getTestParameters().get("AppExecutionCommand");
-//// GlobalLogWriter.get().println("sAppExecutionCommand='" + sAppExecutionCommand + "'");
-////
-//// String sUser = System.getProperty("user.name");
-//// GlobalLogWriter.get().println("user.name='" + sUser + "'");
-////
-//// // String sVCSID = System.getProperty("VCSID");
-//// // GlobalLogWriter.get().println("VCSID='" + sVCSID + "'");
-//// // m_sMailAddress = sVCSID + "@openoffice.org";
-//// m_sMailAddress = System.getProperty("MailAddress");
-//// GlobalLogWriter.get().println("Assumed mail address: " + m_sMailAddress);
-////
-//// m_sParentDistinct = System.getProperty("ParentDistinct");
-////
-//// m_sSourceVersion = System.getProperty("SourceVersion");
-//// m_sSourceName = System.getProperty("SourceName");
-//// m_sDestinationVersion = System.getProperty("DestinationVersion");
-//// m_sDestinationName = System.getProperty("DestinationName");
-//// // createDBEntry();
-//// // GlobalLogWriter.get().println("Current CWS: " + m_sCWS_WORK_STAMP);
-//// // GlobalLogWriter.get().println("Current MWS: " + m_sUPDMinor);
-////
-//// if (m_sSourceVersion == null)
-//// {
-//// System.out.println("Error, Sourceversion is null.");
-//// System.exit(1);
-//// }
-////
-//// sAppExecutionCommand = sAppExecutionCommand.replaceAll( "\\$\\{USERNAME\\}", sUser);
-//// GlobalLogWriter.get().println("sAppExecutionCommand='" + sAppExecutionCommand + "'");
-//
-// // an other way to replace strings
-// // sAppExecutionCommand = utils.replaceAll13(sAppExecutionCommand, "${USERNAME}", sUser);
-//
-// // checkIfOfficeExists(sAppExecutionCommand);
-// // param.put("AppExecutionCommand", new String(sAppExecutionCommand));
-//
-// // System.exit(1);
-//
-// // --------------------------- Start the given Office ---------------------------
-//
-// // startOffice();
-//
-// // ------------------------------ Start a test run ------------------------------
-//
-// // String sCurrentDirectory = System.getProperty("user.dir");
-// // GlobalLogWriter.get().println("Current Dir: " + sCurrentDirectory);
-//// String sDocument = (String) m_aParameterHelper.getTestParameters().get(convwatch.PropertyName.DOC_COMPARATOR_INPUT_PATH);
-//// sDocument = helper.StringHelper.removeQuoteIfExists( sDocument );
-// startTestForFile(_sDocumentName);
-// // if (sDocument.toLowerCase().indexOf("writer") >= 0)
-// // {
-// // startTestForFile(sDocument, WRITER);
-// // }
-// // else if (sDocument.toLowerCase().indexOf("calc") >= 0)
-// // {
-// // startTestForFile(sDocument, CALC);
-// // }
-// // else
-// // {
-// // assure("Can't identify the document no 'writer' nor 'calc' in it's name given.", false);
-// // }
-// }
-// catch (AssureException e)
-// {
-// // stopOffice();
-// // throw new AssureException(e.getMessage());
-// }
-//
-// // ------------------------------ Office shutdown ------------------------------
-// // stopOffice();
-// }
-// -----------------------------------------------------------------------------
- public ArrayList load(String _sDocument /*, int _nType*/)
+ public ArrayList<String> load(String _sDocument /*, int _nType*/)
{
// We need to copy the database file to a place where we have write access, NEVER use the docpool for this
String sOutputPath = m_aParameterHelper.getOutputPath();
@@ -295,9 +211,9 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
assure("There exists no file: " + sDestinationFile, FileHelper.exists(sDestinationFile));
String sFileURL = URLHelper.getFileURLFromSystemPath(sDestinationFile);
- GlobalLogWriter.get().println("File URL: " + sFileURL);
+ GlobalLogWriter.println("File URL: " + sFileURL);
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
// FYI: it is not allowed to open the document read only
// PropertyValue aReadOnly = new PropertyValue(); // always overwrite already exist files
@@ -307,7 +223,7 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
XComponent xDocComponent = loadComponent(sFileURL, getXDesktop(), aPropertyList);
- GlobalLogWriter.get().println("Load done");
+ GlobalLogWriter.println("Load done");
// context = createUnoService("com.sun.star.sdb.DatabaseContext")
// oDataBase = context.getByName("hh")
// oDBDoc = oDataBase.DatabaseDocument
@@ -318,35 +234,35 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
// reportContainer = oDBDoc.getReportDocuments()
// report = reportContainer.loadComponentFromURL("Report40","",0,args)
- ArrayList aList = null;
+ ArrayList<String> aList = null;
try
{
// XInterface x = (XInterface)getMultiServiceFactory().createInstance("com.sun.star.sdb.DatabaseContext");
// assure("can't create instance of com.sun.star.sdb.DatabaseContext", x != null);
-// GlobalLogWriter.get().println("createInstance com.sun.star.sdb.DatabaseContext done");
+// GlobalLogWriter.println("createInstance com.sun.star.sdb.DatabaseContext done");
// XNameAccess xNameAccess = (XNameAccess) UnoRuntime.queryInterface(XNameAccess.class, x);
// showElements(xNameAccess);
// Object aObj = xNameAccess.getByName(sFileURL);
-// GlobalLogWriter.get().println("1");
+// GlobalLogWriter.println("1");
// PropertySetHelper aHelper = new PropertySetHelper(aObj);
// XDocumentDataSource xDataSource = (XDocumentDataSource)UnoRuntime.queryInterface(XDocumentDataSource.class, aObj);
// Object aDatabaseDocument = aHelper.getPropertyValueAsObject("DatabaseDocument");
// XOfficeDatabaseDocument xOfficeDBDoc = xDataSource.getDatabaseDocument();
- XOfficeDatabaseDocument xOfficeDBDoc = (XOfficeDatabaseDocument)UnoRuntime.queryInterface(XOfficeDatabaseDocument.class, xDocComponent);
+ XOfficeDatabaseDocument xOfficeDBDoc = UnoRuntime.queryInterface(XOfficeDatabaseDocument.class, xDocComponent);
// XOfficeDatabaseDocument xOfficeDBDoc = (XOfficeDatabaseDocument)UnoRuntime.queryInterface(XOfficeDatabaseDocument.class, xDataSource);
assure("can't access DatabaseDocument", xOfficeDBDoc != null);
-// GlobalLogWriter.get().println("2");
+// GlobalLogWriter.println("2");
- XModel xDBSource = (XModel)UnoRuntime.queryInterface(XModel.class, xOfficeDBDoc);
+ XModel xDBSource = UnoRuntime.queryInterface(XModel.class, xOfficeDBDoc);
Object aController = xDBSource.getCurrentController();
assure("Controller of xOfficeDatabaseDocument is empty!", aController != null);
-// GlobalLogWriter.get().println("3");
+// GlobalLogWriter.println("3");
- XDatabaseDocumentUI aDBDocUI = (XDatabaseDocumentUI)UnoRuntime.queryInterface(XDatabaseDocumentUI.class, aController);
+ XDatabaseDocumentUI aDBDocUI = UnoRuntime.queryInterface(XDatabaseDocumentUI.class, aController);
aDBDocUI.connect();
boolean isConnect = aDBDocUI.isConnected();
if (isConnect)
@@ -360,19 +276,19 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
// aHelper = new PropertySetHelper(aController);
- XReportDocumentsSupplier xSupplier = (XReportDocumentsSupplier)UnoRuntime.queryInterface(XReportDocumentsSupplier.class, xOfficeDBDoc);
+ XReportDocumentsSupplier xSupplier = UnoRuntime.queryInterface(XReportDocumentsSupplier.class, xOfficeDBDoc);
XNameAccess xNameAccess = xSupplier.getReportDocuments();
assure("xOfficeDatabaseDocument returns no Report Document", xNameAccess != null);
-// GlobalLogWriter.get().println("5");
+// GlobalLogWriter.println("5");
showElements(xNameAccess);
// Object aActiveConnectionObj = aHelper.getPropertyValueAsObject("ActiveConnection");
Object aActiveConnectionObj = aDBDocUI.getActiveConnection();
assure("ActiveConnection is empty", aActiveConnectionObj != null);
-// GlobalLogWriter.get().println("5");
+// GlobalLogWriter.println("5");
- ArrayList aPropertyList2 = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList2 = new ArrayList<PropertyValue>();
PropertyValue aActiveConnection = new PropertyValue();
aActiveConnection.Name = "ActiveConnection";
@@ -384,8 +300,8 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
}
catch(Exception/*com.sun.star.uno.Exception*/ e)
{
- GlobalLogWriter.get().println("ERROR: Exception caught");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: Exception caught");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
// String mTestDocumentPath = (String) param.get("TestDocumentPath");
@@ -413,7 +329,7 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
String sDBConnection = (String)m_aParameterHelper.getTestParameters().get( convwatch.PropertyName.DB_CONNECTION_STRING );
if (sDBConnection != null && sDBConnection.length() > 0)
{
- GlobalLogWriter.get().println("DBConnection: " + sDBConnection);
+ GlobalLogWriter.println("DBConnection: " + sDBConnection);
// TODO: DB
// DB.init(sDBConnection);
@@ -447,9 +363,9 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
}
}
- private ArrayList loadAndStoreReports(XNameAccess _xNameAccess, ArrayList _aPropertyList /*, int _nType*/ )
+ private ArrayList<String> loadAndStoreReports(XNameAccess _xNameAccess, ArrayList<PropertyValue> _aPropertyList /*, int _nType*/ )
{
- ArrayList aList = new ArrayList();
+ ArrayList<String> aList = new ArrayList<String>();
if (_xNameAccess != null)
{
String[] sElementNames = _xNameAccess.getElementNames();
@@ -473,7 +389,7 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
private String getFormatExtension(Object _xComponent /* int _nType*/ )
{
String sExtension;
- XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface( XServiceInfo.class, _xComponent );
+ XServiceInfo xServiceInfo = UnoRuntime.queryInterface( XServiceInfo.class, _xComponent );
if ( xServiceInfo.supportsService( "com.sun.star.sheet.SpreadsheetDocument" ) )
{
// calc
@@ -567,7 +483,7 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
String sOutputURL = URLHelper.getFileURLFromSystemPath(sOutputPath);
- ArrayList aPropertyList = new ArrayList(); // set some properties for storeAsURL
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>(); // set some properties for storeAsURL
// PropertyValue aFileFormat = new PropertyValue();
// aFileFormat.Name = "FilterName";
@@ -580,19 +496,19 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
aPropertyList.add(aOverwrite);
// store the document in an other directory
- XStorable aStorable = (XStorable) UnoRuntime.queryInterface( XStorable.class, _xComponent);
+ XStorable aStorable = UnoRuntime.queryInterface( XStorable.class, _xComponent);
if (aStorable != null)
{
- GlobalLogWriter.get().println("store document as URL: '" + sOutputURL + "'");
+ GlobalLogWriter.println("store document as URL: '" + sOutputURL + "'");
try
{
aStorable.storeAsURL(sOutputURL, PropertyHelper.createPropertyValueArrayFormArrayList(aPropertyList));
}
catch (com.sun.star.io.IOException e)
{
- GlobalLogWriter.get().println("ERROR: Exception caught");
- GlobalLogWriter.get().println("Can't write document URL: '" + sOutputURL + "'");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: Exception caught");
+ GlobalLogWriter.println("Can't write document URL: '" + sOutputURL + "'");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
}
return sBackPathName;
@@ -601,26 +517,26 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
private XComponent loadComponent(String _sName, Object _xComponent, ArrayList _aPropertyList)
{
XComponent xDocComponent = null;
- XComponentLoader xComponentLoader = (XComponentLoader) UnoRuntime.queryInterface( XComponentLoader.class, _xComponent );
+ XComponentLoader xComponentLoader = UnoRuntime.queryInterface( XComponentLoader.class, _xComponent );
try
{
PropertyValue[] aLoadProperties = PropertyHelper.createPropertyValueArrayFormArrayList(_aPropertyList);
- GlobalLogWriter.get().println("Load component: '" + _sName + "'");
+ GlobalLogWriter.println("Load component: '" + _sName + "'");
xDocComponent = xComponentLoader.loadComponentFromURL(_sName, "_blank", FrameSearchFlag.ALL, aLoadProperties);
- GlobalLogWriter.get().println("Load component: '" + _sName + "' done");
+ GlobalLogWriter.println("Load component: '" + _sName + "' done");
}
catch (com.sun.star.io.IOException e)
{
- GlobalLogWriter.get().println("ERROR: Exception caught");
- GlobalLogWriter.get().println("Can't load document '" + _sName + "'");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: Exception caught");
+ GlobalLogWriter.println("Can't load document '" + _sName + "'");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
catch (com.sun.star.lang.IllegalArgumentException e)
{
- GlobalLogWriter.get().println("ERROR: Exception caught");
- GlobalLogWriter.get().println("Illegal Arguments given to loadComponentFromURL.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: Exception caught");
+ GlobalLogWriter.println("Illegal Arguments given to loadComponentFromURL.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
return xDocComponent;
}
@@ -628,16 +544,16 @@ public class OpenOfficeDatabaseReportExtractor extends Assurance
private void closeComponent(XComponent _xDoc)
{
// Close the document
- XCloseable xCloseable = (XCloseable) UnoRuntime.queryInterface(XCloseable.class, _xDoc);
+ XCloseable xCloseable = UnoRuntime.queryInterface(XCloseable.class, _xDoc);
try
{
xCloseable.close(true);
}
catch (com.sun.star.util.CloseVetoException e)
{
- GlobalLogWriter.get().println("ERROR: CloseVetoException caught");
- GlobalLogWriter.get().println("CloseVetoException occured Can't close document.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("ERROR: CloseVetoException caught");
+ GlobalLogWriter.println("CloseVetoException occured Can't close document.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
}
}
diff --git a/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java b/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
index 06330a06d9ab..d918634f8d30 100644
--- a/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
+++ b/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
@@ -89,7 +89,7 @@ public class OpenOfficePostscriptCreator implements IOffice
m_aDocument = loadFromURL(m_aParameterHelper, sInputFileURL);
if (m_aDocument == null)
{
- GlobalLogWriter.get().println("loadDocumentFromURL() failed with document: " + sInputFileURL);
+ GlobalLogWriter.println("loadDocumentFromURL() failed with document: " + sInputFileURL);
throw new OfficeException("load(): failed with document" + sInputFileURL);
}
@@ -101,7 +101,8 @@ public class OpenOfficePostscriptCreator implements IOffice
if (m_aDocument != null)
{
String sDocumentName = FileHelper.appendPath(m_sOutputURL, m_sBasename);
- if (m_aParameterHelper.getReferenceType().toLowerCase().equals("ooo"))
+ if (m_aParameterHelper.getReferenceType().toLowerCase().equals("ooo") ||
+ m_aParameterHelper.getReferenceType().toLowerCase().equals("ps") )
{
String sPrintURL = sDocumentName + ".ps";
@@ -115,13 +116,13 @@ public class OpenOfficePostscriptCreator implements IOffice
storeAsPDF(m_aParameterHelper, m_aDocument, sPDFURL);
String sBasename = FileHelper.getBasename(sPDFURL);
- FileHelper.addBasenameToIndex(m_sOutputURL, sBasename, "OOo", "pdf-export", m_sDocumentName);
+ FileHelper.addBasenameToIndex(m_sOutputURL, sBasename, "pdf", "pdf-export", m_sDocumentName);
}
else
{
throw new OfficeException("unknown reference type");
}
- GlobalLogWriter.get().println("Close document.");
+ GlobalLogWriter.println("Close document.");
m_aDocument.dispose();
}
}
@@ -147,11 +148,11 @@ public class OpenOfficePostscriptCreator implements IOffice
try
{
sValue = AnyConverter.toString(_aValue.Value);
- GlobalLogWriter.get().println("Property " + sName + ":=" + sValue);
+ GlobalLogWriter.println("Property " + sName + ":=" + sValue);
}
catch (com.sun.star.lang.IllegalArgumentException e)
{
- GlobalLogWriter.get().println("showProperty: can't convert a object to string.");
+ GlobalLogWriter.println("showProperty: can't convert a object to string. " + e.getMessage());
}
}
@@ -160,7 +161,7 @@ public class OpenOfficePostscriptCreator implements IOffice
*/
private String getDocumentType( XComponent _aDoc )
{
- XModel xModel = (XModel) UnoRuntime.queryInterface( XModel.class, _aDoc);
+ XModel xModel = UnoRuntime.queryInterface( XModel.class, _aDoc);
PropertyValue[] aArgs = xModel.getArgs();
for (int i=0;i<aArgs.length;i++)
{
@@ -180,7 +181,7 @@ public class OpenOfficePostscriptCreator implements IOffice
private void showDocumentType( XComponent _aDoc )
{
String sNameValue = getDocumentType(_aDoc);
- GlobalLogWriter.get().println(" Property: '" + sNameValue);
+ GlobalLogWriter.println(" Property: '" + sNameValue);
}
/**
* load a OpenOffice.org document from a given URL (_sInputURL)
@@ -196,15 +197,15 @@ public class OpenOfficePostscriptCreator implements IOffice
{
if (_aGTA.getMultiServiceFactory() == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory in GraphicalTestArgument not set.");
+ GlobalLogWriter.println("MultiServiceFactory in GraphicalTestArgument not set.");
return null;
}
Object oDsk = _aGTA.getMultiServiceFactory().createInstance("com.sun.star.frame.Desktop");
- XDesktop aDesktop = (XDesktop)UnoRuntime.queryInterface(XDesktop.class, oDsk);
+ XDesktop aDesktop = UnoRuntime.queryInterface(XDesktop.class, oDsk);
if (aDesktop != null)
{
- GlobalLogWriter.get().println("com.sun.star.frame.Desktop created.");
+ GlobalLogWriter.println("com.sun.star.frame.Desktop created.");
// String sInputURL = aCurrentParameter.sInputURL;
// String sOutputURL = aCurrentParameter.sOutputURL;
// String sPrintFileURL = aCurrentParameter.sPrintToFileURL;
@@ -214,7 +215,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// set here the loadComponentFromURL() properties
// at the moment only 'Hidden' is set, so no window is opened at work
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
// check which properties should set and count it.
// if (_aGTA.isHidden())
@@ -253,10 +254,10 @@ public class OpenOfficePostscriptCreator implements IOffice
aPropertyList.add(ReadOnly);
showProperty(ReadOnly);
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Load document");
- // GlobalLogWriter.get().flush();
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Load document");
+ // GlobalLogWriter.flush();
- XComponentLoader aCompLoader = (XComponentLoader) UnoRuntime.queryInterface( XComponentLoader.class, aDesktop);
+ XComponentLoader aCompLoader = UnoRuntime.queryInterface( XComponentLoader.class, aDesktop);
// XComponent aDoc = null;
@@ -265,30 +266,31 @@ public class OpenOfficePostscriptCreator implements IOffice
_aGTA.getPerformance().stopTime(PerformanceContainer.Load);
if (aDoc != null)
{
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Load document done.");
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Load document done.");
showDocumentType(aDoc);
_aGTA.setDocumentType(getDocumentType(aDoc));
+// TODO: TimeHelper.waitInSeconds(20, "Wait after load document. Maybe helps due to layouting problems.");
}
else
{
- GlobalLogWriter.get().println(" Load document failed.");
+ GlobalLogWriter.println(" Load document failed.");
if (_aGTA.getImportFilterName() != null && _aGTA.getImportFilterName().length() > 0)
{
- GlobalLogWriter.get().println(" Please check FilterName := '" + _aGTA.getImportFilterName() + "'");
+ GlobalLogWriter.println(" Please check FilterName := '" + _aGTA.getImportFilterName() + "'");
}
- GlobalLogWriter.get().println("");
+ GlobalLogWriter.println("");
}
}
else
{
- GlobalLogWriter.get().println("com.sun.star.frame.Desktop failed.");
+ GlobalLogWriter.println("com.sun.star.frame.Desktop failed.");
}
}
catch ( com.sun.star.uno.Exception e )
{
// Some exception occures.FAILED
- GlobalLogWriter.get().println("UNO Exception caught.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("UNO Exception caught.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
e.printStackTrace();
aDoc = null;
}
@@ -298,11 +300,11 @@ public class OpenOfficePostscriptCreator implements IOffice
private boolean exportToPDF(XComponent _xComponent, String _sDestinationName)
{
XServiceInfo xServiceInfo =
- (XServiceInfo) UnoRuntime.queryInterface(
+ UnoRuntime.queryInterface(
XServiceInfo.class, _xComponent
);
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
PropertyValue aFiltername = new PropertyValue();
aFiltername.Name = "FilterName";
aFiltername.Value = getFilterName_forPDF(xServiceInfo);
@@ -310,18 +312,19 @@ public class OpenOfficePostscriptCreator implements IOffice
showProperty(aFiltername);
boolean bWorked = true;
+// TODO: TimeHelper.waitInSeconds(20, "Wait before storeToURL. Maybe helps due to layouting problems.");
try
{
XStorable store =
- (XStorable) UnoRuntime.queryInterface(
+ UnoRuntime.queryInterface(
XStorable.class, _xComponent
);
store.storeToURL(_sDestinationName, PropertyHelper.createPropertyValueArrayFormArrayList(aPropertyList));
}
catch (com.sun.star.io.IOException e)
{
- GlobalLogWriter.get().println("IO Exception caught.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("IO Exception caught.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
bWorked = false;
}
@@ -383,13 +386,13 @@ public class OpenOfficePostscriptCreator implements IOffice
//
// if (aDoc == null)
// {
-// GlobalLogWriter.get().println("Can't load document.");
+// GlobalLogWriter.println("Can't load document.");
// return bBack;
// }
// bBack = storeAsPDF(_aGTA, aDoc, _sOutputURL);
// FileHelper.createInfoFile(_sOutputURL, _aGTA, "as pdf");
//
-// GlobalLogWriter.get().println("Close document.");
+// GlobalLogWriter.println("Close document.");
// aDoc.dispose();
// return bBack;
// }
@@ -406,7 +409,7 @@ public class OpenOfficePostscriptCreator implements IOffice
if (!bBack)
{
- GlobalLogWriter.get().println("Can't store document as PDF.");
+ GlobalLogWriter.println("Can't store document as PDF.");
// bBack = false;
throw new OfficeException("Can't store document as PDF");
}
@@ -444,17 +447,17 @@ public class OpenOfficePostscriptCreator implements IOffice
// {
// // don't store document
// // input and output are equal OR
-// GlobalLogWriter.get().println("Warning: Inputpath and Outputpath are equal. Document will not stored again.");
+// GlobalLogWriter.println("Warning: Inputpath and Outputpath are equal. Document will not stored again.");
// disallowStore();
// }
// bBack = impl_printToFileWithOOo(_aGTA, aDoc, _sOutputURL, _sPrintFileURL);
//
-// GlobalLogWriter.get().println("Close document.");
+// GlobalLogWriter.println("Close document.");
// aDoc.dispose();
// }
// else
// {
-// GlobalLogWriter.get().println("loadDocumentFromURL() failed with document: " + _sInputURL);
+// GlobalLogWriter.println("loadDocumentFromURL() failed with document: " + _sInputURL);
// }
// return bBack;
// }
@@ -471,7 +474,7 @@ public class OpenOfficePostscriptCreator implements IOffice
boolean bFailed = true; // always be a pessimist,
if (_aDoc == null)
{
- GlobalLogWriter.get().println("No document is given.");
+ GlobalLogWriter.println("No document is given.");
return bBack;
}
@@ -482,27 +485,27 @@ public class OpenOfficePostscriptCreator implements IOffice
if (isStoreAllowed())
{
// store the document in an other directory
- XStorable aStorable = (XStorable) UnoRuntime.queryInterface( XStorable.class, _aDoc);
+ XStorable aStorable = UnoRuntime.queryInterface( XStorable.class, _aDoc);
if (aStorable != null)
{
PropertyValue [] szEmptyArgs = new PropertyValue [0];
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Store document.");
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Store document.");
_aGTA.getPerformance().startTime(PerformanceContainer.Store);
aStorable.storeAsURL(_sOutputURL, szEmptyArgs);
_aGTA.getPerformance().stopTime(PerformanceContainer.Store);
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Store document done.");
- TimeHelper.waitInSeconds(1, "After store as URL to:" + _sOutputURL);
- GlobalLogWriter.get().println("Reload stored file test.");
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Store document done.");
+ // TimeHelper.waitInSeconds(1, "After store as URL to:" + _sOutputURL);
+ GlobalLogWriter.println("Reload stored file test.");
XComponent aDoc = loadFromURL(_aGTA, _sOutputURL);
if (aDoc == null)
{
- GlobalLogWriter.get().println("Reload stored file test failed, can't reload file: " + _sOutputURL);
+ GlobalLogWriter.println("Reload stored file test failed, can't reload file: " + _sOutputURL);
}
else
{
- XCloseable xClose = (XCloseable)UnoRuntime.queryInterface(XCloseable.class, aDoc);
+ XCloseable xClose = UnoRuntime.queryInterface(XCloseable.class, aDoc);
if (xClose != null)
{
xClose.close(true);
@@ -511,7 +514,7 @@ public class OpenOfficePostscriptCreator implements IOffice
{
aDoc.dispose();
}
- TimeHelper.waitInSeconds(1, "after close temp document");
+ // TimeHelper.waitInSeconds(1, "after close temp document");
}
}
}
@@ -528,8 +531,8 @@ public class OpenOfficePostscriptCreator implements IOffice
catch ( com.sun.star.uno.Exception e )
{
// Some exception occures.FAILED
- GlobalLogWriter.get().println("UNO Exception caught.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("UNO Exception caught.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
e.printStackTrace();
bBack = false;
@@ -541,8 +544,8 @@ public class OpenOfficePostscriptCreator implements IOffice
// System.out.println("Document loaded.");
// Change Pagesettings to DIN A4
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Print document.");
- XPrintable aPrintable = (XPrintable) UnoRuntime.queryInterface( XPrintable.class, _aDoc);
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Print document.");
+ XPrintable aPrintable = UnoRuntime.queryInterface( XPrintable.class, _aDoc);
if (aPrintable != null)
{
// System.out.println(" Set PaperFormat to DIN A4");
@@ -566,14 +569,14 @@ public class OpenOfficePostscriptCreator implements IOffice
{
if (_aGTA.getPrinterName() != null)
{
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
// PropertyValue [] aPrintProps = new PropertyValue[1];
PropertyValue Arg = new PropertyValue();
Arg.Name = "Name";
Arg.Value = _aGTA.getPrinterName();
aPropertyList.add(Arg);
showProperty(Arg);
- // GlobalLogWriter.get().println("Printername is not null, so set to " + _aGTA.getPrinterName());
+ // GlobalLogWriter.println("Printername is not null, so set to " + _aGTA.getPrinterName());
aPrintable.setPrinter(PropertyHelper.createPropertyValueArrayFormArrayList(aPropertyList));
}
}
@@ -590,21 +593,21 @@ public class OpenOfficePostscriptCreator implements IOffice
// int nPropsCount = 0;
// If we are a SpreadSheet (calc), we need to set PrintAllSheets property to 'true'
- XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface( XServiceInfo.class, _aDoc );
+ XServiceInfo xServiceInfo = UnoRuntime.queryInterface( XServiceInfo.class, _aDoc );
if ( xServiceInfo.supportsService( "com.sun.star.sheet.SpreadsheetDocument" ) )
{
XMultiServiceFactory xMSF = _aGTA.getMultiServiceFactory();
Object aSettings = xMSF.createInstance( "com.sun.star.sheet.GlobalSheetSettings" );
if (aSettings != null)
{
- XPropertySet xPropSet = (XPropertySet) UnoRuntime.queryInterface( XPropertySet.class, aSettings );
+ XPropertySet xPropSet = UnoRuntime.queryInterface( XPropertySet.class, aSettings );
xPropSet.setPropertyValue( "PrintAllSheets", new Boolean( true ) );
- GlobalLogWriter.get().println("PrintAllSheets := true");
+ GlobalLogWriter.println("PrintAllSheets := true");
}
}
- ArrayList aPrintProps = new ArrayList();
- // GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
+ ArrayList<PropertyValue> aPrintProps = new ArrayList<PropertyValue>();
+ // GlobalLogWriter.println("Property FileName:=" + _sPrintFileURL);
// PropertyValue [] aPrintProps = new PropertyValue[nProperties];
PropertyValue Arg = new PropertyValue();
@@ -639,13 +642,13 @@ public class OpenOfficePostscriptCreator implements IOffice
showProperty(Arg);
}
- // GlobalLogWriter.get().println("Start printing.");
+ // GlobalLogWriter.println("Start printing.");
_aGTA.getPerformance().startTime(PerformanceContainer.Print);
aPrintable.print(PropertyHelper.createPropertyValueArrayFormArrayList(aPrintProps));
TimeHelper.waitInSeconds(1, "Start waiting for print ready.");
- GlobalLogWriter.get().println("Wait until document is printed.");
+ GlobalLogWriter.println("Wait until document is printed.");
boolean isBusy = true;
int nPrintCount = 0;
while (isBusy)
@@ -663,21 +666,22 @@ public class OpenOfficePostscriptCreator implements IOffice
if (nPrintCount > 3600)
{
// we will never wait >1h until print is ready!
- GlobalLogWriter.get().println("ERROR: Cancel print due to too long wait.");
+ GlobalLogWriter.println("ERROR: Cancel print due to too long wait.");
throw new com.sun.star.uno.Exception("Convwatch exception, wait too long for printing.");
}
}
- // TimeHelper.waitInSeconds(40, "Start waiting after print ready.");
+// TODO:
+// TimeHelper.waitInSeconds(40, "Start waiting after print ready.");
_aGTA.getPerformance().stopTime(PerformanceContainer.Print);
- GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Print document done.");
+ GlobalLogWriter.println(DateHelper.getDateTimeForHumanreadableLog() + " Print document done.");
// Create a .info file near the printed '.ps' or '.prn' file.
FileHelper.createInfoFile(_sPrintFileURL, _aGTA);
}
else
{
- GlobalLogWriter.get().println("Can't get XPrintable interface.");
+ GlobalLogWriter.println("Can't get XPrintable interface.");
}
bFailed = false;
bBack = true;
@@ -685,8 +689,8 @@ public class OpenOfficePostscriptCreator implements IOffice
catch ( com.sun.star.uno.Exception e )
{
// Some exception occures.FAILED
- GlobalLogWriter.get().println("UNO Exception caught.");
- GlobalLogWriter.get().println("Message: " + e.getMessage());
+ GlobalLogWriter.println("UNO Exception caught.");
+ GlobalLogWriter.println("Message: " + e.getMessage());
e.printStackTrace();
bBack = false;
@@ -694,17 +698,20 @@ public class OpenOfficePostscriptCreator implements IOffice
if (bFailed == true)
{
- GlobalLogWriter.get().println("convwatch.OfficePrint: FAILED");
+ GlobalLogWriter.println("convwatch.OfficePrint: FAILED");
}
else
{
- GlobalLogWriter.get().println("convwatch.OfficePrint: OK");
+ GlobalLogWriter.println("convwatch.OfficePrint: OK");
}
return bBack;
}
/**
+ * @param _aGTA
+ * @param _sAbsoluteOutputPath
+ * @param _sAbsoluteInputFile
* @return true, if the reference (*.prrn file) based on given output path and given input path exist.
* If OVERWRITE_REFERENCE is set, always return false.
*/
@@ -744,7 +751,7 @@ public class OpenOfficePostscriptCreator implements IOffice
String sAbsolutePrintFilename = FileHelper.appendPath(sOutputPath, sPrintFilename + ".prn");
if (FileHelper.exists(sAbsolutePrintFilename) && _aGTA.getOverwrite() == false)
{
- GlobalLogWriter.get().println("Reference already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
+ GlobalLogWriter.println("Reference already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
return true;
}
return false;
@@ -797,7 +804,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// String sAbsolutePrintFilename = sOutputPath + fs + sPrintFilename + ".prn";
// if (FileHelper.exists(sAbsolutePrintFilename) && _aGTA.getOverwrite() == false)
// {
-// GlobalLogWriter.get().println("Reference already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
+// GlobalLogWriter.println("Reference already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
// return true;
// }
//
@@ -816,7 +823,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// }
// else
// {
-// GlobalLogWriter.get().println("OfficePrint.buildreference(): Unknown print type.");
+// GlobalLogWriter.println("OfficePrint.buildreference(): Unknown print type.");
// return false;
// }
// return printToFile(_aGTA, sInputFileURL, sOutputFileURL, sPrintFileURL);
@@ -845,14 +852,14 @@ public class OpenOfficePostscriptCreator implements IOffice
// }
// else if (_aGTA.getReferenceType().toLowerCase().equals("pdf"))
// {
-// GlobalLogWriter.get().println("USE PDF AS EXPORT FORMAT.");
+// GlobalLogWriter.println("USE PDF AS EXPORT FORMAT.");
// bBack = storeAsPDF(_aGTA, _sInputFileURL, _sPrintFileURL);
// }
// else if (_aGTA.getReferenceType().toLowerCase().equals("msoffice"))
// {
// if (MSOfficePostscriptCreator.isMSOfficeDocumentFormat(_sInputFileURL))
// {
-// GlobalLogWriter.get().println("USE MSOFFICE AS EXPORT FORMAT.");
+// GlobalLogWriter.println("USE MSOFFICE AS EXPORT FORMAT.");
// MSOfficePostscriptCreator a = new MSOfficePostscriptCreator();
// try
// {
@@ -862,19 +869,19 @@ public class OpenOfficePostscriptCreator implements IOffice
// catch(OfficeException e)
// {
// e.printStackTrace();
-// GlobalLogWriter.get().println(e.getMessage());
+// GlobalLogWriter.println(e.getMessage());
// throw new OfficeException("Exception caught. Problem with MSOffice printer methods.");
// }
// catch(java.io.IOException e)
// {
-// GlobalLogWriter.get().println(e.getMessage());
+// GlobalLogWriter.println(e.getMessage());
// throw new OfficeException("IOException caught. Problem with MSOffice printer methods.");
// }
// bBack = true;
// }
// else
// {
-// GlobalLogWriter.get().println("This document type is not recognized as MSOffice format, as default fallback StarOffice/OpenOffice.org instead is used.");
+// GlobalLogWriter.println("This document type is not recognized as MSOffice format, as default fallback StarOffice/OpenOffice.org instead is used.");
// bBack = printToFileWithOOo(_aGTA, _sInputFileURL, _sOutputFileURL, _sPrintFileURL);
// }
// }
@@ -898,24 +905,24 @@ public class OpenOfficePostscriptCreator implements IOffice
if (_xMSF == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory not set.");
+ GlobalLogWriter.println("MultiServiceFactory not set.");
return;
}
XTypeDetection aTypeDetection = null;
try
{
Object oObj = _xMSF.createInstance("com.sun.star.document.TypeDetection");
- aTypeDetection = (XTypeDetection)UnoRuntime.queryInterface(XTypeDetection.class, oObj);
+ aTypeDetection = UnoRuntime.queryInterface(XTypeDetection.class, oObj);
}
catch(com.sun.star.uno.Exception e)
{
- GlobalLogWriter.get().println("Can't get com.sun.star.document.TypeDetection.");
+ GlobalLogWriter.println("Can't get com.sun.star.document.TypeDetection.");
return;
}
if (aTypeDetection != null)
{
String sType = aTypeDetection.queryTypeByURL(_sInputURL);
- GlobalLogWriter.get().println("Type is: " + sType);
+ GlobalLogWriter.println("Type is: " + sType);
}
}
@@ -931,7 +938,7 @@ public class OpenOfficePostscriptCreator implements IOffice
if (_xMSF == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory not set.");
+ GlobalLogWriter.println("MultiServiceFactory not set.");
return null;
}
// XFilterFactory aFilterFactory = null;
@@ -942,12 +949,12 @@ public class OpenOfficePostscriptCreator implements IOffice
}
catch(com.sun.star.uno.Exception e)
{
- GlobalLogWriter.get().println("Can't get com.sun.star.document.FilterFactory.");
+ GlobalLogWriter.println("Can't get com.sun.star.document.FilterFactory.");
return null;
}
if (aObj != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aObj);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aObj);
if (aNameAccess != null)
{
@@ -965,7 +972,7 @@ public class OpenOfficePostscriptCreator implements IOffice
if (! aNameAccess.hasByName(_sFilterName))
{
- GlobalLogWriter.get().println("FilterFactory.hasByName() says there exist no '" + _sFilterName + "'" );
+ GlobalLogWriter.println("FilterFactory.hasByName() says there exist no '" + _sFilterName + "'" );
return null;
}
@@ -993,17 +1000,17 @@ public class OpenOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("There are no elements for FilterName '" + _sFilterName + "'");
+ GlobalLogWriter.println("There are no elements for FilterName '" + _sFilterName + "'");
return null;
}
}
catch (com.sun.star.container.NoSuchElementException e)
{
- GlobalLogWriter.get().println("NoSuchElementException caught. " + e.getMessage());
+ GlobalLogWriter.println("NoSuchElementException caught. " + e.getMessage());
}
catch (com.sun.star.lang.WrappedTargetException e)
{
- GlobalLogWriter.get().println("WrappedTargetException caught. " + e.getMessage());
+ GlobalLogWriter.println("WrappedTargetException caught. " + e.getMessage());
}
}
}
@@ -1022,7 +1029,7 @@ public class OpenOfficePostscriptCreator implements IOffice
if (_xMSF == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory not set.");
+ GlobalLogWriter.println("MultiServiceFactory not set.");
return null;
}
// XFilterFactory aFilterFactory = null;
@@ -1033,17 +1040,17 @@ public class OpenOfficePostscriptCreator implements IOffice
}
catch(com.sun.star.uno.Exception e)
{
- GlobalLogWriter.get().println("Can't get com.sun.star.document.FilterFactory.");
+ GlobalLogWriter.println("Can't get com.sun.star.document.FilterFactory.");
return null;
}
if (aObj != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aObj);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aObj);
if (aNameAccess != null)
{
if (! aNameAccess.hasByName(_sFilterName))
{
- GlobalLogWriter.get().println("FilterFactory.hasByName() says there exist no '" + _sFilterName + "'" );
+ GlobalLogWriter.println("FilterFactory.hasByName() says there exist no '" + _sFilterName + "'" );
return null;
}
@@ -1071,17 +1078,17 @@ public class OpenOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("There are no elements for FilterName '" + _sFilterName + "'");
+ GlobalLogWriter.println("There are no elements for FilterName '" + _sFilterName + "'");
return null;
}
}
catch (com.sun.star.container.NoSuchElementException e)
{
- GlobalLogWriter.get().println("NoSuchElementException caught. " + e.getMessage());
+ GlobalLogWriter.println("NoSuchElementException caught. " + e.getMessage());
}
catch (com.sun.star.lang.WrappedTargetException e)
{
- GlobalLogWriter.get().println("WrappedTargetException caught. " + e.getMessage());
+ GlobalLogWriter.println("WrappedTargetException caught. " + e.getMessage());
}
}
}
@@ -1099,23 +1106,23 @@ public class OpenOfficePostscriptCreator implements IOffice
if (_xMSF == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory not set.");
+ GlobalLogWriter.println("MultiServiceFactory not set.");
return null;
}
XTypeDetection aTypeDetection = null;
try
{
Object oObj = _xMSF.createInstance("com.sun.star.document.TypeDetection");
- aTypeDetection = (XTypeDetection)UnoRuntime.queryInterface(XTypeDetection.class, oObj);
+ aTypeDetection = UnoRuntime.queryInterface(XTypeDetection.class, oObj);
}
catch(com.sun.star.uno.Exception e)
{
- GlobalLogWriter.get().println("Can't get com.sun.star.document.TypeDetection.");
+ GlobalLogWriter.println("Can't get com.sun.star.document.TypeDetection.");
return null;
}
if (aTypeDetection != null)
{
- XNameAccess aNameAccess = (XNameAccess)UnoRuntime.queryInterface(XNameAccess.class, aTypeDetection);
+ XNameAccess aNameAccess = UnoRuntime.queryInterface(XNameAccess.class, aTypeDetection);
if (aNameAccess != null)
{
@@ -1128,7 +1135,7 @@ public class OpenOfficePostscriptCreator implements IOffice
if (! aNameAccess.hasByName(_sInternalFilterName))
{
- GlobalLogWriter.get().println("TypeDetection.hasByName() says there exist no '" + _sInternalFilterName + "'" );
+ GlobalLogWriter.println("TypeDetection.hasByName() says there exist no '" + _sInternalFilterName + "'" );
return null;
}
@@ -1148,15 +1155,15 @@ public class OpenOfficePostscriptCreator implements IOffice
if (aPropertyValue.Name.equals("Extensions"))
{
aExtensions = (String[])aPropertyValue.Value;
- GlobalLogWriter.get().println(" Possible extensions are: " + String.valueOf(aExtensions.length));
+ GlobalLogWriter.println(" Possible extensions are: " + String.valueOf(aExtensions.length));
if (aExtensions.length > 0)
{
for (int j=0;j<aExtensions.length;j++)
{
- GlobalLogWriter.get().println(" " + aExtensions[j]);
+ GlobalLogWriter.println(" " + aExtensions[j]);
}
sExtension = aExtensions[0];
- GlobalLogWriter.get().println("");
+ GlobalLogWriter.println("");
}
}
}
@@ -1164,17 +1171,17 @@ public class OpenOfficePostscriptCreator implements IOffice
}
else
{
- GlobalLogWriter.get().println("There are no elements for FilterName '" + _sInternalFilterName + "'");
+ GlobalLogWriter.println("There are no elements for FilterName '" + _sInternalFilterName + "'");
return null;
}
}
catch (com.sun.star.container.NoSuchElementException e)
{
- GlobalLogWriter.get().println("NoSuchElementException caught. " + e.getMessage());
+ GlobalLogWriter.println("NoSuchElementException caught. " + e.getMessage());
}
catch (com.sun.star.lang.WrappedTargetException e)
{
- GlobalLogWriter.get().println("WrappedTargetException caught. " + e.getMessage());
+ GlobalLogWriter.println("WrappedTargetException caught. " + e.getMessage());
}
}
}
@@ -1187,7 +1194,7 @@ public class OpenOfficePostscriptCreator implements IOffice
XMultiServiceFactory xMSF = _aGTA.getMultiServiceFactory();
if (xMSF == null)
{
- GlobalLogWriter.get().println("MultiServiceFactory in GraphicalTestArgument not set.");
+ GlobalLogWriter.println("MultiServiceFactory in GraphicalTestArgument not set.");
return;
}
@@ -1196,33 +1203,33 @@ public class OpenOfficePostscriptCreator implements IOffice
XComponent aDoc = loadFromURL( _aGTA, sInputURL);
if (aDoc == null)
{
- GlobalLogWriter.get().println("Can't load document '"+ sInputURL + "'");
+ GlobalLogWriter.println("Can't load document '"+ sInputURL + "'");
return;
}
if (_sOutputPath == null)
{
- GlobalLogWriter.get().println("Outputpath not set.");
+ GlobalLogWriter.println("Outputpath not set.");
return;
}
if (! isStoreAllowed())
{
- GlobalLogWriter.get().println("It's not allowed to store, check Input/Output path.");
+ GlobalLogWriter.println("It's not allowed to store, check Input/Output path.");
return;
}
// TODO: Do we need to wait?
// TimeHelper.waitInSeconds(1, "wait after loadFromURL.");
- XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface( XServiceInfo.class, aDoc );
+ XServiceInfo xServiceInfo = UnoRuntime.queryInterface( XServiceInfo.class, aDoc );
// String sFilter = getFilterName_forExcel(xServiceInfo);
// System.out.println("Filter is " + sFilter);
// store the document in an other directory
- XStorable xStorable = (XStorable) UnoRuntime.queryInterface( XStorable.class, aDoc);
+ XStorable xStorable = UnoRuntime.queryInterface( XStorable.class, aDoc);
if (xStorable == null)
{
- GlobalLogWriter.get().println("com.sun.star.frame.XStorable is null");
+ GlobalLogWriter.println("com.sun.star.frame.XStorable is null");
return;
}
@@ -1238,7 +1245,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// initialize PropertyArray
// PropertyValue [] aStoreProps = new PropertyValue[ nPropertyCount ];
// int nPropertyIndex = 0;
- ArrayList aPropertyList = new ArrayList();
+ ArrayList<PropertyValue> aPropertyList = new ArrayList<PropertyValue>();
String sExtension = "";
@@ -1247,22 +1254,22 @@ public class OpenOfficePostscriptCreator implements IOffice
String sInternalFilterName = getInternalFilterName(sFilterName, xMSF);
String sServiceName = getServiceNameFromFilterName(sFilterName, xMSF);
- GlobalLogWriter.get().println("Filter detection:");
+ GlobalLogWriter.println("Filter detection:");
// check if service name from file filter is the same as from the loaded document
boolean bServiceFailed = false;
if (sServiceName == null || sInternalFilterName == null)
{
- GlobalLogWriter.get().println("Given FilterName '" + sFilterName + "' seems to be unknown.");
+ GlobalLogWriter.println("Given FilterName '" + sFilterName + "' seems to be unknown.");
bServiceFailed = true;
}
if (! xServiceInfo.supportsService(sServiceName))
{
- GlobalLogWriter.get().println("Service from FilterName '" + sServiceName + "' is not supported by loaded document.");
+ GlobalLogWriter.println("Service from FilterName '" + sServiceName + "' is not supported by loaded document.");
bServiceFailed = true;
}
if (bServiceFailed == true)
{
- GlobalLogWriter.get().println("Please check '" + PropertyName.DOC_CONVERTER_EXPORT_FILTER_NAME + "' in the property file.");
+ GlobalLogWriter.println("Please check '" + PropertyName.DOC_CONVERTER_EXPORT_FILTER_NAME + "' in the property file.");
return;
}
@@ -1273,7 +1280,7 @@ public class OpenOfficePostscriptCreator implements IOffice
sExtension = getFileExtension(sInternalFilterName, xMSF);
if (sExtension == null)
{
- GlobalLogWriter.get().println("Can't found an extension for filtername, take it from the source.");
+ GlobalLogWriter.println("Can't found an extension for filtername, take it from the source.");
}
}
@@ -1283,7 +1290,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// aStoreProps[nPropertyIndex ++] = Arg;
aPropertyList.add(Arg);
showProperty(Arg);
- GlobalLogWriter.get().println("FilterName is set to: " + sFilterName);
+ GlobalLogWriter.println("FilterName is set to: " + sFilterName);
}
String sOutputURL = "";
@@ -1311,38 +1318,41 @@ public class OpenOfficePostscriptCreator implements IOffice
if (FileHelper.exists(sOutputFile) && _aGTA.getOverwrite() == false)
{
- GlobalLogWriter.get().println("File already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
+ GlobalLogWriter.println("File already exist, don't overwrite. Set " + PropertyName.DOC_COMPARATOR_OVERWRITE_REFERENCE + "=true to force overwrite.");
return;
}
sOutputURL = URLHelper.getFileURLFromSystemPath(sOutputFile);
- GlobalLogWriter.get().println("Store document as '" + sOutputURL + "'");
+ GlobalLogWriter.println("Store document as '" + sOutputURL + "'");
xStorable.storeAsURL(sOutputURL, PropertyHelper.createPropertyValueArrayFormArrayList(aPropertyList));
- GlobalLogWriter.get().println("Document stored.");
+ GlobalLogWriter.println("Document stored.");
}
catch (com.sun.star.io.IOException e)
{
- GlobalLogWriter.get().println("Can't store document '" + sOutputURL + "'. Message is :'" + e.getMessage() + "'");
+ GlobalLogWriter.println("Can't store document '" + sOutputURL + "'. Message is :'" + e.getMessage() + "'");
}
// TODO: Do we need to wait?
// TimeHelper.waitInSeconds(1, "unknown in OfficePrint.convertDocument()");
}
-
- private boolean shouldOfficeStart()
- {
- String sNoOffice = (String)m_aParameterHelper.getTestParameters().get( "NoOffice" );
- if (sNoOffice != null)
- {
- if (sNoOffice.toLowerCase().startsWith("t") || sNoOffice.toLowerCase().startsWith("y"))
- {
- return false;
- }
- }
- return true;
- }
+ /**
+ *
+ * @return false, if 'NoOffice=yes' is given
+ */
+// private boolean shouldOfficeStart()
+// {
+// String sNoOffice = (String)m_aParameterHelper.getTestParameters().get( "NoOffice" );
+// if (sNoOffice != null)
+// {
+// if (sNoOffice.toLowerCase().startsWith("t") || sNoOffice.toLowerCase().startsWith("y"))
+// {
+// return false;
+// }
+// }
+// return true;
+// }
OfficeProvider m_aProvider = null;
private void startOffice()
@@ -1370,7 +1380,7 @@ public class OpenOfficePostscriptCreator implements IOffice
// Watcher Object is need in log object to give a simple way to say if a running office is alive.
// As long as a log comes, it pings the Watcher and says the office is alive, if not an
// internal counter increase and at a given point (300 seconds) the office is killed.
- GlobalLogWriter.get().println("Set office watcher");
+ GlobalLogWriter.println("Set office watcher");
if (GlobalLogWriter.get().getWatcher() == null)
{
OfficeWatcher aWatcher = (OfficeWatcher)m_aParameterHelper.getTestParameters().get("Watcher");
@@ -1383,7 +1393,11 @@ public class OpenOfficePostscriptCreator implements IOffice
// Office shutdown
if (m_aProvider != null)
{
- m_aProvider.closeExistingOffice(m_aParameterHelper.getTestParameters(), true);
+ String sAppExecCmd = (String)m_aParameterHelper.getTestParameters().get("AppExecutionCommand");
+ if (sAppExecCmd != null && sAppExecCmd.length() > 0)
+ {
+ m_aProvider.closeExistingOffice(m_aParameterHelper.getTestParameters(), true);
+ }
// if (OSHelper.isWindows())
// {
// aSemaphore.V(aSemaphore.getSemaphoreFile());
diff --git a/qadevOOo/runner/graphical/ParameterHelper.java b/qadevOOo/runner/graphical/ParameterHelper.java
index e3545a56e73b..598ee6c53007 100644
--- a/qadevOOo/runner/graphical/ParameterHelper.java
+++ b/qadevOOo/runner/graphical/ParameterHelper.java
@@ -193,7 +193,7 @@ public class ParameterHelper
String sReferenceType = (String)getTestParameters().get( PropertyName.DOC_COMPARATOR_REFERENCE_TYPE );
if (sReferenceType == null || sReferenceType.length() == 0)
{
- m_sReferenceType = "OOo";
+ m_sReferenceType = "ps";
}
else
{
@@ -241,6 +241,7 @@ public class ParameterHelper
/**
* Helper function to get the buildid of the current used OpenOffice.org
* out of the AppExecutionCommand the build ID
+ * @return
*/
public String getBuildID()
{
@@ -265,11 +266,12 @@ public class ParameterHelper
// check if MultiServiceFactory is given
if (getReferenceType().toLowerCase().equals("pdf") ||
+ getReferenceType().toLowerCase().equals("ps") ||
getReferenceType().toLowerCase().equals("ooo"))
{
if (xMSF == null)
{
- GlobalLogWriter.get().println("ERROR! MultiServiceFactory not given.");
+ GlobalLogWriter.println("ERROR! MultiServiceFactory not given.");
}
}
return xMSF;
@@ -417,5 +419,15 @@ public class ParameterHelper
return m_sHTMLPrefix;
}
+ public boolean createSmallPictures()
+ {
+ // boolean bCreateSmallPictures = true;
+ boolean bNoSmallPictures = m_aCurrentParams.getBool( PropertyName.NO_SMALL_PICTURES);
+ if (bNoSmallPictures == true)
+ {
+ return false;
+ }
+ return true;
+ }
}
diff --git a/qadevOOo/runner/graphical/PerformanceContainer.java b/qadevOOo/runner/graphical/PerformanceContainer.java
index c31d1efb79db..ab3b292926e5 100644
--- a/qadevOOo/runner/graphical/PerformanceContainer.java
+++ b/qadevOOo/runner/graphical/PerformanceContainer.java
@@ -59,7 +59,7 @@ public class PerformanceContainer /* extends *//* implements */ {
{
if (_nCurrentTimer == 0)
{
- GlobalLogWriter.get().println("Forgotten to initialise a start timer.");
+ GlobalLogWriter.println("Forgotten to initialise a start timer.");
return 0;
}
long nMeanTime = System.currentTimeMillis();
@@ -160,7 +160,7 @@ public class PerformanceContainer /* extends *//* implements */ {
}
catch (NumberFormatException e)
{
- GlobalLogWriter.get().println("Can't convert string to double " + _sStr);
+ GlobalLogWriter.println("Can't convert string to double " + _sStr);
}
return nValue;
}
@@ -185,7 +185,7 @@ public class PerformanceContainer /* extends *//* implements */ {
File aFile = new File(sFilename);
if (! aFile.exists())
{
- GlobalLogWriter.get().println("couldn't find file " + sFilename);
+ GlobalLogWriter.println("couldn't find file " + sFilename);
return;
}
@@ -236,13 +236,13 @@ public class PerformanceContainer /* extends *//* implements */ {
}
catch (java.io.FileNotFoundException fne)
{
- GlobalLogWriter.get().println("couldn't open file " + sFilename);
- GlobalLogWriter.get().println("Message: " + fne.getMessage());
+ GlobalLogWriter.println("couldn't open file " + sFilename);
+ GlobalLogWriter.println("Message: " + fne.getMessage());
}
catch (java.io.IOException ie)
{
- GlobalLogWriter.get().println("Exception while reading file " + sFilename);
- GlobalLogWriter.get().println("Message: " + ie.getMessage());
+ GlobalLogWriter.println("Exception while reading file " + sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
}
try
{
@@ -250,8 +250,8 @@ public class PerformanceContainer /* extends *//* implements */ {
}
catch (java.io.IOException ie)
{
- GlobalLogWriter.get().println("Couldn't close file " + sFilename);
- GlobalLogWriter.get().println("Message: " + ie.getMessage());
+ GlobalLogWriter.println("Couldn't close file " + sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
}
}
diff --git a/qadevOOo/runner/graphical/PropertyName.java b/qadevOOo/runner/graphical/PropertyName.java
index 8ca2835e8086..729fd0c33c38 100644
--- a/qadevOOo/runner/graphical/PropertyName.java
+++ b/qadevOOo/runner/graphical/PropertyName.java
@@ -69,5 +69,5 @@ public interface PropertyName
// final public static String DB_CONNECTION_STRING = "DB_CONNECTION_STRING";
// final public static String CHECK_NEED_TOOLS = "CHECK_NEED_TOOLS";
// final public static String CREATE_DEFAULT = "CREATE_DEFAULT_REFERENCE";
-
+ final public static String NO_SMALL_PICTURES = "NoSmallPictures";
}
diff --git a/qadevOOo/runner/graphical/TimeHelper.java b/qadevOOo/runner/graphical/TimeHelper.java
index d0180d82e423..057f9cd19494 100644
--- a/qadevOOo/runner/graphical/TimeHelper.java
+++ b/qadevOOo/runner/graphical/TimeHelper.java
@@ -29,6 +29,8 @@
package graphical;
+import java.util.Calendar;
+
/**
*
* @author ll93751
@@ -42,9 +44,48 @@ public class TimeHelper
*/
static void waitInSeconds(int _nSeconds, String _sReason)
{
- GlobalLogWriter.get().println("Wait " + String.valueOf(_nSeconds) + " sec. Reason: " + _sReason);
+ GlobalLogWriter.println("Wait 0.25 * " + String.valueOf(_nSeconds) + " sec. Reason: " + _sReason);
try {
- java.lang.Thread.sleep(_nSeconds * 1000);
+ java.lang.Thread.sleep(_nSeconds * 250);
} catch (java.lang.InterruptedException e2) {}
}
+
+ private int m_nSeconds;
+ private int m_nMilliSeconds;
+ private long m_nRealMilliSeconds;
+
+ private boolean m_bIsStopped = false;
+
+ public TimeHelper()
+ {}
+
+ public void start()
+ {
+ m_bIsStopped = false;
+ Calendar cal = Calendar.getInstance();
+ m_nSeconds = cal.get(Calendar.SECOND);
+ m_nMilliSeconds = cal.get(Calendar.MILLISECOND);
+ }
+ public void stop()
+ {
+ Calendar cal = Calendar.getInstance();
+ m_bIsStopped = true;
+ int nSeconds = cal.get(Calendar.SECOND);
+ m_nSeconds = nSeconds - m_nSeconds;
+ if (m_nSeconds < 0)
+ {
+ // add a minute
+ m_nSeconds += 60;
+ }
+
+ int nMilliSeconds = cal.get(Calendar.MILLISECOND);
+ m_nMilliSeconds = nMilliSeconds - m_nMilliSeconds;
+ m_nRealMilliSeconds = m_nSeconds * 1000 + m_nMilliSeconds;
+ }
+
+ public String getTime()
+ {
+ return String.valueOf(m_nRealMilliSeconds);
+ }
+
}
diff --git a/qadevOOo/runner/graphical/Tolerance.java b/qadevOOo/runner/graphical/Tolerance.java
new file mode 100644
index 000000000000..90e853c9124c
--- /dev/null
+++ b/qadevOOo/runner/graphical/Tolerance.java
@@ -0,0 +1,23 @@
+/*
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+package graphical;
+
+/**
+ *
+ * @author ll93751
+ */
+public class Tolerance
+{
+ private int m_nTolerance;
+ public Tolerance(int _nAccept)
+ {
+ m_nTolerance = _nAccept;
+ }
+ public int getAccept()
+ {
+ return m_nTolerance;
+ }
+}
diff --git a/qadevOOo/runner/graphical/makefile.mk b/qadevOOo/runner/graphical/makefile.mk
index db1f84ca26ca..4e1b0e98cba1 100644
--- a/qadevOOo/runner/graphical/makefile.mk
+++ b/qadevOOo/runner/graphical/makefile.mk
@@ -64,7 +64,8 @@ PostscriptCreator.java \
PropertyName.java \
TimeHelper.java \
WrongEnvironmentException.java \
-WrongSuffixException.java
+WrongSuffixException.java \
+Tolerance.java
# GraphicalComparator.java
diff --git a/qadevOOo/runner/helper/ClParser.java b/qadevOOo/runner/helper/ClParser.java
index 7e54bccb174e..583aea56f977 100644
--- a/qadevOOo/runner/helper/ClParser.java
+++ b/qadevOOo/runner/helper/ClParser.java
@@ -26,6 +26,7 @@
************************************************************************/
package helper;
+import java.io.File;
import java.util.Properties;
import lib.TestParameters;
@@ -94,7 +95,8 @@ public class ClParser
if (pName.equals("TestDocumentPath"))
{
- System.setProperty("DOCPTH", pValue);
+ System.setProperty(
+ "DOCPTH", new File(pValue).getAbsolutePath());
}
else if (pName.equals(PropertyName.SRC_ROOT))
{
diff --git a/qadevOOo/runner/helper/OfficeProvider.java b/qadevOOo/runner/helper/OfficeProvider.java
index adeecbdeba1d..8589de47ea82 100644
--- a/qadevOOo/runner/helper/OfficeProvider.java
+++ b/qadevOOo/runner/helper/OfficeProvider.java
@@ -130,9 +130,7 @@ public class OfficeProvider implements AppProvider
try
{
- desk = (XDesktop) UnoRuntime.queryInterface(XDesktop.class,
- msf.createInstance(
- "com.sun.star.frame.Desktop"));
+ desk = UnoRuntime.queryInterface(XDesktop.class, msf.createInstance("com.sun.star.frame.Desktop"));
}
catch (com.sun.star.uno.Exception ue)
{
@@ -341,18 +339,15 @@ public class OfficeProvider implements AppProvider
{
// Get component context
- final XComponentContext xcomponentcontext = com.sun.star.comp.helper.Bootstrap.createInitialComponentContext(
- null);
+ final XComponentContext xcomponentcontext = com.sun.star.comp.helper.Bootstrap.createInitialComponentContext(null);
// initial serviceManager
final XMultiComponentFactory xLocalServiceManager = xcomponentcontext.getServiceManager();
// create a connector, so that it can contact the office
// XUnoUrlResolver urlResolver = UnoUrlResolver.create(xcomponentcontext);
- final Object xUrlResolver = xLocalServiceManager.createInstanceWithContext(
- "com.sun.star.bridge.UnoUrlResolver", xcomponentcontext);
- final XUnoUrlResolver urlResolver = (XUnoUrlResolver) UnoRuntime.queryInterface(
- XUnoUrlResolver.class, xUrlResolver);
+ final Object xUrlResolver = xLocalServiceManager.createInstanceWithContext("com.sun.star.bridge.UnoUrlResolver", xcomponentcontext);
+ final XUnoUrlResolver urlResolver = UnoRuntime.queryInterface(XUnoUrlResolver.class, xUrlResolver);
final Object rInitialObject = urlResolver.resolve(connectStr);
@@ -363,8 +358,7 @@ public class OfficeProvider implements AppProvider
debug = true;
dbg("resolved url");
- xMSF = (XMultiServiceFactory) UnoRuntime.queryInterface(
- XMultiServiceFactory.class, rInitialObject);
+ xMSF = UnoRuntime.queryInterface(XMultiServiceFactory.class, rInitialObject);
}
return xMSF;
@@ -485,7 +479,7 @@ public class OfficeProvider implements AppProvider
try
{
Object quickStarter = msf.createInstance("com.sun.star.office.Quickstart");
- XFastPropertySet fps = (XFastPropertySet) UnoRuntime.queryInterface(XFastPropertySet.class, quickStarter);
+ XFastPropertySet fps = UnoRuntime.queryInterface(XFastPropertySet.class, quickStarter);
fps.setFastPropertyValue(0, false);
}
catch (com.sun.star.uno.Exception ex)
@@ -495,9 +489,7 @@ public class OfficeProvider implements AppProvider
try
{
- desk = (XDesktop) UnoRuntime.queryInterface(XDesktop.class,
- msf.createInstance(
- "com.sun.star.frame.Desktop"));
+ desk = UnoRuntime.queryInterface(XDesktop.class, msf.createInstance("com.sun.star.frame.Desktop"));
msf = null;
if (desk != null)
@@ -616,9 +608,7 @@ public class OfficeProvider implements AppProvider
{
while (compEnum.hasMoreElements())
{
- final XCloseable closer = (XCloseable) UnoRuntime.queryInterface(
- XCloseable.class,
- compEnum.nextElement());
+ final XCloseable closer = UnoRuntime.queryInterface(XCloseable.class, compEnum.nextElement());
if (closer != null)
{
@@ -658,8 +648,7 @@ public class OfficeProvider implements AppProvider
if (xPathSubst != null)
{
- return (XStringSubstitution) UnoRuntime.queryInterface(
- XStringSubstitution.class, xPathSubst);
+ return UnoRuntime.queryInterface(XStringSubstitution.class, xPathSubst);
}
else
{
@@ -790,6 +779,7 @@ public class OfficeProvider implements AppProvider
this.ow = ow;
}
+ @Override
public void run()
{
System.out.println(utils.getDateTime() + "OfficeProvider:Owp: start ");
diff --git a/qadevOOo/runner/lib/TestCase.java b/qadevOOo/runner/lib/TestCase.java
index e5214f2edb40..6b8b960c3014 100644
--- a/qadevOOo/runner/lib/TestCase.java
+++ b/qadevOOo/runner/lib/TestCase.java
@@ -140,18 +140,16 @@ public abstract class TestCase {
message = e.toString();
System.out.println("Exception while getting Environment "+message);
e.printStackTrace();
+ cleanup(tParam, log);
}
return tEnv;
}
/**
* Disposes the <code>TestEnvironment</code> when it is not needed anymore.
- * The method calls <code>cleanupTestEnvironment()</code>.
*
* @param tEnv the environment to dispose
* @param tParam test parameters
- *
- * @see #cleanupTestEnvironment()
*/
public synchronized void disposeTestEnvironment( TestEnvironment tEnv,
TestParameters tParam ) {
@@ -174,22 +172,6 @@ public abstract class TestCase {
TestParameters tParam, PrintWriter log );
/**
- * Called while disposing a <code>TestEnvironment</code>. In the
- * implementation does nothing. Subclasses can override to clean up
- * the environments created by them.
- *
- * @param tParam test parameters
- * @param tEnv the environment to cleanup
- * @param log writer to log information while testing
- *
- * @see TestEnvironment
- * @see #disposeTestEnvironment()
- */
- protected void cleanupTestEnvironment( TestParameters Param,
- TestEnvironment tEnv, PrintWriter log ) {
- }
-
- /**
* @return the name of the object
*/
public String getObjectName() {
diff --git a/qadevOOo/runner/lib/TestEnvironment.java b/qadevOOo/runner/lib/TestEnvironment.java
index 877f681e3b3c..9848a5b2b633 100644
--- a/qadevOOo/runner/lib/TestEnvironment.java
+++ b/qadevOOo/runner/lib/TestEnvironment.java
@@ -38,23 +38,23 @@ import java.util.Hashtable;
* @see TestCase
*/
-public class TestEnvironment {
+public final class TestEnvironment {
/**
* Contains object relations - auxiliary objects associated with the
* tested object and required for testing.
*/
- protected Hashtable relations = new Hashtable(10);
+ private final Hashtable relations = new Hashtable(10);
/**
* An instance of the tested implementation object.
*/
- protected XInterface testObject;
+ private final XInterface testObject;
/**
* Indicates that the testObject is in invalid state and should notbe
* used for testing anymore.
*/
- protected boolean disposed = false;
+ private boolean disposed = false;
/**
* A reference to TestCase which has created the test environment.
diff --git a/qadevOOo/runner/org/openoffice/Runner.java b/qadevOOo/runner/org/openoffice/Runner.java
index 979fc527f775..a3741774917e 100644
--- a/qadevOOo/runner/org/openoffice/Runner.java
+++ b/qadevOOo/runner/org/openoffice/Runner.java
@@ -182,9 +182,9 @@ public class Runner
}
}
- public static void main(String[] args)
+ public static boolean run(String... args)
{
- System.out.println("OOoRunner Main() version from 20100125 (yyyymmdd)");
+ System.out.println("OOoRunner Main() version from 20100323 (yyyymmdd)");
setStartTime(getTime());
@@ -246,12 +246,16 @@ public class Runner
if (!worked)
{
System.out.println("Job " + param.get("TestJob") + " failed");
- System.exit(-1);
}
else
{
System.out.println("Job " + param.get("TestJob") + " done");
- System.exit(0);
}
+ return worked;
+ }
+
+ public static void main(String[] args)
+ {
+ System.exit(run(args) ? 0 : -1);
}
}
diff --git a/qadevOOo/runner/util/AccessibilityTools.java b/qadevOOo/runner/util/AccessibilityTools.java
index c698839f3149..3fb964a2362b 100644
--- a/qadevOOo/runner/util/AccessibilityTools.java
+++ b/qadevOOo/runner/util/AccessibilityTools.java
@@ -51,18 +51,7 @@ public class AccessibilityTools {
}
public static XAccessible getAccessibleObject(XInterface xObject) {
- XAccessible xAccessible = null;
-
- try {
- xAccessible = (XAccessible) UnoRuntime.queryInterface(
- XAccessible.class, xObject);
- } catch (Exception e) {
- System.out.println(
- "caught exception while getting accessible object" + e);
- e.printStackTrace();
- }
-
- return xAccessible;
+ return UnoRuntime.queryInterface(XAccessible.class, xObject);
}
public static XWindow getCurrentContainerWindow(XMultiServiceFactory msf,
diff --git a/qadevOOo/runner/util/UITools.java b/qadevOOo/runner/util/UITools.java
index 1a639d18b252..c9562949632f 100644
--- a/qadevOOo/runner/util/UITools.java
+++ b/qadevOOo/runner/util/UITools.java
@@ -674,26 +674,6 @@ public class UITools {
}
}
-
- /**
- * fetch the active window which is on the top of the X-desktop
- * @return the active window
- * @throws java.lang.Exception if something fail
- */
- public XWindow getActiveTopWindow() throws java.lang.Exception
- {
- XInterface xToolKit = null;
- try {
- xToolKit = (XInterface) mMSF.createInstance("com.sun.star.awt.Toolkit") ;
- } catch (com.sun.star.uno.Exception e) {
- throw new Exception("Could not toolkit: " + e.toString());
- }
- XExtendedToolkit tk = (XExtendedToolkit)
- UnoRuntime.queryInterface(XExtendedToolkit.class, xToolKit);
- Object atw = tk.getActiveTopWindow();
- return (XWindow) UnoRuntime.queryInterface(XWindow.class, atw);
- }
-
/**
* fetch the window which is equal to the given <CODE>WindowName</CODE>
* @return the named window
diff --git a/qadevOOo/runner/util/utils.java b/qadevOOo/runner/util/utils.java
index 1467edf05375..3f882f10fafb 100644
--- a/qadevOOo/runner/util/utils.java
+++ b/qadevOOo/runner/util/utils.java
@@ -38,11 +38,14 @@ import java.util.ArrayList;
import java.io.RandomAccessFile;
import java.net.Socket;
import java.net.ServerSocket;
+import java.net.URI;
+import java.net.URISyntaxException;
import com.sun.star.beans.XPropertySet;
import com.sun.star.beans.Property;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.uno.UnoRuntime;
+import com.sun.star.ucb.InteractiveAugmentedIOException;
import com.sun.star.ucb.XSimpleFileAccess;
import com.sun.star.lang.XServiceInfo;
@@ -364,18 +367,13 @@ public class utils {
*
*/
public static String getOfficeTemp(XMultiServiceFactory msf) {
- String tmpDir = util.utils.getUsersTempDir();
+ String url = getOfficeUserPath(msf) + "/test-temp/";
try {
- String tmp = (String) getOfficeSettingsValue(msf, "Temp");
- if (!tmp.endsWith(System.getProperty("file.separator"))) {
- tmp += System.getProperty("file.separator");
- }
- tmpDir = getFullURL(tmp);
- } catch (Exception e) {
- System.out.println("Couldn't get Office TEMP");
- e.printStackTrace();
+ new File(new URI(url)).mkdir();
+ } catch (URISyntaxException e) {
+ throw new RuntimeException(e);
}
- return tmpDir;
+ return url;
}
/**
@@ -545,16 +543,10 @@ public class utils {
return res;
}
- /**
- * Copies file to a new location using OpenOffice.org features. If the target
- * file already exists, the file is deleted.
- *
- * @returns <code>true</code> if the file was successfully copied,
- * <code>false</code> if some errors occured (e.g. file is locked, used
- * by another process).
- */
- public static boolean overwriteFile(XMultiServiceFactory xMsf, String oldF, String newF) {
- boolean res = false;
+ private static void overwriteFile_impl(
+ XMultiServiceFactory xMsf, String oldF, String newF)
+ throws InteractiveAugmentedIOException
+ {
try {
Object fileacc = xMsf.createInstance("com.sun.star.comp.ucb.SimpleFileAccess");
@@ -564,15 +556,42 @@ public class utils {
simpleAccess.kill(newF);
}
simpleAccess.copy(oldF, newF);
- res = true;
- } catch (com.sun.star.ucb.InteractiveAugmentedIOException e) {
- return false;
+ } catch (InteractiveAugmentedIOException e) {
+ throw e;
} catch (com.sun.star.uno.Exception e) {
- System.out.println("Couldn't copy " + oldF + " to " + newF + ".");
+ System.out.println("Couldn't copy " + oldF + " to " + newF + ":");
e.printStackTrace();
+ throw new RuntimeException(e);
}
+ }
- return res;
+ /**
+ * Copies file to a new location using OpenOffice.org features. If the target
+ * file already exists, the file is deleted.
+ *
+ * @returns <code>true</code> if the file was successfully copied,
+ * <code>false</code> if some errors occured (e.g. file is locked, used
+ * by another process).
+ */
+ public static boolean tryOverwriteFile(
+ XMultiServiceFactory xMsf, String oldF, String newF)
+ {
+ try {
+ overwriteFile_impl(xMsf, oldF, newF);
+ } catch (InteractiveAugmentedIOException e) {
+ return false;
+ }
+ return true;
+ }
+
+ public static void doOverwriteFile(
+ XMultiServiceFactory xMsf, String oldF, String newF)
+ {
+ try {
+ overwriteFile_impl(xMsf, oldF, newF);
+ } catch (InteractiveAugmentedIOException e) {
+ throw new RuntimeException(e);
+ }
}
public static boolean hasPropertyByName(XPropertySet props, String aName) {
diff --git a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleComponent.java b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleComponent.java
index 5279ed5b79d9..c5e302451c21 100644
--- a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleComponent.java
+++ b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleComponent.java
@@ -167,34 +167,53 @@ public class _XAccessibleComponent extends MultiMethodTest {
boolean locRes = true;
for (int x = -1; x <= bounds.Width; x++) {
- locRes &= !oObj.containsPoint(new Point(x, -1));
- locRes &= !oObj.containsPoint(
- new Point(x, bounds.Height + bounds.Y));
+ if (oObj.containsPoint(new Point(x, -1))) {
+ log.println(
+ "Outer upper and lower bounds CONTAIN some component point"
+ + " (" + x + ", -1) - FAILED");
+ locRes = false;
+ break;
+ }
+ if (oObj.containsPoint(new Point(x, bounds.Height + bounds.Y))) {
+ log.println(
+ "Outer upper and lower bounds CONTAIN some component point"
+ + " (" + x + ", " + bounds.Height + bounds.Y
+ + ") - FAILED");
+ locRes = false;
+ break;
+ }
}
if (locRes) {
log.println("Outer upper and lower bounds contain no component " +
"points - OK");
} else {
- log.println("Outer upper and lower bounds CONTAIN some component " +
- "points - FAILED");
result = false;
}
locRes = true;
for (int y = -1; y <= bounds.Height; y++) {
- locRes &= !oObj.containsPoint(new Point(-1, y));
- locRes &= !oObj.containsPoint(
- new Point(bounds.X + bounds.Width, y));
+ if (oObj.containsPoint(new Point(-1, y))) {
+ log.println(
+ "Outer left and right bounds CONTAIN some component point"
+ + " (-1, " + y + ") - FAILED");
+ locRes = false;
+ break;
+ }
+ if (oObj.containsPoint(new Point(bounds.X + bounds.Width, y))) {
+ log.println(
+ "Outer left and right bounds CONTAIN some component point"
+ + " (" + bounds.X + bounds.Width + ", " + y + ") - FAILED");
+ locRes = false;
+ break;
+ }
}
if (locRes) {
log.println("Outer left and right bounds contain no component " +
"points - OK");
} else {
- log.println("Outer left and right bounds CONTAIN some component " +
- "points - FAILED");
result = false;
}
diff --git a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleContext.java b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleContext.java
index c0668a254195..47b24a337f2c 100644
--- a/qadevOOo/tests/java/ifc/accessibility/_XAccessibleContext.java
+++ b/qadevOOo/tests/java/ifc/accessibility/_XAccessibleContext.java
@@ -327,8 +327,7 @@ public class _XAccessibleContext extends MultiMethodTest {
}
tRes.tested("getLocale()",
- (loc != null) && (loc.Language.length() > 0) &&
- (loc.Country.length() > 0));
+ (loc != null) && (loc.Language.length() > 0));
}
protected boolean checkStates(String[] expectedStateNames,
diff --git a/qadevOOo/tests/java/ifc/awt/_XMessageBoxFactory.java b/qadevOOo/tests/java/ifc/awt/_XMessageBoxFactory.java
index c96d42e91215..9c96506938da 100644
--- a/qadevOOo/tests/java/ifc/awt/_XMessageBoxFactory.java
+++ b/qadevOOo/tests/java/ifc/awt/_XMessageBoxFactory.java
@@ -27,17 +27,18 @@
package ifc.awt;
+import com.sun.star.awt.AsyncCallback;
import com.sun.star.awt.Rectangle;
+import com.sun.star.awt.XCallback;
+import com.sun.star.awt.XMessageBox;
+import com.sun.star.awt.XMessageBoxFactory;
+import com.sun.star.awt.XRequestCallback;
+import com.sun.star.awt.XWindow;
import com.sun.star.awt.XWindowPeer;
import com.sun.star.lang.XMultiServiceFactory;
+import com.sun.star.uno.Any;
+import com.sun.star.uno.UnoRuntime;
import lib.MultiMethodTest;
-
-import com.sun.star.awt.XMessageBoxFactory;
-import com.sun.star.awt.XWindow;
-import com.sun.star.frame.XModel;
-import java.io.PrintWriter;
-import lib.Status;
-import lib.StatusException;
import util.UITools;
/**
@@ -50,81 +51,60 @@ import util.UITools;
* @see com.sun.star.awt.XMessageBoxFactory
*/
public class _XMessageBoxFactory extends MultiMethodTest {
-
public XMessageBoxFactory oObj = null;
- private XWindowPeer the_win = null;
- private XModel xModel = null;
-
- /**
- * Retrieves object relation.
- * @throws StatusException If the relation not found.
- */
- public void before() {
- the_win = (XWindowPeer) tEnv.getObjRelation("WINPEER");
- if (the_win == null)
- throw new StatusException(Status.failed("Relation 'WINPEER' not found")) ;
- xModel = (XModel) tEnv.getObjRelation("XModel");
- if (xModel == null)
- throw new StatusException(Status.failed("Relation 'xModel' not found")) ;
-
- }
-
-
- /**
- * As <code>execute()</code> method is a blocking call,
- * then it must be executed in a separate thread. This
- * thread class just call <code>execute</code> method
- * of tested object.
- */
- protected Thread execThread = new Thread(
- new Runnable() {
- public void run() {
- Rectangle rect = new Rectangle(0,0,100,100);
- oObj.createMessageBox(the_win, rect, "errorbox", 1, "The Title", "The Message") ;
- }
- }) ;
-
- /**
- * Starts the execution of MessageBox in a separate thread.
- * As this call is blocking then the thread execution
- * must not be finished. <p>
- * Has <b>OK</b> status if thread wasn't finished and
- * no exceptions occured.
- */
public void _createMessageBox() {
- boolean result = true ;
-
- log.println("Starting createMessageBox() thread ...") ;
- execThread.start() ;
-
- try {
- execThread.join(200) ;
- } catch (InterruptedException e) {
- log.println("createMessageBox() thread was interrupted") ;
- result = false ;
+ final XMessageBox mb = oObj.createMessageBox(
+ (XWindowPeer) tEnv.getObjRelation("WINPEER"),
+ new Rectangle(0, 0, 100, 100), "errorbox", 1, "The Title",
+ "The Message");
+ final UITools tools = new UITools(
+ (XMultiServiceFactory) tParam.getMSF(),
+ UnoRuntime.queryInterface(XWindow.class, mb));
+ final boolean[] done = new boolean[] { false };
+ final boolean[] good = new boolean[] { false };
+ XRequestCallback async = AsyncCallback.create(
+ tParam.getComponentContext());
+ async.addCallback(
+ new XCallback() {
+ public void notify(Object aData) {
+ mb.execute();
+ synchronized (done) {
+ done[0] = true;
+ done.notifyAll();
+ }
+ }
+ },
+ Any.VOID);
+ async.addCallback(
+ new XCallback() {
+ public void notify(Object aData) {
+ try {
+ tools.clickButton("OK");
+ } catch (RuntimeException e) {
+ throw e;
+ } catch (Exception e) {
+ throw new RuntimeException(e);
+ }
+ synchronized (good) {
+ good[0] = true;
+ }
+ }
+ },
+ Any.VOID);
+ synchronized (done) {
+ while (!done[0]) {
+ try {
+ done.wait();
+ } catch (InterruptedException e) {
+ throw new RuntimeException(e);
+ }
+ }
}
- result &= execThread.isAlive() ;
-
- UITools oUITools = new UITools((XMultiServiceFactory) tParam.getMSF(), xModel);
-
- XWindow xWindow = null;
- try{
- xWindow = oUITools.getActiveTopWindow();
-
- oUITools.printAccessibleTree(log, tParam.getBool("DebugIsActive"));
-
- oUITools.clickButton("OK");
-
- } catch (java.lang.Exception e) {
- e.printStackTrace((PrintWriter) log);
- log.println("Could not cklick 'OK' on messagebox: " + e.toString());
- result = false;
+ boolean ok;
+ synchronized (good) {
+ ok = good[0];
}
-
- tRes.tested("createMessageBox()", result) ;
+ tRes.tested("createMessageBox()", ok);
}
-
}
-
-
diff --git a/qadevOOo/tests/java/ifc/awt/_XSystemChildFactory.java b/qadevOOo/tests/java/ifc/awt/_XSystemChildFactory.java
new file mode 100644
index 000000000000..fec9281871eb
--- /dev/null
+++ b/qadevOOo/tests/java/ifc/awt/_XSystemChildFactory.java
@@ -0,0 +1,40 @@
+/*************************************************************************
+*
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+*
+************************************************************************/
+
+package ifc.awt;
+
+import com.sun.star.awt.XSystemChildFactory;
+import lib.MultiMethodTest;
+
+public final class _XSystemChildFactory extends MultiMethodTest {
+ public XSystemChildFactory oObj;
+
+ public void _createSystemChild() {
+ //TODO
+ tRes.tested("createSystemChild()", true);
+ }
+}
diff --git a/qadevOOo/tests/java/ifc/awt/_XToolkit.java b/qadevOOo/tests/java/ifc/awt/_XToolkit.java
index 20b89b88ace5..8824c3bba9ac 100644
--- a/qadevOOo/tests/java/ifc/awt/_XToolkit.java
+++ b/qadevOOo/tests/java/ifc/awt/_XToolkit.java
@@ -35,6 +35,8 @@ import com.sun.star.awt.XDevice;
import com.sun.star.awt.XRegion;
import com.sun.star.awt.XToolkit;
import com.sun.star.awt.XWindowPeer;
+import com.sun.star.lang.XComponent;
+import com.sun.star.uno.UnoRuntime;
/**
* Testing <code>com.sun.star.awt.XToolkit</code>
@@ -87,6 +89,7 @@ public class _XToolkit extends MultiMethodTest {
if (cWin == null) {
log.println("createWindow() create a NULL Object");
} else {
+ UnoRuntime.queryInterface(XComponent.class, cWin).dispose();
res = true;
}
} catch (com.sun.star.lang.IllegalArgumentException ex) {
@@ -111,6 +114,8 @@ public class _XToolkit extends MultiMethodTest {
if ( (cWins[0] == null) || (cWins[1] == null) ) {
log.println("createWindows() creates NULL Windows");
} else {
+ UnoRuntime.queryInterface(XComponent.class, cWins[0]).dispose();
+ UnoRuntime.queryInterface(XComponent.class, cWins[1]).dispose();
res = true;
}
} catch (com.sun.star.lang.IllegalArgumentException ex) {
diff --git a/qadevOOo/tests/java/ifc/beans/_XMultiPropertyStates.java b/qadevOOo/tests/java/ifc/beans/_XMultiPropertyStates.java
index 0d1f43b8e0c5..552a012f1161 100644
--- a/qadevOOo/tests/java/ifc/beans/_XMultiPropertyStates.java
+++ b/qadevOOo/tests/java/ifc/beans/_XMultiPropertyStates.java
@@ -55,9 +55,8 @@ public class _XMultiPropertyStates extends MultiMethodTest {
public XMultiPropertyStates oObj = null;
- Object[] defaults = null;
- PropertyState[] states = null;
- String[] names = null;
+ private PropertyState[] states = null;
+ private String[] names = null;
public void before() {
names = (String[]) tEnv.getObjRelation("PropertyNames");
@@ -83,7 +82,7 @@ public class _XMultiPropertyStates extends MultiMethodTest {
public void _getPropertyDefaults() {
boolean result = false;
try {
- defaults = oObj.getPropertyDefaults(names);
+ Object[] defaults = oObj.getPropertyDefaults(names);
result = (defaults != null) && defaults.length == names.length;
log.println("Number of default values: " + defaults.length);
} catch (com.sun.star.beans.UnknownPropertyException e) {
diff --git a/qadevOOo/tests/java/ifc/beans/_XPropertySet.java b/qadevOOo/tests/java/ifc/beans/_XPropertySet.java
index 0690dd3713cc..54c1f3431bbf 100644
--- a/qadevOOo/tests/java/ifc/beans/_XPropertySet.java
+++ b/qadevOOo/tests/java/ifc/beans/_XPropertySet.java
@@ -64,7 +64,7 @@ public class _XPropertySet extends MultiMethodTest {
/**
* Flag that indicates change listener was called.
*/
- boolean propertyChanged = false;
+ private boolean propertyChanged = false;
/**
* Listener that must be called on bound property changing.
@@ -79,12 +79,12 @@ public class _XPropertySet extends MultiMethodTest {
public void disposing (EventObject obj) {}
};
- XPropertyChangeListener PClistener = new MyChangeListener();
+ private final XPropertyChangeListener PClistener = new MyChangeListener();
/**
* Flag that indicates veto listener was called.
*/
- boolean vetoableChanged = false;
+ private boolean vetoableChanged = false;
/**
* Listener that must be called on constrained property changing.
@@ -99,19 +99,19 @@ public class _XPropertySet extends MultiMethodTest {
public void disposing (EventObject obj) {}
};
- XVetoableChangeListener VClistener = new MyVetoListener();
+ private final XVetoableChangeListener VClistener = new MyVetoListener();
/**
* Structure that collects three properties of each type to test :
* Constrained, Bound and Normal.
*/
- public class PropsToTest {
+ private final class PropsToTest {
String constrained = null;
String bound = null;
String normal = null;
}
- PropsToTest PTT = new PropsToTest();
+ private final PropsToTest PTT = new PropsToTest();
/**
* Tests method <code>getPropertySetInfo</code>. After test completed
@@ -470,7 +470,7 @@ public class _XPropertySet extends MultiMethodTest {
* Gets the properties being tested. Searches and stores by one
* property of each kind (Bound, Vetoable, Normal).
*/
- public PropsToTest getPropsToTest(XPropertySetInfo xPSI) {
+ public void getPropsToTest(XPropertySetInfo xPSI) {
Property[] properties = xPSI.getProperties();
String bound = "";
@@ -544,9 +544,6 @@ public class _XPropertySet extends MultiMethodTest {
//get a random normal property
PTT.normal=getRandomString(normal);
-
- return PTT;
-
}
/**
diff --git a/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java b/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
index b11659265441..fa987a09a227 100644
--- a/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
+++ b/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
@@ -36,6 +36,7 @@ import lib.StatusException;
import lib.Status;
import com.sun.star.beans.PropertyValue;
import com.sun.star.beans.XPropertySet;
+import com.sun.star.sdb.SQLFilterOperator;
/**
* Testing <code>com.sun.star.sdb.XSingleSelectQueryComposer</code>
@@ -172,7 +173,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
boolean ok = true;
try{
- oObj.appendFilterByColumn(xProp, true);
+ oObj.appendFilterByColumn(xProp, true,SQLFilterOperator.EQUAL);
log.println("appendFilterByColumn: " + xQueryAna.getFilter());
ok = ok && (xQueryAna.getFilter().indexOf(colName) > 0);
@@ -183,7 +184,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
try{
- oObj.appendFilterByColumn(xProp, false);
+ oObj.appendFilterByColumn(xProp, false,SQLFilterOperator.EQUAL);
log.println("appendFilterByColumn: " + xQueryAna.getFilter());
ok = ok && (xQueryAna.getFilter().indexOf(colName) > 0);
@@ -194,8 +195,8 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
try{
XPropertySet dummy = null;
- oObj.appendFilterByColumn(dummy, true);
- log.println("unexpected Exception was not thorwn");
+ oObj.appendFilterByColumn(dummy, true,SQLFilterOperator.EQUAL);
+ log.println("expected Exception was not thrown");
tRes.tested("appendFilterByColumn()", false);
} catch (com.sun.star.sdbc.SQLException e){
@@ -227,7 +228,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
try{
XPropertySet dummy = null;
oObj.appendGroupByColumn(dummy);
- log.println("unexpected Exception was not thorwn");
+ log.println("expected Exception was not thrown");
tRes.tested("appendGroupByColumn()", false);
} catch (com.sun.star.sdbc.SQLException e){
@@ -320,7 +321,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
boolean ok = true;
try{
- oObj.appendHavingClauseByColumn(xProp, true);
+ oObj.appendHavingClauseByColumn(xProp, true,SQLFilterOperator.EQUAL);
log.println("appendHavingClauseByColumn: " + xQueryAna.getFilter());
ok = ok && (xQueryAna.getFilter().indexOf(colName) > 0);
@@ -330,8 +331,8 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
}
try{
XPropertySet dummy = null;
- oObj.appendHavingClauseByColumn(dummy, true);
- log.println("unexpected Exception was not thorwn");
+ oObj.appendHavingClauseByColumn(dummy, true,SQLFilterOperator.EQUAL);
+ log.println("expected Exception was not thrown");
tRes.tested("appendHavingClauseByColumn()", false);
} catch (com.sun.star.sdbc.SQLException e){
@@ -363,7 +364,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
try{
XPropertySet dummy = null;
oObj.appendOrderByColumn(dummy, true);
- log.println("unexpected Exception was not thorwn");
+ log.println("expected Exception was not thrown");
tRes.tested("appendOrderByColumn()", false);
} catch (com.sun.star.sdbc.SQLException e){
diff --git a/qadevOOo/tests/java/ifc/sheet/_XRangeSelection.java b/qadevOOo/tests/java/ifc/sheet/_XRangeSelection.java
index 8df7366842fd..bb61dbe55049 100644
--- a/qadevOOo/tests/java/ifc/sheet/_XRangeSelection.java
+++ b/qadevOOo/tests/java/ifc/sheet/_XRangeSelection.java
@@ -250,10 +250,6 @@ public class _XRangeSelection extends MultiMethodTest {
throw new StatusException("Could not create 'com.sun.star.awt.Toolkit'.", e);
}
XExtendedToolkit xExtendedToolkit = (XExtendedToolkit)UnoRuntime.queryInterface(XExtendedToolkit.class, aToolkit);
- AccessibilityTools accTools = new AccessibilityTools();
- XWindow xWindow = (XWindow)UnoRuntime.queryInterface(XWindow.class, xExtendedToolkit.getActiveTopWindow());
- XAccessible xRoot = accTools.getAccessibleObject(xWindow);
-
XTopWindow tw = null;
XAccessibleComponent xAccessibleComponent = null;
@@ -286,7 +282,7 @@ public class _XRangeSelection extends MultiMethodTest {
return null;
}
- xWindow = (XWindow)UnoRuntime.queryInterface(XWindow.class, tw);
+ XWindow xWindow = (XWindow)UnoRuntime.queryInterface(XWindow.class, tw);
Rectangle posSize = xWindow.getPosSize();
// compare the center point with the dimensions of the current top window
diff --git a/qadevOOo/tests/java/mod/_basctl/AccessibleShape.java b/qadevOOo/tests/java/mod/_basctl/AccessibleShape.java
index 39833520920f..1dd3feb3e4ec 100644
--- a/qadevOOo/tests/java/mod/_basctl/AccessibleShape.java
+++ b/qadevOOo/tests/java/mod/_basctl/AccessibleShape.java
@@ -32,7 +32,6 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.awt.PosSize;
import com.sun.star.awt.Rectangle;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XDesktop;
@@ -58,7 +57,6 @@ public class AccessibleShape extends TestCase {
XTextDocument xTextDoc = null;
XInterface oObj = null;
- XWindow basicIDE = null;
protected void cleanup(TestParameters Param, PrintWriter log) {
log.println("Cleaning up");
@@ -115,15 +113,9 @@ public class AccessibleShape extends TestCase {
throw new StatusException("Couldn't get toolkit", e );
}
-
- XExtendedToolkit tk = (XExtendedToolkit)
- UnoRuntime.queryInterface(XExtendedToolkit.class,oObj);
-
-
AccessibilityTools at = new AccessibilityTools();
- basicIDE = (XWindow)
- UnoRuntime.queryInterface(XWindow.class,tk.getActiveTopWindow());
+ final XWindow basicIDE = xFrame.getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(basicIDE);
@@ -138,23 +130,19 @@ public class AccessibleShape extends TestCase {
tEnv.addObjRelation("Destroy", Boolean.TRUE);
- final XExtendedToolkit subtk = tk;
-
tEnv.addObjRelation("EventProducer",
new ifc.accessibility._XAccessibleEventBroadcaster.EventProducer() {
public void fireEvent() {
- XWindow xWin = (XWindow) UnoRuntime.queryInterface(
- XWindow.class, subtk.getActiveTopWindow());
- Rectangle oldPosSize = xWin.getPosSize();
+ Rectangle oldPosSize = basicIDE.getPosSize();
Rectangle newPosSize = new Rectangle();
newPosSize.Width = oldPosSize.Width/2;
newPosSize.Height = oldPosSize.Height/2;
newPosSize.X = oldPosSize.X + 20;
newPosSize.Y = oldPosSize.Y + 20;
- xWin.setPosSize(newPosSize.X, newPosSize.Y, newPosSize.Width,
+ basicIDE.setPosSize(newPosSize.X, newPosSize.Y, newPosSize.Width,
newPosSize.Height, PosSize.POSSIZE);
utils.shortWait(1000);
- xWin.setPosSize(oldPosSize.X, oldPosSize.Y, oldPosSize.Width,
+ basicIDE.setPosSize(oldPosSize.X, oldPosSize.Y, oldPosSize.Width,
oldPosSize.Height, PosSize.POSSIZE);
}
});
diff --git a/qadevOOo/tests/java/mod/_dbaccess/ConnectionLineAccessibility.java b/qadevOOo/tests/java/mod/_dbaccess/ConnectionLineAccessibility.java
index 27efe8cf0447..c515ffaf8c01 100644
--- a/qadevOOo/tests/java/mod/_dbaccess/ConnectionLineAccessibility.java
+++ b/qadevOOo/tests/java/mod/_dbaccess/ConnectionLineAccessibility.java
@@ -39,12 +39,12 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.awt.PosSize;
import com.sun.star.awt.Rectangle;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.beans.XPropertySet;
import com.sun.star.container.XNameAccess;
import com.sun.star.container.XNameContainer;
+import com.sun.star.frame.XModel;
import com.sun.star.frame.XStorable;
import com.sun.star.lang.XComponent;
import com.sun.star.lang.XMultiServiceFactory;
@@ -347,12 +347,8 @@ public class ConnectionLineAccessibility extends TestCase
util.utils.shortWait(1000);
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, toolkit);
-
- Object atw = tk.getActiveTopWindow();
-
- xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, atw);
+ xWindow = UnoRuntime.queryInterface(XModel.class, QueryComponent).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = AccessibilityTools.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_dbaccess/JoinViewAccessibility.java b/qadevOOo/tests/java/mod/_dbaccess/JoinViewAccessibility.java
index 5644fd3e995e..8ec0c0db1bfa 100644
--- a/qadevOOo/tests/java/mod/_dbaccess/JoinViewAccessibility.java
+++ b/qadevOOo/tests/java/mod/_dbaccess/JoinViewAccessibility.java
@@ -39,12 +39,12 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.awt.PosSize;
import com.sun.star.awt.Rectangle;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.beans.XPropertySet;
import com.sun.star.container.XNameAccess;
import com.sun.star.container.XNameContainer;
+import com.sun.star.frame.XModel;
import com.sun.star.frame.XStorable;
import com.sun.star.lang.XComponent;
import com.sun.star.lang.XMultiServiceFactory;
@@ -326,12 +326,8 @@ public class JoinViewAccessibility extends TestCase {
QueryComponent = DesktopTools.loadDoc ((XMultiServiceFactory) Param.getMSF (),".component:DB/QueryDesign",loadProps);
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface (
- XExtendedToolkit.class, toolkit);
-
- Object atw = tk.getActiveTopWindow ();
-
- xWindow = (XWindow) UnoRuntime.queryInterface (XWindow.class, atw);
+ xWindow = UnoRuntime.queryInterface(XModel.class, QueryComponent).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = AccessibilityTools.getAccessibleObject (xWindow);
diff --git a/qadevOOo/tests/java/mod/_dbaccess/ORowSet.java b/qadevOOo/tests/java/mod/_dbaccess/ORowSet.java
index 37311b118d0e..c349d5dcdb28 100644
--- a/qadevOOo/tests/java/mod/_dbaccess/ORowSet.java
+++ b/qadevOOo/tests/java/mod/_dbaccess/ORowSet.java
@@ -293,7 +293,7 @@ public class ORowSet extends TestCase {
oldF = utils.getFullURL(origDB);
newF = tempFolder + tableName + ".dbf";
}
- while ( !utils.overwriteFile( orb, oldF, newF ) );
+ while ( !utils.tryOverwriteFile( orb, oldF, newF ) );
m_tableFile = newF;
}
diff --git a/qadevOOo/tests/java/mod/_dbaccess/TableWindowAccessibility.java b/qadevOOo/tests/java/mod/_dbaccess/TableWindowAccessibility.java
index 1617f34cbbef..4c39c1590890 100644
--- a/qadevOOo/tests/java/mod/_dbaccess/TableWindowAccessibility.java
+++ b/qadevOOo/tests/java/mod/_dbaccess/TableWindowAccessibility.java
@@ -39,12 +39,12 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.accessibility.XAccessibleComponent;
import com.sun.star.awt.Point;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.beans.XPropertySet;
import com.sun.star.container.XNameAccess;
import com.sun.star.container.XNameContainer;
+import com.sun.star.frame.XModel;
import com.sun.star.frame.XStorable;
import com.sun.star.lang.XComponent;
import com.sun.star.lang.XMultiServiceFactory;
@@ -300,12 +300,8 @@ public class TableWindowAccessibility extends TestCase {
QueryComponent = DesktopTools.loadDoc((XMultiServiceFactory) Param.getMSF (),".component:DB/QueryDesign",loadProps);
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, toolkit);
-
- Object atw = tk.getActiveTopWindow();
-
- xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, atw);
+ xWindow = UnoRuntime.queryInterface(XModel.class, QueryComponent).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = AccessibilityTools.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_forms/ODatabaseForm.java b/qadevOOo/tests/java/mod/_forms/ODatabaseForm.java
index fe44c30e7c05..4b360e20fd10 100644
--- a/qadevOOo/tests/java/mod/_forms/ODatabaseForm.java
+++ b/qadevOOo/tests/java/mod/_forms/ODatabaseForm.java
@@ -311,7 +311,7 @@ public class ODatabaseForm extends TestCase {
oldF = utils.getFullURL(origDB);
newF = utils.getOfficeTemp((XMultiServiceFactory) tParam.getMSF()) + tableName +
".dbf";
- } while (!utils.overwriteFile(((XMultiServiceFactory) tParam.getMSF()), oldF, newF) &&
+ } while (!utils.tryOverwriteFile(((XMultiServiceFactory) tParam.getMSF()), oldF, newF) &&
(uniqueSuffix++ < 50));
}
}
diff --git a/qadevOOo/tests/java/mod/_fwk/ModuleUIConfigurationManager.java b/qadevOOo/tests/java/mod/_fwk/ModuleUIConfigurationManager.java
index c4a81bb06d8d..7b30a94b3293 100755
--- a/qadevOOo/tests/java/mod/_fwk/ModuleUIConfigurationManager.java
+++ b/qadevOOo/tests/java/mod/_fwk/ModuleUIConfigurationManager.java
@@ -70,18 +70,21 @@ public class ModuleUIConfigurationManager extends TestCase {
*/
protected void cleanup(TestParameters tParam, PrintWriter log) {
log.println(" disposing xTextDoc ");
-
- try {
- XCloseable closer = (XCloseable) UnoRuntime.queryInterface(
- XCloseable.class, xTextDoc);
- closer.close(true);
- } catch (com.sun.star.util.CloseVetoException e) {
- log.println("couldn't close document");
- } catch (com.sun.star.lang.DisposedException e) {
- log.println("couldn't close document");
+ if (xTextDoc != null) {
+ try {
+ XCloseable closer = (XCloseable) UnoRuntime.queryInterface(
+ XCloseable.class, xTextDoc);
+ closer.close(true);
+ } catch (com.sun.star.util.CloseVetoException e) {
+ log.println("couldn't close document");
+ } catch (com.sun.star.lang.DisposedException e) {
+ log.println("couldn't close document");
+ }
}
log.println(" disposing storage");
- xStore.dispose();
+ if (xStore != null) {
+ xStore.dispose();
+ }
}
/**
diff --git a/qadevOOo/tests/java/mod/_sd/DrawController_DrawView.java b/qadevOOo/tests/java/mod/_sd/DrawController_DrawView.java
index 3243ec48e3c5..be510ff1f98c 100644
--- a/qadevOOo/tests/java/mod/_sd/DrawController_DrawView.java
+++ b/qadevOOo/tests/java/mod/_sd/DrawController_DrawView.java
@@ -47,7 +47,6 @@ import com.sun.star.drawing.XDrawPagesSupplier;
import com.sun.star.drawing.XShape;
import com.sun.star.drawing.XShapes;
import com.sun.star.frame.XController;
-import com.sun.star.frame.XDesktop;
import com.sun.star.frame.XFrame;
import com.sun.star.frame.XModel;
import com.sun.star.lang.XComponent;
@@ -87,23 +86,10 @@ import com.sun.star.util.XModifiable;
* @see ifc.drawing._XDrawView
*/
public class DrawController_DrawView extends TestCase {
- static XDesktop the_Desk;
static XComponent xDrawDoc;
static XComponent xSecondDrawDoc;
/**
- * Creates the instance of the service
- * <code>com.sun.star.frame.Desktop</code>.
- * @see com.sun.star.frame.Desktop
- */
- protected void initialize(TestParameters Param, PrintWriter log) {
- the_Desk = (XDesktop)
- UnoRuntime.queryInterface(
- XDesktop.class, DesktopTools.createDesktop(
- (XMultiServiceFactory)Param.getMSF()) );
- }
-
- /**
* Called while disposing a <code>TestEnvironment</code>.
* Disposes Impress documents.
* @param tParam test parameters
@@ -216,9 +202,10 @@ public class DrawController_DrawView extends TestCase {
XModel aModel2 = (XModel)
UnoRuntime.queryInterface(XModel.class, xSecondDrawDoc);
+ XController aController2 = aModel2.getCurrentController();
XWindow anotherWindow = (XWindow) UnoRuntime.queryInterface(
- XWindow.class,aModel2.getCurrentController());
+ XWindow.class, aController2);
log.println( "creating a new environment for impress view object" );
TestEnvironment tEnv = new TestEnvironment( oObj );
@@ -276,16 +263,13 @@ public class DrawController_DrawView extends TestCase {
tEnv.addObjRelation("XUserInputInterception.XModel", aModel);
- XFrame the_frame = the_Desk.getCurrentFrame();
+ XFrame the_frame = aController2.getFrame();
tEnv.addObjRelation("Frame", the_frame);
- aModel = (XModel)
- UnoRuntime.queryInterface(XModel.class, xSecondDrawDoc);
//Adding ObjRelations for XController
- tEnv.addObjRelation("SecondModel", aModel);
+ tEnv.addObjRelation("SecondModel", aModel2);
- XController secondController = aModel.getCurrentController();
- tEnv.addObjRelation("SecondController", secondController);
+ tEnv.addObjRelation("SecondController", aController2);
tEnv.addObjRelation("XDispatchProvider.URL",
"slot:27009");
diff --git a/qadevOOo/tests/java/mod/_sfx/StandaloneDocumentInfo.java b/qadevOOo/tests/java/mod/_sfx/StandaloneDocumentInfo.java
index 715fdc72d371..81e0d459c0a3 100644
--- a/qadevOOo/tests/java/mod/_sfx/StandaloneDocumentInfo.java
+++ b/qadevOOo/tests/java/mod/_sfx/StandaloneDocumentInfo.java
@@ -87,7 +87,7 @@ public class StandaloneDocumentInfo extends TestCase {
destUrl = utils.getOfficeTemp((XMultiServiceFactory)tParam.getMSF()) +
"SfxStandaloneDocInfoObject.sdw";
- utils.overwriteFile((XMultiServiceFactory)tParam.getMSF(), srcUrl, destUrl) ;
+ utils.doOverwriteFile((XMultiServiceFactory)tParam.getMSF(), srcUrl, destUrl) ;
}
/**
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBox.java b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBox.java
index 4f6d849844d4..358819ee733d 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBox.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBox.java
@@ -38,7 +38,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -158,21 +157,9 @@ public class AccessibleBrowseBox extends TestCase {
shortWait();
- try {
- oObj = (XInterface) ((XMultiServiceFactory) tParam.getMSF()).createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(XExtendedToolkit.class, oObj);
-
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderBar.java b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderBar.java
index 45b9d3ed19d3..b953abde994e 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderBar.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderBar.java
@@ -43,7 +43,6 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.accessibility.XAccessibleComponent;
import com.sun.star.awt.Point;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -204,20 +203,9 @@ public class AccessibleBrowseBoxHeaderBar extends TestCase {
XInterface oObj = null;
- try {
- oObj = (XInterface) ( (XMultiServiceFactory) tParam.getMSF())
- .createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderCell.java b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderCell.java
index be46f92503ee..2e7cb013e2ee 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderCell.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxHeaderCell.java
@@ -40,7 +40,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -202,21 +201,9 @@ public class AccessibleBrowseBoxHeaderCell extends TestCase {
throw new StatusException("Could not select Biblio-Database", ex);
}
-
- try {
- oObj = (XInterface) ((XMultiServiceFactory)tParam.getMSF()).createInstance
- ("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- throw new StatusException("Couldn't get toolkit", e );
- }
-
- XExtendedToolkit tk = (XExtendedToolkit)
- UnoRuntime.queryInterface(XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow)
- UnoRuntime.queryInterface(XWindow.class, tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTable.java b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTable.java
index 5c0b40a2c944..6842fd6da8e2 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTable.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTable.java
@@ -39,7 +39,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -199,22 +198,9 @@ public class AccessibleBrowseBoxTable extends TestCase {
XInterface oObj = null;
- try {
- oObj = (XInterface)((XMultiServiceFactory)tParam.getMSF())
- .createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTableCell.java b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTableCell.java
index 83d74f295f4c..973f0bf9c324 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTableCell.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleBrowseBoxTableCell.java
@@ -39,7 +39,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -191,26 +190,9 @@ public class AccessibleBrowseBoxTableCell extends TestCase {
shortWait();
- try {
- oObj = (XInterface) ((XMultiServiceFactory)tParam.getMSF()).createInstance
- ("com.sun.star.awt.Toolkit") ;
- xInit.initialize(params);
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e );
- }
-
- shortWait();
-
- XExtendedToolkit tk = (XExtendedToolkit)
- UnoRuntime.queryInterface(XExtendedToolkit.class,oObj);
-
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow)
- UnoRuntime.queryInterface(XWindow.class,tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleTabBar.java b/qadevOOo/tests/java/mod/_svtools/AccessibleTabBar.java
index 903b9341eb2a..c646aa1eaf25 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleTabBar.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleTabBar.java
@@ -38,8 +38,8 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.awt.PosSize;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
+import com.sun.star.frame.XModel;
import com.sun.star.lang.XComponent;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.uno.UnoRuntime;
@@ -108,23 +108,12 @@ public class AccessibleTabBar extends TestCase {
XInterface oObj = null;
- try {
- oObj = (XInterface) msf.createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
shortWait();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
+ XWindow xWindow = UnoRuntime.queryInterface(XModel.class, xDoc).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
at.printAccessibleTree(log, xRoot, tParam.getBool(util.PropertyName.DEBUG_IS_ACTIVE));
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBox.java b/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBox.java
index 2dfaa15448ad..6134bd1a3aef 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBox.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBox.java
@@ -39,7 +39,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -179,22 +178,9 @@ public class AccessibleTreeListBox extends TestCase {
XInterface oObj = null;
- try {
- oObj = (XInterface) ((XMultiServiceFactory)tParam.getMSF()).createInstance
- ("com.sun.star.awt.Toolkit") ;
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e );
- }
-
- XExtendedToolkit tk = (XExtendedToolkit)
- UnoRuntime.queryInterface(XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow)
- UnoRuntime.queryInterface(XWindow.class, tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBoxEntry.java b/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBoxEntry.java
index 7d1014d7ec4d..c4ee3562d720 100644
--- a/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBoxEntry.java
+++ b/qadevOOo/tests/java/mod/_svtools/AccessibleTreeListBoxEntry.java
@@ -39,7 +39,6 @@ import util.SOfficeFactory;
import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
import com.sun.star.beans.PropertyValue;
import com.sun.star.frame.XController;
@@ -231,24 +230,11 @@ public class AccessibleTreeListBoxEntry extends TestCase {
throw new StatusException("Could not select Biblio-Database", ex);
}
-
- try {
- shortWait();
- oObj = (XInterface) ( (XMultiServiceFactory) tParam.getMSF())
- .createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- throw new StatusException("Couldn't get toolkit", e);
- }
-
shortWait();
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
+ XWindow xWindow = secondController.getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
diff --git a/qadevOOo/tests/java/mod/_sw/CharacterStyle.java b/qadevOOo/tests/java/mod/_sw/CharacterStyle.java
index d1f9c6018436..4c91540d52c2 100755
--- a/qadevOOo/tests/java/mod/_sw/CharacterStyle.java
+++ b/qadevOOo/tests/java/mod/_sw/CharacterStyle.java
@@ -55,15 +55,13 @@ import util.utils;
* @see com.sun.star.style.CharacterStyle
*/
public class CharacterStyle extends TestCase {
-
- XTextDocument xTextDoc;
- SOfficeFactory SOF = null;
+ private XTextDocument xTextDoc;
/**
* Creates text document.
*/
protected void initialize( TestParameters tParam, PrintWriter log ) {
- SOF = SOfficeFactory.getFactory( (XMultiServiceFactory)tParam.getMSF() );
+ SOfficeFactory SOF = SOfficeFactory.getFactory( (XMultiServiceFactory)tParam.getMSF() );
try {
log.println( "creating a textdocument" );
xTextDoc = SOF.createTextDoc( null );
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleFixedText.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleFixedText.java
index e0ad77dfa753..3bc7e81885c3 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleFixedText.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleFixedText.java
@@ -34,7 +34,6 @@ import com.sun.star.awt.PosSize;
import com.sun.star.awt.XControl;
import com.sun.star.awt.XControlContainer;
import com.sun.star.awt.XControlModel;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XFixedText;
import com.sun.star.awt.XWindow;
import com.sun.star.lang.XMultiServiceFactory;
@@ -150,17 +149,11 @@ public class AccessibleFixedText extends TestCase {
throw new StatusException("Couldn't get toolkit", e);
}
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
shortWait();
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
-
- XAccessible xRoot = at.getAccessibleObject(xWindow);
+ XAccessible xRoot = at.getAccessibleObject(xWinDlg);
at.printAccessibleTree(log, xRoot, Param.getBool(util.PropertyName.DEBUG_IS_ACTIVE));
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenu.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenu.java
index d309f8cd969d..4eaec80dcd81 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenu.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenu.java
@@ -31,8 +31,8 @@ import com.sun.star.accessibility.XAccessible;
import com.sun.star.accessibility.XAccessibleAction;
import com.sun.star.accessibility.XAccessibleContext;
import com.sun.star.accessibility.XAccessibleText;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
+import com.sun.star.frame.XModel;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.text.XTextDocument;
import com.sun.star.uno.UnoRuntime;
@@ -102,23 +102,10 @@ public class AccessibleMenu extends TestCase {
throw new StatusException("Can't create document", e);
}
- XInterface oObj = null;
-
- try {
- oObj = (XInterface) msf.createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
shortWait();
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- tk.getActiveTopWindow());
+ XWindow xWindow = UnoRuntime.queryInterface(XModel.class, xTextDoc).
+ getCurrentController().getFrame().getContainerWindow();
AccessibilityTools at = new AccessibilityTools();
@@ -127,6 +114,7 @@ public class AccessibleMenu extends TestCase {
at.printAccessibleTree(log, xRoot, Param.getBool(util.PropertyName.DEBUG_IS_ACTIVE));
XAccessibleContext menubar = at.getAccessibleObjectForRole(xRoot,
AccessibleRole.MENU_BAR);
+ XInterface oObj = null;
Object menu2 = null;
try {
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuBar.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuBar.java
index 86929c463167..2441bdaa7075 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuBar.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuBar.java
@@ -30,8 +30,8 @@ import com.sun.star.accessibility.AccessibleRole;
import com.sun.star.accessibility.XAccessible;
import com.sun.star.accessibility.XAccessibleAction;
import com.sun.star.accessibility.XAccessibleComponent;
-import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
+import com.sun.star.frame.XModel;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.text.XTextDocument;
import com.sun.star.uno.UnoRuntime;
@@ -83,34 +83,18 @@ public class AccessibleMenuBar extends TestCase {
*/
protected TestEnvironment createTestEnvironment(TestParameters Param,
PrintWriter log) {
- XInterface oObj = null;
-
- try {
- oObj = (XInterface) ((XMultiServiceFactory) Param.getMSF()).createInstance(
- "com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
shortWait();
AccessibilityTools at = new AccessibilityTools();
- Object atw = tk.getActiveTopWindow();
-
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- atw);
+ XWindow xWindow = UnoRuntime.queryInterface(XModel.class, xTextDoc).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
at.printAccessibleTree(log, xRoot, Param.getBool(util.PropertyName.DEBUG_IS_ACTIVE));
- oObj = at.getAccessibleObjectForRole(xRoot, AccessibleRole.MENU_BAR);
+ XInterface oObj = at.getAccessibleObjectForRole(xRoot, AccessibleRole.MENU_BAR);
log.println("ImplementationName " + utils.getImplName(oObj));
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuSeparator.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuSeparator.java
index 4c68b532b4b2..f05bcb025803 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuSeparator.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleMenuSeparator.java
@@ -32,6 +32,7 @@ import com.sun.star.accessibility.XAccessibleAction;
import com.sun.star.accessibility.XAccessibleContext;
import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
+import com.sun.star.frame.XModel;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.text.XTextDocument;
import com.sun.star.uno.UnoRuntime;
@@ -82,27 +83,12 @@ public class AccessibleMenuSeparator extends TestCase {
*/
protected TestEnvironment createTestEnvironment(TestParameters Param,
PrintWriter log) {
- XInterface oObj = null;
-
- try {
- oObj = (XInterface) msf.createInstance("com.sun.star.awt.Toolkit");
- } catch (com.sun.star.uno.Exception e) {
- log.println("Couldn't get toolkit");
- e.printStackTrace(log);
- throw new StatusException("Couldn't get toolkit", e);
- }
-
- XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(
- XExtendedToolkit.class, oObj);
-
shortWait();
AccessibilityTools at = new AccessibilityTools();
- Object atw = tk.getActiveTopWindow();
-
- XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class,
- atw);
+ XWindow xWindow = UnoRuntime.queryInterface(XModel.class, xTextDoc).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
@@ -110,6 +96,7 @@ public class AccessibleMenuSeparator extends TestCase {
XAccessibleContext MenuBar = at.getAccessibleObjectForRole(xRoot,
AccessibleRole.MENU_BAR);
XAccessibleAction act = null;
+ XInterface oObj = null;
try {
//activate Edit-Menu
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleStatusBar.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleStatusBar.java
index 432493d9d134..32dd630370a3 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleStatusBar.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleStatusBar.java
@@ -32,7 +32,6 @@ import com.sun.star.awt.PosSize;
import com.sun.star.awt.Rectangle;
import com.sun.star.awt.XExtendedToolkit;
import com.sun.star.awt.XWindow;
-import com.sun.star.frame.XDesktop;
import com.sun.star.frame.XModel;
import com.sun.star.lang.XMultiServiceFactory;
import com.sun.star.text.XTextDocument;
@@ -84,19 +83,9 @@ import util.SOfficeFactory;
* @see ifc.accessibility.XAccessibleAction
*/
public class AccessibleStatusBar extends TestCase {
- private static XDesktop the_Desk;
private static XTextDocument xTextDoc;
/**
- * Creates the Desktop service (<code>com.sun.star.frame.Desktop</code>).
- */
- protected void initialize(TestParameters Param, PrintWriter log) {
- the_Desk = (XDesktop) UnoRuntime.queryInterface(XDesktop.class,
- DesktopTools.createDesktop(
- (XMultiServiceFactory) Param.getMSF()));
- }
-
- /**
* Disposes the document, if exists, created in
* <code>createTestEnvironment</code> method.
*/
@@ -155,16 +144,13 @@ public class AccessibleStatusBar extends TestCase {
throw new StatusException("Couldn't create document", e);
}
- XModel aModel = (XModel) UnoRuntime.queryInterface(XModel.class,
- xTextDoc);
-
XInterface oObj = null;
AccessibilityTools at = new AccessibilityTools();
- XWindow xWindow = at.getCurrentContainerWindow(
- (XMultiServiceFactory) tParam.getMSF(),
- aModel);
+ final XWindow xWindow =
+ UnoRuntime.queryInterface(XModel.class, xTextDoc).
+ getCurrentController().getFrame().getContainerWindow();
XAccessible xRoot = at.getAccessibleObject(xWindow);
@@ -180,15 +166,14 @@ public class AccessibleStatusBar extends TestCase {
tEnv.addObjRelation("EventProducer",
new ifc.accessibility._XAccessibleEventBroadcaster.EventProducer() {
public void fireEvent() {
- XWindow xWin = (XWindow) UnoRuntime.queryInterface(
- XWindow.class, tk.getActiveTopWindow());
- Rectangle newPosSize = xWin.getPosSize();
+ Rectangle newPosSize = xWindow.getPosSize();
newPosSize.Width = newPosSize.Width - 20;
newPosSize.Height = newPosSize.Height - 20;
newPosSize.X = newPosSize.X + 20;
newPosSize.Y = newPosSize.Y + 20;
- xWin.setPosSize(newPosSize.X, newPosSize.Y, newPosSize.Width,
- newPosSize.Height, PosSize.POSSIZE);
+ xWindow.setPosSize(
+ newPosSize.X, newPosSize.Y, newPosSize.Width,
+ newPosSize.Height, PosSize.POSSIZE);
}
});
diff --git a/qadevOOo/tests/java/mod/_toolkit/AccessibleToolBox.java b/qadevOOo/tests/java/mod/_toolkit/AccessibleToolBox.java
index 381ef7571b9f..c02017508695 100644
--- a/qadevOOo/tests/java/mod/_toolkit/AccessibleToolBox.java
+++ b/qadevOOo/tests/java/mod/_toolkit/AccessibleToolBox.java
@@ -47,8 +47,6 @@ import lib.TestParameters;
import util.AccessibilityTools;
import util.DesktopTools;
import util.SOfficeFactory;
-import util.UITools;
-
/**
* Test for object that implements the following interfaces :
@@ -141,20 +139,10 @@ public class AccessibleToolBox extends TestCase {
throw new StatusException("Couldn't create document", e);
}
- XModel aModel = (XModel) UnoRuntime.queryInterface(XModel.class,
- xTextDoc);
-
XInterface oObj = null;
- UITools oUI = new UITools(msf, aModel);
-
- XWindow xWindow = null;
- try {
- xWindow = oUI.getActiveTopWindow();
- } catch (Exception ex) {
- ex.printStackTrace(log);
- throw new StatusException("Couldn't get active top window", ex);
- }
+ XWindow xWindow = UnoRuntime.queryInterface(XModel.class, xTextDoc).
+ getCurrentController().getFrame().getContainerWindow();
AccessibilityTools at = new AccessibilityTools();
diff --git a/qadevOOo/tests/java/mod/_toolkit/UnoTreeControl.java b/qadevOOo/tests/java/mod/_toolkit/UnoTreeControl.java
index 8b6aacee0734..5be41be69f27 100644
--- a/qadevOOo/tests/java/mod/_toolkit/UnoTreeControl.java
+++ b/qadevOOo/tests/java/mod/_toolkit/UnoTreeControl.java
@@ -220,8 +220,6 @@ public class UnoTreeControl extends TestCase {
});
System.out.println("ImplementationName: " + utils.getImplName(oObj));
- //this.getAccessibleContext(xNode);
-
return tEnv;
} // finish method getTestEnvironment
@@ -289,26 +287,6 @@ public class UnoTreeControl extends TestCase {
}
}
- private XAccessibleContext getAccessibleContext(XMutableTreeNode xNode ){
-
- UITools oDocUITools = new UITools(this.mxMSF, this.xTextDoc);
-
- XWindow xDialogWindow = null;
- try {
-
- xDialogWindow = oDocUITools.getActiveTopWindow();
- } catch (Exception ex) {
- ex.printStackTrace();
- }
-
- UITools oDialog = new UITools(mxMSF, xDialogWindow);
-
- oDialog.printAccessibleTree(log, debug);
-
- return null;
-
- }
-
private class execurteDialog extends Thread{
private XDialog mXDialog;
diff --git a/smoketestoo_native/config.pl b/smoketestoo_native/config.pl
deleted file mode 100755
index 988d1176ed42..000000000000
--- a/smoketestoo_native/config.pl
+++ /dev/null
@@ -1,83 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-use File::Path;
-
-$branddir = $ARGV[0];
-$userinstalldir = $ARGV[1];
-$buildid = $ARGV[2];
-
-if ($ENV{GUI} ne "UNX") {
- $quickstart = $branddir . "program/quickstart.exe";
- print "kill $quickstart\n";
- unlink $quickstart or die "cannot unlink $fullquickstart_path";
-}
-
-$regpath = $userinstalldir . "user";
-$regfile = $regpath . "/registrymodifications.xcu";
-print "create $regfile\n";
-mkpath($regpath, 0, 0777);
-open (OUT, "> $regfile") or die "cannot open $regfile for writing";
-print OUT << "EOF";
-<oor:items xmlns:oor='http://openoffice.org/2001/registry'>
- <item oor:path='/org.openoffice.Office.Common/Help/Registration'>
- <prop oor:name='ReminderDate'>
- <value>Patch$buildid</value>
- </prop>
- </item>
- <item oor:path='/org.openoffice.Office.Common/Misc'>
- <prop oor:name='FirstRun'>
- <value>false</value>
- </prop>
- </item>
- <item oor:path='/org.openoffice.Office.Common/Security/Scripting'>
- <prop oor:name='MacroSecurityLevel'>
- <value>0</value>
- </prop>
- <prop oor:name='OfficeBasic'>
- <value>2</value>
- </prop>
- </item>
- <item oor:path='/org.openoffice.Office.OOoImprovement.Settings/Participation'>
- <prop oor:name='InvitationAccepted'>
- <value>false</value>
- </prop>
- <prop oor:name='ShowedInvitation'>
- <value>true</value>
- </prop>
- </item>
- <item oor:path='/org.openoffice.Setup/Office'>
- <prop oor:name='FirstStartWizardCompleted'>
- <value>true</value>
- </prop>
- <prop oor:name='LicenseAcceptDate'>
- <value>2100-01-01T00:00:00</value>
- </prop>
- </item>
-</oor:items>
-EOF
-close OUT;
diff --git a/smoketestoo_native/data/TestExtension.oxt b/smoketestoo_native/data/TestExtension.oxt
deleted file mode 100755
index 70580b6a52e3..000000000000
--- a/smoketestoo_native/data/TestExtension.oxt
+++ /dev/null
Binary files differ
diff --git a/smoketestoo_native/data/dbgsv.ini b/smoketestoo_native/data/dbgsv.ini
deleted file mode 100644
index 42142b4124e5..000000000000
--- a/smoketestoo_native/data/dbgsv.ini
+++ /dev/null
@@ -1,42 +0,0 @@
-[output]
-log_file=dbgsv.log
-overwrite=1
-include=
-exclude=
-include_class=
-exclude_class=
-trace=dev/null
-warning=dev/null
-error=window
-
-[memory]
-initialize=1
-overwrite=0
-overwrite_free=0
-pointer=0
-report=0
-trace=0
-new_and_delete=0
-object_test=0
-sys_alloc=0
-leak_report=0
-
-init_byte=77
-bound_byte=55
-free_byte=33
-
-[gui]
-debug_window_state=
-
-[objects]
-check_this=0
-check_function=0
-check_exit=0
-generate_report=0
-trace=0
-
-[test]
-profiling=0
-resources=1
-dialog=0
-bold_app_font=0
diff --git a/smoketestoo_native/data/scripts/Global.xba b/smoketestoo_native/data/scripts/Global.xba
deleted file mode 100755
index c56b444cf030..000000000000
--- a/smoketestoo_native/data/scripts/Global.xba
+++ /dev/null
@@ -1,739 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
-<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Global" script:language="StarBasic">REM ***** BASIC *****
-
-const cMaxErrorStates = 13
-
-const cCoGreen = 4057917, cCoRed = 16711680, cCoGrey = 12632256
-const cParagraphBreak = 0
-
-global const cExtensionFileName = &quot;TestExtension.oxt&quot;
-
-global const cDocNew = 0, cDocCut = 1, cDocPaste = 2, cDocSaveOpen8 = 3, cDocSaveOpenXML = 4, cDocSaveOpen50 = 5, cDocClose = 6, cDocWrite = 7
-global const cNewsInit = 0, cNewsSend = 1, cNewsRead = 2
-global const cDBService = 0, cDBOpen = 1, cDBInsert = 2, cDBDelete = 3, cDBSeek = 4, cDBClose = 5
-global const cEXTService = 0, cEXTInstall = 1, cEXTUninstall = 2
-global const cScheduleDateRead = 0
-global const cLogfileFailed = 255
-
-global const cStWriter = 0, cStCalc = 1, cStPraesentation = 2, cStZeichnen = 3
-global const cStMessage = 12, cStHTML = 6, cStChart = 4, cStJava = 7
-global const cStMath = 5, cStNews = 10, cStSchedule = 8, cStDataBase = 9
-global const cStExtension = 11
-global const cStNone = -1
-
-global const cFlt8 = 0, cFlt50 = 32, cFltNewDoc = 64, cFltXML = 128
-
-global const frmWriter = 1, frmCalc = 2, frmMessage = 3, frmImpress = 4
-global const frmMath = 5, frmImage = 6, frmChart = 7, frmHyperText = 8, frmDraw = 9
-global const frmDataBase = 10, frmSchedule = 11, frmNews = 12, frmJava = 13
-global const frmExtension = 14
-
-global const cLogUnknown = 0, cLogFalse = 1, cLogTrue = 2
-
-&apos;UserFieldKennungen
-Global const cYes = &quot;y&quot;, cNo = &quot;n&quot;
-Global const cStateNo = 0, cStateYes = 1
-
-&apos;Feldtypen
-Global const cFtExtUser = 21, cFtPageNum = 5, cFtStatistic = 8, cFtDateTime = 27, cFtDatabase = 31
-
-&apos;UnoStrings
-Global const cUnoSeparator = &quot;.&quot;
-Global const cUnoPrefix = &quot;com.sun.star.&quot;
-Global const cUnoUserField = cUnoPrefix + &quot;text.FieldMaster.User&quot;
-Global const cUnoExtUserField = cUnoPrefix + &quot;text.TextField.ExtendedUser&quot;
-Global const cUnoMasterDataBase = cUnoPrefix + &quot;text.FieldMaster.Database&quot;
-Global const cUnoDataBase = cUnoPrefix + &quot;text.TextField.Database&quot;
-Global const cUnoDateTime = cUnoPrefix + &quot;text.TextField.DateTime&quot;
-Global const cUnoTextGraphi2 = cUnoPrefix + &quot;text.Graphic&quot;
-Global const cUnoJavaLoader = cUnoPrefix + &quot;loader.Java&quot;
-Global const cUnoDatabaseContext = cUnoPrefix + &quot;sdb.DatabaseContext&quot;
-Global const cUnoRowSet = cUnoPrefix + &quot;sdb.RowSet&quot;
-Global const cUnoSmoketestTestExtension = cUnoPrefix + &quot;comp.smoketest.TestExtension&quot;
-Global const cUnoSmoketestCommandEnvironment = cUnoPrefix + &quot;deployment.test.SmoketestCommandEnvironment&quot;
-Global const cUnothePackageManagerFactory = cUnoPrefix + &quot;deployment.thePackageManagerFactory&quot;
-
-&apos;UserFieldNames
-Global const cUserFieldTestWriter = &quot;Writer&quot;, cUserFieldTestCalc = &quot;Calc&quot;, cUserFieldTestImpress = &quot;Impress&quot;
-Global const cUserFieldTestDraw = &quot;Draw&quot;, cUserFieldTestMath = &quot;Math&quot;, cUserFieldTestChart = &quot;Chart&quot;
-Global const cUserFieldTestHTML = &quot;HTML&quot;, cUserFieldTestJava = &quot;Java&quot;, cUserFieldTestDatabase = &quot;Database&quot;
-Global const cUserFieldTestExtension = &quot;Extension&quot;
-Global const cUserFieldTestOpenSaveXML = &quot;SaveOpenXML&quot;, cUserFieldTestOpenSave50 = &quot;SaveOpen50&quot;, cUserFieldTestCut = &quot;Cut&quot;
-Global const cUserFieldTestPaste = &quot;Paste&quot;, cUserFieldTestTerminateAfterTest = &quot;Terminate&quot;, cUserFieldTestOpenSave8 = &quot;SaveOpen8&quot;
-
-Global const cOptionsDialogName = &quot;OptionsDlg&quot;, cTest10Modul = &quot;Standard&quot;
-
-Global const cDlgCancel = 1, cDlgOk = 0, cDlgStartTest = 2
-
-global gErrorState (cMaxErrorStates, 5) as integer
-
-global gOutputDoc as Object
-global gOutputDocNotUno as Object
-global gOptionsDialog as Object
-Dim bMakeMailAccount as Boolean, bTestMail as Boolean, bTestDocs as Boolean
-Dim bTestSchedule as Boolean, bTestAdr as Boolean
-
-Global bMakeWriterTest as boolean, bMakeCalcTest as boolean, bMakeImpressTest as boolean
-Global bMakeDrawTest as Boolean, bMakeMathTest as boolean, bMakeChartTest as boolean
-Global bMakeHTMLTest as boolean, bMakeJavaTest as boolean, bMakeDBTest as boolean
-Global bMakeExtensionTest as boolean
-Global bMakeSaveOpenXMLTest as boolean, bMakeSaveOpen50Test as boolean, bMakeCutTest as boolean
-Global bMakePasteTest as boolean, bMakeTerminateAfterTest as boolean, bShowTable as boolean
-Global bMakeSaveOpen8Test as boolean
-
-global sExtensionURL as string
-
-Dim gDlgState as Integer
-
-Sub SetGlobalDoc
- gOutPutDoc = StarDesktop.CurrentComponent
-end Sub
-
-Sub ClearStatus
- for j% = 0 to cMaxErrorStates
- for i% = 0 to 5
- gErrorState (j%, i%) = cLogUnknown
- next i%
- next j%
-end Sub
-
-Sub ClearAllText
- call SetGlobalDoc
- call ClearDoc (gOutPutDoc)
- call ClearStatus
-end Sub
-
-Sub Main
- call SetGlobalDoc
- if bShowTable then
- call ClearDoc (gOutPutDoc)
- end If
-
- call ClearStatus
-
- Call Test_10er.Main
-
- if bShowTable then
- call CreateStatusTable2
- call CreateStatusTable
- call CreateDocState
- call CreateSecondState
- gOutputDoc.CurrentController.ViewCursor.JumpToFirstPage
- end if
-End Sub
-
-Sub CreateStatusTable
- dim tableHeaders(7) as string
- tableHeaders(cStWriter) = &quot;Writer&quot;
- tableHeaders(cStCalc) = &quot;Calc&quot;
- tableHeaders(cStPraesentation) = &quot;Präsen- tation&quot;
- tableHeaders(cStZeichnen) = &quot;Zeichn.&quot;
- tableHeaders(cStChart) = &quot;Diagr.&quot;
- tableHeaders(cStMath) = &quot;Math&quot;
- tableHeaders(cStHTML) = &quot;HTML&quot;
- tableHeaders(cStJava) = &quot;Java&quot;
-
- dim tableColums(5) as string
- tableColums(cDocNew) = &quot;new&quot;
- tableColums(cDocCut) = &quot;cut&quot;
- tableColums(cDocPaste) = &quot;paste&quot;
- tableColums(cDocSaveOpen8) = &quot;V8.0&quot;
- tableColums(cDocSaveOpenXML) = &quot;XML&quot;
- tableColums(cDocSaveOpen50) = &quot;V5.0&quot;
-&apos; tableColums(cDocClose) = &quot;close&quot;
-
- aDoc = gOutPutDoc
-
- xText = aDoc.Text
- xCursor = xText.createTextCursor()
-
-&apos; xCursor.gotoStart(FALSE)
-&apos; xCursor.GoRight (2, False)
-&apos; SetParagraphBreak (xCursor)
-&apos; SetParagraphBreak (xCursor)
- xCursor.gotoStart(FALSE)
- xCursor.GoRight (4, False)
- SetParagraphBreak (xCursor)
- xCursor.GoRight (1, False)
- SetParagraphBreak (xCursor)
- xCursor.GoRight (1, False)
-
- table = aDoc.createInstance(&quot;com.sun.star.text.TextTable&quot;)
- table.initialize(7,9)
- table.Name = &quot;StTab1&quot;
- xText.insertTextContent(xCursor, table, FALSE)
-
- tableCursor = table.createCursorByCellName(table.CellNames(0))
- tableCursor.gotoStart(FALSE)
- tableCursor.goRight(1,FALSE)
-
- for i% = 0 to 7
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.String=tableHeaders(i%)
-
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
-
- tableCursor.goRight(1,FALSE)
- next i%
-
- xCursor.gotoStart(FALSE)
-&apos; SetParagraphBreak (xCursor)
-&apos; SetParagraphBreak (xCursor)
-
- tableCursor.gotoStart(FALSE)
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
-
- for i% = 0 to 5
- tableCursor.goDown(1,FALSE)
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.String=tableColums(i%)
-
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
- next i%
-end Sub
-
-Sub CreateStatusTable2
- dim tableHeaders(5) as string
- tableHeaders(cStDataBase-9) = &quot;Database&quot;
- tableHeaders(1) = &quot;&quot;
- tableHeaders(cStExtension-9) = &quot;Extension&quot;
- tableHeaders(3) = &quot;&quot;
- tableHeaders(4) = &quot;&quot;
-
- dim tableColums(5) as string
- tableColums(cDBService ) = &quot;services&quot;
- tableColums(cDBOpen ) = &quot;open&quot;
- tableColums(cDBInsert ) = &quot;insert&quot;
- tableColums(cDBDelete ) = &quot;delete&quot;
- tableColums(cDBSeek ) = &quot;seek&quot;
- tableColums(cDBClose ) = &quot;close&quot;
-
- dim tableColums2(3) as string
- tableColums2(cEXTService ) = &quot;services&quot;
- tableColums2(cEXTInstall ) = &quot;install&quot;
- tableColums2(cEXTUninstall ) = &quot;uninstall&quot;
-
- aDoc = gOutPutDoc
-
- xText = aDoc.Text
- xCursor = xText.createTextCursor()
-
- xCursor.gotoStart(FALSE)
- xCursor.GoRight (4, False)
- SetParagraphBreak (xCursor)
- SetParagraphBreak (xCursor)
- xCursor.gotoEnd(FALSE)
-
- table = aDoc.createInstance(&quot;com.sun.star.text.TextTable&quot;)
- table.initialize(7,6)
- table.Name = &quot;StTab2&quot;
- &apos;table.RelativeWidth =500
-
- xText.insertTextContent(xCursor, table, FALSE)
-
- tableCursor = table.createCursorByCellName(table.CellNames(0))
- tableCursor.gotoStart(FALSE)
- tableCursor.goRight(1,FALSE)
-
- for i% = 0 to 5
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.String=tableHeaders(i%)
-
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
-
- tableCursor.goRight(1,FALSE)
- next i%
-
- tableCursor.gotoStart(FALSE)
-
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
-
- for i% = 0 to 5
- tableCursor.goDown(1,FALSE)
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.String=tableColums(i%)
-
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
- next i%
-
- tableCursor.gotoStart(FALSE)
- tableCursor.goRight(2,FALSE)
-
- for i% = 0 to 3
- tableCursor.goDown(1,FALSE)
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
- xCell.String=tableColums2(i%)
-
- xCell.BackTransparent = False
- xCell.BackColor = cCoGrey
- next i%
-end Sub
-
-
-Sub CreateDocState
- aDoc = gOutPutDoc
- table = aDoc.TextTables.GetByIndex (1)
- &apos;table = aDoc.TextTables.GetByName (&quot;StTab1&quot;)
-
- for j% = 0 to 7
- for i% = 0 to 5
- sRangeName = GetRangeName(j%, i%+1)
-
- tableCursor = table.createCursorByCellName(sRangeName)
-
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
-
- xCell.BackTransparent = False
-
- if gErrorState (j%, i%) = cLogTrue then
- xCell.BackColor = cCoGreen
- else if gErrorState (j%, i%) = cLogFalse then
- xCell.BackColor = cCoRed
- else
- xCell.BackColor = cCoGrey
- end If
- end If
-
- next i%
- next j%
-end Sub
-
-Sub CreateSecondState
- aDoc = gOutPutDoc
- table = aDoc.TextTables.GetByIndex (0)
- &apos;table = aDoc.TextTables.GetByName (&quot;StTab2&quot;)
-
- for j% = 0 to cMaxErrorStates-9
- for i% = 0 to 5
- sRangeName = GetRangeName(j%, i%+1)
-
- tableCursor = table.createCursorByCellName(sRangeName)
-
- cName = tableCursor.getRangeName()
- xCell = table.getCellByName(cName)
-
- xCell.BackTransparent = False
-
- if gErrorState (j%+9, i%) = cLogTrue then
- xCell.BackColor = cCoGreen
- else if gErrorState (j%+9, i%) = cLogFalse then
- xCell.BackColor = cCoRed
- else
- xCell.BackColor = cCoGrey
- end If
- end If
-
- next i%
- next j%
-end Sub
-
-Function GetRangeName (nColumn as integer, nRow as integer) as string
- GetRangeName = chr (nColumn+66) + Trim(Str(nRow+1))
-end Function
-
-Sub SetStatus (nDocType as Integer, nAction as Integer, bState as Boolean)
- Dim nStatusType as Integer
- Dim nState as integer
- nStatusType = GetStatusType (nDocType)
- If nStatusType = cStNone then Exit Sub
-
- if bState then
- nState = cLogTrue
- else
- nState = cLogFalse
- end If
-
- gErrorState (nStatusType, nAction) = nState
-end Sub
-
-Function GetStatusType (nDocType as Integer) as Integer
- Select Case ( nDocType )
- case frmWriter
- GetStatusType = cStWriter &apos; Textdokument
- case frmCalc
- GetStatusType = cStCalc &apos;Tabellendokument
- case frmMessage
- GetStatusType = cStMessage &apos;Nachricht
- case frmImpress
- GetStatusType = cStPraesentation &apos;Präsentation
- case frmDraw
- GetStatusType = cStZeichnen &apos;Zeichnen
- case frmMath
- GetStatusType = cStMath &apos;Formel
- case frmImage
- GetStatusType = cStBild &apos;Bild
- case frmHyperText
- GetStatusType = cStHTML &apos;Hypertext-Dokument
- case frmChart
- GetStatusType = cStChart &apos;Diagramm
- case frmSchedule
- GetStatusType = cStSchedule &apos;Diagramm
- case frmJava
- GetStatusType = cStJava &apos;Java
- case frmNews
- GetStatusType = cStNews &apos;News
- case frmDataBase
- GetStatusType = cStDataBase &apos;DataBase
- case frmExtension
- GetStatusType = cStExtension &apos;Extension
- case else
- GetStatusType = cStNone
- end Select
-end Function
-
-Sub SetParagraphBreak (aCursor as Object)
- aCursor.Text.InsertControlCharacter (aCursor, cParagraphBreak, True)
-end Sub
-
-Sub ClearDoc (aDoc as Object)
- Dim aText as Object
- Dim i%
- for i%=1 to aDoc.TextTables.count
- aDoc.TextTables.GetByIndex(0).dispose
- next
-
- aText = aDoc.Text.CreateTextCursor
- aText.GotoStart (False)
- aText.GoRight (3, False)
- SetParagraphBreak (aText)
- aText.GotoEnd (True)
- aText.String=&quot;&quot;
-end Sub
-
-Sub ClearDocFull (aDoc as Object)
- Dim aText as Object
- Dim i%
- for i%=1 to aDoc.TextTables.count
- aDoc.TextTables.GetByIndex(0).dispose
- next
-
- aText = aDoc.Text.CreateTextCursor
- aText.GotoStart (False)
- aText.GotoEnd (True)
- aText.String=&quot;&quot;
-end Sub
-
-Sub SetGlobalOptionsDialog ()
-
- Dim oLibContainer As Object, oLib As Object
- Dim oInputStreamProvider As Object
- Dim oDialog As Object
-
- Const sLibName = cTest10Modul
- Const sDialogName = cOptionsDialogName
-
- REM get library and input stream provider
- oLibContainer = DialogLibraries
-
- REM load the library
- oLibContainer.loadLibrary( sLibName )
-
- oLib = oLibContainer.getByName( sLibName )
- oInputStreamProvider = oLib.getByName( sDialogName )
-
- REM create dialog control
- gOptionsDialog = CreateUnoDialog( oInputStreamProvider )
-
-end Sub
-
-Sub ShowOptionsDlg
-
- call SetGlobalDoc
- call SetGlobalOptionsDialog
- call GetOptions
-
- REM show the dialog
- gOptionsDialog.execute()
-
- &apos; jetzt läuft der Dialog, bis ein Button gedrückt wird
-
- Select Case (gDlgState)
- case cDlgOk
- call SetOptions ()
- case cDlgStartTest
- call SetOptions ()
- call StartTestByOptions ()
- end Select
-
- gOptionsDialog.dispose()
-
-end Sub
-
-Sub SetOptions
- call SetGlobalDoc
- SetUserFieldState (cUserFieldTestWriter, -(gOptionsDialog.getControl(&quot;cbWriterTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestCalc, -(gOptionsDialog.getControl(&quot;cbCalcTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestImpress, -(gOptionsDialog.getControl(&quot;cbImpressTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestDraw, -(gOptionsDialog.getControl(&quot;cbDrawTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestHTML, -(gOptionsDialog.getControl(&quot;cbHTMLTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestMath, -(gOptionsDialog.getControl(&quot;cbMathTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestChart, -(gOptionsDialog.getControl(&quot;cbChartTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestJava, -(gOptionsDialog.getControl(&quot;cbJavaTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestDatabase, -(gOptionsDialog.getControl(&quot;cbDatabaseTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestExtension, -(gOptionsDialog.getControl(&quot;cbExtensionTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestOpenSaveXML, -(gOptionsDialog.getControl(&quot;cbSaveOpenXMLTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestOpenSave50, -(gOptionsDialog.getControl(&quot;cbSaveOpen50Test&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestOpenSave8, -(gOptionsDialog.getControl(&quot;cbSaveOpen8Test&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestCut, -(gOptionsDialog.getControl(&quot;cbCutTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestPaste, -(gOptionsDialog.getControl(&quot;cbPasteTest&quot;).getState), gOutPutDoc)
- SetUserFieldState (cUserFieldTestTerminateAfterTest, -(gOptionsDialog.getControl(&quot;cbTerminateAfterTest&quot;).getState), gOutPutDoc)
-end Sub
-
-Sub GetOptions
- call SetGlobalDoc
- gOptionsDialog.getControl(&quot;cbWriterTest&quot;).setState( -( GetUserFieldState (cUserFieldTestWriter, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbCalcTest&quot;).setState ( -( GetUserFieldState (cUserFieldTestCalc, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbImpressTest&quot;).setState( -( GetUserFieldState (cUserFieldTestImpress, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbDrawTest&quot;).setState( -( GetUserFieldState (cUserFieldTestDraw, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbHTMLTest&quot;).setState( -( GetUserFieldState (cUserFieldTestHTML, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbMathTest&quot;).setState( -( GetUserFieldState (cUserFieldTestMath, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbChartTest&quot;).setState( -( GetUserFieldState (cUserFieldTestChart, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbJavaTest&quot;).setState( -( GetUserFieldState (cUserFieldTestJava, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbDatabaseTest&quot;).setState( -( GetUserFieldState (cUserFieldTestDatabase, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbExtensionTest&quot;).setState( -( GetUserFieldState (cUserFieldTestExtension, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbSaveOpenXMLTest&quot;).setState( -( GetUserFieldState (cUserFieldTestOpenSaveXML, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbSaveOpen50Test&quot;).setState( -( GetUserFieldState (cUserFieldTestOpenSave50, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbSaveOpen8Test&quot;).setState( -( GetUserFieldState (cUserFieldTestOpenSave8, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbCutTest&quot;).setState( -( GetUserFieldState (cUserFieldTestCut, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbPasteTest&quot;).setState( -( GetUserFieldState (cUserFieldTestPaste, gOutPutDoc)))
- gOptionsDialog.getControl(&quot;cbTerminateAfterTest&quot;).setState( -( GetUserFieldState (cUserFieldTestTerminateAfterTest, gOutPutDoc)))
-End Sub
-
-Sub ReadOptions
- call SetGlobalDoc
- bTestDocs = true
- bMakeWriterTest = GetUserFieldState (cUserFieldTestWriter, gOutPutDoc)
- bMakeCalcTest = GetUserFieldState (cUserFieldTestCalc, gOutPutDoc)
- bMakeImpressTest = GetUserFieldState (cUserFieldTestImpress, gOutPutDoc)
- bMakeDrawTest = GetUserFieldState (cUserFieldTestDraw, gOutPutDoc)
- bMakeHTMLTest = GetUserFieldState (cUserFieldTestHTML, gOutPutDoc)
- bMakeMathTest = GetUserFieldState (cUserFieldTestMath, gOutPutDoc)
- bMakeChartTest = GetUserFieldState (cUserFieldTestChart, gOutPutDoc)
- bMakeJavaTest = GetUserFieldState (cUserFieldTestJava, gOutPutDoc)
- bMakeDBTest = GetUserFieldState (cUserFieldTestDatabase, gOutPutDoc)
- bMakeExtensionTest = GetUserFieldState (cUserFieldTestExtension, gOutPutDoc)
- bMakeSaveOpenXMLTest = GetUserFieldState (cUserFieldTestOpenSaveXML, gOutPutDoc)
- bMakeSaveOpen50Test = GetUserFieldState (cUserFieldTestOpenSave50, gOutPutDoc)
- bMakeSaveOpen8Test = GetUserFieldState (cUserFieldTestOpenSave8, gOutPutDoc)
- bMakeCutTest = GetUserFieldState (cUserFieldTestCut, gOutPutDoc)
- bMakePasteTest = GetUserFieldState (cUserFieldTestPaste, gOutPutDoc)
- bMakeTerminateAfterTest = GetUserFieldState (cUserFieldTestTerminateAfterTest, gOutPutDoc)
-end Sub
-
-Sub SetDefaultOptions
- bTestDocs = true
- bMakeWriterTest = true
- bMakeCalcTest = true
- bMakeImpressTest = true
- bMakeDrawTest = true
- bMakeHTMLTest = true
- bMakeMathTest = true
- bMakeChartTest = true
- bMakeJavaTest = true
- bMakeDBTest = true
- bMakeExtensionTest = true
- bMakeSaveOpenXMLTest = true
- REM Disable StarOffice 5.0 tests in case binfilter has not been included
- if Environ(&quot;WITH_BINFILTER&quot;) = &quot;NO&quot; then
- bMakeSaveOpen50Test = false
- else
- bMakeSaveOpen50Test = true
- End If
- bMakeSaveOpen8Test = true
- bMakeCutTest = true
- bMakePasteTest = true
- bMakeTerminateAfterTest = true
-end Sub
-
-Sub ShutdownQuickstarter
- dim qs as Object
- qs = createUnoService(&quot;com.sun.star.comp.desktop.QuickstartWrapper&quot; )
- qs.setFastPropertyValue( 0, false )
-end Sub
-
-Sub StartTestByOptions
- call ShutdownQuickstarter
- bShowTable = true
- call ReadOptions
- call Main
-
- if bMakeTerminateAfterTest then
-
- ClearDocFull (gOutPutDoc)
- gOutPutDoc.dispose
- &apos;StarDesktop.Terminate
-
- &apos;EnableReschedule( false )
- &apos;DispatchSlot( 5300 )
- stop
- End If
-end Sub
-
-Sub StartTestWithDefaultOptions
- call ShutdownQuickstarter
- bShowTable = false
- call SetDefaultOptions
- call Main
-
- if bMakeTerminateAfterTest then
- stop
-
- ClearDocFull (gOutPutDoc)
- gOutPutDoc.dispose
- &apos;StarDesktop.Terminate
- &apos;EnableReschedule( false )
- &apos;DispatchSlot( 5300 )
- stop
- End If
-end Sub
-
-Sub DispatchSlot(SlotID as Integer)
- Dim oArg() as new com.sun.star.beans.PropertyValue
- Dim oUrl as new com.sun.star.util.URL
- Dim oTrans as Object
- Dim oDisp as Object
-
- oTrans = createUNOService(&quot;com.sun.star.util.URLTransformer&quot;)
- oUrl.Complete = &quot;slot:&quot; &amp; CStr(SlotID)
- oTrans.parsestrict(oUrl)
-
- oDisp = StarDesktop.queryDispatch(oUrl, &quot;_self&quot;, 0)
- oDisp.dispatch(oUrl, oArg())
-End Sub
-
-Sub LoadLibrary( LibName As String )
-
- dim args(1)
- dim arg as new com.sun.star.beans.PropertyValue
- arg.Name = &quot;LibraryName&quot;
- arg.Value = LibName
- args(0) = arg
-
- dim url as new com.sun.star.util.URL
- dim trans as object
- trans = createUnoService(&quot;com.sun.star.util.URLTransformer&quot; )
- url.Complete = &quot;slot:6517&quot;
- trans.parsestrict( url )
-
- dim disp as object
- disp = StarDesktop.currentFrame.queryDispatch( url, &quot;&quot;, 0 )
- disp.dispatch( url, args() )
-
-End Sub
-
-Sub ExecuteSlot( SlotNr As String, oDoc as Object )
- dim args()
- dim url as new com.sun.star.util.URL
- dim trans as object
- dim disp as object
-
- trans = createUnoService(&quot;com.sun.star.util.URLTransformer&quot; )
- url.Complete = &quot;slot:&quot; + SlotNr
- trans.parsestrict( url )
-
- disp = oDoc.CurrentController.Frame.queryDispatch( url, &quot;&quot;, 0 )
- disp.dispatch( url, args() )
-
-End Sub
-
-Sub CutText (oDoc as Object)
- ExecuteSlot (&quot;5710&quot;, oDoc)
-End Sub
-
-Sub PasteText (oDoc as Object)
- ExecuteSlot (&quot;5712&quot;, oDoc)
-End Sub
-
-Sub DelAllUserFields (aDoc as Object)
- Dim aFieldType as Object
- Dim aElements as Variant
- Dim i%
- Dim aFieldMasters, aFieldMaster as Object
- Dim sElement$
- aFieldMasters = aDoc.TextFieldMasters
- aElements = aFieldMasters.ElementNames
- for i = 0 to UBound(aElements)
- sElement$ = aElements(i)
- if 0 &lt;&gt; instr(sElement$, cUnoUserField ) then
- aFieldMaster = aFieldMasters.GetByName(sElement$)
- aFieldMaster.Dispose
- endif
- next
-end Sub
-
-Function GetUserFieldState (sName as String, aDoc as Object) as boolean
- Dim sFieldText as String
- Dim bState as boolean
- sFieldText = ReadUserField (sName, aDoc)
-
- if LCase(sFieldText) = cYes then
- bState = true
- else
- bState = false
- end IF
-
- GetUserFieldState = bState
-end Function
-
-Sub SetUserFieldState (sName as String, nState as boolean, aDoc as Object)
- Dim sFieldText as String
-
- sFieldText = cNo &apos;default
-
- Select case nState
- case true
- sFieldText = cYes
- case false
- sFieldText = cNo
- end Select
-
- WriteUserField (sFieldText, sName, aDoc)
-end Sub
-
-Function ReadUserField(sFieldName as String, aDoc as Object) as String
- Dim aMasters as Object
- aMasters = aDoc.TextFieldMasters
- if aMasters.HasByName (cUnoUserField+cUnoSeparator+sFieldName) then
- ReadUserField = aMasters.GetByName (cUnoUserField+cUnoSeparator+sFieldName).Content
- else
- ReadUserField = &quot;&quot;
- end If
-End Function
-
-Sub WriteUserField(sValue as String, sFieldName as String, aDoc as Object, optional aCursor as Object)
- Dim aMasters, aUserField, aTxtCursor as Object
- aMasters = aDoc.TextFieldMasters
- if aMasters.HasByName (cUnoUserField+cUnoSeparator+sFieldName) then
- aUserField = aMasters.GetByName (cUnoUserField+cUnoSeparator+sFieldName)
- else
- aUserField = aDoc.CreateInstance (cUnoUserField)
- aUserField.Name = sFieldName
- end if
- aUserField.Content = sValue
-End Sub
-
-Sub WriteExtUserField(nIndex as Integer, aCursor as Object, aDoc as Object)
- Dim aUserField as Object
- aUserField = aDoc.CreateInstance (cUnoExtUserField)
- aUserField.UserDataType = nIndex
- aCursor.Text.InsertTextContent (aCursor, aUserField, True)
- aUserField.Fix = True
-End Sub
-</script:module>
diff --git a/smoketestoo_native/data/scripts/Test_10er.xba b/smoketestoo_native/data/scripts/Test_10er.xba
deleted file mode 100755
index b475dfe53b42..000000000000
--- a/smoketestoo_native/data/scripts/Test_10er.xba
+++ /dev/null
@@ -1,907 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
-<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Test_10er" script:language="StarBasic">REM 10er Test
-
-const sSWLogFileName = &quot;swlog.dat&quot;, sSCLogFileName = &quot;sclog.dat&quot;
-const sSDLogFileName = &quot;sdlog.dat&quot;, sSMathLogFileName = &quot;smalog.dat&quot;
-const sSImDLogFileName = &quot;simlog.dat&quot;, sSChartLogFileName = &quot;schlog.dat&quot;
-const sSHptLogFileName = &quot;shptlog.dat&quot;, sSMessageLogFileName = &quot;smeslog.dat&quot;
-const sSDrawLogFileName = &quot;sdrwlog.dat&quot;, sJavaLogFileName = &quot;javalog.dat&quot;
-const sSDBLogFileName = &quot;dblog.dat&quot;, sExtLogFileName = &quot;extlog.dat&quot;
-const sLogFileName = &quot;log.dat&quot;
-const cTempFileName = &quot;ttt&quot;
-
-const cMessageSaveOpen8Doc = &quot;Save/Open open Documents (8.0)&quot;
-const cMessageSaveOpenXMLDoc = &quot;Save/Open Document XML (6/7)&quot;
-const cMessageSaveOpen50Doc = &quot;Save/Open Document 5.0&quot;
-const cMessageNewDoc = &quot;New Document&quot;
-const cMessageCloseDoc = &quot;Close Document&quot;
-const cMessageCutObj = &quot;Cut Object&quot;
-const cMessagePasteObj = &quot;Paste Object&quot;
-
-Global sWorkPath$
-Global sWorkPathURL$
-Global FileChannel%
-Global MainFileChannel%
-
-Sub Main
- call TestAllDocs()
-end Sub
-
-Sub DeleteAllSavedFiles()
- Dim sFileName as String
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmWriter)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmCalc)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmImpress)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmDraw)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmHyperText)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmWriter or cFltXML)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmCalc or cFltXML)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmImpress or cFltXML)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmDraw or cFltXML)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmWriter or cFlt50)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmCalc or cFlt50)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmImpress or cFlt50)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
- sFileName = sWorkPath+cTempFileName+&quot;.&quot;+GetDocEndings(frmDraw or cFlt50)
- If FileExists (sFileName) then
- Kill (sFileName)
- End If
-End Sub
-
-Sub DeleteAllLogFiles()
- If FileExists (sWorkPath+sLogFileName) then
- Kill (sWorkPath+sLogFileName)
- End If
- If FileExists (sWorkPath+sSWLogFileName) then
- Kill (sWorkPath+sSWLogFileName)
- End If
- If FileExists (sWorkPath+sSCLogFileName) then
- Kill (sWorkPath+sSCLogFileName)
- End If
- If FileExists (sWorkPath+sSDLogFileName) then
- Kill (sWorkPath+sSDLogFileName)
- End If
- If FileExists (sWorkPath+sSMathLogFileName) then
- Kill (sWorkPath+sSMathLogFileName)
- End If
- If FileExists (sWorkPath+sSImDLogFileName) then
- Kill (sWorkPath+sSImDLogFileName)
- End If
- If FileExists (sWorkPath+sSChartLogFileName) then
- Kill (sWorkPath+sSChartLogFileName)
- End If
- If FileExists (sWorkPath+sSHptLogFileName) then
- Kill (sWorkPath+sSHptLogFileName)
- End If
- If FileExists (sWorkPath+sSMessageLogFileName) then
- Kill (sWorkPath+sSMessageLogFileName)
- End If
- If FileExists (sWorkPath+sSDrawLogFileName) then
- Kill (sWorkPath+sSDrawLogFileName)
- End If
- If FileExists (sWorkPath+sJavaLogFileName) then
- Kill (sWorkPath+sJavaLogFileName)
- End If
- If FileExists (sWorkPath+sSDBLogFileName) then
- Kill (sWorkPath+sSDBLogFileName)
- End If
- If FileExists (sWorkPath+sExtLogFileName) then
- Kill (sWorkPath+sExtLogFileName)
- End If
-end Sub
-
-Function OpenLogDat (sFileName as String) as Integer
- Dim LocaleFileChannel%
- If FileExists (sWorkPath+sFileName) then
- Kill (sWorkPath+sFileName)
- End If
- LocaleFileChannel% = Freefile
- Open sWorkPath+sFileName For Output As LocaleFileChannel%
- OpenLogDat = LocaleFileChannel%
-end Function
-
-Function GetWorkPath as string
- sTemp = &quot;$(userpath)/temp/&quot;
- GetWorkPath = CreateUnoService(&quot;com.sun.star.config.SpecialConfigManager&quot;).SubstituteVariables(sTemp)
-End Function
-
-Function GetWorkURL as string
- sTemp = &quot;$(userurl)/temp/&quot;
- GetWorkURL = CreateUnoService(&quot;com.sun.star.config.SpecialConfigManager&quot;).SubstituteVariables(sTemp)
-End Function
-
-Function GetSystem (sTmpWorkPath as string) as string
- GetSystem = &quot;&quot;
- if InStr (sTmpWorkPath, &quot;:&quot;) then
- GetSystem = &quot;windows&quot;
- else
- GetSystem = &quot;unix&quot;
- End If
-end Function
-
-Function ConvertPathToWin (sTmpWorkPath as string) as string
- for i%=1 to Len(sTmpWorkPath)
- sTemp = Mid (sTmpWorkPath, i%, 1)
- if sTemp = &quot;/&quot; then
- sTmpWorkPath = Left (sTmpWorkPath, i%-1) + &quot;\&quot; + Right (sTmpWorkPath, Len(sTmpWorkPath)-i%)
- else
- if sTemp = &quot;|&quot; then
- sTmpWorkPath = Left (sTmpWorkPath, i%-1) + &quot;:&quot; + Right (sTmpWorkPath, Len(sTmpWorkPath)-i%)
- end If
- end If
- next i%
- ConvertPathToWin = sTmpWorkPath
-end Function
-
-Sub TestAllDocs()
-DIM sDocURL as String, sDocPath as String
-DIM nStrPos as Long
-
- sWorkPath = GetWorkPath
- sWorkPathURL = GetWorkURL
-
- if GetSystem (sWorkPath) = &quot;windows&quot; then
- sWorkPath = ConvertPathToWin (sWorkPath)
- end if
-
- &apos;search ExtensionURL
- sExtensionURL = sWorkPathURL
- If not FileExists (sExtensionURL + cExtensionFileName) then
- if bShowTable then
- sDocURL = gOutPutDoc.URL
- CompatibilityMode(true)
- nStrPos = InStrRev (sDocURL, &quot;/&quot; )
- CompatibilityMode(false)
- if nStrPos then
- sDocURL = Left (sDocURL, nStrPos)
- sExtensionURL = sDocURL
- If not FileExists (sExtensionURL + cExtensionFileName) then
- bMakeExtensionTest = false &apos; test is not possible then
- end if
- else
- bMakeExtensionTest = false &apos; test is not possible then
- end if
-
- else
- bMakeExtensionTest = false &apos; test is not possible then
- end if
-
- end if
-
- call DeleteAllSavedFiles()
- call DeleteAllLogFiles()
- MainFileChannel = OpenLogDat (sLogFileName)
- call WriteTestSequence (MainFileChannel)
- if bMakeWriterTest then
- call MakeDocTest (frmWriter)
- end if
- if bMakeCalcTest then
- call MakeDocTest (frmCalc)
- end if
- if bMakeImpressTest then
- call MakeDocTest (frmImpress)
- end if
- if bMakeDrawTest then
- call MakeDocTest (frmDraw)
- end if
- if bMakeHTMLTest then
- call MakeDocTest (frmHyperText)
- end if
- if bMakeChartTest then
- call MakeChartTest (frmChart)
- end if
- if bMakeMathTest then
- call MakeNewDoc (frmMath)
- end if
- if bMakeJavaTest then
- call TestJava (frmJava)
- end if
- if bMakeDBTest then
- call Test_DB.TestDB (frmDataBase)
- end if
- if bMakeExtensionTest then
- call Test_Ext.TestExtensions (frmExtension)
- end if
-
- Close #MainFileChannel
-end Sub
-
-Sub WriteTestSequence (FileChannel as integer)
- Print #FileChannel, &quot;Sequence of testing&quot;
-
- if bMakeWriterTest then
- WriteTests (&quot;writer : &quot;, true, FileChannel)
- end if
- if bMakeCalcTest then
- WriteTests (&quot;calc : &quot;, true, FileChannel)
- end if
- if bMakeImpressTest then
- WriteTests (&quot;impress : &quot;, true, FileChannel)
- end if
- if bMakeDrawTest then
- WriteTests (&quot;draw : &quot;, true, FileChannel)
- end if
- if bMakeHTMLTest then
- WriteTests (&quot;HTML : &quot;, true, FileChannel)
- end if
- if bMakeChartTest then
- WriteTests (&quot;chart : &quot;, false, FileChannel)
- end if
- if bMakeMathTest then
- WriteTests (&quot;math : &quot;, false, FileChannel)
- end if
- if bMakeJavaTest then
- WriteTests (&quot;Java : &quot;, false, FileChannel)
- end if
- if bMakeDBTest then
- WriteDBTests (&quot;Database : &quot;, FileChannel)
- end if
- if bMakeExtensionTest then
- WriteExtensionTests (&quot;Extension : &quot;, FileChannel)
- end if
-
- Print #FileChannel
-end Sub
-
-Sub WriteTests (sText as string, bTestAll as boolean, nFileChannel as integer)
- Dim sWriteStr as string
-
- sWriteStr = sText
- sWriteStr = sWriteStr + &quot;new&quot;
- if bTestAll then
- if bMakeCutTest then
- sWriteStr = sWriteStr + &quot;, cut&quot;
- end if
- if bMakePasteTest then
- sWriteStr = sWriteStr + &quot;, paste&quot;
- end if
- if bMakeSaveOpen8Test then
- sWriteStr = sWriteStr + &quot;, save 8.0&quot;
- end if
- if bMakeSaveOpenXMLTest then
- sWriteStr = sWriteStr + &quot;, save XML&quot;
- end if
- if bMakeSaveOpen50Test then
- sWriteStr = sWriteStr + &quot;, save 5.0&quot;
- end if
- if bMakeSaveOpen8Test then
- sWriteStr = sWriteStr + &quot;, open 8.0&quot;
- end if
- if bMakeSaveOpenXMLTest then
- sWriteStr = sWriteStr + &quot;, open XML&quot;
- end if
- if bMakeSaveOpen50Test then
- sWriteStr = sWriteStr + &quot;, open 5.0&quot;
- end if
- end if
-
- sWriteStr = sWriteStr + &quot;, close&quot;
-
- Print #nFileChannel, sWriteStr
-end Sub
-
-Sub WriteDBTests (sText as string, nFileChannel as integer)
- Dim sWriteStr as string
-
- sWriteStr = sText
- sWriteStr = sWriteStr + &quot;open / services&quot;
- sWriteStr = sWriteStr + &quot;, insert&quot;
- sWriteStr = sWriteStr + &quot;, delete&quot;
- sWriteStr = sWriteStr + &quot;, seek&quot;
- sWriteStr = sWriteStr + &quot;, close&quot;
-
- Print #nFileChannel, sWriteStr
-end Sub
-
-Sub WriteExtensionTests (sText as string, nFileChannel as integer)
- Dim sWriteStr as string
-
- sWriteStr = sText
- sWriteStr = sWriteStr + &quot;services&quot;
- sWriteStr = sWriteStr + &quot;, install&quot;
- sWriteStr = sWriteStr + &quot;, uninstall&quot;
-
- Print #nFileChannel, sWriteStr
-end Sub
-
-Sub MakeDocTest (FilterType as Integer)
- Dim oDoc as Object
- Dim sFileNameXML$, sFileName50$, sFileName8$
- Dim bError as Boolean
- Dim nCurrentAction as Integer
-
- On Local Error GoTo DOCTESTERROR
- nCurrentAction = cLogfileFailed
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
- nCurrentAction = cDocNew
- oDoc = LoadDoc (&quot;private:factory/&quot; + GetDocFilter(FilterType or cFltNewDoc))
- LogState (not IsNull (oDoc), GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, FileChannel)
- LogState (not IsNull (oDoc), GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, MainFileChannel)
- SetStatus (FilterType, cDocNew, not IsNull (oDoc))
- if not IsNull (oDoc) then
- nCurrentAction = cDocCut
- call CutAndPaste(FilterType, oDoc)
-&apos; bError = oDoc.CurrentController.frame.close
- nCurrentAction = cDocSaveOpen8
- if bMakeSaveOpen8Test and IsFilterAvailable (FilterType or cFlt8) then
- sFileName8 = sWorkPathURL+cTempFileName+&quot;.&quot;+GetDocEndings(FilterType or cFlt8)
- SaveDoc (sFileName8, oDoc, GetDocFilter(FilterType or cFlt8))
- end if
- nCurrentAction = cDocSaveOpenXML
- if bMakeSaveOpenXMLTest and IsFilterAvailable (FilterType or cFltXML) then
- sFileNameXML = sWorkPathURL+cTempFileName+&quot;.&quot;+GetDocEndings(FilterType or cFltXML)
- SaveDoc (sFileNameXML, oDoc, GetDocFilter(FilterType or cFltXML))
- end if
- nCurrentAction = cDocSaveOpen50
- if bMakeSaveOpen50Test and IsFilterAvailable (FilterType or cFlt50) then
- sFileName50 = sWorkPathURL+cTempFileName+&quot;.&quot;+GetDocEndings(FilterType or cFlt50)
- SaveDoc (sFileName50, oDoc, GetDocFilter(FilterType or cFlt50))
- end if
-&apos; oDoc.dispose
- nCurrentAction = cDocClose
- oDoc.close (true)
-&apos; bError = true &apos; nur zum ¦bergang, weil bError = oDoc.CurrentController.frame.close nicht geht
-&apos; LogState (bError, GetDocFilter(FilterType)+&quot; &quot;+ cMessageCloseDoc, FileChannel)
-&apos; LogState (bError, GetDocFilter(FilterType)+&quot; &quot;+ cMessageCloseDoc, MainFileChannel)
-&apos; SetStatus (FilterType, cDocClose, bError)
- nCurrentAction = cDocSaveOpen8
- if bMakeSaveOpen8Test and IsFilterAvailable (FilterType or cFlt8) then
- oDoc = LoadDoc (sFileName8)
-
-&apos; oDoc = Documents.open(sFileName)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpen8Doc, FileChannel)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpen8Doc, MainFileChannel)
- SetStatus (FilterType, cDocSaveOpen8, not IsNull (oDoc))
-
- if not IsNull (oDoc) then
-&apos; oDoc.dispose
- nCurrentAction = cDocClose
- oDoc.close (true)
- end If
- end if
-
- nCurrentAction = cDocSaveOpenXML
- if bMakeSaveOpenXMLTest and IsFilterAvailable (FilterType or cFltXML) then
- oDoc = LoadDoc (sFileNameXML)
-
-&apos; oDoc = Documents.open(sFileName)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpenXMLDoc, FileChannel)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpenXMLDoc, MainFileChannel)
- SetStatus (FilterType, cDocSaveOpenXML, not IsNull (oDoc))
-
- if not IsNull (oDoc) then
-&apos; oDoc.dispose
- nCurrentAction = cDocClose
- oDoc.close (true)
- end If
- end if
-
- nCurrentAction = cDocSaveOpen50
- if bMakeSaveOpen50Test and IsFilterAvailable (FilterType or cFlt50) then
- oDoc = LoadDoc (sFileName50)
-
-&apos; oDoc = Documents.open(sFileName)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpen50Doc, FileChannel)
- LogState (not IsNull (oDoc),GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageSaveOpen50Doc, MainFileChannel)
- SetStatus (FilterType, cDocSaveOpen50, not IsNull (oDoc))
-
- if not IsNull (oDoc) then
-&apos; oDoc.dispose
- nCurrentAction = cDocClose
- oDoc.close (true)
- end If
- end if
- end If
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
- Exit Sub &apos; Without error
-
- DOCTESTERROR:
- If (nCurrentAction = cLogfileFailed) then
- SetStatus (FilterType, cDocNew, False)
- Exit Sub
- else
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), FileChannel)
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), MainFileChannel)
- SetStatus (FilterType, nCurrentAction, False)
- Close #FileChannel%
- End If
- Exit Sub &apos; With error
-End Sub
-
-Sub MakeNewDoc (FilterType as Integer)
- DIM oDoc as Object
- Dim bError as Boolean
- Dim nCurrentAction as Integer
- On Local Error GoTo DOCTESTERROR2
- nCurrentAction = cLogfileFailed
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
- nCurrentAction = cDocNew
-&apos; oDoc = Documents.Add(GetDocFilter(FilterType))
- oDoc = LoadDoc (&quot;private:factory/&quot; + GetDocFilter(FilterType or cFltNewDoc))
- LogState (not IsNull (oDoc), GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, FileChannel)
- LogState (not IsNull (oDoc), GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, MainFileChannel)
- SetStatus (FilterType, cDocNew, not IsNull (oDoc))
- if not IsNull (oDoc) then
- nCurrentAction = cDocClose
-&apos; oDoc.dispose
- oDoc.close (true)
-&apos; bError = true &apos; nur zum ¦bergang, weil bError = oDoc.CurrentController.frame.close nicht geht
-&apos; LogState (bError, GetDocFilter(FilterType)+&quot; &quot;+ cMessageCloseDoc, FileChannel)
-&apos; LogState (bError, GetDocFilter(FilterType)+&quot; &quot;+ cMessageCloseDoc, MainFileChannel)
-&apos; SetStatus (FilterType, cDocClose, bError)
- end If
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
- Exit Sub &apos; Without error
-
- DOCTESTERROR2:
- If (nCurrentAction = cLogfileFailed) then
- SetStatus (FilterType, cDocNew, False)
- Exit Sub
- else
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), FileChannel)
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), MainFileChannel)
- SetStatus (FilterType, nCurrentAction, False)
- Close #FileChannel%
- End If
- Exit Sub &apos; With error
-End Sub
-
-Sub MakeChartTest (FilterType as Integer)
- Dim oCharts as Object
- Dim oDoc as Object
- Dim oRange(0) as New com.sun.star.table.CellRangeAddress
- Dim oRect as New com.sun.star.awt.Rectangle
- const cChartName=&quot;TestChart&quot;
- Dim bError as Boolean
- Dim nCurrentAction as Integer
- On Local Error GoTo CHARTTESTERROR
- nCurrentAction = cLogfileFailed
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
- nCurrentAction = cDocNew
- oDoc = LoadDoc (&quot;private:factory/&quot; + GetDocFilter(frmCalc or cFltNewDoc))
- if not IsNull (oDoc) then
- oCharts = oDoc.sheets(0).Charts
- oCharts.AddNewByName (cChartName, oRect, oRange(), true, true)
- bError=oCharts.HasByName(cChartName)
- LogState (bError, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, FileChannel)
- LogState (bError, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, MainFileChannel)
- SetStatus (FilterType, cDocNew, bError)
-&apos; oDoc.dispose
- nCurrentAction = cDocClose
- oDoc.close (true)
- else
- LogState (not IsNull (oDoc), GetDocFilter(frmCalc or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, FileChannel)
- LogState (not IsNull (oDoc), GetDocFilter(frmCalc or cFltNewDoc)+&quot; &quot;+ cMessageNewDoc, MainFileChannel)
- SetStatus (frmCalc, cDocNew, not IsNull (oDoc))
- End if
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
- Exit Sub &apos; Without error
-
- CHARTTESTERROR:
- If (nCurrentAction = cLogfileFailed) then
- SetStatus (FilterType, cDocNew, False)
- Exit Sub
- else
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), FileChannel)
- LogState (False, GetDocFilter(FilterType or cFltNewDoc)+&quot; &quot;+ GetErrorMessage(nCurrentAction), MainFileChannel)
- SetStatus (FilterType, nCurrentAction, False)
- Close #FileChannel%
- End If
- Exit Sub &apos; With error
-End Sub
-
-Sub LogState (bState as Boolean, sText as String, nLocaleFileChannel as integer)
- if bState then
- Print #nLocaleFileChannel, sText+&quot; -&gt; ok&quot;
- else
- Print #nLocaleFileChannel, sText+&quot; -&gt; error&quot;
- end If
-end Sub
-
-Function GetDocEndings (DocType as Integer) as String
- Select Case ( DocType )
- case frmWriter or cFlt8
- GetDocEndings = &quot;odt&quot; &apos; Textdokument
- case frmCalc or cFlt8
- GetDocEndings = &quot;ods&quot; &apos;Tabellendokument
- case frmImpress or cFlt8
- GetDocEndings = &quot;odp&quot; &apos;PrÕsentation
- case frmDraw or cFlt8
- GetDocEndings = &quot;odg&quot; &apos;Zeichen
- case frmHyperText, frmHyperText or cFlt50, frmHyperText or cFltXML
- GetDocEndings = &quot;html&quot; &apos;Hypertext-Dokument
- case frmWriter or cFlt50
- GetDocEndings = &quot;sdw&quot; &apos; Textdokument 5.0
- case frmCalc or cFlt50
- GetDocEndings = &quot;sdc&quot; &apos;Tabellendokument 5.0
- case frmImpress or cFlt50
- GetDocEndings = &quot;sdd&quot; &apos;PrÕsentation 5.0
- case frmDraw or cFlt50
- GetDocEndings = &quot;sda&quot; &apos;Zeichen 5.0
- case frmWriter or cFltXML
- GetDocEndings = &quot;sxw&quot; &apos; Textdokument
- case frmCalc or cFltXML
- GetDocEndings = &quot;sxc&quot; &apos;Tabellendokument
- case frmImpress or cFltXML
- GetDocEndings = &quot;sxi&quot; &apos;PrÕsentation
- case frmDraw or cFltXML
- GetDocEndings = &quot;sxd&quot; &apos;Zeichen
- case else
- GetDocEndings = &quot;&quot;
- end Select
-end Function
-
-Function GetDocFilter (DocType as Integer) as String
- Select Case ( DocType )
- case frmWriter or cFlt8
- GetDocFilter = &quot;writer8&quot; &apos; Textdokument
- case frmCalc or cFlt8
- GetDocFilter = &quot;calc8&quot; &apos;Tabellendokument
- case frmImpress or cFlt8
- GetDocFilter = &quot;impress8&quot; &apos;Präsentation
- case frmDraw or cFlt8
- GetDocFilter = &quot;draw8&quot; &apos;Zeichen
- case frmMath or cFlt8
- GetDocFilter = &quot;math8&quot; &apos;Formel
-
- case frmWriter or cFltXML
- GetDocFilter = &quot;StarOffice XML (Writer)&quot; &apos; Textdokument
- case frmCalc or cFltXML
- GetDocFilter = &quot;StarOffice XML (Calc)&quot; &apos;Tabellendokument
- case frmImpress or cFltXML
- GetDocFilter = &quot;StarOffice XML (Impress)&quot; &apos;Präsentation
- case frmDraw or cFltXML
- GetDocFilter = &quot;StarOffice XML (Draw)&quot; &apos;Zeichen
- case frmMath or cFltXML
- GetDocFilter = &quot;StarOffice XML (Math)&quot; &apos;Formel
-
- case frmHyperText, frmHyperText or cFlt50, frmHyperText or cFltXML
- GetDocFilter = &quot;HTML&quot; &apos;Hypertext-Dokument
- case frmWriter or cFlt50
- GetDocFilter = &quot;StarWriter 5.0&quot; &apos; Textdokument 5.0
- case frmCalc or cFlt50
- GetDocFilter = &quot;StarCalc 5.0&quot; &apos;Tabellendokument 5.0
- case frmImpress or cFlt50
- GetDocFilter = &quot;StarImpress 5.0&quot; &apos;Präsentation 5.0
- case frmDraw or cFlt50
- GetDocFilter = &quot;StarDraw 5.0&quot; &apos;Zeichen 5.0
- case frmMath or cFlt50
- GetDocFilter = &quot;StarMath 5.0&quot; &apos;Formel 5.0
-
- case frmWriter or cFltNewDoc
- GetDocFilter = &quot;swriter&quot; &apos; Textdokument
- case frmCalc or cFltNewDoc
- GetDocFilter = &quot;scalc&quot; &apos;Tabellendokument
- case frmMessage or cFltNewDoc
- GetDocFilter = &quot;Message&quot; &apos;Nachricht
- case frmImpress or cFltNewDoc
- GetDocFilter = &quot;simpress&quot; &apos;Präsentation
- case frmDraw or cFltNewDoc
- GetDocFilter = &quot;sdraw&quot; &apos;Zeichen
- case frmMath or cFltNewDoc
- GetDocFilter = &quot;smath&quot; &apos;Formel
- case frmImage or cFltNewDoc
- GetDocFilter = &quot;simage&quot; &apos;Bild
- case frmHyperText or cFltNewDoc
- GetDocFilter = &quot;swriter/web&quot; &apos;Hypertext-Dokument
- case frmChart or cFltNewDoc
- GetDocFilter = &quot;schart&quot; &apos;Diagramm
- case else
- GetDocFilter = &quot;&quot;
- end Select
-end Function
-
-Function GetLogFileName (DocType as Integer) as String
- Select Case ( DocType )
- case frmWriter
- GetLogFileName = sSWLogFileName &apos; Textdokument
- case frmCalc
- GetLogFileName = sSCLogFileName &apos;Tabellendokument
- case frmMessage
- GetLogFileName = sSMessageLogFileName &apos;Nachricht
- case frmImpress
- GetLogFileName = sSDLogFileName &apos;PrÕsentation
- case frmDraw
- GetLogFileName = sSDrawLogFileName &apos;Zeichnen
- case frmMath
- GetLogFileName = sSMathLogFileName &apos;Formel
- case frmImage
- GetLogFileName = sSImDLogFileName &apos;Bild
- case frmHyperText
- GetLogFileName = sSHptLogFileName &apos;Hypertext-Dokument
- case frmChart
- GetLogFileName = sSChartLogFileName &apos;Diagramm
- case frmJava
- GetLogFileName = sJavaLogFileName &apos;Java
- case frmDataBase
- GetLogFileName = sSDBLogFileName &apos;Database
- case frmExtension
- GetLogFileName = sExtLogFileName &apos;Extension
- case else
- GetLogFileName = &quot;&quot;
- end Select
-end Function
-
-Function GetErrorMessageOnAction (nAction as Integer) as String
- Select Case ( nAction )
- case cDocNew
- GetErrorMessageOnAction = cMessageNewDoc
- case cDocCut
- GetErrorMessageOnAction = cMessageCutObj
- case cDocPaste
- GetErrorMessageOnAction = cMessagePasteObj
- case cDocSaveOpen8
- GetErrorMessageOnAction = cMessageSaveOpen8Doc
- case cDocSaveOpenXML
- GetErrorMessageOnAction = cMessageSaveOpenXMLDoc
- case cDocSaveOpen50
- GetErrorMessageOnAction = cMessageSaveOpen50Doc
- case cDocClose
- GetErrorMessageOnAction = cMessageCloseDoc
- case else
- GetErrorMessageOnAction = &quot;&quot;
- end Select
-end Function
-
-Function IsFilterAvailable (FilterType as Integer) as boolean
- IsFilterAvailable = true
- if ((FilterType = (frmHyperText or cFlt50)) or (FilterType = (frmHyperText or cFltXML))) then
- IsFilterAvailable = false
- end if
-End Function
-
-Function TestJava (FilterType as Integer) as boolean
- Dim oObj as Object
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
- oObj = createUnoService(cUnoJavaLoader)
- LogState (not IsNull (oObj), &quot;Java &quot;+ cMessageNewDoc, FileChannel)
- LogState (not IsNull (oObj), &quot;Java &quot;+ cMessageNewDoc, MainFileChannel)
- SetStatus (FilterType, cDocNew, not IsNull (oObj))
-
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
-
- TestJava = not IsNull (oObj)
-End Function
-
-Sub CutAndPaste (DocType as Integer, oDoc as Object)
- Dim sText as String
- Dim oWin as Object
- Dim oText as Object
- Dim oView as Object
- Dim bCutState as boolean, bPasteState as boolean
- Select Case ( DocType )
- case frmWriter
- Dim oCursor as Object
-
- sText = &quot;AutomaticText&quot;
- oText = oDoc.GetText
- oCursor = oText.CreateTextCursor
- oText.InsertString(oCursor, sText, true) &apos; Cursor selektiert den Text
- oView = oDoc.getCurrentController
- oView.Select(oCursor)
-
- if bMakeCutTest then
- call CutText (oDoc)
-
- if oText.GetString = &quot;&quot; Then
- bCutState = True
- else
- bCutState = False
- end If
- SetStatus (DocType, cDocCut, bCutState)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, FileChannel)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, MainFileChannel)
- end if
-
- if bMakePasteTest and bMakeCutTest then
- call PasteText (oDoc)
-
- if oText.GetString = sText Then
- bPasteState = True
- else
- bPasteState = False
- end If
- SetStatus (DocType, cDocPaste, bPasteState)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, FileChannel)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, MainFileChannel)
- end if
-
- case frmCalc
- DIM oCell as Object
-
- sText = &quot;AutomaticText&quot;
- oCell = oDoc.Sheets(0).GetCellByPosition(0, 0)
- oCell.String = sText
- oView = oDoc.getCurrentController
- oView.Select(oCell)
-
- if bMakeCutTest then
- call CutText (oDoc)
-
- if oCell.String = &quot;&quot; Then
- bCutState = True
- else
- bCutState = False
- end If
- SetStatus (DocType, cDocCut, bCutState)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, FileChannel)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, MainFileChannel)
- end if
-
- if bMakePasteTest and bMakeCutTest then
- call PasteText (oDoc)
-
- if oCell.String = sText Then
- bPasteState = True
- else
- bPasteState = False
- end If
- SetStatus (DocType, cDocPaste, bPasteState)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, FileChannel)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, MainFileChannel)
- end if
- case frmMessage
- case frmImpress, frmDraw
- Dim oPage as Object
- Dim oRect as Object
- Dim xSize as Object
- Dim xPoint as Object
- Dim bObjState as Boolean
-
- xSize = CreateUnoStruct (&quot;com.sun.star.awt.Size&quot;)
- xPoint = CreateUnoStruct (&quot;com.sun.star.awt.Point&quot;)
- xSize.Width = 2000
- xSize.Height = 2000
- xPoint.x = 10000
- xPoint.y = 10000
- oPage = oDoc.DrawPages(0)
- oRect = oDoc.CreateInstance(&quot;com.sun.star.drawing.RectangleShape&quot;)
- oRect.Size = xSize
- oRect.Position = xPoint
- oPage.add(oRect)
-
- oView = oDoc.getCurrentController
- oView.Select(oRect)
-
- &apos; Prüft ob überhaupt ein Object angelegt wurde
- if oPage.count = 1 Then
- bObjState = True
- else
- bObjState = False
- end If
-
- if bMakeCutTest then
- call CutText (oDoc)
-
- if (oPage.count = 0) and bObjState Then
- bCutState = True
- else
- bCutState = False
- end If
- SetStatus (DocType, cDocCut, bCutState)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, FileChannel)
- LogState (bCutState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessageCutObj, MainFileChannel)
- end if
-
- wait (1000) &apos;wait after cut
-
- if bMakePasteTest and bMakeCutTest then
- call PasteText (oDoc)
-
- if (oPage.count = 1) and bObjState Then
- bPasteState = True
- else
- bPasteState = False
- end If
- SetStatus (DocType, cDocPaste, bPasteState)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, FileChannel)
- LogState (bPasteState, GetDocFilter(DocType or cFltNewDoc)+&quot; &quot;+ cMessagePasteObj, MainFileChannel)
- end if
- case frmMath
- case frmImage
- case frmHyperText
- case frmChart
- end Select
-end Sub
-
-Sub LoadLibrary( LibName as String )
-
- dim args(1)
- dim arg as new com.sun.star.beans.PropertyValue
- arg.Name = &quot;LibraryName&quot;
- arg.Value = LibName
- args(0) = arg
-
- dim url as new com.sun.star.util.URL
- dim trans as object
- trans = createUnoService(&quot;com.sun.star.util.URLTransformer&quot; )
- url.Complete = &quot;slot:6517&quot;
- trans.parsestrict( url )
-
- dim disp as object
- disp = StarDesktop.currentFrame.queryDispatch( url, &quot;&quot;, 0 )
- disp.dispatch( url, args() )
-
-End Sub
-
-Sub LoadDoc (DocName as String) as Object
- dim trans as object
- trans = createUnoService(&quot;com.sun.star.util.URLTransformer&quot; )
- url = createUnoStruct(&quot;com.sun.star.util.URL&quot; )
- url.Complete = DocName
- if Left(DocName, 5 ) &lt;&gt; &quot;file:&quot; then
- trans.parsestrict( url )
- endif
-
- Dim aPropArray(0) as Object
- aPropArray(0) = CreateUnoStruct(&quot;com.sun.star.beans.PropertyValue&quot;)
- aPropArray(0).Name = &quot;OpenFlags&quot;
- aPropArray(0).Value = &quot;S&quot;
-
- dim doc as object
- dim noargs()
- doc = StarDesktop.loadComponentFromURL( url.Complete, &quot;_blank&quot;, 0, aPropArray() ) &apos; XModel
- LoadDoc = doc
-End Sub
-
-Sub SaveDoc (DocName as String, oDoc as Object, sFilterName as string )
- dim trans as object
- trans = createUnoService(&quot;com.sun.star.util.URLTransformer&quot; )
- url = createUnoStruct(&quot;com.sun.star.util.URL&quot; )
- url.Complete = DocName
- if Left(DocName, 5 ) &lt;&gt; &quot;file:&quot; then
- trans.parsestrict( url )
- endif
-
- if not (sFilterName = &quot;&quot;) then
- Dim aPropArray(0) as Object
- aPropArray(0) = CreateUnoStruct(&quot;com.sun.star.beans.PropertyValue&quot;)
- aPropArray(0).Name = &quot;FilterName&quot;
- aPropArray(0).Value = sFilterName
-
- oDoc.storeAsURL( url.Complete, aPropArray() )
- else
- MessageBox &quot;Filtername is unknown!&quot;
- end if
-end Sub
-</script:module> \ No newline at end of file
diff --git a/smoketestoo_native/data/scripts/Test_DB.xba b/smoketestoo_native/data/scripts/Test_DB.xba
deleted file mode 100755
index 7e5a74bfe2ab..000000000000
--- a/smoketestoo_native/data/scripts/Test_DB.xba
+++ /dev/null
@@ -1,135 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
-<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Test_DB" script:language="StarBasic">REM ***** Database Test *****
-
-const cMessageDatabaseService = &quot;Database Service&quot;
-const cMessageDatabaseOpen = &quot;Open Database&quot;
-const cMessageDatabaseInsert = &quot;Insert record into Database&quot;
-const cMessageDatabaseDelete = &quot;Delete record from Database&quot;
-const cMessageDatabaseSeek = &quot;Read other record from Database&quot;
-const cMessageDatabaseClose = &quot;Close Database&quot;
-
-Sub TestDB (FilterType as Integer)
-
-Dim oDBConnection as Object, oDataSource as Object, oDBContext as Object
-Dim sDBName as String, sTable as String, sCurrentMessage as String
-Dim nRowCount as Integer, nCurrentAction as Integer
-Dim bResult as Boolean
-Const sTestString = &quot;Automatical Test&quot;
-
-
- On Local Error GoTo DBERROR
-
- nCurrentAction = cLogfileFailed
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
-
- nCurrentAction = cDBService
- sCurrentMessage = cMessageDatabaseService + &quot; &quot; + cUnoDatabaseContext
-
- oDBContext = CreateUnoService(cUnoDatabaseContext)
- sDBName=oDBContext.ElementNames(0) &apos;Names of Databases
-
- nCurrentAction = cDBOpen
- sCurrentMessage = cMessageDatabaseOpen
-
- oDataSource = oDBContext.GetByName(sDBName)
- sTable=oDataSource.Tables.ElementNames(0)
- oDBConnection = oDBContext.GetByName(sDBName).GetConnection(&quot;&quot;,&quot;&quot;)
-
- LogState (not IsNull (oDBConnection), &quot;Database &quot;+ cMessageDatabaseOpen, FileChannel)
- LogState (not IsNull (oDBConnection), &quot;Database &quot;+ cMessageDatabaseOpen, MainFileChannel)
- SetStatus (FilterType, cDBOpen, not IsNull (oDBConnection))
- if (IsNull(oDBConnection)) then
- Close #FileChannel%
- Exit Sub
- End If
-
- &apos; Database is open now
-
- nCurrentAction = cDBService
- sCurrentMessage = cMessageDatabaseService + &quot; &quot; + cUnoRowSet
- oRowSet = createUnoService(cUnoRowSet)
-
- if (IsNull(oRowSet)) then
- LogState (not IsNull (oRowSet), &quot;Database &quot;+ cMessageDatabaseService + &quot; &quot; + cUnoRowSet, FileChannel)
- LogState (not IsNull (oRowSet), &quot;Database &quot;+ cMessageDatabaseService + &quot; &quot; + cUnoRowSet, MainFileChannel)
- SetStatus (FilterType, cDBService, not IsNull (oRowSet))
- Exit Sub
- else
- LogState (not IsNull (oRowSet), &quot;Database &quot;+ cMessageDatabaseService, FileChannel)
- LogState (not IsNull (oRowSet), &quot;Database &quot;+ cMessageDatabaseService, MainFileChannel)
- SetStatus (FilterType, cDBService, not IsNull (oRowSet))
- End If
-
- nCurrentAction = cDBInsert
- sCurrentMessage = cMessageDatabaseInsert
-
- oRowSet.ActiveConnection = oDBConnection
-
- oRowSet.CommandType = com.sun.star.sdb.CommandType.COMMAND
- oRowSet.Command = &quot;SELECT * FROM &quot; + sTable
- oRowSet.execute()
-
- oRowSet.moveToInsertRow
- oRowSet.updateString(5, sTestString)
-
- oRowSet.insertRow()
- nRowCount=oRowSet.RowCount
-
- oRowSet.moveToCurrentRow()
-
- bResult = (oRowSet.getString(5) = sTestString)
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseInsert, FileChannel)
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseInsert, MainFileChannel)
- SetStatus (FilterType, cDBInsert, bResult)
-
- &apos;delete only if insert passed
-
- if (bResult) Then
- nCurrentAction = cDBDelete
- sCurrentMessage = cMessageDatabaseDelete
- oRowSet.deleteRow()
- bResult = (nRowCount - oRowSet.RowCount = 0)
- if ( bResult ) Then
- oRowSet.next()
- bResult = (nRowCount - oRowSet.RowCount = 1)
- End If
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseDelete, FileChannel)
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseDelete, MainFileChannel)
- SetStatus (FilterType, cDBDelete, bResult)
- End If
-
- &apos; read other record
-
- nCurrentAction = cDBSeek
- sCurrentMessage = cMessageDatabaseSeek
- oRowSet.first()
- bResult = not (oRowSet.getString(5) = sTestString)
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseSeek, FileChannel)
- LogState (bResult, &quot;Database &quot;+ cMessageDatabaseSeek, MainFileChannel)
- SetStatus (FilterType, cDBSeek, bResult)
-
- nCurrentAction = cDBClose
- sCurrentMessage = cMessageDatabaseClose
- oDBConnection.Dispose()
- LogState (True, &quot;Database &quot;+ cMessageDatabaseClose, FileChannel)
- LogState (True, &quot;Database &quot;+ cMessageDatabaseClose, MainFileChannel)
- SetStatus (FilterType, cDBClose, True)
-
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
- Exit Sub &apos; Without error
-
- DBERROR:
- If (nCurrentAction = cLogfileFailed) then
- SetStatus (FilterType, cDBOpen, False)
- Exit Sub
- else
- LogState (False, &quot;Database &quot;+ sCurrentMessage, FileChannel)
- LogState (False, &quot;Database &quot;+ sCurrentMessage, MainFileChannel)
- SetStatus (FilterType, nCurrentAction, False)
- Close #FileChannel%
- End If
- Exit Sub &apos; With error
-End Sub
-</script:module> \ No newline at end of file
diff --git a/smoketestoo_native/data/scripts/Test_Ext.xba b/smoketestoo_native/data/scripts/Test_Ext.xba
deleted file mode 100755
index 00fc93ff86eb..000000000000
--- a/smoketestoo_native/data/scripts/Test_Ext.xba
+++ /dev/null
@@ -1,95 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
-<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Test_Ext" script:language="StarBasic">REM ***** BASIC *****
-
-const cMessageExtensionService = &quot;Extension Service&quot;
-const cMessageExtensionInstall = &quot;Install Extension&quot;
-const cMessageExtensionUninstall = &quot;Uninstall Extension&quot;
-
-Sub TestExtensions (FilterType as Integer)
-Dim oTestExtension as Object, obj_null as Object
-Dim sCurrentMessage as String
-Dim nCurrentAction as Integer
-Dim bResult as Boolean
-Dim sImplementationNameString as String
-sImplementationNameString = cUnoSmoketestTestExtension + &quot;$_TestExtension&quot;
-
- On Local Error GoTo EXTERROR
-
- nCurrentAction = cLogfileFailed
- FileChannel% = OpenLogDat (GetLogFileName(FilterType))
-
- sCurrentMessage = cMessageExtensionService
- nCurrentAction = cEXTService
-
- &apos;Create an implementation of com.sun.star.ucb.XCommandEnvironment which is needed for
- &apos;adding the extension. The implementation is in
- &apos;javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java and the code is in juh.jar
- cmdEnv = createUnoService(cUnoSmoketestCommandEnvironment)
-
- &apos;Create the component context and then get the singleton thePackageManagerFactory
- &apos;A singleton cannot be created with createUnoService
- ctx = getDefaultContext
- factory = ctx.getValueByName(&quot;/singletons/&quot; + cUnothePackageManagerFactory)
-
- &apos;Get the XPackageManager interface. By passing &quot;user&quot; we determine that the actions we perform on
- &apos;XPackageManager only affect the user installation. To modify the share installation one would pass &quot;share&quot;.
- ext_mgr = factory.getPackageManager(&quot;user&quot;)
-
- LogState (not IsNull (ext_mgr), &quot;Extension &quot;+ cMessageExtensionService, FileChannel)
- LogState (not IsNull (ext_mgr), &quot;Extension &quot;+ cMessageExtensionService, MainFileChannel)
- SetStatus (FilterType, cEXTService, not IsNull (ext_mgr))
- if (IsNull(ext_mgr)) then
- Close #FileChannel%
- Exit Sub
- End If
-
- sCurrentMessage = cMessageExtensionInstall
- nCurrentAction = cEXTInstall
-
- &apos;Add the extension. We must provide a file URL here.
- ext_mgr.addPackage(sExtensionURL + cExtensionFileName, &quot;&quot;, obj_null, cmdEnv)
-
- &apos;Check if the extension has been added by creating a service which is contained in the extension.
- oTestExtension = createUnoService(cUnoSmoketestTestExtension)
- bResult = (oTestExtension.getImplementationName = sImplementationNameString)
- LogState (bResult, &quot;Extension &quot;+ cMessageExtensionInstall, FileChannel)
- LogState (bResult, &quot;Extension &quot;+ cMessageExtensionInstall, MainFileChannel)
- SetStatus (FilterType, cEXTInstall, bResult)
- if (not bResult) then
- Close #FileChannel%
- Exit Sub
- End If
-
- sCurrentMessage = cMessageExtensionUninstall
- nCurrentAction = cEXTUninstall
-
- &apos;Remove the package
- ext_mgr.removePackage(&quot;org.openoffice.legacy.&quot; + cExtensionFileName, cExtensionFileName, obj_null, cmdEnv)
-
- &apos;Try to create the service which is contained in the now removed extension.
- oTestExtension = createUnoService(cUnoSmoketestTestExtension)
-
- &apos;The service must not be available anymore. Therefor isNull must return true.
- LogState (IsNull (oTestExtension), &quot;Extension &quot;+ cMessageExtensionUninstall, FileChannel)
- LogState (IsNull (oTestExtension), &quot;Extension &quot;+ cMessageExtensionUninstall, MainFileChannel)
- SetStatus (FilterType, cEXTUninstall, IsNull (oTestExtension))
-
- Print #FileChannel, &quot;---&quot;
- Close #FileChannel%
- Exit Sub &apos; Without error
-
- EXTERROR:
- If (nCurrentAction = cLogfileFailed) then
- SetStatus (FilterType, cEXTService, False)
- Exit Sub
- else
- LogState (False, &quot;Extension &quot;+ sCurrentMessage, FileChannel)
- LogState (False, &quot;Extension &quot;+ sCurrentMessage, MainFileChannel)
- SetStatus (FilterType, nCurrentAction, False)
- Close #FileChannel%
- End If
- Exit Sub &apos; With error
-
-End Sub
-</script:module> \ No newline at end of file
diff --git a/smoketestoo_native/data/scripts/script.xlb b/smoketestoo_native/data/scripts/script.xlb
deleted file mode 100755
index 6b7873432f75..000000000000
--- a/smoketestoo_native/data/scripts/script.xlb
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE library:library PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "library.dtd">
-<library:library xmlns:library="http://openoffice.org/2000/library" library:name="Standard" library:readonly="false" library:passwordprotected="false">
- <library:element library:name="Global"/>
- <library:element library:name="Test_10er"/>
- <library:element library:name="Test_DB"/>
- <library:element library:name="Test_Ext"/>
-</library:library> \ No newline at end of file
diff --git a/smoketestoo_native/data/smoketestdoc.sxw b/smoketestoo_native/data/smoketestdoc.sxw
index b9139efda28d..84e1e30bfc4e 100755
--- a/smoketestoo_native/data/smoketestdoc.sxw
+++ b/smoketestoo_native/data/smoketestdoc.sxw
Binary files differ
diff --git a/smoketestoo_native/data/solaris/sparc/admin b/smoketestoo_native/data/solaris/sparc/admin
deleted file mode 100644
index 6639c2406d06..000000000000
--- a/smoketestoo_native/data/solaris/sparc/admin
+++ /dev/null
@@ -1,6 +0,0 @@
-action=nocheck
-conflict=nocheck
-setuid=nocheck
-idepend=nocheck
-mail=
-
diff --git a/smoketestoo_native/data/solaris/sparc/getuid.so b/smoketestoo_native/data/solaris/sparc/getuid.so
deleted file mode 100755
index 13c193879c4b..000000000000
--- a/smoketestoo_native/data/solaris/sparc/getuid.so
+++ /dev/null
Binary files differ
diff --git a/smoketestoo_native/data/solaris/x86/admin b/smoketestoo_native/data/solaris/x86/admin
deleted file mode 100644
index 6639c2406d06..000000000000
--- a/smoketestoo_native/data/solaris/x86/admin
+++ /dev/null
@@ -1,6 +0,0 @@
-action=nocheck
-conflict=nocheck
-setuid=nocheck
-idepend=nocheck
-mail=
-
diff --git a/smoketestoo_native/data/solaris/x86/getuid.so b/smoketestoo_native/data/solaris/x86/getuid.so
deleted file mode 100755
index c5cdc8ce7a7b..000000000000
--- a/smoketestoo_native/data/solaris/x86/getuid.so
+++ /dev/null
Binary files differ
diff --git a/smoketestoo_native/makefile.mk b/smoketestoo_native/makefile.mk
index ae7fbb01d502..0337c748d914 100644
--- a/smoketestoo_native/makefile.mk
+++ b/smoketestoo_native/makefile.mk
@@ -1,7 +1,6 @@
-#***********************************************************************
-#
+#*************************************************************************
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,33 +21,48 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+#***********************************************************************/
+
+PRJ = .
+PRJNAME = smoketestoo_native
+TARGET = smoketest
+
+ENABLE_EXCEPTIONS = TRUE
-PRJ=.
+.INCLUDE: settings.mk
-PRJNAME=test10
-TARGET=t1
+CFLAGSCXX += $(CPPUNIT_CFLAGS)
-.INCLUDE : settings.mk
+SLOFILES = $(SHL1OBJS)
-STAR_REGISTRY=
-.EXPORT : STAR_REGISTRY
-.EXPORT : PERL
-.EXPORT : DMAKE_WORK_DIR
+SHL1TARGET = smoketest
+SHL1OBJS = $(SLO)/smoketest.obj
+SHL1RPATH = NONE
+SHL1STDLIBS = $(CPPUHELPERLIB) $(CPPULIB) $(CPPUNITLIB) $(SALLIB) $(TESTLIB)
+SHL1VERSIONMAP = version.map
+DEF1NAME = $(SHL1TARGET)
-.INCLUDE : target.mk
+.INCLUDE: target.mk
+.INCLUDE: installationtest.mk
-ALLTAR : make_test
+ALLTAR : cpptest
+cpptest : $(SHL1TARGETN) $(BIN)/smoketestdoc.sxw
-make_test:
-.IF $(NOREMOVE)
- @$(PERL) smoketest.pl -nr $(LAST_MINOR) $(BUILD)
-.ELSE
- @$(PERL) smoketest.pl $(LAST_MINOR) $(BUILD)
-.ENDIF
+OOO_CPPTEST_ARGS = $(SHL1TARGETN) -env:arg-doc=$(BIN)/smoketestdoc.sxw
-noremove:
- @$(PERL) smoketest.pl -nr $(LAST_MINOR) $(BUILD)
+$(BIN)/smoketestdoc.sxw: data/smoketestdoc.sxw
+ $(COPY) $< $@
+.IF "$(OS)" != "WNT"
+$(installationtest_instpath).flag : $(shell ls \
+ $(installationtest_instset)/OOo_*_install-arc_$(defaultlangiso).tar.gz)
+ $(RM) -r $(installationtest_instpath)
+ $(MKDIRHIER) $(installationtest_instpath)
+ cd $(installationtest_instpath) && $(GNUTAR) xfz \
+ $(installationtest_instset)/OOo_*_install-arc_$(defaultlangiso).tar.gz
+ $(MV) $(installationtest_instpath)/OOo_*_install-arc_$(defaultlangiso) \
+ $(installationtest_instpath)/opt
+ $(TOUCH) $@
+cpptest : $(installationtest_instpath).flag
+.END
diff --git a/smoketestoo_native/prj/build.lst b/smoketestoo_native/prj/build.lst
index 5a0b659bd6d1..f4bd5368c65b 100644
--- a/smoketestoo_native/prj/build.lst
+++ b/smoketestoo_native/prj/build.lst
@@ -1,4 +1,4 @@
-smtoon smoketestoo_native :: instsetoo_native NULL
+smtoon smoketestoo_native :: instsetoo_native test NULL
smtoon smoketestoo_native usr1 - all smoketestoonative_mkout NULL
smtoon smoketestoo_native\com\sun\star\comp\smoketest nmake - all smoketestoonative_csscs NULL
smtoon smoketestoo_native nmake - all,test10 smoketestoonative_mk smoketestoonative_csscs NULL
diff --git a/smoketestoo_native/smoketest.cxx b/smoketestoo_native/smoketest.cxx
new file mode 100644
index 000000000000..e2cb51127f47
--- /dev/null
+++ b/smoketestoo_native/smoketest.cxx
@@ -0,0 +1,169 @@
+/*************************************************************************
+*
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+*
+************************************************************************/
+
+#include "sal/config.h"
+
+#include "boost/noncopyable.hpp"
+#include "com/sun/star/beans/PropertyState.hpp"
+#include "com/sun/star/beans/PropertyValue.hpp"
+#include "com/sun/star/document/MacroExecMode.hpp"
+#include "com/sun/star/frame/DispatchResultEvent.hpp"
+#include "com/sun/star/frame/DispatchResultState.hpp"
+#include "com/sun/star/frame/XComponentLoader.hpp"
+#include "com/sun/star/frame/XController.hpp"
+#include "com/sun/star/frame/XDispatchProvider.hpp"
+#include "com/sun/star/frame/XDispatchResultListener.hpp"
+#include "com/sun/star/frame/XModel.hpp"
+#include "com/sun/star/frame/XNotifyingDispatch.hpp"
+#include "com/sun/star/lang/EventObject.hpp"
+#include "com/sun/star/uno/Reference.hxx"
+#include "com/sun/star/uno/RuntimeException.hpp"
+#include "com/sun/star/uno/Sequence.hxx"
+#include "com/sun/star/util/URL.hpp"
+#include "cppuhelper/implbase1.hxx"
+#include "cppunit/TestAssert.h"
+#include "cppunit/TestFixture.h"
+#include "cppunit/extensions/HelperMacros.h"
+#include "cppunit/plugin/TestPlugIn.h"
+#include "osl/conditn.hxx"
+#include "osl/diagnose.h"
+#include "rtl/ustring.h"
+#include "rtl/ustring.hxx"
+#include "test/getargument.hxx"
+#include "test/officeconnection.hxx"
+#include "test/oustringostreaminserter.hxx"
+#include "test/toabsolutefileurl.hxx"
+
+namespace {
+
+namespace css = com::sun::star;
+
+struct Result: private boost::noncopyable {
+ osl::Condition condition;
+ bool success;
+ rtl::OUString result;
+};
+
+class Listener:
+ public cppu::WeakImplHelper1< css::frame::XDispatchResultListener >
+{
+public:
+ Listener(Result * result): result_(result) { OSL_ASSERT(result != 0); }
+
+private:
+ virtual void SAL_CALL disposing(css::lang::EventObject const &)
+ throw (css::uno::RuntimeException) {}
+
+ virtual void SAL_CALL dispatchFinished(
+ css::frame::DispatchResultEvent const & Result)
+ throw (css::uno::RuntimeException);
+
+ Result * result_;
+};
+
+void Listener::dispatchFinished(css::frame::DispatchResultEvent const & Result)
+ throw (css::uno::RuntimeException)
+{
+ result_->success =
+ (Result.State == css::frame::DispatchResultState::SUCCESS) &&
+ (Result.Result >>= result_->result);
+ result_->condition.set();
+}
+
+class Test: public CppUnit::TestFixture {
+public:
+ virtual void setUp();
+
+ virtual void tearDown();
+
+private:
+ CPPUNIT_TEST_SUITE(Test);
+ CPPUNIT_TEST(test);
+ CPPUNIT_TEST_SUITE_END();
+
+ void test();
+
+ test::OfficeConnection connection_;
+};
+
+void Test::setUp() {
+ connection_.setUp();
+}
+
+void Test::tearDown() {
+ connection_.tearDown();
+}
+
+void Test::test() {
+ rtl::OUString doc;
+ CPPUNIT_ASSERT(
+ test::getArgument(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("doc")), &doc));
+ css::uno::Sequence< css::beans::PropertyValue > args(1);
+ args[0].Name = rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("MacroExecutionMode"));
+ args[0].Handle = -1;
+ args[0].Value <<=
+ com::sun::star::document::MacroExecMode::ALWAYS_EXECUTE_NO_WARN;
+ args[0].State = css::beans::PropertyState_DIRECT_VALUE;
+ css::util::URL url;
+ url.Complete = rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "vnd.sun.star.script:Standard.Global.StartTestWithDefaultOptions?"
+ "language=Basic&location=document"));
+ Result result;
+ css::uno::Reference< css::frame::XNotifyingDispatch >(
+ css::uno::Reference< css::frame::XDispatchProvider >(
+ css::uno::Reference< css::frame::XController >(
+ css::uno::Reference< css::frame::XModel >(
+ css::uno::Reference< css::frame::XComponentLoader >(
+ connection_.getFactory()->createInstance(
+ rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "com.sun.star.frame.Desktop"))),
+ css::uno::UNO_QUERY_THROW)->loadComponentFromURL(
+ test::toAbsoluteFileUrl(doc),
+ rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("_default")),
+ 0, args),
+ css::uno::UNO_QUERY_THROW)->getCurrentController(),
+ css::uno::UNO_SET_THROW)->getFrame(),
+ css::uno::UNO_QUERY_THROW)->queryDispatch(
+ url, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0),
+ css::uno::UNO_QUERY_THROW)->dispatchWithNotification(
+ url, css::uno::Sequence< css::beans::PropertyValue >(),
+ new Listener(&result));
+ result.condition.wait();
+ CPPUNIT_ASSERT(result.success);
+ CPPUNIT_ASSERT_EQUAL(rtl::OUString(), result.result);
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(Test);
+
+}
+
+CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/smoketestoo_native/smoketest.pl b/smoketestoo_native/smoketest.pl
deleted file mode 100755
index f5ef32f31bcb..000000000000
--- a/smoketestoo_native/smoketest.pl
+++ /dev/null
@@ -1,1279 +0,0 @@
-:
-eval 'exec perl -wS $0 ${1+"$@"}'
- if 0;
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-#
-# smoketest - do the smoketest
-#
-
-use lib ("$ENV{SOLARENV}/bin/modules");
-
-use File::Basename;
-use File::Path;
-use File::Copy;
-use Getopt::Long;
-use SourceConfig;
-
-########################
-# #
-# Globale Variablen #
-# #
-#########################
-$is_debug = 0; # run without executing commands
-$is_command_infos = 0; # print command details before exec
-$is_protocol_test = 0;
-$is_remove_on_error = 0;
-$is_remove_at_end = 1;
-$is_do_deinstall = 0;
-$is_without_msiexec = 1;
-$is_oo = 1;
-
-$sourceconfig_obj;
-$gui = $ENV{GUI};
-$temp_path = $ENV{TEMP};
-$vcsid = $ENV{VCSID};
-$sversion_saved = 0;
-$FileURLPrefix = "file:///";
-$userinstalldir = "UserInstallation";
-$cygwin = "cygwin";
-$prefered_lang = "en-US";
-$global_instset_mask = "";
-$smoketest_install = $ENV{SMOKETESTINSTALLSET};
-
-if (!defined($gui)) {
- print "The workstamp is missing. Please use setsolar\n";
- exit(1);
-}
-
-if (($gui eq "WNT") and ($ENV{USE_SHELL} ne "4nt")) {
- $gui = $cygwin;
-}
-
-if (!defined($temp_path) and (($gui eq "UNX") or ($gui eq $cygwin))) {
- $temp_path = $ENV{TMPDIR};
- if (!defined($temp_path) and (-d "/tmp")) {
- $temp_path = "/tmp";
- }
-}
-
-if (defined($ENV{INSTALLPATH_SMOKETEST})) {
- $installpath_without = $ENV{INSTALLPATH_SMOKETEST};
-}
-else {
- $installpath_without = $temp_path;
-}
-
-if (!defined($installpath_without)) {
- print "Your temp value is missing. Please set your temp-variable or define INSTALLPATH_SMOKETEST\n\n";
- exit(1);
-}
-
-if (!((defined($ENV{UPDATER})) and ($ENV{UPDATER} eq "YES") and !defined($ENV{CWS_WORK_STAMP})) ) {
- $is_protocol_test = 0;
-}
-
-if ($gui eq "WNT") {
- $PathSeparator = '\\';
- $NewPathSeparator = ';';
- $dos = "$ENV{COMSPEC} -c";
- $PERL = "$dos $ENV{PERL}";
- $REMOVE_DIR = "$dos del /qsxyz";
- $REMOVE_FILE = "$dos del";
- $LIST_DIR = "$dos ls";
- $COPY_FILE = "$dos copy";
- $COPY_DIR = "$dos copy /s";
- $MK_DIR = "md";
- $RENAME_FILE = "ren";
- $nul = '> NUL';
- $RESPFILE="response_fat_wnt";
- $SVERSION_INI = $ENV{USERPROFILE} . $PathSeparator . "Anwendungsdaten" . $PathSeparator . "sversion.ini";
- $SOFFICEBIN = "soffice.exe";
- $bootstrapini = "bootstrap.ini";
- $bootstrapiniTemp = $bootstrapini . "_";
- $packpackage = "msi";
- $installpath_without =~ s/\//\\/g;
-}
-elsif ($gui eq "UNX") {
- $is_do_deinstall = 0;
- $PathSeparator = '/';
- $NewPathSeparator = ':';
- $dos = "";
- $PERL = "$ENV{PERL}";
- $REMOVE_DIR = "rm -rf";
- $REMOVE_FILE = "rm -f";
- $LIST_DIR = "ls";
- $COPY_FILE = "cp -f";
- $MK_DIR = "mkdir";
- $RENAME_FILE = "mv";
- $nul = '> /dev/null';
- $RESPFILE="response_fat_unx";
- $SVERSION_INI = $ENV{HOME} . $PathSeparator . ".sversionrc";
- $bootstrapini = "bootstraprc";
- $bootstrapiniTemp = $bootstrapini . "_";
- $packpackage = $ENV{PKGFORMAT};
- $SOFFICEBIN = "soffice";
- if ($ENV{OS} eq "MACOSX") {
- $COPY_DIR = "cp -RPfp";
- }
- else {
- $COPY_DIR = "cp -rf";
- }
-}
-elsif ($gui eq $cygwin) {
- $PathSeparator = '/';
- $NewPathSeparator = ':';
- $dos = "";
- $PERL = "$ENV{PERL}";
- $REMOVE_DIR = "rm -rf";
- $REMOVE_FILE = "rm -f";
- $LIST_DIR = "ls";
- $COPY_FILE = "cp -f";
- $COPY_DIR = "cp -rf";
- $MK_DIR = "mkdir";
- $RENAME_FILE = "mv";
- $nul = '> /dev/null';
- $RESPFILE="response_fat_wnt";
- $SVERSION_INI = $ENV{USERPROFILE} . $PathSeparator . "Anwendungsdaten" . $PathSeparator . "sversion.ini";
- $SOFFICEBIN = "soffice";
- $bootstrapini = "bootstrap.ini";
- $bootstrapiniTemp = $bootstrapini . "_";
- $CygwinLineends = $/;
- $WinLineends = "\r\n";
- $packpackage = "msi";
- $installpath_without =~ s/\\/\//g;
-}
-else {
- print_error ("not supported system\n",1);
-}
-
-if ($is_without_msiexec) {
- require installer::windows::admin; import installer::windows::admin;
- $installer::globals::logfilename = $ENV{DMAKE_WORK_DIR} . $PathSeparator . $ENV{OUTPATH} . $ENV{PROEXT} . $PathSeparator . "misc" . $PathSeparator . "installer.log";
- $installer::globals::exithandler = \&install_error;
-}
-
-if ($is_oo) {
- @install_list = ( 'instsetoo_native'
- );
-}
-else {
- @install_list = ( 'instset_native'
- );
-}
-
-@error_messages = ( '',
- 'lock flag for pkgadd still exist. Installation not possible!',
- 'Error during installation!',
- 'Error: patching configuration failed!',
- 'Error: starting office failed or office crashed!',
- 'Error during testing',
- 'can not copy extension',
- 'Error in setup log',
- 'installationsset is not complete',
- 'can not copy all basic scripts',
- 'can not patch bottstrapini',
- 'msiexec failed. Maybe you have got an installed version',
- 'deinstallation is incomplete',
- 'this packformat is not supported for this environment',
- 'can not set execute permission'
-);
-
-my $show_NoMessage = 0;
-my $show_Message = 1;
-
-my $error_logflag = 1;
-my $error_setup = 2;
-my $error_patchConfig = 3;
-my $error_startOffice = 4;
-my $error_testResult = 5;
-my $error_copyExtension = 6;
-my $error_setup_log = 7;
-my $error_installset = 8;
-my $error_copyBasic = 9;
-my $error_patchBootstrap = 10;
-my $error_msiexec = 11;
-my $error_deinst = 12;
-my $error_packformat = 13;
-my $error_permission = 14;
-
-my $command_normal = 0;
-my $command_withoutErrorcheck = 1;
-my $command_withoutOutput = 2;
-
-if ($is_oo) {
- $PRODUCT="OpenOffice";
-}
-else {
- $PRODUCT="StarOffice";
-}
-
-if (($ENV{PKGFORMAT} eq "installed") and (!defined ($ENV{FORCE2ARCHIVE}))) {
- $packpackage = $ENV{PKGFORMAT}; # take it for all environments
-}
-elsif (defined ($ENV{FORCE2ARCHIVE})) {
- $packpackage = "archive"; # take it for all environments
-}
-$StandDir = $ENV{SOLARSRC} . $PathSeparator;
-$SHIP = defined $ENV{SHIPDRIVE} ? $ENV{SHIPDRIVE} . $PathSeparator : "shipdrive_not_set";
-$PORDUCT = "$SHIP$ENV{INPATH}$PathSeparator$PRODUCT$PathSeparator$packpackage$PathSeparator";
-$DATA="$ENV{DMAKE_WORK_DIR}$PathSeparator" . "data$PathSeparator";
-$WORK_STAMP_LC=$ENV{WORK_STAMP};
-$WORK_STAMP_LC =~ tr/A-Z/a-z/;
-$ENV{DBGSV_INIT} = $DATA . "dbgsv.ini";
-$ExtensionDir = $ENV{DMAKE_WORK_DIR} . $PathSeparator . $ENV{OUTPATH} . $ENV{PROEXT} . $PathSeparator . "bin" . $PathSeparator;
-
-if (defined($vcsid)) {
- $installpath_without .= $PathSeparator . $vcsid;
-}
-if (!$is_oo) {
- $installpath_without .= $PathSeparator . "StarOffice";
-}
-else {
- $installpath_without .= $PathSeparator . "OpenOffice";
-}
-
-$installpath = $installpath_without . $PathSeparator;
-$installpath = glob $installpath;
-
-$ENV{STAR_REGISTRY}="";
-$milestone = "";
-
-#### options ####
-
-$opt_nr = 0;
-GetOptions('nr');
-
-if ($opt_nr) {
- $is_remove_at_end = 0; # do not remove installation
-}
-if ( $ARGV[0] ) {
- $milestone = $ARGV[0];
-}
-if ( $ARGV[1] ) {
- $buildid = $ARGV[1];
-}
-
-
-#### script id #####
-
-( $script_name = $0 ) =~ s/^.*\b(\w+)\.pl$/$1/;
-
-$id_str = ' $Revision: 1.35 $ ';
-$id_str =~ /Revision:\s+(\S+)\s+\$/
- ? ($script_rev = $1) : ($script_rev = "-");
-
-print "$script_name -- version: $script_rev\n";
-
-
-#### main ####
-
-if (!$is_debug) {
- if ($is_do_deinstall) {
- deinstallInstallation ($installpath);
- }
- removeOldInstallation($installpath);
- save_sversion ($SVERSION_INI);
-}
-
-($INSTSETNAME, $INSTALLSET) = getInstset();
-
-print "Install: $INSTALLSET$INSTSETNAME\n";
-prepare();
-doTest();
-
-if (!$is_debug) {
- restore_sversion ($SVERSION_INI);
- if ($is_remove_at_end) {
- if ($is_do_deinstall) {
- deinstallInstallation ($installpath);
- }
- removeInstallation($installpath);
- }
- else {
- print_notRemoved ($installpath);
- }
-}
-print "smoketest successful!\n";
-exit (0);
-
-#########################
-# #
-# Procedures #
-# #
-#########################
-
-sub getSubFiles {
- my ($startDir, $DirArray_ref, $mask) = @_;
- my ($dir);
- opendir(DIR,"$startDir");
- while($dir = readdir(DIR)) {
- if (($dir =~ /\.$/) or ($dir !~ /$mask/)) {
- next;
- }
- push (@{$DirArray_ref}, "$dir");
- }
- closedir(DIR);
-
-}
-
-sub getSubDirs {
- my ($startDir, $DirArray_ref) = @_;
- my ($dir);
- opendir(DIR,"$startDir");
- while($dir = readdir(DIR)) {
- if (($dir !~ /\.$/) and ( -d "$startDir$dir") ) {
- push (@{$DirArray_ref}, "$dir");
- }
- }
- closedir(DIR);
-
-}
-
-sub getSubDirsFullPath {
- my ($startDir, $DirArray_ref) = @_;
- my ($dir);
- opendir(DIR,"$startDir");
- while($dir = readdir(DIR)) {
- if (($dir !~ /\.$/) and ( -d "$startDir$dir") ) {
- push (@{$DirArray_ref}, "$startDir$dir");
- }
- }
- closedir(DIR);
-
-}
-
-sub findSubDir {
- my ($DirArray_ref) = @_;
- my (@sortedArray, $dir, $instdir);
- @sortedArray = sort langsort @{$DirArray_ref};
- print "Langs: @sortedArray\n" if $is_command_infos;
- foreach $dir (@sortedArray) {
- if ($dir =~ /log$/) {
- next;
- }
- $instdir = "$dir";
- return $instdir;
- }
- return "";
-}
-
-sub findMultiple {
- my ($base, $name) = @_;
- my ($f, @s, @res);
- opendir(DIR, $base) or die "cannot open dir $base";
- while ($f = readdir(DIR)) {
- push @res, "$base" if $f eq $name;
- push @s, $f if
- -d "$base$f" && ! -l "$base$f" && $f ne '.' && $f ne '..';
- }
- closedir(DIR);
- foreach $f (@s) {
- push @res, findMultiple("$base$f$PathSeparator", $name);
- }
- return @res;
-}
-
-sub findUnique {
- my ($base, $name) = @_;
- my @res = findMultiple($base, $name);
- die "no unique $name in $base" unless @res == 1;
- return $res[0];
-}
-
-sub prepare {
- if ($gui eq "UNX") {
- $ENV{ignore_patch_check}="t";
- $ENV{OOO_FORCE_DESKTOP} = "none";
- }
-
-}
-
-sub is_Installset_ok {
- my ($installpath, $installname) = @_;
- my ($is_ok, $infile);
- $is_ok = 1;
- $infile = $INSTALLSET. "log$PathSeparator";
- $infile =~ s/_pre_//;
- $infile =~ s/[\/\\]normal[\/\\]//;
- $infile =~ s/\.(\d+)$/_$1\.html/;
- #if ($installname =~ /(?:_pre_){0,1}(.*)\.(\d+)/) {
- # $infile .= "$1_$2.html";
- # print "protocol: $infile\n" if $is_debug;
- #}
- open INTABLE, "<$infile" or return errorFromOpen ($infile);
- while(<INTABLE>) {
- $line = $_;
- if ( $line =~ />(error)(.*)</ ) {
- print "ERROR: $1$2\n";
- $is_ok = 0;
- }
- }
- close INTABLE;
- return $is_ok;
-}
-
-sub errorFromOpen {
- my ($file) = @_;
- print "ERROR: can't open $file\n";
- return 0;
-}
-
-sub doTest {
- my ($Command);
- my (@Params, $basedir, $basisdir, $branddir);
-
- # check installset (error 8)
-
- if (($INSTSETNAME ne "") and $is_protocol_test) {
- if (!is_Installset_ok ("$PORDUCT", $INSTSETNAME)) {
- print_error ($error_messages[$error_installset], $error_installset);
- }
- }
-
- # install office (error 2)
-
- $basedir = doInstall ("$INSTALLSET$INSTSETNAME$PathSeparator", $installpath);
- $basisdir = findUnique($basedir, 'ure-link');
- $branddir = findUnique($basedir, 'basis-link');
- if ( (defined($ENV{OS})) && ($ENV{OS} eq "MACOSX") ) {
- $programpath = "$branddir". "MacOS$PathSeparator";
- }
- else {
- $programpath = "$branddir". "program$PathSeparator";
- }
- $userinstallpath_without = $installpath . $userinstalldir;
- $userinstallpath = $userinstallpath_without . $PathSeparator;
- $userpath = "$userinstallpath" . "user$PathSeparator";
- $basicpath = $userpath . "basic$PathSeparator";
- $standardbasicpath = "$basisdir" . "presets$PathSeparator" . "basic$PathSeparator";
- $LOGPATH="$userinstallpath" . "user" . $PathSeparator . "temp";
-
- if ($gui eq "UNX") {
- $Command = "chmod -R 777 \"$basedir\"*";
- execute_system ("$Command");
- }
-
- # check setup log file (error 7)
-
-# $Command = "$PERL check_setup.pl \"$programpath" . "setup.log\"";
-# execute_Command ($Command, $error_setup_log, $show_Message, $command_normal );
-
- # patch config (error 3)
-
- $Command = "$PERL config.pl \"$branddir\" \"$userinstallpath\" \"$buildid\"";
- execute_Command ($Command, $error_patchConfig, $show_Message, $command_normal );
-
- # copy basicscripts (error 9)
-
- $Command = "$COPY_FILE \"$DATA" . "scripts$PathSeparator" . "\"*.x* \"$standardbasicpath" . "Standard$PathSeparator\"";
- execute_Command ($Command, $error_copyBasic, $show_Message, $command_withoutOutput);
-
- createPath("$basicpath", $error_copyBasic);
- $Command = "$COPY_DIR \"$standardbasicpath\"* \"$basicpath\"";
- execute_Command ($Command, $error_copyBasic, $show_Message, $command_withoutOutput);
-
- # patching bootstrap (error 11)
-
- if (!patch_bootstrap ("$programpath$bootstrapini", "$programpath$bootstrapiniTemp")) {
- print_error ($error_messages[$error_patchBootstrap], $error_patchBootstrap);
- }
-
- # copy extension (error 6)
-
- createPath ($LOGPATH, $error_copyExtension);
- $Command = "$COPY_FILE \"$ExtensionDir" . "TestExtension.oxt\" " . "\"$LOGPATH$PathSeparator\"";
- execute_Command ($Command, $error_copyExtension, $show_Message, $command_withoutOutput);
-
-
- # start office (error 4)
-
- print "starting office ($INSTSETNAME)\n";
-
- $Command = "\"$programpath" . "$SOFFICEBIN\" -norestore -nocrashreport macro:///Standard.Global.StartTestWithDefaultOptions";
- if ( (defined($ENV{OS})) && ($ENV{OS} eq "MACOSX") ) {
- $Command = "cd \"$programpath\"; " . $Command;
- }
- execute_Command ($Command, $error_startOffice, $show_Message, $command_normal);
-
- # test if smoketest is ok (error 5)
-
- $Command = "$PERL testlog.pl \"$LOGPATH\"";
- execute_Command ($Command, $error_testResult, $show_Message, $command_normal);
-
- # deinstall office (error 6)
-
- if ($is_remove_at_end) {
- print "Deinstalling Office\n";
- }
-# $Command = "$PERL deinstall.pl \"$LOGPATH\" \"$installpath\"";
-# execute_Command ($Command, $error_deinstall, $show_NoMessage, $command_normal);
-}
-
-sub install_error {
- print_error ($error_messages[$error_setup], $error_setup);
-}
-
-sub doInstall {
- my ($installsetpath, $dest_installdir) = @_;
- my ($DirArray, $mask, $file, $Command, $optdir, $rpmdir, $system, $mach, $basedir, $output_ref, $olddir, $newdir);
- if (($ENV{PKGFORMAT} eq "installed") and (!defined($ENV{FORCE2ARCHIVE}))) {
- createPath ($dest_installdir, $error_setup);
- $Command = "$COPY_DIR \"$installsetpath\" \"$dest_installdir\"";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- @DirArray = ();
- getSubDirsFullPath ($dest_installdir, \@DirArray);
- if ($#DirArray == 0) {
- $basedir = $DirArray[0] . $PathSeparator;
- }
- elsif ($#DirArray == -1) {
- print_error ($error_setup, $show_Message);
- }
- else {
- $basedir = $dest_installdir;
- }
- }
- elsif (($gui eq "WNT") or ($gui eq $cygwin)) {
- if (defined($ENV{FORCE2ARCHIVE})) {
- print_error ($error_messages[$error_packformat], $error_packformat);
- }
- $mask = "\\.msi\$";
- getSubFiles ("$installsetpath", \@DirArray, $mask);
- if ($#DirArray == -1) {
- print_error ("Installationset in $installsetpath is incomplete", 2);
- }
- foreach $file (@DirArray) {
- if ($is_without_msiexec) {
- if ($is_debug) {
- print "Debugmode: no installation from $installsetpath\n";
- }
- else {
- createPath ($dest_installdir, $error_setup);
- installer::windows::admin::make_admin_install ($installsetpath . $file, $dest_installdir);
- if ($gui eq $cygwin) {
- $Command = "find $dest_installdir \\( -name \"installhelper\" -prune -o -name \"*.exe\" -o -name \"*.dll\" -o -name \"*.manifest\" -o -name \"*.bin\" -o -name \"*.jar\" \\) -exec chmod a+x {} \\;";
- execute_Command ($Command, $error_permission, $show_Message, $command_normal);
- }
- }
- }
- else
- {
- if ($gui eq $cygwin) {
- my $convertinstallset = ConvertCygwinToWin_Shell("$installsetpath$file");
- my $convertdestdir = ConvertCygwinToWin_Shell($dest_installdir);
- $_inst_cmd=$ENV{SMOKETEST_SOINSTCMD};
- if ( defined($_inst_cmd) ) {
- $Command = $_inst_cmd . " $convertinstallset -qn TARGETDIR=$convertdestdir";
- }
- else {
- $Command = "msiexec.exe /a $convertinstallset -qn TARGETDIR=$convertdestdir ALLUSERS=2";
- }
- }
- else {
- $_inst_cmd=$ENV{SMOKETEST_SOINSTCMD};
- if ( defined($_inst_cmd) ) {
- $Command = $_inst_cmd . " $installsetpath$file -qn TARGETDIR=$dest_installdir";
- }
- else {
- $Command = "msiexec.exe /a $installsetpath$file -qn TARGETDIR=$dest_installdir ALLUSERS=2";
- }
- }
- execute_Command ($Command, $error_msiexec, $show_Message, $command_normal);
- }
- }
- $basedir = $dest_installdir;
- }
- elsif ($gui eq "UNX") {
- $system = `uname -s`;
- chomp $system;
- $mach = `uname -m`;
- chomp $mach;
- if (defined ($ENV{EPM}) && ($ENV{EPM} eq 'NO')) { # do the install ourselves ...
-# FIXME - this tool should work nicely without such hacks
-# cut/paste from ooo-build/bin/ooinstall
- my $instoo_dir = "$ENV{SRC_ROOT}/instsetoo_native";
-
- if ( $ENV{'SYSTEM_MOZILLA'} eq 'YES' ) {
- if (defined $ENV{'LD_LIBRARY_PATH'}) {
- $ENV{'LD_LIBRARY_PATH'} =
- "$ENV{'LD_LIBRARY_PATH'}:$ENV{'MOZ_LIB'}";
- } else {
- $ENV{'LD_LIBRARY_PATH'} = $ENV{'MOZ_LIB'};
- }
- }
- $ENV{'PYTHONPATH'} = "$ENV{SRC_ROOT}/instsetoo_native/$ENV{INPATH}/bin:$ENV{SOLARVERSION}/$ENV{INPATH}/lib";
- $ENV{OUT} = "../$ENV{INPATH}";
- $ENV{LOCAL_OUT} = "../$ENV{INPATH}";
- $ENV{LOCAL_COMMON_OUT} = "../$ENV{INPATH}";
- my $sane_destdir = $dest_installdir;
- $sane_destdir .= "oootest";
- createPath ($sane_destdir, $error_setup);
- $Command = "cd $instoo_dir/util ; perl -w $ENV{SOLARENV}/bin/make_installer.pl " .
- "-f openoffice.lst -l en-US -p OpenOffice " .
- "-buildid \"smoketestoo\" -simple $sane_destdir";
-# FIXME - this tool should work nicely without such evil
- execute_Command ($Command, $error_setup, $show_Message, $command_normal);
- return "$sane_destdir/"
-
- } elsif ( (defined($system)) && ($system eq "Linux") ) {
- if (defined ($ENV{FORCE2ARCHIVE}) and ($ENV{FORCE2ARCHIVE} eq "TRUE")) {
- $optdir = $dest_installdir; #needed for getting work dir at the end
- $mask = "\\.tar\\.gz\$";
- getSubFiles ("$installsetpath", \@DirArray, $mask);
- if ($#DirArray == -1) {
- print_error ("Installationset in $installsetpath is incomplete", 2);
- }
- elsif ($#DirArray == 0) {
- createPath ($dest_installdir, $error_setup);
- $Command = "cd \"$dest_installdir\" && tar xzvf \"$installsetpath$DirArray[0]\"";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- }
- else {
- print_error ($error_setup, $show_Message);
- }
- }
- elsif ($ENV{PKGFORMAT} eq "deb") { # default is rpm
- $installsetpath .= "DEBS$PathSeparator";
- $optdir = "$dest_installdir" . "opt" . $PathSeparator;
- createPath ($optdir, $error_setup);
- $mask = "\\.deb\$";
- getSubFiles ("$installsetpath", \@DirArray, $mask);
- if ($#DirArray == -1) {
- print_error ("Installationset in $installsetpath is incomplete", 2);
- }
- foreach $file (@DirArray) {
- if ( ($file =~ /-menus-/) or ($file =~ /^adabas/) or (/^j2re-/) or ($file =~ /-gnome-/) ) {
- next;
- }
- $Command = "dpkg-deb -x $installsetpath$file $dest_installdir";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutErrorcheck | $command_withoutOutput);
- }
- }
- else {
- $installsetpath .= "RPMS$PathSeparator";
- $optdir = "$dest_installdir" . "opt" . $PathSeparator;
- $rpmdir = "$dest_installdir" . "rpm" . $PathSeparator;
- createPath ($optdir, $error_setup);
- createPath ($rpmdir, $error_setup);
- my $ld_library_backup = $ENV{LD_LIBRARY_PATH};
- if ( defined $ENV{SYSBASE}) {
- my $sysbase=$ENV{SYSBASE};
- if ( "$ld_library_backup" eq "" ) {
- $ENV{LD_LIBRARY_PATH} = "$sysbase/usr/lib";
- } else {
- $ENV{LD_LIBRARY_PATH} = "$ld_library_backup:$sysbase/lib";
- }
- }
- $Command = "rpm --initdb --define \"_dbpath $rpmdir\"";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- $mask = "\\.rpm\$";
- getSubFiles ("$installsetpath", \@DirArray, $mask);
- if ($#DirArray == -1) {
- print_error ("Installationset in $installsetpath is incomplete", 2);
- }
- foreach $file (@DirArray) {
- if ( ($file =~ /-menus-/) or ($file =~ /^adabas/) or (/^j2re-/) or ($file =~ /-gnome-/) ) {
- next;
- }
- $Command = "rpm ";
- $Command .= "--ignorearch " if (defined $ENV{HOSTTYPE} && ($ENV{HOSTTYPE} eq 'x86_64-linux'));
- $Command .= "--define \"_dbpath $rpmdir\" --install --ignoresize --nodeps -vh --relocate /opt=${dest_installdir}opt $installsetpath$file";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutErrorcheck | $command_withoutOutput);
- }
- $ENV{LD_LIBRARY_PATH}=$ld_library_backup;
- }
- }
- elsif ( (defined($system)) && ($system eq "SunOS") ) {
- if (defined($ENV{FORCE2ARCHIVE})) {
- print_error ($error_messages[$error_packformat], $error_packformat);
- }
- @DirArray = ();
- $mask = "^.ai.pkg.zone.lock";
- getSubFiles ("/tmp", \@DirArray, $mask);
- if ($#DirArray >= 0) {
- foreach $file (@DirArray) {
- $Command = "$REMOVE_FILE /tmp/$file";
- execute_Command ($Command, $error_logflag, $show_Message, $command_withoutOutput);
- }
- }
- if ($mach eq sun4u) {
- $solarisdata = $DATA . "solaris$PathSeparator" . "sparc$PathSeparator";
- }
- else {
- $solarisdata = $DATA . "solaris$PathSeparator" . "x86$PathSeparator";
- }
- $installsetpath .= "packages$PathSeparator";
- $optdir = "$dest_installdir" . "opt" . $PathSeparator;
- createPath ($optdir, $error_setup);
- createPath ($dest_installdir . "usr$PathSeparator" . "bin", $error_setup);
- @DirArray = ();
- getSubDirs ("$installsetpath", \@DirArray);
- my $ld_preload = $ENV{LD_PRELOAD};
- $ENV{LD_PRELOAD} = $solarisdata . "getuid.so";
- if ($#DirArray == -1) {
- print_error ("Installationset in $installsetpath is incomplete", 2);
- }
- foreach $file (@DirArray) {
- if ( ($file =~ /-gnome/) or ($file =~ /-cde/) or ($file =~ /adabas/) or ($file =~ /j3/) or ($file =~ /-desktop-/) ) {
- next;
- }
- $Command = "pkgparam -d $installsetpath $file BASEDIR";
- $output_ref = execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- if (($#{@$output_ref} > -1) and ($$output_ref[0] ne "") ) {
- createPath ("$dest_installdir$$output_ref[0]", $error_setup);
- }
- $Command = "pkgadd -a $solarisdata" . "admin -d $installsetpath -R $dest_installdir $file";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutErrorcheck | $command_withoutOutput);
- }
- my $pkgadd_tmpfile = "/tmp/.ai.pkg.zone.lock*";
- $Command = "$REMOVE_FILE $pkgadd_tmpfile";
- execute_Command ($Command, $error_setup, $show_NoMessage, $command_withoutErrorcheck | $command_withoutOutput);
- $ENV{LD_PRELOAD} = $ld_preload;
- }
- elsif ( (defined($ENV{OS})) && ($ENV{OS} eq "MACOSX") ) {
- if (defined($ENV{FORCE2ARCHIVE})) {
- print_error ($error_messages[$error_packformat], $error_packformat);
- }
- @DirArray = ();
- my $install_dmg;
- getSubFiles ("$installsetpath", \@DirArray, "^[a-zA-Z0-9].*\\.dmg\$");
- if ($#DirArray == 0) {
- $install_dmg = "$installsetpath" . $DirArray[0];
- }
- elsif ($#DirArray > 0) {
- print_error ("more than one installset found in $installsetpath", 2);
- }
- else {
- print_error ("no installset found in $installsetpath", 2);
- }
- $Command = "hdiutil attach " . $install_dmg;
- my $output_ref;
- $output_ref = execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- my $volumeinfo = $$output_ref[$#{@{$output_ref}}];
- if (!$volumeinfo =~ /OpenOffice/) {
- print_error ("mount of $install_dmg failed", 2);
- }
- $volumeinfo =~ s/\s{2,}/;/g;
- my @volumeinfos = split(/;/,$volumeinfo);
- my $detachpath = $volumeinfos[0];
- my $newinstallsetpath = $volumeinfos[2] . $PathSeparator;
- createPath ($dest_installdir, $error_setup);
- $Command = "$COPY_DIR \"$newinstallsetpath\" \"$dest_installdir\"";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- $Command = "hdiutil detach " . $detachpath;
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- @DirArray = ();
- getSubFiles ("$dest_installdir", \@DirArray, "\\.app");
- if ($#DirArray == 0) {
- $optdir = "$dest_installdir" . $DirArray[0] . $PathSeparator;
- my $PListFile = "Info.plist";
- my $officeDir = "$optdir" . "Contents" . $PathSeparator;
- my $programmDir = "$officeDir" . "MacOS" . $PathSeparator;
- $Command = "$COPY_FILE \"$officeDir$PListFile\" \"$programmDir$PListFile\"";
- execute_Command ($Command, $error_setup, $show_Message, $command_withoutOutput);
- }
- else {
- print_error ("Installation in $dest_installdir is incomplete", 2);
- }
- }
- else {
- print_error ("Plattform is not supported", 2);
- }
- @DirArray = ();
- getSubDirsFullPath ($optdir, \@DirArray);
- if ($#DirArray == 0) {
- $basedir = $DirArray[0] . $PathSeparator;
- }
- elsif ($#DirArray == -1) {
- print_error ($error_setup, $show_Message);
- }
- else {
- $basedir = $optdir;
- }
- }
- return ($basedir);
-}
-
-sub langsort {
- if ($a eq $prefered_lang) {
- return -1;
- }
- elsif ($b eq $prefered_lang) {
- return 1;
- }
- else {
- $a cmp $b;
- }
-}
-
-sub getInstset {
- my ($INSTSET, $NEWINSTSET);
- my (@DirArray, $InstDir, $RootDir, $TestDir1, $TestDir2);
-
- if (defined ($ENV{EPM}) && ($ENV{EPM} eq 'NO') && ($gui eq "UNX")) { # we do the install ourselves ...
- return ();
- }
-
- print "get Instset\n" if $is_debug;
- $NEWINSTSET = "";
- if (defined($smoketest_install)) {
- my $mask = "\\" . $PathSeparator . "\$";
- $smoketest_install =~ s/$mask//;
- my ($sufix);
- ($NEWINSTSET, $INSTSET, $sufix) = fileparse ($smoketest_install);
- return ($NEWINSTSET, $INSTSET);
- }
- if (!isLocalEnv() and !defined($ENV{CWS_WORK_STAMP}) and (-e $SHIP)) {
- ($NEWINSTSET, $INSTSET) = getSetFromServer();
- }
- else {
- $InstDir="";
- $RootDir=$ENV{DMAKE_WORK_DIR};
- $RootDir=~s/\w+$//;
- foreach $project (@install_list) {
- @DirArray=();
- $TestDir1 = "$RootDir$project$PathSeparator$ENV{INPATH}$PathSeparator$PRODUCT$PathSeparator$packpackage$PathSeparator" . "install$PathSeparator";
- if (-e "$TestDir1") {
- $InstDir= $TestDir1;
- }
- else {
- $sourceconfig_obj = SourceConfig->new() if (!defined ($sourceconfig_obj));
- my $module_path = $sourceconfig_obj->get_module_path($project);
- # only if module exists
- if (defined ($module_path)) {
- $TestDir2 = "$module_path$PathSeparator$ENV{INPATH}$PathSeparator$PRODUCT$PathSeparator$packpackage$PathSeparator" . "install$PathSeparator";
- }
- else {
- $TestDir2 = $module_path;
- }
- if (defined ($TestDir2) && -e "$TestDir2") {
- $InstDir="$TestDir2";
- }
- }
- if ($InstDir eq "") {
- next;
- }
- getSubDirs ("$InstDir", \@DirArray);
- $INSTSET = findSubDir (\@DirArray);
- print "Lang-Sel: $INSTSET\n" if $is_command_infos;
-;
- if ($INSTSET ne "") {
- $NEWINSTSET = $INSTSET;
- $INSTSET = $InstDir;
- print "new: $INSTSET\n";
- }
- if (($INSTSET ne "") and (-e $INSTSET)) {
- return ($NEWINSTSET, $INSTSET);
- }
- }
- print_error ("no installationset found\n",2);
- }
- return ($NEWINSTSET, $INSTSET);
-}
-
-sub isLocalEnv {
- my $returnvalue = 0;
- if (defined ($ENV{SOL_TMP}) && defined ($ENV{SOLARVERSION})) {
- my $mask = $ENV{SOL_TMP};
- $mask =~ s/\\/\\\\/;
- print "Mask: $mask\n" if $is_debug;
- if ($ENV{SOLARVERSION}=~ /$mask/) {
- $returnvalue = 1;
- }
- }
- return $returnvalue;
-}
-
-sub get_productcode {
- my ( $installpath ) = @_;
- my ($path, $productcode);
- $productcode = "";
- $path = "$installpath" . "setup.ini";
- print "$path\n" if $is_debug;
- if ( !open(SETUP,$path) ) {
- print "FATAL: can't open $path\n" if ($is_command_infos);
- return ($productcode);
- }
-
- if (!eof(SETUP)) {
- while (<SETUP>) {
- chomp;
- if ( /productcode=(\{[\d\w-]+\})/ ) {
- $productcode = $1;
- }
- }
-
- close(SETUP);
- }
- return ($productcode);
-}
-
-sub InstsetSort {
- my ($a1, $b1);
- if ($a =~ /$global_instset_mask/) {
- $a1 = $1;
- }
- if ($b =~ /$global_instset_mask/) {
- $b1 = $1;
- }
- $a1 <=> $b1;
-}
-
-sub getSetFromServer {
- my ($DirName, $SetupFullPath);
- my $workspace = $ENV{WORK_STAMP};
- my $platform = $ENV{INPATH};
- my $latestset;
- my (@DirArray, $mask);
- $SetupFullPath = $PORDUCT;
- if ( ! ( $workspace && $platform ) ) {
- print_error ( "Error: environment not set correctly.", 1);
- }
- if (!defined($milestone)) {
- print_error ("Milestone ist not defined!", 2);
- }
- if (!defined($buildid)) {
- print_error ("Build-ID ist not defined!", 2);
- }
-
-# if ( $SetupFullPath =~ /^\/s.*\/install\// ) {
-# if ( $gui eq "UNX" ) {
-# $SetupFullPath = "/net/jumbo.germany" . $SetupFullPath;
-# } else {
-# $SetupFullPath = "\\\\jumbo" . $SetupFullPath;
-# }
-# }
-
-# my $ws_lc = lc $workspace;
- $mask = "^$workspace" . "_" . $milestone . "_native_packed-(\\d+)_en-US\\.$buildid";
- $global_instset_mask = $mask;
- getSubFiles ($SetupFullPath, \@DirArray, $mask);
- @DirArray = sort InstsetSort @DirArray;
- if ($#DirArray > -1) {
- $latestset = $DirArray [$#DirArray];
- $DirName = $latestset;
- }
- else {
- print_error ("Cannot find install set $SetupFullPath for $workspace $milestone", 2);
- }
- print "Latest install sets: $latestset\n" if $is_debug;
-
- print "$DirName\t $SetupFullPath\n" if $is_debug;
-
- # compare with file system
- # at the moment just the existence is checked. For security reasons it might be
- # better to additionally check whether there are newer sets (this must not happen,
- # but who knows ...)
- if ( -d $SetupFullPath ) {
- return ($DirName, $SetupFullPath);
- } else {
- print_error ("Cannot find install set $SetupFullPath for $workspace $milestone", 2);
- }
-}
-
-sub patch_bootstrap {
- my ($sourcefile, $destfile) = @_;
- my (@convert_split, $line);
- my ($Error) = 1;
- my ($lineend);
-
- if ($is_debug) {
- print "patching bootstrap $sourcefile ...\n";
- return 1;
- }
-
- $Error &= move ("$sourcefile", "$destfile");
-
- open OUTFILE, ">$sourcefile" or return errorFromOpen ($sourcefile);
- open INFILE, "<$destfile" or return errorFromOpen ($destfile);
- binmode(OUTFILE);
- binmode(INFILE);
- while(<INFILE>) {
- $line = $_;
-
- if ( $line =~ /UserInstallation/ ) {
- if ($line =~ /(\r\n)/) {
- $lineend = $1;
- }
- elsif ($line =~ /(\n)/) {
- $lineend = $1;
- }
- else {
- $lineend = $/;
- }
- @convert_split = split "=", $line;
- $line = $convert_split[0];
- $line .= "=";
- if ($gui eq $cygwin) {
- $line .= ConvertToFileURL(ConvertCygwinToWin($userinstallpath_without));
- }
- else {
- $line .= ConvertToFileURL($userinstallpath_without);
- }
- $line .= $lineend;
- }
- print OUTFILE "$line";
-
- }
-
- close OUTFILE;
- close INFILE;
- $Error &= unlink ($destfile);
- return ($Error);
-}
-
-sub SetWinLineends () {
- $/ = $WinLineends;
-}
-
-sub SetCygwinLineends () {
- $/ = $CygwinLineends;
-}
-
-sub ConvertToFileURL {
- my ($filename) = @_;
- my ($FileURL);
-
- $FileURL = $FileURLPrefix . $filename;
- $FileURL =~ s/\\/\//g;
- $FileURL =~ s/\/\/\/\//\/\/\//; # 4 slashes to 3 slashes
- return ($FileURL);
-}
-
-sub ConvertCygwinToWin_Shell {
- my ($cygwinpath) = @_;
- my ($winpath);
- $winpath = ConvertCygwinToWin ($cygwinpath);
- $winpath =~ s/\\/\\\\/g;
- return ($winpath);
-}
-
-sub ConvertCygwinToWin {
- my ($cygwinpath) = @_;
- my ($winpath);
- my ($last_lineends) = $/;
- SetCygwinLineends();
- $winpath=`cygpath --windows $cygwinpath`;
- chomp($winpath);
- $/ = $last_lineends;
- return ($winpath);
-}
-
-sub createPath {
- my ($path, $Error) = @_;
- if (!-d "$path") {
- if (!$is_debug) {
- eval {mkpath("$path", 0, 0777)};
- if ($@) {
- print_error ($error_messages[$Error], $Error);
- }
- }
- else {
- print "mkpath($path, 0, 0777)\n";
- }
- }
-}
-
-sub save_sversion {
- my ($sversion) = @_;
- my ($sversion_bak) = $sversion . "_";
- if (-e $sversion) {
- if (-e $sversion_bak) {
- execute_system("$REMOVE_FILE \"$sversion_bak\"");
- }
- execute_system("$COPY_FILE \"$sversion\" \"$sversion_bak\"");
- execute_system("$REMOVE_FILE \"$sversion\"");
- $sversion_saved = 1;
- }
-}
-
-sub restore_sversion {
- my ($sversion) = @_;
- my ($sversion_bak) = $sversion . "_";
- if ($sversion_saved) {
- if (-e $sversion) {
- execute_system("$REMOVE_FILE \"$sversion\"");
- }
- execute_system("$COPY_FILE \"$sversion_bak\" \"$sversion\"");
- execute_system("$REMOVE_FILE \"$sversion_bak\"");
- $sversion_saved = 0;
- }
-}
-
-sub removeOldInstallation {
- my ($installpath) = @_;
- if (!$is_debug) {
- if (-e $installpath) {
- execute_system("$REMOVE_DIR \"$installpath\"");
- }
- if (-e $installpath) {
- print_error ("can not clear old installation in $installpath\n", 3);
- }
- }
-}
-
-sub removeInstallation {
- my ($installpath) = @_;
- if (!$is_debug) {
- if (-e $installpath) {
- execute_system("$REMOVE_DIR \"$installpath\"");
- }
- }
-}
-
-sub deinstallInstallation {
- my ($installpath) = @_;
- my ($productcode);
- if ($gui eq "UNX") { return; }
- if (!$is_debug) {
- if (-e $installpath) {
- $productcode = get_productcode ($installpath);
- print "Productcode: $productcode\n" if ($is_command_infos);
- if ($productcode ne "") {
- print "deinstalling $productcode ...\n";
- $Command = "msiexec.exe -x $productcode -qn";
- execute_Command ($Command, $error_deinst, $show_Message, $command_withoutErrorcheck | $command_withoutOutput);
- }
- }
- }
-}
-
-sub setInstallpath {
- my ($infile, $outfile, $installpath) = @_;
- if (-e $outfile) {
- execute_system ("$REMOVE_FILE \"$outfile\"");
-
- }
- open OUTTABLE, ">$outfile" or die "Error: can\'t open solarfile $outfile";
- open INTABLE, "<$infile" or die "Error: can\'t open solarfile $infile";
- while(<INTABLE>) {
- $line = $_;
- if ( $line =~ /^DESTINATIONPATH=officeinstallpath/ ) {
- $line =~ s/officeinstallpath/$installpath/;
- }
- print OUTTABLE "$line";
- }
- close INTABLE;
- close OUTTABLE;
-}
-
-sub execute_Command {
- my ($Command, $Errorcode, $showMessage, $command_action) = @_;
- my ($Returncode, $output_ref);
- if (!$is_debug) {
- if ( ($command_action & $command_withoutOutput) == $command_withoutOutput) {
- ($Returncode, $output_ref) = execute_system ("$Command");
- }
- else {
- print "$Command\n" if $is_command_infos;
- $Returncode = system ("$Command");
- }
- if ($Returncode) {
- if ($showMessage) {
- if (($command_action & $command_withoutErrorcheck) == $command_withoutErrorcheck) {
- print_warning ($error_messages[$Errorcode], $Errorcode);
- }
- else {
- print_error ($error_messages[$Errorcode], $Errorcode);
- }
- }
- else {
- if (($command_action & $command_withoutErrorcheck) != $command_withoutErrorcheck) {
- do_exit ($Errorcode);
- }
- }
- }
- }
- else {
- print "$Command\n";
- }
- return $output_ref;
-}
-
-sub execute_system {
- my ($command) = shift;
- my (@output_array, $line);
- if ( $is_command_infos ) {
- print STDERR "TRACE_SYSTEM: $command\n";
- }
- open( COMMAND, "$command 2>&1 |");
- while ($line = <COMMAND>) {
- chomp $line;
- push (@output_array, $line);
- }
- close(COMMAND);
- return $?, \@output_array;
-}
-
-sub print_warning
-{
- my $message = shift;
-
- print STDERR "$script_name: ";
- print STDERR "WARNING $message\n";
- return;
-}
-
-sub print_error
-{
- my $message = shift;
- my $error_code = shift;
-
- print STDERR "$script_name: ";
- print STDERR "ERROR: $message\n";
-
- do_exit($error_code);
-}
-
-sub print_notRemoved {
- my ($installpath) = @_;
- print "no deinstallation from $installpath\n";
-}
-
-sub do_exit
-{
- my $error_code = shift;
-
- if ($sversion_saved) {
- restore_sversion ($SVERSION_INI);
- }
- if ($is_remove_on_error) {
- if ($is_do_deinstall) {
- deinstallInstallation ($installpath);
- }
- removeInstallation($installpath);
- }
- else {
- print_notRemoved ($installpath);
- }
- if ( $error_code ) {
- print STDERR "\nFAILURE: $script_name aborted.\n";
- }
- exit($error_code);
-
-}
diff --git a/smoketestoo_native/testlog.pl b/smoketestoo_native/testlog.pl
deleted file mode 100755
index 6b44c75728fb..000000000000
--- a/smoketestoo_native/testlog.pl
+++ /dev/null
@@ -1,286 +0,0 @@
-:
-eval 'exec perl -wS $0 ${1+"$@"}'
- if 0;
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-### globals ###
-
-$is_debug = 0;
-
-$global_log = "log.dat";
-
-%logfiles_list = ("writer", "swlog.dat",
- "math", "smalog.dat",
- "HTML", "shptlog.dat",
- "draw", "sdrwlog.dat",
- "impress", "sdlog.dat",
- "calc", "sclog.dat",
- "chart", "schlog.dat",
- "Java", "javalog.dat",
- "Database", "dblog.dat",
- "Extension", "extlog.dat"
-);
-
-%log = ();
-@ApplicationLog = ();
-$dont_kill ="dont_deinstall";
-$error_str = "error";
-$tests_complete = "---";
-$gui = $ENV{GUI};
-$inpath = $ENV{INPATH};
-$cygwin = "cygwin";
-
-if ($^O =~ /cygwin/) {
- $gui = $cygwin;
-}
-
-if (($gui eq "UNX") or ($gui eq $cygwin)) {
- $pathslash = "/";
-}
-else
-{
- $pathslash = "\\";
-}
-
-$misc = $inpath . $pathslash . "misc" . $pathslash;
-$okfile = $misc . "ok.bat";
-umask (02);
-
-### sub routines ###
-
-sub test_logfile {
- my ($file, $testname) = @_;
- my ($line, $failed, $complete, $linecount, $LastLineError);
-
- $failed = 0;
- $complete = 0;
- $linecount = -1;
- $LastLineError = 0;
-
- if (! -e $file) {
- print "error: $testname failed! Logfile is missing.\n" if $is_debug;
-
- return (0,0);
- }
-
- open TABLE, "<$file" or die "Error: can´t open log file $file]";
-
- while(<TABLE>) {
- $line = $_;
- chomp $line;
- $linecount++;
- if ( $line =~ /$error_str/ ) {
- print "error: $testname: $line\n";
- $failed = 1;
- $LastLineError = 1;
- }
- elsif ( $line =~ /$tests_complete/ ) {
- $complete = 1;
- print "$file: $line\n" if $is_debug;
- }
- else
- {
- print "$testname: $line\n" if $is_debug;
- $LastLineError = 0;
- }
- }
-
- close TABLE;
-
- print "$failed $complete $LastLineError $linecount\n" if $is_debug;
-
- if (!$complete) {
- my $message = "error: $testname: the test was not complete!";
- if ((!$failed) || (($failed) && (!$LastLineError))) {
- my $errormessage = getLog ($testname, $linecount+1);
- if ($errormessage ne "") {
- $message .= " $errormessage possibly failed!";
- }
- }
- if (!$failed && !$is_testerror) {
- print "$message\n";
- }
- }
-
- if (!$failed && $complete) {
- print "true\n" if $is_debug;
- return (1,1);
- }
- else
- {
- print "false\n" if $is_debug;
- return (0,1);
- }
-}
-
-sub readGlobalLog {
- my ($line);
- my $logfilename = $logfiledir . $pathslash . $global_log;
- if (! -e $logfilename) {
- print "$logfilename: file is missing\n" if $is_debug;
- return 0;
- }
-
- open TABLE, "<$logfilename" or die "Error: can´t open log file $logfilename]";
-
- my $failed = 0;
- my $complete = 0;
- my $FirstLine = 1;
- while(defined($line = <TABLE>) and !$complete) {
- chomp $line;
- if ($FirstLine) {
- if ( $line =~ /Sequence of testing/ ) {
- $FirstLine = 0;
- next;
- }
- else {
- print "$logfilename: $line\n" if $is_debug;
- $failed = 1;
- return 0;
- }
- }
- else {
- if ( $line eq "" ) {
- $complete = 1;
- next;
- }
- my @splitedLine = split(/:/,$line);
- my $testApplication = $splitedLine [0];
- $testApplication =~ s/^ *(.*?) *$/$1/g; #truncate
- my $testAction = $splitedLine [1];
- @splitedLine = split(/,/,$testAction);
- my @log_array = ();
- foreach my $action (@splitedLine) {
- $action =~ s/^ *(.*?) *$/$1/g; #truncate
- if ($action =~ /\//) {
- my @splitAction = split(/\//,$action);
- my @specialAction;
- foreach my $doubleaction (@splitAction) {
- $doubleaction =~ s/^ *(.*?) *$/$1/g; #truncate
- push (@specialAction, $doubleaction);
- }
- $action = join (' or ', @specialAction);
- foreach my $doubleaction (@splitAction) {
- push (@log_array, $action);
- }
- }
- else {
- push (@log_array, $action);
- }
- }
- push (@ApplicationLog, $testApplication);
- $log{$testApplication} = \@log_array;
- }
- }
-
- close TABLE;
-
- return 1;
-}
-
-sub getLog {
- my ($testname, $linecount) = @_;
- if ($linecount <= $#{@{$log{$testname}}}) {
- return $log{$testname}[$linecount];
- }
- else {
- return "";
- }
-}
-
-### main ###
-
-$idStr = ' $Revision: 1.6 $ ';
-$idStr =~ /Revision:\s+(\S+)\s+\$/
- ? ($cpflat2minor_rev = $1) : ($cpflat2minor_rev = "-");
-
-print "TestLog -- Version: $cpflat2minor_rev\n";
-
-if (-e $okfile) {
- unlink ($okfile);
-}
-
-if ( ($#ARGV >-1) && ($#ARGV < 1) ) {
- $ARGV[0] =~ s/\"//g;
-}
-
-if ( ! ( ($#ARGV < 1) && $ARGV[0] && (-d $ARGV[0]) ) ) {
- print "Error! Usage: testlog <log_directory>\n" ;
- exit(1);
-}
-
-$logfiledir = $ARGV[0];
-$is_testerror = 0;
-$is_OneTestAvailable = 0;
-
-print "%logfiles_list\n" if $is_debug;
-
-readGlobalLog();
-
-foreach my $applog (@ApplicationLog) {
- if (!exists($logfiles_list{$applog})) {
- next;
- }
- my $logname = $logfiles_list{$applog};
- $current_file = $logfiledir . $pathslash . $logname;
- my ($error, $logfile) = test_logfile ($current_file, $applog);
-
- if ($logfile) {
- $is_OneTestAvailable = 1;
- }
- elsif (!$is_testerror) {
- print "error: $applog failed! Logfile is missing.\n";
- }
-
- if (!$error) {
- $is_testerror = 1;
- }
-
-}
-
-# write file to prevent deinstallation of office
-if ($is_testerror) {
- $dont_del_file = $logfiledir . $pathslash . $dont_kill;
- open (ERRFILE, ">$dont_del_file");
- print ERRFILE "dont delete flag";
- close (ERRFILE);
-}
-else {
- print "$okfile\n" if $is_debug;
- open( OKFILE, ">$okfile");
- print OKFILE "echo ok!\n";
- close( OKFILE );
- chmod (0775, "$okfile");
-}
-
-if (!$is_OneTestAvailable) {
- print "error: no test succeeded! Maybe Office crashed during starting!\n";
- $is_testerror = 1;
-}
-
-exit($is_testerror);
diff --git a/testtools/source/bridgetest/component.map b/smoketestoo_native/version.map
index e4b038369818..00a28463c5d2 100644
--- a/testtools/source/bridgetest/component.map
+++ b/smoketestoo_native/version.map
@@ -23,13 +23,11 @@
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
-#*************************************************************************
+#***********************************************************************/
UDK_3_0_0 {
global:
- component_getFactory;
- component_getImplementationEnvironment;
- component_writeInfo;
+ cppunitTestPlugIn;
local:
*;
diff --git a/testshl2/util/makefile.mk b/test/inc/makefile.mk
index 57eb9d546beb..c8428466005b 100644
--- a/testshl2/util/makefile.mk
+++ b/test/inc/makefile.mk
@@ -1,7 +1,6 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,17 +21,18 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..
-
-PRJNAME=testshl2
-TARGET=testshl2
+#***********************************************************************/
-# --- Settings -----------------------------------------------------
+PRJ = ..
+PRJNAME = test
+TARGET = inc
-.INCLUDE : settings.mk
+ENABLE_EXCEPTIONS = TRUE
+VISIBILITY_HIDDEN = TRUE
-# --- Targets ------------------------------------------------------
+.INCLUDE: settings.mk
+.INCLUDE: target.mk
-.INCLUDE : target.mk
+.IF "$(ENABLE_PCH)" != ""
+ALLTAR: $(SLO)/precompiled.pch $(SLO)/precompiled_ex.pch
+.ENDIF
diff --git a/test/inc/pch/precompiled_test.cxx b/test/inc/pch/precompiled_test.cxx
new file mode 100644
index 000000000000..7077411c8fc5
--- /dev/null
+++ b/test/inc/pch/precompiled_test.cxx
@@ -0,0 +1,26 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#include "precompiled_test.hxx"
diff --git a/test/inc/pch/precompiled_test.hxx b/test/inc/pch/precompiled_test.hxx
new file mode 100644
index 000000000000..d4927944f9c7
--- /dev/null
+++ b/test/inc/pch/precompiled_test.hxx
@@ -0,0 +1,30 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#if defined PRECOMPILED_HEADERS
+
+#include "sal/config.h"
+
+#endif
diff --git a/test/inc/test/detail/testdllapi.hxx b/test/inc/test/detail/testdllapi.hxx
new file mode 100644
index 000000000000..41d5b4d69b8c
--- /dev/null
+++ b/test/inc/test/detail/testdllapi.hxx
@@ -0,0 +1,39 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#ifndef INCLUDED_TEST_DETAIL_TESTDLLAPI_HXX
+#define INCLUDED_TEST_DETAIL_TESTDLLAPI_HXX
+
+#include "sal/config.h"
+
+#include "sal/types.h"
+
+#if defined OOO_DLLIMPLEMENTATION_TEST
+#define OOO_DLLPUBLIC_TEST SAL_DLLPUBLIC_EXPORT
+#else
+#define OOO_DLLPUBLIC_TEST SAL_DLLPUBLIC_IMPORT
+#endif
+
+#endif
diff --git a/test/inc/test/getargument.hxx b/test/inc/test/getargument.hxx
new file mode 100644
index 000000000000..1b4df29d2115
--- /dev/null
+++ b/test/inc/test/getargument.hxx
@@ -0,0 +1,44 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#ifndef INCLUDED_TEST_GETARGUMENT_HXX
+#define INCLUDED_TEST_GETARGUMENT_HXX
+
+#include "sal/config.h"
+
+#include "test/detail/testdllapi.hxx"
+
+namespace rtl { class OUString; }
+
+namespace test {
+
+// Obtain the value of an argument tunneled in via an "arg-<name>" bootstrap
+// variable:
+OOO_DLLPUBLIC_TEST bool getArgument(
+ rtl::OUString const & name, rtl::OUString * value);
+
+}
+
+#endif
diff --git a/test/inc/test/officeconnection.hxx b/test/inc/test/officeconnection.hxx
new file mode 100644
index 000000000000..99a319d51a7e
--- /dev/null
+++ b/test/inc/test/officeconnection.hxx
@@ -0,0 +1,65 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#ifndef INCLUDED_TEST_OFFICECONNECTION_HXX
+#define INCLUDED_TEST_OFFICECONNECTION_HXX
+
+#include "sal/config.h"
+
+#include "boost/noncopyable.hpp"
+#include "com/sun/star/uno/Reference.hxx"
+#include "osl/process.h"
+#include "test/detail/testdllapi.hxx"
+
+namespace com { namespace sun { namespace star { namespace lang {
+ class XMultiServiceFactory;
+} } } }
+
+namespace test {
+
+// Start up and shut down an OOo instance (details about the OOo instance are
+// tunneled in via "arg-..." bootstrap variables):
+class OOO_DLLPUBLIC_TEST OfficeConnection: private boost::noncopyable {
+public:
+ OfficeConnection();
+
+ ~OfficeConnection();
+
+ void setUp();
+
+ void tearDown();
+
+ com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >
+ getFactory() const;
+
+private:
+ oslProcess process_;
+ com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >
+ factory_;
+};
+
+}
+
+#endif
diff --git a/test/inc/test/oustringostreaminserter.hxx b/test/inc/test/oustringostreaminserter.hxx
new file mode 100644
index 000000000000..187b0ebd5f83
--- /dev/null
+++ b/test/inc/test/oustringostreaminserter.hxx
@@ -0,0 +1,48 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#ifndef INCLUDED_TEST_OUSTRINGOSTREAMINSERTER_HXX
+#define INCLUDED_TEST_OUSTRINGOSTREAMINSERTER_HXX
+
+#include "sal/config.h"
+
+#include <ostream>
+
+#include "osl/thread.h"
+#include "rtl/ustring.hxx"
+
+// Include this header to support rtl::OUString in CPPUNIT_ASSERT macros.
+
+template< typename charT, typename traits > std::basic_ostream<charT, traits> &
+operator <<(
+ std::basic_ostream<charT, traits> & stream, rtl::OUString const & string)
+{
+ return stream <<
+ rtl::OUStringToOString(string, osl_getThreadTextEncoding()).getStr();
+ // best effort; potentially loses data due to conversion failures and
+ // embedded null characters
+}
+
+#endif
diff --git a/test/inc/test/toabsolutefileurl.hxx b/test/inc/test/toabsolutefileurl.hxx
new file mode 100644
index 000000000000..5828a050fb75
--- /dev/null
+++ b/test/inc/test/toabsolutefileurl.hxx
@@ -0,0 +1,44 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#ifndef INCLUDED_TEST_TOABSOLUTEFILEURL_HXX
+#define INCLUDED_TEST_TOABSOLUTEFILEURL_HXX
+
+#include "sal/config.h"
+
+#include "test/detail/testdllapi.hxx"
+
+namespace rtl { class OUString; }
+
+namespace test {
+
+// Convert a pathname in system notation, potentially relative to the process's
+// current working directory, to an absolute file URL:
+OOO_DLLPUBLIC_TEST rtl::OUString toAbsoluteFileUrl(
+ rtl::OUString const & relativePathname);
+
+}
+
+#endif
diff --git a/test/prj/build.lst b/test/prj/build.lst
new file mode 100644
index 000000000000..1bf76d664a7a
--- /dev/null
+++ b/test/prj/build.lst
@@ -0,0 +1,4 @@
+te test : BOOST:boost cppu cppuhelper CPPUNIT:cppunit javaunohelper offuh ridljar sal solenv unoil NULL
+te test\inc nmake - all inc NULL
+te test\source\cpp nmake - all source_cpp inc NULL
+te test\source\java nmake - all source_java NULL
diff --git a/test/prj/d.lst b/test/prj/d.lst
new file mode 100644
index 000000000000..bcea8bee46fe
--- /dev/null
+++ b/test/prj/d.lst
@@ -0,0 +1,12 @@
+mkdir: %_DEST%\inc%_EXT%\test
+mkdir: %_DEST%\inc%_EXT%\test\detail
+..\%__SRC%\bin\test.dll %_DEST%\bin%_EXT%\test.dll
+..\%__SRC%\lib\itest.lib %_DEST%\lib%_EXT%\itest.lib
+..\%__SRC%\lib\libtest.dylib %_DEST%\lib%_EXT%\libtest.dylib
+..\%__SRC%\lib\libtest.so %_DEST%\lib%_EXT%\libtest.so
+..\inc\test\detail\testdllapi.hxx %_DEST%\inc%_EXT%\test\detail\testdllapi.hxx
+..\inc\test\getargument.hxx %_DEST%\inc%_EXT%\test\getargument.hxx
+..\inc\test\officeconnection.hxx %_DEST%\inc%_EXT%\test\officeconnection.hxx
+..\inc\test\oustringostreaminserter.hxx %_DEST%\inc%_EXT%\test\oustringostreaminserter.hxx
+..\inc\test\toabsolutefileurl.hxx %_DEST%\inc%_EXT%\test\toabsolutefileurl.hxx
+..\%__SRC%\class\test.jar %_DEST%\bin%_EXT%\test.jar
diff --git a/test/source/cpp/getargument.cxx b/test/source/cpp/getargument.cxx
new file mode 100644
index 000000000000..339c5c9c797d
--- /dev/null
+++ b/test/source/cpp/getargument.cxx
@@ -0,0 +1,42 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#include "sal/config.h"
+
+#include "osl/diagnose.h"
+#include "rtl/bootstrap.hxx"
+#include "rtl/ustring.h"
+#include "rtl/ustring.hxx"
+#include "test/getargument.hxx"
+
+namespace test {
+
+bool getArgument(rtl::OUString const & name, rtl::OUString * value) {
+ OSL_ASSERT(value != 0);
+ return rtl::Bootstrap::get(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("arg-")) + name, *value);
+}
+
+}
diff --git a/testshl2/workben/skeleton/makefile.mk b/test/source/cpp/makefile.mk
index a9025d2717f5..8494bd4aaa05 100644
--- a/testshl2/workben/skeleton/makefile.mk
+++ b/test/source/cpp/makefile.mk
@@ -1,7 +1,6 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,30 +21,35 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+#***********************************************************************/
-PRJ := ..$/..
-PRJNAME := testshl2
+PRJ = ../..
+PRJNAME = test
+TARGET = cpp
-TARGET := testshl2_workben_skeleton
-
-ENABLE_EXCEPTIONS := TRUE
-
-# --- Settings -----------------------------------------------------
+ENABLE_EXCEPTIONS = TRUE
+VISIBILITY_HIDDEN = TRUE
.INCLUDE: settings.mk
-SHL1TARGET := $(TARGET)
-SHL1OBJS := \
- $(SLO)$/skeleton.obj
-
-SHL1IMPLIB := i$(SHL1TARGET)
-SHL1STDLIBS := $(CPPUNITLIB) $(SALLIB)
-SHL1VERSIONMAP := export.map
-DEF1NAME := $(SHL1TARGET)
-
-# --- Targets ------------------------------------------------------
+CDEFS += -DOOO_DLLIMPLEMENTATION_TEST
+CFLAGSCXX += $(CPPUNIT_CFLAGS)
+
+SLOFILES = \
+ $(SLO)/getargument.obj \
+ $(SLO)/officeconnection.obj \
+ $(SLO)/toabsolutefileurl.obj
+
+SHL1IMPLIB = i$(SHL1TARGET)
+SHL1OBJS = $(SLOFILES)
+SHL1RPATH = NONE
+SHL1STDLIBS = \
+ $(CPPUHELPERLIB) \
+ $(CPPULIB) \
+ $(CPPUNITLIB) \
+ $(SALLIB)
+SHL1TARGET = test
+SHL1USE_EXPORTS = name
+DEF1NAME = $(SHL1TARGET)
.INCLUDE: target.mk
-.INCLUDE : _cppunit.mk
diff --git a/test/source/cpp/officeconnection.cxx b/test/source/cpp/officeconnection.cxx
new file mode 100644
index 000000000000..ccfd2cd0a069
--- /dev/null
+++ b/test/source/cpp/officeconnection.cxx
@@ -0,0 +1,173 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#include "sal/config.h"
+
+#include "com/sun/star/bridge/UnoUrlResolver.hpp"
+#include "com/sun/star/bridge/XUnoUrlResolver.hpp"
+#include "com/sun/star/connection/NoConnectException.hpp"
+#include "com/sun/star/frame/XDesktop.hpp"
+#include "com/sun/star/lang/DisposedException.hpp"
+#include "com/sun/star/lang/XMultiServiceFactory.hpp"
+#include "com/sun/star/uno/Reference.hxx"
+#include "cppuhelper/bootstrap.hxx"
+#include "cppunit/TestAssert.h"
+#include "osl/process.h"
+#include "osl/time.h"
+#include "sal/types.h"
+#include "test/getargument.hxx"
+#include "test/officeconnection.hxx"
+#include "test/toabsolutefileurl.hxx"
+
+namespace {
+
+namespace css = com::sun::star;
+
+}
+
+namespace test {
+
+OfficeConnection::OfficeConnection(): process_(0) {}
+
+OfficeConnection::~OfficeConnection() {}
+
+void OfficeConnection::setUp() {
+ rtl::OUString desc;
+ rtl::OUString argSoffice;
+ CPPUNIT_ASSERT(
+ getArgument(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("soffice")),
+ &argSoffice));
+ if (argSoffice.matchAsciiL(RTL_CONSTASCII_STRINGPARAM("path:"))) {
+ oslProcessInfo info;
+ info.Size = sizeof info;
+ CPPUNIT_ASSERT_EQUAL(
+ osl_Process_E_None,
+ osl_getProcessInfo(0, osl_Process_IDENTIFIER, &info));
+ desc = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("pipe,name=oootest")) +
+ rtl::OUString::valueOf(static_cast< sal_Int64 >(info.Ident));
+ rtl::OUString noquickArg(
+ RTL_CONSTASCII_USTRINGPARAM("-quickstart=no"));
+ rtl::OUString nofirstArg(
+ RTL_CONSTASCII_USTRINGPARAM("-nofirststartwizard"));
+ rtl::OUString norestoreArg(RTL_CONSTASCII_USTRINGPARAM("-norestore"));
+ rtl::OUString acceptArg(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("-accept=")) + desc +
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(";urp")));
+ rtl::OUString argUser;
+ CPPUNIT_ASSERT(
+ getArgument(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("user")), &argUser));
+ rtl::OUString userArg(
+ rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("-env:UserInstallation=")) +
+ toAbsoluteFileUrl(argUser));
+ rtl::OUString jreArg(
+ RTL_CONSTASCII_USTRINGPARAM("-env:UNO_JAVA_JFW_ENV_JREHOME=true"));
+ rtl::OUString classpathArg(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "-env:UNO_JAVA_JFW_ENV_CLASSPATH=true"));
+ rtl_uString * args[] = {
+ noquickArg.pData, nofirstArg.pData, norestoreArg.pData,
+ acceptArg.pData, userArg.pData, jreArg.pData, classpathArg.pData };
+ rtl_uString ** envs = 0;
+ rtl::OUString argEnv;
+ if (getArgument(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("env")), &argEnv))
+ {
+ envs = &argEnv.pData;
+ }
+ CPPUNIT_ASSERT_EQUAL(
+ osl_Process_E_None,
+ osl_executeProcess(
+ toAbsoluteFileUrl(
+ argSoffice.copy(RTL_CONSTASCII_LENGTH("path:"))).pData,
+ args, sizeof args / sizeof args[0], 0, 0, 0, envs,
+ envs == 0 ? 0 : 1, &process_));
+ } else if (argSoffice.matchAsciiL(RTL_CONSTASCII_STRINGPARAM("connect:"))) {
+ desc = argSoffice.copy(RTL_CONSTASCII_LENGTH("connect:"));
+ } else {
+ CPPUNIT_FAIL(
+ "\"soffice\" argument starts with neither \"path:\" nor"
+ " \"connect:\"");
+ }
+ css::uno::Reference< css::bridge::XUnoUrlResolver > resolver(
+ css::bridge::UnoUrlResolver::create(
+ cppu::defaultBootstrap_InitialComponentContext()));
+ for (;;) {
+ try {
+ factory_ =
+ css::uno::Reference< css::lang::XMultiServiceFactory >(
+ resolver->resolve(
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("uno:")) +
+ desc +
+ rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ ";urp;StarOffice.ServiceManager"))),
+ css::uno::UNO_QUERY_THROW);
+ break;
+ } catch (css::connection::NoConnectException &) {}
+ if (process_ != 0) {
+ TimeValue delay = { 1, 0 }; // 1 sec
+ CPPUNIT_ASSERT_EQUAL(
+ osl_Process_E_TimedOut,
+ osl_joinProcessWithTimeout(process_, &delay));
+ }
+ }
+}
+
+void OfficeConnection::tearDown() {
+ if (factory_.is()) {
+ css::uno::Reference< css::frame::XDesktop > desktop(
+ factory_->createInstance(
+ rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop"))),
+ css::uno::UNO_QUERY_THROW);
+ factory_.clear();
+ try {
+ CPPUNIT_ASSERT(desktop->terminate());
+ desktop.clear();
+ } catch (css::lang::DisposedException &) {}
+ // it appears that DisposedExceptions can already happen while
+ // receiving the response of the terminate call
+ }
+ if (process_ != 0) {
+ CPPUNIT_ASSERT_EQUAL(osl_Process_E_None, osl_joinProcess(process_));
+ oslProcessInfo info;
+ info.Size = sizeof info;
+ CPPUNIT_ASSERT_EQUAL(
+ osl_Process_E_None,
+ osl_getProcessInfo(process_, osl_Process_EXITCODE, &info));
+ CPPUNIT_ASSERT_EQUAL(oslProcessExitCode(0), info.Code);
+ osl_freeProcessHandle(process_);
+ }
+}
+
+css::uno::Reference< css::lang::XMultiServiceFactory >
+OfficeConnection::getFactory() const {
+ return factory_;
+}
+
+}
diff --git a/test/source/cpp/toabsolutefileurl.cxx b/test/source/cpp/toabsolutefileurl.cxx
new file mode 100644
index 000000000000..be7f2ae20921
--- /dev/null
+++ b/test/source/cpp/toabsolutefileurl.cxx
@@ -0,0 +1,83 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+#include "sal/config.h"
+
+#include "com/sun/star/uno/Reference.hxx"
+#include "com/sun/star/uno/RuntimeException.hpp"
+#include "com/sun/star/uno/XInterface.hpp"
+#include "osl/file.hxx"
+#include "osl/process.h"
+#include "rtl/ustring.hxx"
+#include "test/toabsolutefileurl.hxx"
+
+namespace {
+
+namespace css = com::sun::star;
+
+}
+
+namespace test {
+
+rtl::OUString toAbsoluteFileUrl(rtl::OUString const & relativePathname) {
+ rtl::OUString cwd;
+ oslProcessError e1 = osl_getProcessWorkingDir(&cwd.pData);
+ if (e1 != osl_Process_E_None) {
+ throw css::uno::RuntimeException(
+ (rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "osl_getProcessWorkingDir failed with ")) +
+ rtl::OUString::valueOf(static_cast< sal_Int32 >(e1))),
+ css::uno::Reference< css::uno::XInterface >());
+ }
+ rtl::OUString url;
+ osl::FileBase::RC e2 = osl::FileBase::getFileURLFromSystemPath(
+ relativePathname, url);
+ if (e2 != osl::FileBase::E_None) {
+ throw css::uno::RuntimeException(
+ (rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "osl::FileBase::getFileURLFromSystemPath(")) +
+ relativePathname +
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(") failed with ")) +
+ rtl::OUString::valueOf(static_cast< sal_Int32 >(e2))),
+ css::uno::Reference< css::uno::XInterface >());
+ }
+ rtl::OUString absUrl;
+ e2 = osl::FileBase::getAbsoluteFileURL(cwd, url, absUrl);
+ if (e2 != osl::FileBase::E_None) {
+ throw css::uno::RuntimeException(
+ (rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "osl::FileBase::getAbsoluteFileURL(")) +
+ cwd + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(", ")) + url +
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(") failed with ")) +
+ rtl::OUString::valueOf(static_cast< sal_Int32 >(e2))),
+ css::uno::Reference< css::uno::XInterface >());
+ }
+ return absUrl;
+}
+
+}
diff --git a/test/source/java/OfficeConnection.java b/test/source/java/OfficeConnection.java
new file mode 100644
index 000000000000..6887c3bfa3cd
--- /dev/null
+++ b/test/source/java/OfficeConnection.java
@@ -0,0 +1,221 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+package org.openoffice.test;
+
+import com.sun.star.bridge.UnoUrlResolver;
+import com.sun.star.bridge.XUnoUrlResolver;
+import com.sun.star.comp.helper.Bootstrap;
+import com.sun.star.connection.NoConnectException;
+import com.sun.star.frame.XDesktop;
+import com.sun.star.lang.DisposedException;
+import com.sun.star.lang.XMultiServiceFactory;
+import com.sun.star.uno.UnoRuntime;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.PrintStream;
+import java.util.Map;
+import java.util.UUID;
+import static org.junit.Assert.*;
+
+/** Start up and shut down an OOo instance.
+
+ Details about the OOo instance are tunneled in via
+ org.openoffice.test.arg.... system properties.
+*/
+public final class OfficeConnection {
+ /** Start up an OOo instance.
+ */
+ public void setUp() throws Exception {
+ String sofficeArg = getArgument("soffice");
+ if (sofficeArg.startsWith("path:")) {
+ description = "pipe,name=oootest" + UUID.randomUUID();
+ ProcessBuilder pb = new ProcessBuilder(
+ sofficeArg.substring("path:".length()), "-quickstart=no",
+ "-nofirststartwizard", "-norestore",
+ "-accept=" + description + ";urp",
+ "-env:UserInstallation=" + getArgument("user"),
+ "-env:UNO_JAVA_JFW_ENV_JREHOME=true",
+ "-env:UNO_JAVA_JFW_ENV_CLASSPATH=true");
+ String envArg = getArgument("env");
+ if (envArg != null) {
+ Map<String, String> env = pb.environment();
+ int i = envArg.indexOf("=");
+ if (i == -1) {
+ env.remove(envArg);
+ } else {
+ env.put(envArg.substring(0, i), envArg.substring(i + 1));
+ }
+ }
+ process = pb.start();
+ outForward = new Forward(process.getInputStream(), System.out);
+ outForward.start();
+ errForward = new Forward(process.getErrorStream(), System.err);
+ errForward.start();
+ } else if (sofficeArg.startsWith("connect:")) {
+ description = sofficeArg.substring("connect:".length());
+ } else {
+ fail(
+ "\"soffice\" argument \"" + sofficeArg +
+ " starts with neither \"path:\" nor \"connect:\"");
+ }
+ XUnoUrlResolver resolver = UnoUrlResolver.create(
+ Bootstrap.createInitialComponentContext(null));
+ for (;;) {
+ try {
+ factory = UnoRuntime.queryInterface(
+ XMultiServiceFactory.class,
+ resolver.resolve(
+ "uno:" + description +
+ ";urp;StarOffice.ServiceManager"));
+ break;
+ } catch (NoConnectException e) {}
+ if (process != null) {
+ assertNull(waitForProcess(process, 1000)); // 1 sec
+ }
+ }
+ }
+
+ /** Shut down the OOo instance.
+ */
+ public void tearDown()
+ throws InterruptedException, com.sun.star.uno.Exception
+ {
+ boolean desktopTerminated = true;
+ if (factory != null) {
+ XDesktop desktop = UnoRuntime.queryInterface(
+ XDesktop.class,
+ factory.createInstance("com.sun.star.frame.Desktop"));
+ factory = null;
+ try {
+ desktopTerminated = desktop.terminate();
+ } catch (DisposedException e) {}
+ // it appears that DisposedExceptions can already happen while
+ // receiving the response of the terminate call
+ desktop = null;
+ } else if (process != null) {
+ process.destroy();
+ }
+ int code = 0;
+ if (process != null) {
+ code = process.waitFor();
+ }
+ boolean outTerminated = outForward == null || outForward.terminated();
+ boolean errTerminated = errForward == null || errForward.terminated();
+ assertTrue(desktopTerminated);
+ assertEquals(0, code);
+ assertTrue(outTerminated);
+ assertTrue(errTerminated);
+ }
+
+ /** Obtain the service factory of the running OOo instance.
+ */
+ public XMultiServiceFactory getFactory() {
+ return factory;
+ }
+
+ //TODO: get rid of this hack for legacy qa/unoapi tests
+ public String getDescription() {
+ return description;
+ }
+
+ private static String getArgument(String name) {
+ return System.getProperty("org.openoffice.test.arg." + name);
+ }
+
+ private static Integer waitForProcess(Process process, final long millis)
+ throws InterruptedException
+ {
+ final Thread t1 = Thread.currentThread();
+ Thread t2 = new Thread("waitForProcess") {
+ public void run() {
+ try {
+ Thread.currentThread().sleep(millis);
+ } catch (InterruptedException e) {}
+ t1.interrupt();
+ }
+ };
+ boolean old = Thread.interrupted();
+ // clear interrupted status, get old status
+ t2.start();
+ int n = 0;
+ boolean done = false;
+ try {
+ n = process.waitFor();
+ done = true;
+ } catch (InterruptedException e) {}
+ t2.interrupt();
+ try {
+ t2.join();
+ } catch (InterruptedException e) {
+ t2.join();
+ }
+ Thread.interrupted(); // clear interrupted status
+ if (old) {
+ t1.interrupt(); // reset old status
+ }
+ return done ? new Integer(n) : null;
+ }
+
+ private static final class Forward extends Thread {
+ public Forward(InputStream in, PrintStream out) {
+ super("process output forwarder");
+ this.in = in;
+ this.out = out;
+ }
+
+ public void run() {
+ for (;;) {
+ byte[] buf = new byte[1024];
+ int n;
+ try {
+ n = in.read(buf);
+ } catch (IOException e) {
+ throw new RuntimeException("wrapping", e);
+ }
+ if (n == -1) {
+ break;
+ }
+ out.write(buf, 0, n);
+ }
+ done = true;
+ }
+
+ public boolean terminated() throws InterruptedException {
+ join();
+ return done;
+ }
+
+ private final InputStream in;
+ private final PrintStream out;
+ private boolean done = false;
+ }
+
+ private String description;
+ private Process process = null;
+ private Forward outForward = null;
+ private Forward errForward = null;
+ private XMultiServiceFactory factory = null;
+}
diff --git a/testshl2/workben/codegen/makefile.mk b/test/source/java/makefile.mk
index 24039e69a548..a541d532f158 100644
--- a/testshl2/workben/codegen/makefile.mk
+++ b/test/source/java/makefile.mk
@@ -1,7 +1,6 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,24 +21,29 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-
-PRJNAME=testshl2
-TARGET=codegen
-# this is removed at the moment because we need some enhancements
-# TESTDIR=TRUE
-
-ENABLE_EXCEPTIONS=TRUE
+#***********************************************************************/
-# --- Settings -----------------------------------------------------
+PRJ = ../..
+PRJNAME = test
+TARGET = java
-.INCLUDE : settings.mk
+.IF "$(OOO_JUNIT_JAR)" != ""
-#------------------------------- All object files -------------------------------
+PACKAGE = org/openoffice/test
+JAVAFILES = OfficeConnection.java
+JARFILES = juh.jar ridl.jar unoil.jar
+EXTRAJARFILES = $(OOO_JUNIT_JAR)
+JARTARGET = test.jar
+JARCLASSDIRS = $(PACKAGE)
+JARCLASSPATH = $(JARFILES)
+ # expect $(OOO_JUNIT_JAR) to be on CLASSPATH wherever test.jar is used (also,
+ # on Windows, $(OOO_JUNIT_JAR) could be an absolute pathname with drive letter
+ # like X:/path and some JVMs would refuse to load test.jar if its MANIFEST.MF
+ # Class-Path contained such a pathname that looks like an unknown URL with
+ # scheme X)
-# --- Targets ------------------------------------------------------
+.END
-.INCLUDE : target.mk
+.INCLUDE: settings.mk
+.INCLUDE: target.mk
diff --git a/testautomation/chart2/optional/includes/ch2_lvl1a.inc b/testautomation/chart2/optional/includes/ch2_lvl1a.inc
index 42ee8ff48bd1..5f72fd7e32f9 100644..100755
--- a/testautomation/chart2/optional/includes/ch2_lvl1a.inc
+++ b/testautomation/chart2/optional/includes/ch2_lvl1a.inc
@@ -174,7 +174,9 @@ testcase tChartShapes
' Call hToolbarSelect("Drawing", true)
' endif
- printlog " Insert a shape to the chart by <STRG-RETURN>"
+ printlog " Insert a shape to the chart by <STRG-RETURN>"
+ Kontext "DocumentChart"
+ DocumentChart.TypeKeys "<F6>",4
Kontext "DrawBar"
sleep (1)
DrawBar.typekeys "<TAB>",TRUE
diff --git a/testautomation/chart2/tools/ch_tools_select.inc b/testautomation/chart2/tools/ch_tools_select.inc
index 00c86ed8e12e..beeda0d3dcdd 100644..100755
--- a/testautomation/chart2/tools/ch_tools_select.inc
+++ b/testautomation/chart2/tools/ch_tools_select.inc
@@ -127,7 +127,7 @@ function fChartSelectElement ( iObjectPosition as INTEGER ) as boolean
fChartSelectElement = FALSE
try
Kontext "Toolbar"
- sleep (1)
+ sleep (2)
ChartElementSelector.Select (iObjectPosition)
fChartSelectElement = TRUE
catch
diff --git a/testautomation/dbaccess/optional/includes/ctrl_Several1.inc b/testautomation/dbaccess/optional/includes/ctrl_Several1.inc
index 71a581f52cdf..0d7b24cbc0f2 100644..100755
--- a/testautomation/dbaccess/optional/includes/ctrl_Several1.inc
+++ b/testautomation/dbaccess/optional/includes/ctrl_Several1.inc
@@ -586,7 +586,7 @@ testcase tComboBox
endcase
'--------------------------------------------------------------------------------------
-testcase tLabelField
+testcase tLabelField
'/// Open a new document,
printlog "Open a new document,"
diff --git a/testautomation/dbaccess/optional/includes/ctrl_Several2.inc b/testautomation/dbaccess/optional/includes/ctrl_Several2.inc
index 182be64e9ac8..4d49e459b231 100644..100755
--- a/testautomation/dbaccess/optional/includes/ctrl_Several2.inc
+++ b/testautomation/dbaccess/optional/includes/ctrl_Several2.inc
@@ -234,12 +234,9 @@ testcase tImageButton
printlog "set properties"
'to activate property: scale, following properties must be active: Graphics (with choosen path)
Kontext "TabGeneralControl"
- if gNetzInst = false then
- fsetControlProperty("ImageButton","Graphics", gOfficePath + ConvertPath("share/gallery/bullets/blkpearl.gif"))
- else
- fsetControlProperty("ImageButton","Graphics", gNetzOfficePath + ConvertPath("share/gallery/bullets/blkpearl.gif"))
- endif
- sleep(1)
+ fsetControlProperty("ImageButton","Graphics", gOfficePath + ConvertPath("share/gallery/bullets/blkpearl.gif"))
+
+ sleep(1)
TabGeneralControl.TypeKeys "<RETURN>" , true
fsetControlProperty("ImageControl","Scale","1") 'listbox content: no
'fsetControlProperty("ImageControl","Frame","4")
diff --git a/testautomation/dbaccess/optional/includes/db_Relations.inc b/testautomation/dbaccess/optional/includes/db_Relations.inc
index 3d10a132d43a..e04a1be4c6d6 100644..100755
--- a/testautomation/dbaccess/optional/includes/db_Relations.inc
+++ b/testautomation/dbaccess/optional/includes/db_Relations.inc
@@ -32,8 +32,10 @@
'\***********************************************************************
function tRelation( sFileName, sPWD, sRelTable1, sRelTable2 )
'/// create an 1:1 and 1:n relation between two test tables
- Dim i, j, ix as integer 'counter
- Dim iNoDS as integer 'number of data source in listbox
+ Dim i as integer 'counter
+ Dim j as integer 'counter
+ Dim ix as integer 'counter
+ Dim iNoDS as integer 'number of data source in listbox
Dim iNoTab as integer 'number of tables in grid
Dim DSOK as boolean 'datasource present check
@@ -206,8 +208,10 @@ end function
function tDoubleRelation( sFileName, sPWD, sRelTable1, sRelTable2, sRelTable3 )
'/// create an 1:1 relation, close and save relation dialog,
'/// reopen the dialog and add an 1:n relation with third test table
- Dim i, j, ix as integer 'counter
- Dim iNoDS as integer 'number of data source in listbox
+ Dim i as integer 'counter
+ Dim j as integer 'counter
+ Dim ix as integer 'counter
+ Dim iNoDS as integer 'number of data source in listbox
Dim iNoTab as integer 'number of tables in grid
Dim DSOK as boolean 'datasource present check
@@ -351,7 +355,7 @@ function tDoubleRelation( sFileName, sPWD, sRelTable1, sRelTable2, sRelTable3 )
if breltablefound <> 1 then 'needed table not found if variable <> 1
warnlog "proper table: " + sRelTable3 + " not found - test abort"
- call fCloseRealtionDesign
+ call fCloseRelationDesign
call fCloseDatabase
exit function
else
diff --git a/testautomation/dbaccess/optional/includes/frm_FormFilter.inc b/testautomation/dbaccess/optional/includes/frm_FormFilter.inc
index 7a73842c62eb..b8e3ccc2d896 100755
--- a/testautomation/dbaccess/optional/includes/frm_FormFilter.inc
+++ b/testautomation/dbaccess/optional/includes/frm_FormFilter.inc
@@ -205,7 +205,11 @@ testcase tFF_Navigator
elseif iSprache = 49 then
if FilterNavigator.getSelText <> "WIE '*value*'" then
warnlog "The text is not right in the filter navigator. It have to be WIE '*value*' but it is " + FilterNavigator.getSelText
- endif
+ endif
+ elseif iSprache = 50 then
+ if FilterNavigator.getSelText <> "LIKE '*value*'" then
+ warnlog "The text is not right in the filter navigator. It have to be LIKE '*value*' but it is " + FilterNavigator.getSelText
+ endif
elseif iSprache = 81 then
elseif iSprache = 82 then
diff --git a/testautomation/dbaccess/optional/includes/wiz_DatabaseWizard.inc b/testautomation/dbaccess/optional/includes/wiz_DatabaseWizard.inc
index eb8dd4a15c35..bd25224ba429 100755
--- a/testautomation/dbaccess/optional/includes/wiz_DatabaseWizard.inc
+++ b/testautomation/dbaccess/optional/includes/wiz_DatabaseWizard.inc
@@ -233,38 +233,7 @@ qaerrorlog "not yet implemented"
endcase
'-------------------------------------------------------------------------
testcase tAdabas
-
- qaerrorlog "not yet implemented"
- goto endsub
-
qaerrorlog "not yet implemented"
- goto endsub
-
- if gPlatform = "x86" then
- printlog "Adabas doesn't exists under x86."
- goto endsub
- elseif gOOO then
- printlog "Adabas doesn't exists under Openoffice.org."
- goto endsub
- end if
-
- dim aDatabaseProperties(6) as string
- aDatabaseProperties() = tools_dbtools_fgetAdabasDatabaseProperties()
-
- ' if and only if no properties are defined in the environment file the test is stopped
- if(aDatabaseProperties(1) = "no") then
- qaerrorlog "No database properties from Adabas defiened. The Test is stopped here."
- goto endsub
- endif
-
- call fCreateAdabasDatasource( sFileName, aDatabaseProperties(2), aDatabaseProperties(3), aDatabaseProperties(4))
- call fOpendatabase(gOfficePath + "user/work/tt_adabas.odb","testuser")
-
- Kontext "ContainerView"
- ViewTables
-
- call fCloseDatabase(true)
-
endcase
'-------------------------------------------------------------------------
testcase tdBase
diff --git a/testautomation/dbaccess/required/includes/MainApp.inc b/testautomation/dbaccess/required/includes/MainApp.inc
index fa3c1a4b0a14..4d5855ac9bba 100755
--- a/testautomation/dbaccess/required/includes/MainApp.inc
+++ b/testautomation/dbaccess/required/includes/MainApp.inc
@@ -608,7 +608,10 @@ endcase
'-------------------------------------------------------------------------
function getMenuItemCount as Integer
'use this function becasue this doesn't count the pick list
- Dim i, j, Ende, nID as Integer
+ Dim i as Integer
+ Dim j as Integer
+ Dim Ende as Integer
+ Dim nID as Integer
Sleep 2
j=0
for i=1 to MenuGetItemCount
diff --git a/testautomation/dbaccess/required/includes/Query.inc b/testautomation/dbaccess/required/includes/Query.inc
index d981fd79656e..f6fa45acbdd7 100644..100755
--- a/testautomation/dbaccess/required/includes/Query.inc
+++ b/testautomation/dbaccess/required/includes/Query.inc
@@ -156,7 +156,7 @@ testcase tSwitchDesign
sTableName = TableName.GetSelText
printlog "- Add 'biblio' table to query design"
if sTableName <> "biblio" then
- warnlog "It should be the 'biblio'-database table but it is the '" & SelEntry & "' database table?!"
+ warnlog "It should be the 'biblio'-database table but it is the '" & sTableName & "' database table?!"
goto endsub
else
AddTable.Click
@@ -909,7 +909,10 @@ endcase
'-------------------------------------------------------------------------
function getMenuItemCount as Integer
'use this function becasue this doesn't count the pick list
- Dim i, j, Ende, nID as Integer
+ Dim i as Integer
+ Dim j as Integer
+ Dim Ende as Integer
+ Dim nID as Integer
Sleep 2
j=0
for i=1 to MenuGetItemCount
diff --git a/testautomation/dbaccess/required/includes/Table.inc b/testautomation/dbaccess/required/includes/Table.inc
index 93c9341d5f6a..f7a00c22fcd5 100644..100755
--- a/testautomation/dbaccess/required/includes/Table.inc
+++ b/testautomation/dbaccess/required/includes/Table.inc
@@ -588,7 +588,10 @@ endcase
'-------------------------------------------------------------------------
function getMenuItemCount as Integer
'use this function becasue this doesn't count the pick list
- Dim i, j, Ende, nID as Integer
+ Dim i as Integer
+ Dim j as Integer
+ Dim Ende as Integer
+ Dim nID as Integer
Sleep 2
j=0
for i=1 to MenuGetItemCount
diff --git a/testautomation/dbaccess/required/includes/TableDesign.inc b/testautomation/dbaccess/required/includes/TableDesign.inc
index 42d86ccd0c5f..9204d34de1b9 100644..100755
--- a/testautomation/dbaccess/required/includes/TableDesign.inc
+++ b/testautomation/dbaccess/required/includes/TableDesign.inc
@@ -467,7 +467,10 @@ endcase
'-------------------------------------------------------------------------
function getMenuItemCount as Integer
'use this function becasue this doesn't count the pick list
- Dim i, j, Ende, nID as Integer
+ Dim i as Integer
+ Dim j as Integer
+ Dim Ende as Integer
+ Dim nID as Integer
Sleep 2
j=0
for i=1 to MenuGetItemCount
diff --git a/testautomation/dbaccess/tools/formtools.inc b/testautomation/dbaccess/tools/formtools.inc
index 058fa5cb52bd..90d29b647384 100644..100755
--- a/testautomation/dbaccess/tools/formtools.inc
+++ b/testautomation/dbaccess/tools/formtools.inc
@@ -118,7 +118,7 @@ function fSaveForm( sFormName as string, optional bCloseForm as boolean )
endif
fSaveForm = true
else
- fSaveFrom = false
+ fSaveForm = false
end if
if ( IsMissing( bCloseForm ) ) then
diff --git a/testautomation/dbaccess/tools/reporttools.inc b/testautomation/dbaccess/tools/reporttools.inc
index 32a4926edee0..89dd00b504c6 100644..100755
--- a/testautomation/dbaccess/tools/reporttools.inc
+++ b/testautomation/dbaccess/tools/reporttools.inc
@@ -138,23 +138,23 @@ function fSaveReport( sReportName as string, optional bCloseReport as boolean )
hMenuSelectNr(6) ' the Save
Kontext "ReportSaveDialog"
- if ReportSaveDialog.exists(3) then
- ReportName.setText(sReportName)
+ if FormSaveDialog.exists(3) then
+ FormName.setText(sReportName)
SaveBtn.Click
'click yes in the overwrite messages box
Kontext "MessageBox"
if MessageBox.exists(1) then
MessageBox.Yes
endif
- fSaveReport = true
+ fSaveReport = true
else
- fSaveFrom = false
+ fSaveReport = false
end if
if ( IsMissing( bCloseReport ) ) then
' nothing
else
- call fCloseReport()
+ call fCloseReportDesign()
end if
end function
@@ -167,7 +167,7 @@ function fOpenReport(sReportName as string)
if ( fFindReport(sReportName) = true ) then
printlog "Report found -> open"
Kontext "ContainerView"
- OpenReport ' uno-Slot .uno:DB/Open
+ OpenForm ' uno-Slot .uno:DB/Open
sleep(1)
fOpenReport = true
else
diff --git a/testautomation/dbaccess/tools/tabletools.inc b/testautomation/dbaccess/tools/tabletools.inc
index 44887eb78c0f..fb354dcd4a75 100644..100755
--- a/testautomation/dbaccess/tools/tabletools.inc
+++ b/testautomation/dbaccess/tools/tabletools.inc
@@ -127,7 +127,7 @@ function tCompareMatrixValues(sDSName as string, sRefFileUrl as string, cTable_o
endif
else
if cTable_or_Query = "t" then warnlog "Table: " + sTableName + " not found - Test aborted"
- if cTable_or_Query = "q" then warnlog "Table: " + sQueryName + " not found - Test aborted"
+ if cTable_or_Query = "q" then warnlog "Query: " + sTableName + " not found - Test aborted"
endif
printlog "*** End Testcase"
sleep 1
@@ -203,7 +203,8 @@ function fCreateRefFile(sDSName as string, cTable_or_Query as string, sTableName
'/// reading out values from table, create a reference table and input values in
printlog "start reading out values from table and writing in ref table"
iNumber = Freefile
- dim i,j as integer 'counter
+ dim i as integer 'counter
+ dim j as integer 'counter
Open sRefFileUrl for Output as iNumber
for i = 1 to iRowAmount
for j = 1 to iColAmount
@@ -708,10 +709,10 @@ function fFindTableInBeamer(sDSName1,sTableName1)
next i
if (bfindTable = false) then
- warnlog "Datasource " + sDSName + " not found!"
+ warnlog "Datasource " + sDSName1 + " not found!"
exit function
else
- printlog "Datasource " + sDSName + " found!"
+ printlog "Datasource " + sDSName1 + " found!"
' I set the bfindTable flag again back to false
' for the next test of the table
bfindTable = false
diff --git a/testautomation/extensions/optional/e_issues.bas b/testautomation/extensions/optional/e_issues.bas
new file mode 100755
index 000000000000..549ad69b1a2e
--- /dev/null
+++ b/testautomation/extensions/optional/e_issues.bas
@@ -0,0 +1,55 @@
+'encoding UTF-8 Do not remove or change this line!
+'**************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : Extension publisher string
+'*
+'\******************************************************************************
+
+sub main
+
+ use "extensions\optional\includes\issue110083.inc"
+
+ call hStatusIn( "extensions" , "e_issues.bas" )
+ call tExtensionIssue110083()
+ call hStatusOut()
+
+end sub
+
+'*******************************************************************************
+
+sub LoadIncludeFiles
+
+ use "global\system\includes\gvariabl.inc"
+ use "global\system\includes\master.inc"
+ use "global\tools\includes\optional\t_extension_manager_tools.inc"
+ gApplication = "WRITER"
+ call GetUseFiles()
+
+end sub
+
diff --git a/testautomation/extensions/optional/e_taskpane.bas b/testautomation/extensions/optional/e_taskpane.bas
new file mode 100644
index 000000000000..b6d29d22283d
--- /dev/null
+++ b/testautomation/extensions/optional/e_taskpane.bas
@@ -0,0 +1,49 @@
+'encoding UTF-8 Do not remove or change this line!
+'**************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/************************************************************************
+'*
+'* owner :
+'*
+'* short description :
+'*
+'\***********************************************************************
+
+sub main
+
+ use "extensions/optional/includes/e_taskpane.inc"
+ call tTaskPane
+
+end sub
+
+sub LoadIncludeFiles
+
+ use "global\system\includes\gvariabl.inc"
+ use "global\system\includes\master.inc"
+ use "global\tools\includes\optional\t_extension_manager_tools.inc"
+ gApplication = "CALC"
+ call GetUseFiles()
+
+end sub \ No newline at end of file
diff --git a/testautomation/extensions/optional/includes/e_taskpane.inc b/testautomation/extensions/optional/includes/e_taskpane.inc
new file mode 100644
index 000000000000..6d1794e68456
--- /dev/null
+++ b/testautomation/extensions/optional/includes/e_taskpane.inc
@@ -0,0 +1,74 @@
+'encoding UTF-8 Do not remove or change this line!
+'**************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/************************************************************************
+'*
+'* owner :
+'*
+'* short description :
+'*
+'\***********************************************************************
+testcase tTaskPane
+
+ Dim sExtensionPath as String
+ Dim iStatus as integer
+
+ sExtensionPath = gTesttoolPath + "extensions/optional/input/extensions/TaskPaneComponent/TaskPaneComponent.oxt"
+
+ iStatus = hExtensionAddGUI( sExtensionPath, "InstallForUser, NoLicense" )
+ if(iStatus <= 0 ) then
+ warnlog "extension could not installed. ErrorCode is " + iStatus
+ goto endsub
+ endif
+
+ call hNewDocument
+
+ kontext "DocumentCalc"
+
+ DocumentCalc.useMenu
+
+ hMenuSelectNr(3)
+ if(hMenuItemIsChecked(11)) then
+ ' do nothing. The pane is displayed
+ else
+ hMenuSelectNr(11)
+ endif
+
+ kontext "MSC_Special_Dialog"
+ if ( MSC_Special_Dialog.exists(1) ) then
+ printlog "task pane exists"
+ else
+ warnlog "task pane does not exists"
+ endif
+
+ call hCloseDocument
+
+ iStatus = hExtensionRemoveGUI("TaskPaneComponent.oxt")
+ if(iStatus <> 0 ) then
+ warnlog "extension could not deinstalled. ErrorCode is " + iStatus
+ goto endsub
+ endif
+
+endcase
diff --git a/testautomation/extensions/optional/includes/issue110083.inc b/testautomation/extensions/optional/includes/issue110083.inc
new file mode 100755
index 000000000000..8940f7f8274c
--- /dev/null
+++ b/testautomation/extensions/optional/includes/issue110083.inc
@@ -0,0 +1,79 @@
+'encoding UTF-8 Do not remove or change this line!
+'*******************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : CWS sb112 fixes a problem with configuration schemas
+'*
+'\******************************************************************************
+
+testcase tExtensionIssue110083()
+
+ printlog( "Configuration/-schema .xcu/.xcs-files which might trigger exceptions from unopkg/Extension Manager" )
+
+ const NUMBER_OF_TEST_EXTENSIONS = 2
+
+ dim cExtensionNames( NUMBER_OF_TEST_EXTENSIONS ) as string
+ cExtensionNames( 1 ) = "LoggingOptions.xcs"
+ cExtensionNames( 2 ) = "Logging.xcu"
+
+ dim cErrorIdentifier( NUMBER_OF_TEST_EXTENSIONS ) as string
+ cErrorIdentifier( 1 ) = "no component element"
+ cErrorIdentifier( 2 ) = "no component element"
+
+ dim cExtensionPath as string
+ cExtensionPath = gTesttoolPath & "extensions/optional/input/issues/"
+
+ dim cExtension as string
+
+ dim iCurrentExtension as integer
+
+
+ for iCurrentExtension = 1 to NUMBER_OF_TEST_EXTENSIONS
+
+ cExtension = convertpath( cExtensionPath & cExtensionNames( iCurrentExtension ) )
+ hExtensionAddGUI( cExtension, "" )
+
+ kontext "Active"
+ if ( Active.exists() ) then
+ if ( instr( Active.getText, cErrorIdentifier( iCurrentExtension ) ) > 0 ) then
+ warnlog( "#i110083# - Error installing .xcs/.xcu-file: " & cExtensionNames( iCurrentExtension ) )
+ Active.ok()
+
+ kontext "PackageManager"
+ PackageManager.close()
+ else
+ warnlog( "Unexpected messagebox displayed. It cannot be handled" )
+ endif
+ else
+ hExtensionRemoveGUI( cExtensionNames( iCurrentExtension ) )
+ endif
+
+ next iCurrentExtension
+
+endcase
+
diff --git a/testautomation/extensions/optional/includes/platforms.inc b/testautomation/extensions/optional/includes/platforms.inc
index bb8bea80b12f..4f96701afd20 100644..100755
--- a/testautomation/extensions/optional/includes/platforms.inc
+++ b/testautomation/extensions/optional/includes/platforms.inc
@@ -78,7 +78,7 @@ testcase tExtensionPlatforms
printlog( "Current extension: " & cCurrentExtensionFile )
iStatus = hExtensionAddGUI( cCurrentExtensionPath, "InstallForUser, NoLicense, NoUpdate, Verbose" )
- if ( iStatus >= 0 ) then
+ if ( iStatus = -7 or iStatus >= 0 ) then
kontext "Active"
if ( Active.exists( 2 ) ) then
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/build.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/build.xml
new file mode 100755
index 000000000000..4428a95f551b
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/build.xml
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- You may freely edit this file. See commented blocks below for -->
+<!-- some examples of how to customize the build. -->
+<!-- (If you delete it and reopen the project it will be recreated.) -->
+<project name="TaskPaneComponent" default="default" basedir=".">
+ <description>Builds, tests, and runs the project extension project.</description>
+ <import file="nbproject/build-uno-impl.xml"/>
+ <!--
+
+ There exist several targets which are by default empty and which can be
+ used for execution of your tasks. These targets are usually executed
+ before and after some main targets. They are:
+
+ -pre-init: called before initialization of project properties
+ -post-init: called after initialization of project properties
+ -pre-compile: called before javac compilation
+ -post-compile: called after javac compilation
+ -pre-compile-single: called before javac compilation of single file
+ -post-compile-single: called after javac compilation of single file
+ -pre-compile-test: called before javac compilation of JUnit tests
+ -post-compile-test: called after javac compilation of JUnit tests
+ -pre-compile-test-single: called before javac compilation of single JUnit test
+ -post-compile-test-single: called after javac compilation of single JUunit test
+ -pre-jar: called before JAR building
+ -post-jar: called after JAR building
+ -pre-uno-package: called before OXT creation
+ -post-uno-package: called after OXT creation
+ -post-clean: called after cleaning build products
+
+ (Targets beginning with '-' are not intended to be called on their own.)
+
+ Example of inserting an obfuscator after compilation could look like this:
+
+ <target name="-post-compile">
+ <obfuscate>
+ <fileset dir="${build.classes.dir}"/>
+ </obfuscate>
+ </target>
+
+ For list of available properties check the imported
+ nbproject/build-impl.xml file.
+
+
+ Another way to customize the build is by overriding existing main targets.
+ The targets of interest are:
+
+ -init-macrodef-javac: defines macro for javac compilation
+ -init-macrodef-junit: defines macro for junit execution
+ -init-macrodef-debug: defines macro for class debugging
+ -init-macrodef-java: defines macro for class execution
+ -do-jar-with-manifest: JAR building (if you are using a manifest)
+ -do-jar-without-manifest: JAR building (if you are not using a manifest)
+ run: execution of project
+ -javadoc-build: Javadoc generation
+ test-report: JUnit report generation
+
+ An example of overriding the target for project execution could look like this:
+
+ <target name="run" depends="TypeBrowser2-impl.jar">
+ <exec dir="bin" executable="launcher.exe">
+ <arg file="${dist.jar}"/>
+ </exec>
+ </target>
+
+ Notice that the overridden target depends on the jar target and not only on
+ the compile target as the regular run target does. Again, for a list of available
+ properties which you can use, check the target you are overriding in the
+ nbproject/build-impl.xml file.
+
+ -->
+
+</project>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-impl.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-impl.xml
new file mode 100755
index 000000000000..f01ad79df06e
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-impl.xml
@@ -0,0 +1,794 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+*** GENERATED FROM project.xml - DO NOT EDIT ***
+*** EDIT ../build.xml INSTEAD ***
+
+For the purpose of easier reading the script
+is divided into following sections:
+
+ - initialization
+ - compilation
+ - jar
+ - execution
+ - debugging
+ - javadoc
+ - junit compilation
+ - junit execution
+ - junit debugging
+ - applet
+ - cleanup
+
+ -->
+<project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="TaskPaneComponent-impl">
+ <fail message="Please build using Ant 1.7.1 or higher.">
+ <condition>
+ <not>
+ <antversion atleast="1.7.1"/>
+ </not>
+ </condition>
+ </fail>
+ <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>
+ <!--
+ ======================
+ INITIALIZATION SECTION
+ ======================
+ -->
+ <target name="-pre-init">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="-pre-init" name="-init-private">
+ <property file="nbproject/private/config.properties"/>
+ <property file="nbproject/private/configs/${config}.properties"/>
+ <property file="nbproject/private/private.properties"/>
+ </target>
+ <target depends="-pre-init,-init-private" name="-init-user">
+ <property file="${user.properties.file}"/>
+ <!-- The two properties below are usually overridden -->
+ <!-- by the active platform. Just a fallback. -->
+ <property name="default.javac.source" value="1.4"/>
+ <property name="default.javac.target" value="1.4"/>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user" name="-init-project">
+ <property file="nbproject/configs/${config}.properties"/>
+ <property file="nbproject/project.properties"/>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
+ <available file="${manifest.file}" property="manifest.available"/>
+ <condition property="main.class.available">
+ <and>
+ <isset property="main.class"/>
+ <not>
+ <equals arg1="${main.class}" arg2="" trim="true"/>
+ </not>
+ </and>
+ </condition>
+ <condition property="manifest.available+main.class">
+ <and>
+ <isset property="manifest.available"/>
+ <isset property="main.class.available"/>
+ </and>
+ </condition>
+ <condition property="do.mkdist">
+ <and>
+ <isset property="libs.CopyLibs.classpath"/>
+ <not>
+ <istrue value="${mkdist.disabled}"/>
+ </not>
+ </and>
+ </condition>
+ <condition property="manifest.available+main.class+mkdist.available">
+ <and>
+ <istrue value="${manifest.available+main.class}"/>
+ <isset property="do.mkdist"/>
+ </and>
+ </condition>
+ <condition property="manifest.available+mkdist.available">
+ <and>
+ <istrue value="${manifest.available}"/>
+ <isset property="do.mkdist"/>
+ </and>
+ </condition>
+ <condition property="manifest.available-mkdist.available">
+ <or>
+ <istrue value="${manifest.available}"/>
+ <isset property="do.mkdist"/>
+ </or>
+ </condition>
+ <condition property="manifest.available+main.class-mkdist.available">
+ <or>
+ <istrue value="${manifest.available+main.class}"/>
+ <isset property="do.mkdist"/>
+ </or>
+ </condition>
+ <condition property="have.tests">
+ <or/>
+ </condition>
+ <condition property="have.sources">
+ <or>
+ <available file="${src.dir}"/>
+ </or>
+ </condition>
+ <condition property="netbeans.home+have.tests">
+ <and>
+ <isset property="netbeans.home"/>
+ <isset property="have.tests"/>
+ </and>
+ </condition>
+ <condition property="no.javadoc.preview">
+ <and>
+ <isset property="javadoc.preview"/>
+ <isfalse value="${javadoc.preview}"/>
+ </and>
+ </condition>
+ <property name="run.jvmargs" value=""/>
+ <property name="javac.compilerargs" value=""/>
+ <property name="work.dir" value="${basedir}"/>
+ <condition property="no.deps">
+ <and>
+ <istrue value="${no.dependencies}"/>
+ </and>
+ </condition>
+ <property name="javac.debug" value="true"/>
+ <property name="javadoc.preview" value="true"/>
+ <property name="application.args" value=""/>
+ <property name="source.encoding" value="${file.encoding}"/>
+ <property name="runtime.encoding" value="${source.encoding}"/>
+ <condition property="javadoc.encoding.used" value="${javadoc.encoding}">
+ <and>
+ <isset property="javadoc.encoding"/>
+ <not>
+ <equals arg1="${javadoc.encoding}" arg2=""/>
+ </not>
+ </and>
+ </condition>
+ <property name="javadoc.encoding.used" value="${source.encoding}"/>
+ <property name="includes" value="**"/>
+ <property name="excludes" value=""/>
+ <property name="do.depend" value="false"/>
+ <condition property="do.depend.true">
+ <istrue value="${do.depend}"/>
+ </condition>
+ <path id="endorsed.classpath.path" path="${endorsed.classpath}"/>
+ <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">
+ <length length="0" string="${endorsed.classpath}" when="greater"/>
+ </condition>
+ <property name="javac.fork" value="false"/>
+ </target>
+ <target name="-post-init">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
+ <fail unless="src.dir">Must set src.dir</fail>
+ <fail unless="build.dir">Must set build.dir</fail>
+ <fail unless="dist.dir">Must set dist.dir</fail>
+ <fail unless="build.classes.dir">Must set build.classes.dir</fail>
+ <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
+ <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
+ <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
+ <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
+ <fail unless="dist.jar">Must set dist.jar</fail>
+ </target>
+ <target name="-init-macrodef-property">
+ <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute name="name"/>
+ <attribute name="value"/>
+ <sequential>
+ <property name="@{name}" value="${@{value}}"/>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-javac">
+ <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${src.dir}" name="srcdir"/>
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <attribute default="${javac.classpath}" name="classpath"/>
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="${javac.debug}" name="debug"/>
+ <attribute default="${empty.dir}" name="sourcepath"/>
+ <attribute default="${empty.dir}" name="gensrcdir"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property location="${build.dir}/empty" name="empty.dir"/>
+ <mkdir dir="${empty.dir}"/>
+ <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+ <src>
+ <dirset dir="@{gensrcdir}" erroronmissingdir="false">
+ <include name="*"/>
+ </dirset>
+ </src>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <compilerarg line="${javac.compilerargs}"/>
+ <customize/>
+ </javac>
+ </sequential>
+ </macrodef>
+ <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${src.dir}" name="srcdir"/>
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <attribute default="${javac.classpath}" name="classpath"/>
+ <sequential>
+ <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ </depend>
+ </sequential>
+ </macrodef>
+ <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <sequential>
+ <fail unless="javac.includes">Must set javac.includes</fail>
+ <pathconvert pathsep="," property="javac.includes.binary">
+ <path>
+ <filelist dir="@{destdir}" files="${javac.includes}"/>
+ </path>
+ <globmapper from="*.java" to="*.class"/>
+ </pathconvert>
+ <delete>
+ <files includes="${javac.includes.binary}"/>
+ </delete>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-junit">
+ <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <sequential>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}">
+ <batchtest todir="${build.test.results.dir}"/>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-debug-args" name="-init-macrodef-nbjpda">
+ <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${main.class}" name="name"/>
+ <attribute default="${debug.classpath}" name="classpath"/>
+ <attribute default="" name="stopclassname"/>
+ <sequential>
+ <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="${debug-transport}">
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ </nbjpdastart>
+ </sequential>
+ </macrodef>
+ <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${build.classes.dir}" name="dir"/>
+ <sequential>
+ <nbjpdareload>
+ <fileset dir="@{dir}" includes="${fix.classes}">
+ <include name="${fix.includes}*.class"/>
+ </fileset>
+ </nbjpdareload>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-debug-args">
+ <property name="version-output" value="java version &quot;${ant.java.version}"/>
+ <condition property="have-jdk-older-than-1.4">
+ <or>
+ <contains string="${version-output}" substring="java version &quot;1.0"/>
+ <contains string="${version-output}" substring="java version &quot;1.1"/>
+ <contains string="${version-output}" substring="java version &quot;1.2"/>
+ <contains string="${version-output}" substring="java version &quot;1.3"/>
+ </or>
+ </condition>
+ <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
+ <istrue value="${have-jdk-older-than-1.4}"/>
+ </condition>
+ <condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem">
+ <os family="windows"/>
+ </condition>
+ <condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}">
+ <isset property="debug.transport"/>
+ </condition>
+ </target>
+ <target depends="-init-debug-args" name="-init-macrodef-debug">
+ <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="classname"/>
+ <attribute default="${debug.classpath}" name="classpath"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <java classname="@{classname}" dir="${work.dir}" fork="true">
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
+ <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="run-sys-prop."/>
+ <mapper from="run-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <customize/>
+ </java>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-java">
+ <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${main.class}" name="classname"/>
+ <attribute default="${run.classpath}" name="classpath"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <java classname="@{classname}" dir="${work.dir}" fork="true">
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
+ <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="run-sys-prop."/>
+ <mapper from="run-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <customize/>
+ </java>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-presetdef-jar">
+ <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <jar compress="${jar.compress}" jarfile="${dist.jar}">
+ <j2seproject1:fileset dir="${build.classes.dir}"/>
+ </jar>
+ </presetdef>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>
+ <!--
+ ===================
+ COMPILATION SECTION
+ ===================
+ -->
+ <target name="-deps-jar-init" unless="built-jar.properties">
+ <property location="${build.dir}/built-jar.properties" name="built-jar.properties"/>
+ <delete file="${built-jar.properties}" quiet="true"/>
+ </target>
+ <target if="already.built.jar.${basedir}" name="-warn-already-built-jar">
+ <echo level="warn" message="Cycle detected: TaskPaneComponent was already built"/>
+ </target>
+ <target depends="init,-deps-jar-init" name="deps-jar" unless="no.deps">
+ <mkdir dir="${build.dir}"/>
+ <touch file="${built-jar.properties}" verbose="false"/>
+ <property file="${built-jar.properties}" prefix="already.built.jar."/>
+ <antcall target="-warn-already-built-jar"/>
+ <propertyfile file="${built-jar.properties}">
+ <entry key="${basedir}" value=""/>
+ </propertyfile>
+ </target>
+ <target depends="init,-check-automatic-build,-clean-after-automatic-build" name="-verify-automatic-build"/>
+ <target depends="init" name="-check-automatic-build">
+ <available file="${build.classes.dir}/.netbeans_automatic_build" property="netbeans.automatic.build"/>
+ </target>
+ <target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build">
+ <antcall target="clean"/>
+ </target>
+ <target depends="init,deps-jar" name="-pre-pre-compile">
+ <mkdir dir="${build.classes.dir}"/>
+ </target>
+ <target name="-pre-compile">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target if="do.depend.true" name="-compile-depend">
+ <pathconvert property="build.generated.subdirs">
+ <dirset dir="${build.generated.sources.dir}" erroronmissingdir="false">
+ <include name="*"/>
+ </dirset>
+ </pathconvert>
+ <j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/>
+ </target>
+ <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
+ <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>
+ <copy todir="${build.classes.dir}">
+ <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+ </copy>
+ </target>
+ <target name="-post-compile">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
+ <target name="-pre-compile-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
+ <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
+ <j2seproject3:force-recompile/>
+ <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/>
+ </target>
+ <target name="-post-compile-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
+ <!--
+ ====================
+ JAR BUILDING SECTION
+ ====================
+ -->
+ <target depends="init" name="-pre-pre-jar">
+ <dirname file="${dist.jar}" property="dist.jar.dir"/>
+ <mkdir dir="${dist.jar.dir}"/>
+ </target>
+ <target name="-pre-jar">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available-mkdist.available">
+ <j2seproject1:jar/>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class-mkdist.available">
+ <j2seproject1:jar manifest="${manifest.file}"/>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available">
+ <j2seproject1:jar manifest="${manifest.file}">
+ <j2seproject1:manifest>
+ <j2seproject1:attribute name="Main-Class" value="${main.class}"/>
+ </j2seproject1:manifest>
+ </j2seproject1:jar>
+ <echo>To run this application from the command line without Ant, try:</echo>
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <property location="${dist.jar}" name="dist.jar.resolved"/>
+ <pathconvert property="run.classpath.with.dist.jar">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
+ </pathconvert>
+ <echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Main-Class" value="${main.class}"/>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ <echo>To run this application from the command line without Ant, try:</echo>
+ <property location="${dist.jar}" name="dist.jar.resolved"/>
+ <echo>java -jar "${dist.jar.resolved}"</echo>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+mkdist.available" name="-do-jar-with-libraries-without-mainclass" unless="main.class.available">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.mkdist" name="-do-jar-with-libraries-without-manifest" unless="manifest.available">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ </target>
+ <target name="-post-jar">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-jar-with-libraries-without-mainclass,-do-jar-with-libraries-without-manifest,-post-jar" description="Build JAR." name="jar"/>
+ <!--
+ =================
+ EXECUTION SECTION
+ =================
+ -->
+ <target depends="init,compile" description="Run a main class." name="run">
+ <j2seproject1:java>
+ <customize>
+ <arg line="${application.args}"/>
+ </customize>
+ </j2seproject1:java>
+ </target>
+ <target name="-do-not-recompile">
+ <property name="javac.includes.binary" value=""/>
+ </target>
+ <target depends="init,compile-single" name="run-single">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <j2seproject1:java classname="${run.class}"/>
+ </target>
+ <target depends="init,compile-test-single" name="run-test-with-main">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <j2seproject1:java classname="${run.class}" classpath="${run.test.classpath}"/>
+ </target>
+ <!--
+ =================
+ DEBUGGING SECTION
+ =================
+ -->
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger">
+ <j2seproject1:nbjpdastart name="${debug.class}"/>
+ </target>
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test">
+ <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/>
+ </target>
+ <target depends="init,compile" name="-debug-start-debuggee">
+ <j2seproject3:debug>
+ <customize>
+ <arg line="${application.args}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">
+ <j2seproject1:nbjpdastart stopclassname="${main.class}"/>
+ </target>
+ <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>
+ <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
+ <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
+ <j2seproject3:debug classname="${debug.class}"/>
+ </target>
+ <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>
+ <target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test">
+ <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
+ <j2seproject3:debug classname="${debug.class}" classpath="${debug.test.classpath}"/>
+ </target>
+ <target depends="init,compile-test-single,-debug-start-debugger-main-test,-debug-start-debuggee-main-test" if="netbeans.home" name="debug-test-with-main"/>
+ <target depends="init" name="-pre-debug-fix">
+ <fail unless="fix.includes">Must set fix.includes</fail>
+ <property name="javac.includes" value="${fix.includes}.java"/>
+ </target>
+ <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
+ <j2seproject1:nbjpdareload/>
+ </target>
+ <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
+ <!--
+ ===============
+ JAVADOC SECTION
+ ===============
+ -->
+ <target depends="init" name="-javadoc-build">
+ <mkdir dir="${dist.javadoc.dir}"/>
+ <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
+ <classpath>
+ <path path="${javac.classpath}"/>
+ </classpath>
+ <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
+ <filename name="**/*.java"/>
+ </fileset>
+ <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
+ <include name="**/*.java"/>
+ </fileset>
+ </javadoc>
+ </target>
+ <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">
+ <nbbrowse file="${dist.javadoc.dir}/index.html"/>
+ </target>
+ <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
+ <!--
+ =========================
+ JUNIT COMPILATION SECTION
+ =========================
+ -->
+ <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
+ <mkdir dir="${build.test.classes.dir}"/>
+ </target>
+ <target name="-pre-compile-test">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target if="do.depend.true" name="-compile-test-depend">
+ <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir=""/>
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
+ <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir=""/>
+ <copy todir="${build.test.classes.dir}"/>
+ </target>
+ <target name="-post-compile-test">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
+ <target name="-pre-compile-test-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
+ <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
+ <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>
+ <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="" srcdir=""/>
+ <copy todir="${build.test.classes.dir}"/>
+ </target>
+ <target name="-post-compile-test-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
+ <!--
+ =======================
+ JUNIT EXECUTION SECTION
+ =======================
+ -->
+ <target depends="init" if="have.tests" name="-pre-test-run">
+ <mkdir dir="${build.test.results.dir}"/>
+ </target>
+ <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
+ <j2seproject3:junit testincludes="**/*Test.java"/>
+ </target>
+ <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init" if="have.tests" name="test-report"/>
+ <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
+ <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
+ <target depends="init" if="have.tests" name="-pre-test-run-single">
+ <mkdir dir="${build.test.results.dir}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
+ <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
+ <j2seproject3:junit excludes="" includes="${test.includes}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
+ <!--
+ =======================
+ JUNIT DEBUGGING SECTION
+ =======================
+ -->
+ <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
+ <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
+ <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
+ <delete file="${test.report.file}"/>
+ <mkdir dir="${build.test.results.dir}"/>
+ <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
+ <customize>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <arg value="${test.class}"/>
+ <arg value="showoutput=true"/>
+ <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
+ <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
+ <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
+ </target>
+ <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
+ <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
+ <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
+ </target>
+ <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
+ <!--
+ =========================
+ APPLET EXECUTION SECTION
+ =========================
+ -->
+ <target depends="init,compile-single" name="run-applet">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <j2seproject1:java classname="sun.applet.AppletViewer">
+ <customize>
+ <arg value="${applet.url}"/>
+ </customize>
+ </j2seproject1:java>
+ </target>
+ <!--
+ =========================
+ APPLET DEBUGGING SECTION
+ =========================
+ -->
+ <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <j2seproject3:debug classname="sun.applet.AppletViewer">
+ <customize>
+ <arg value="${applet.url}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>
+ <!--
+ ===============
+ CLEANUP SECTION
+ ===============
+ -->
+ <target name="-deps-clean-init" unless="built-clean.properties">
+ <property location="${build.dir}/built-clean.properties" name="built-clean.properties"/>
+ <delete file="${built-clean.properties}" quiet="true"/>
+ </target>
+ <target if="already.built.clean.${basedir}" name="-warn-already-built-clean">
+ <echo level="warn" message="Cycle detected: TaskPaneComponent was already built"/>
+ </target>
+ <target depends="init,-deps-clean-init" name="deps-clean" unless="no.deps">
+ <mkdir dir="${build.dir}"/>
+ <touch file="${built-clean.properties}" verbose="false"/>
+ <property file="${built-clean.properties}" prefix="already.built.clean."/>
+ <antcall target="-warn-already-built-clean"/>
+ <propertyfile file="${built-clean.properties}">
+ <entry key="${basedir}" value=""/>
+ </propertyfile>
+ </target>
+ <target depends="init" name="-do-clean">
+ <delete dir="${build.dir}"/>
+ <delete dir="${dist.dir}" followsymlinks="false" includeemptydirs="true"/>
+ </target>
+ <target name="-post-clean">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>
+ <target name="-check-call-dep">
+ <property file="${call.built.properties}" prefix="already.built."/>
+ <condition property="should.call.dep">
+ <not>
+ <isset property="already.built.${call.subproject}"/>
+ </not>
+ </condition>
+ </target>
+ <target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">
+ <ant antfile="${call.script}" inheritall="false" target="${call.target}">
+ <propertyset>
+ <propertyref prefix="transfer."/>
+ <mapper from="transfer.*" to="*" type="glob"/>
+ </propertyset>
+ </ant>
+ </target>
+</project>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-uno-impl.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-uno-impl.xml
new file mode 100755
index 000000000000..25b3f25f86c7
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/build-uno-impl.xml
@@ -0,0 +1,462 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+*** AUTOMATICALLY GENERATED - DO NOT EDIT ***
+*** EDIT ../build.xml INSTEAD ***
+-->
+<project name="TaskPaneComponentuno-impl" default="netbeans" basedir="..">
+ <description>Builds, tests, and runs an UNO project.</description>
+
+ <import file="build-impl.xml"/>
+
+ <!-- ================================================================================== -->
+
+ <target name="-uno-project-init" depends="-do-init">
+ <property file="nbproject/project-uno.properties"/>
+ <property name="build.uno.version" value="2.0.6"/>
+
+ <!-- set variablers from SDK and Office -->
+ <echo message="setting up UNO environment ..."/>
+ <property name="office.unopkg" value="${office.program.dir}${file.separator}unopkg"/>
+ <property name="office.soffice" value="${office.program.dir}${file.separator}soffice"/>
+
+ <property name="sdk.idl.dir" location="${oo.sdk.dir}${file.separator}idl"/>
+ <property name="sdk.idlc" value="${sdk.bin.dir}${file.separator}idlc"/>
+ <property name="sdk.regmerge" value="${ure.bin.dir}${file.separator}regmerge"/>
+ <property name="sdk.javamaker" value="${sdk.bin.dir}${file.separator}javamaker"/>
+
+ <dirname property="project.dir" file="build.xml"/>
+ <property name="uno.package.name" value="${project.dir}${file.separator}${dist.dir}${file.separator}${project.name}.oxt"/>
+ <property name="src.dir.absolute" value="${project.dir}${file.separator}${src.dir}"/>
+
+ <property name="idl.out" value="${project.dir}${file.separator}${build.dir}${file.separator}idl"/>
+ <property name="idl.classes.dir" value="${project.dir}${file.separator}${build.classes.dir}"/>
+ <property name="idl.out.urd" value="${idl.out}/urd"/>
+ <property name="idl.out.rdb" value="${idl.out}/rdb"/>
+ <property name="idl.rdb.name" value="types.rdb"/>
+ <property name="idl.rdb.fullpath" value="${idl.out.rdb}/${idl.rdb.name}"/>
+
+ <property name="images.base.dir" value="${build.dir}/img"/>
+ <property name="build.registry.dir" value="${build.dir}/cpreg"/>
+
+ <mkdir dir="${idl.out}"/>
+ <mkdir dir="${idl.out.urd}"/>
+ <mkdir dir="${idl.out.rdb}"/>
+ <mkdir dir="${images.base.dir}"/>
+ <mkdir dir="${build.registry.dir}"/>
+
+ <condition property="oo.version.three">
+ <equals arg1="${oo.version.number}" arg2="three"/>
+ </condition>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+ <!-- handle images -->
+ <target name="-uno-images-condition" description="check images" depends="-uno-project-init">
+ <available file="${images.dir}" type="dir" property="images.required"/>
+ </target>
+
+ <target name="images" description="copy images" depends="-uno-images-condition" if="images.required">
+ <mkdir dir="${images.base.dir}/${images.dir}"/>
+ <copy todir="${images.base.dir}/${images.dir}">
+ <fileset dir="${images.dir}"/>
+ </copy>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+ <!-- handle xcu/xcs files with package names -->
+
+ <target name="-uno-registryfiles-condition" description="check xcu and xcs files" depends="-uno-project-init">
+ <available file="${registry.dir}" type="dir" property="xcuxcs.required"/>
+ </target>
+
+ <target name="registry" description="copy registry files" depends="-uno-registryfiles-condition" if="xcuxcs.required">
+ <mkdir dir="${build.registry.dir}/${registry.dir}"/>
+ <copy todir="${build.registry.dir}/${registry.dir}">
+ <fileset dir="${registry.dir}" includes="**/*.xcu,**/*.xcs"/>
+ </copy>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="-uno-idl-idlc-condition" description="check idlc dependencies" depends="-uno-project-init">
+ <uptodate property="idlc.notRequired" targetfile ="${build.dir}/idlc.compile">
+ <srcfiles dir= "${src.dir}" includes="**/*.idl"/>
+ </uptodate>
+ </target>
+
+ <!-- compile UNO idl files: execution -->
+ <target name="-uno-idl-idlc" description="Compile the IDL Conditionally" depends="-uno-idl-idlc-condition" unless="idlc.notRequired">
+ <apply executable="${sdk.idlc}" dir="${office.program.dir}" failonerror="true">
+ <env key="PATH" path="${office.tool.path}"/>
+ <env key="LD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <env key="DYLD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <arg value="-C"/>
+ <arg value="-O"/>
+ <arg value="${idl.out.urd}"/>
+ <arg value="-I"/>
+ <arg value="${src.dir.absolute}"/>
+ <arg value="-I"/>
+ <arg value="${sdk.idl.dir}"/>
+ <fileset dir="${src.dir}" includes="**/*.idl" casesensitive="yes" id="idl.list.id"/>
+ </apply>
+ <!-- list for copying idl files in own jar -->
+ <property name="idl.file" refid="idl.list.id"/>
+ <propertyfile file="${idl.out}/idl_list.properties">
+ <entry key="idl.file.list" value="${idl.file}"/>
+ </propertyfile>
+ <replace file="${idl.out}/idl_list.properties" token=".idl" value=".class"/>
+ <replace file="${idl.out}/idl_list.properties" token=";" value=","/>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <!-- merge urd files: execution -->
+ <target name="-uno-idl-regmerge" description="Merge urd Files Conditionally" depends="-uno-idl-idlc,-uno-idl-idlc-condition" unless="idlc.notRequired">
+ <!-- to only extract the new files, delete the old rdb -->
+ <delete file="${idl.rdb.fullpath}"/>
+ <apply executable="${sdk.regmerge}" dir="${office.program.dir}" failonerror="true">
+ <env key="PATH" path="${office.tool.path}"/>
+ <env key="LD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <env key="DYLD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <arg file="${idl.rdb.fullpath}"/>
+ <arg value="/UCR"/>
+ <fileset dir="${idl.out.urd}" includes="**/*.urd" casesensitive="yes"/>
+ </apply>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <!-- should javamaker be executed -->
+ <target name="-uno-idl-javamaker-condition" description="check if rdb was created" depends="-uno-idl-regmerge,-uno-idl-idlc-condition">
+ <available file="${idl.rdb.name}" filepath="${idl.out.rdb}" property="javamaker.Required"/>
+ </target>
+
+ <!-- generate Java class files from type library: execution -->
+ <target name="-uno-idl-javamaker" depends="-uno-idl-regmerge,-uno-idl-idlc-condition,-uno-idl-javamaker-condition" if="javamaker.Required" unless="idlc.notRequired">
+ <echo message="generating java class files from rdb..."/>
+ <exec executable="${sdk.javamaker}" dir="${office.program.dir}" failonerror="true">
+ <env key="PATH" path="${office.tool.path}"/>
+ <env key="LD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <env key="DYLD_LIBRARY_PATH" path="${office.tool.path}"/>
+ <arg value="-BUCR"/>
+ <arg value="-O"/>
+ <arg value="${idl.classes.dir}"/>
+ <arg file="${idl.rdb.fullpath}"/>
+ <arg value="${oo.unotypes.rdb}"/> <!-- from ConfigurationSettings -->
+ <arg value="${oo.offapi.rdb}"/> <!-- from ConfigurationSettings -->
+ </exec>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="-uno-idl-result" depends="-uno-idl-javamaker">
+ <touch file="${build.dir}/idlc.compile"/>
+ <echo message="build UNO idl files finished"/>
+ </target>
+
+ <!-- the main target, called in recursive builds -->
+ <target name="uno-idl-compile" description="Compiles UNO idl files" depends="-uno-idl-result"/>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="jar" depends="-uno-project-init,uno-idl-compile,-jar-idl-types,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-openoffice-manifest,-post-jar">
+ <jar basedir="${build.classes.dir}" compress="true" filesonly="true" manifest="${build.dir}/MANIFEST.MF" jarfile="${dist.jar}" excludes="**/*.xml,**/*.txt,${idl.file.list},${build.classes.excludes}"/>
+ </target>
+
+ <target name="-jar-idl-types" depends="-do-uno-types" unless="no.idl.files">
+ <mkdir dir="${dist.dir}"/>
+ <jar basedir="${build.classes.dir}" compress="true" jarfile="${dist.dir}/${idl_types.jar}" includes="${idl.file.list}">
+ <manifest>
+ <attribute name="UNO-Type-Path" value="&lt;&gt;"/>
+ </manifest>
+ </jar>
+ </target>
+
+ <target name="-do-openoffice-manifest" depends="-copy-user-manifest,-external-jars,-do-registration,-do-class-path"/>
+
+ <!-- macro for checking manifest entries from a user manifest -->
+ <macrodef name="check-manifest-entry">
+ <attribute name="entry.name"/>
+ <attribute name="condition.property.name"/>
+ <sequential>
+ <condition property="@{condition.property.name}">
+ <and>
+ <!-- if file does not exist, "isfileselected" is not executed -->
+ <!-- necessary construct because available is not allowed here
+ but should be according to documentation -->
+ <istrue value="${build.manifest.exists}"/>
+ <!-- produces an error if file is not there -->
+ <isfileselected file="${build.dir}/MANIFEST.MF">
+ <contains text="@{entry.name}"/>
+ </isfileselected>
+ </and>
+ </condition>
+ </sequential>
+ </macrodef>
+
+ <!-- enter the class path with external jars, if external jars exit and the user did not enter his own -->
+ <target name="-do-class-path" depends="-external-jars,-check-class-path" unless="class.path.exists">
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <attribute name="Class-Path" value="${external.jars}"/>
+ </manifest>
+ </target>
+ <target name="-check-class-path">
+ <check-manifest-entry condition.property.name="class.path.exists" entry.name="Class-Path"/>
+ </target>
+
+ <!-- enter idl type definitions if it exists and if the user did not overwrite it -->
+ <target name="-do-uno-types" depends="-do-empty-unopath,-do-idl-unopath"/>
+ <target name="-do-idl-unopath" depends="-check-uno-types" if="own.idl.files" unless="uno.path.exists">
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <attribute name="UNO-Type-Path" value="${idl_types.jar}"/>
+ </manifest>
+ </target>
+ <target name="-do-empty-unopath" depends="-check-uno-types" if="no.idl.files" unless="uno.path.exists">
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <attribute name="UNO-Type-Path" value=""/>
+ </manifest>
+ </target>
+ <target name="-check-uno-types">
+ <property file="${idl.out}/idl_list.properties"/>
+ <check-manifest-entry condition.property.name="uno.path.exists" entry.name="UNO-Type-Path"/>
+ <condition property="no.idl.files">
+ <equals arg1="${idl.file.list}" arg2="" trim="true"/>
+ </condition>
+ <condition property="own.idl.files">
+ <not>
+ <istrue value="${no.idl.files}"/>
+ </not>
+ </condition>
+ </target>
+
+ <!-- enter the registration classes unless the user did not enter his own. Do nothing when the project is old -->
+ <target name="-do-registration" depends="-do-central-registration,-check-registration-classes-name"
+ if="new.project.registration" unless="do.no.registration">
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <section name="${slash.registration.class}">
+ <attribute name="RegistrationClasses" value="${registration.classname}"/>
+ </section>
+ </manifest>
+ </target>
+ <target name="-check-registration-classes-name">
+ <check-manifest-entry condition.property.name="registration.classes.exists" entry.name="RegistrationClasses"/>
+ <condition property="do.no.registration">
+ <or>
+ <istrue value="${registration.classes.exists}"/>
+ <istrue value="${registration.class.exists}"/>
+ </or>
+ </condition>
+ </target>
+
+ <!-- enter the registration class name unless the user did not enter his own. Do nothing when the project is old -->
+ <target name="-do-central-registration" depends="-check-registration-class-name,-do-old-project-registration" if="new.project.registration" unless="registration.class.exists">
+ <property name="regclass.properties" value="${build.dir}/regclass.properties"/>
+ <propertyfile file="${regclass.properties}">
+ <entry key="dot.registration" value="${slash.registration.class}"/>
+ </propertyfile>
+ <replace file="${regclass.properties}" token=".class" value=""/>
+ <replace file="${regclass.properties}" token="/" value="."/>
+ <property file="${regclass.properties}"/>
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <attribute name="RegistrationClassName" value="${dot.registration}"/>
+ </manifest>
+ </target>
+ <target name="-check-registration-class-name">
+ <check-manifest-entry condition.property.name="registration.class.exists" entry.name="RegistrationClassName"/>
+ </target>
+
+ <!-- Do the registration for older projects without a central registration class -->
+ <target name="-do-old-project-registration" depends="-check-for-old-project" if="old.project.registration" unless="registration.class.exists">
+ <manifest file="${build.dir}/MANIFEST.MF" mode="update">
+ <attribute name="RegistrationClassName" value="${registration.classname}"/>
+ </manifest>
+ </target>
+ <target name="-check-for-old-project">
+ <!-- central registration class in project -->
+ <fileset id="registration.class.name" dir="${build.dir}/classes">
+ <patternset>
+ <include name="**/CentralRegistrationClass.class"/>
+ </patternset>
+ </fileset>
+ <property name="systemslash.registration.class" refid="registration.class.name"/>
+ <!-- make forward slash from backslash on Windows -->
+ <property name="regclass.properties" value="${build.dir}/regclass.properties"/>
+ <propertyfile file="${regclass.properties}">
+ <entry key="slash.registration.class" value="${systemslash.registration.class}"/>
+ </propertyfile>
+ <replace file="${regclass.properties}" token="\\" value="/"/>
+ <property file="${regclass.properties}"/>
+ <!-- now slash is ok -->
+ <condition property="old.project.registration">
+ <equals trim="true" arg1="${slash.registration.class}" arg2=""/>
+ </condition>
+ <condition property="new.project.registration">
+ <isfalse value="${old.project.registration}"/>
+ </condition>
+ </target>
+
+ <!-- copy the user manifest if it exists -->
+ <target name="-copy-user-manifest" depends="-check-user-manifest" if="user.manifest.exists">
+ <copy file="manifest.mf" tofile="${build.dir}/MANIFEST.MF" overwrite="true"/>
+ <available file="${build.dir}/MANIFEST.MF" property="build.manifest.exists"/>
+ </target>
+ <target name="-check-user-manifest">
+ <available file="manifest.mf" property="user.manifest.exists"/>
+ </target>
+
+ <!-- handle the class path for external jar files unless there is a user overwrite -->
+ <target name="-external-jars" depends="-rm-external-jars,-add-external-jars"/>
+
+ <target name="-add-external-jars" depends="-external-jars-condition" if="do.externalJars">
+ <!-- get property external.jars for classpath from props file -->
+ <property file="${dist.dir}/${external.jar.dir}/jars.properties"/>
+ </target>
+
+ <target name="-rm-external-jars" depends="-external-jars-condition" unless="do.externalJars">
+ <!-- empty property, if no jars -->
+ <property name="external.jars" value=""/>
+ </target>
+
+ <target name="-external-jars-condition">
+ <available file="${dist.dir}/${external.jar.dir}" type="dir" property="do.externalJars"/>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="-delete-uno-package">
+ <delete failonerror="false" file="${uno.package.name}"/>
+ </target>
+
+ <target name="-pre-uno-package">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+
+ <target name="-license-exists">
+ <available file="${project.dir}/${licenses.dir}" type="dir" property="do.license"/>
+ </target>
+
+ <!-- test for licenses dir is necessary because zipfileset fails if dir not there -->
+ <target name="-uno-package-with-license" depends="-license-exists" if="do.license">
+ <zip update="true" destfile="${uno.package.name}">
+ <zipfileset dir="${project.dir}/${licenses.dir}" includes="**" casesensitive="yes" prefix="${licenses.dir}"/>
+ </zip>
+ </target>
+
+ <target name="-description-exists">
+ <available file="${project.dir}/${description.dir}" type="dir" property="do.description"/>
+ </target>
+
+ <!-- test for description dir is necessary because zipfileset fails if dir not there -->
+ <target name="-uno-package-with-description" depends="-description-exists" if="do.description">
+ <zip update="true" destfile="${uno.package.name}">
+ <zipfileset dir="${project.dir}/${description.dir}" includes="**" casesensitive="yes" prefix="${description.dir}"/>
+ </zip>
+ </target>
+
+ <target name="-help-exists">
+ <available file="${project.dir}/${help.dir}" type="dir" property="do.help"/>
+ </target>
+
+ <!-- test for help dir is necessary because zipfileset fails if dir not there -->
+ <target name="-uno-package-with-help" depends="-help-exists" if="do.help">
+ <zip update="true" destfile="${uno.package.name}">
+ <zipfileset dir="${help.dir}" includes="${help.content.extensions}" prefix="${help.dir}"/>
+ </zip>
+ </target>
+
+ <target name="-dialogs-exists">
+ <available file="${project.dir}/${dialogs.dir}" type="dir" property="do.dialogs"/>
+ </target>
+
+ <!-- test for dialogs dir is necessary because zipfileset fails if dir not there -->
+ <target name="-uno-package-with-dialogs" depends="-dialogs-exists" if="do.dialogs">
+ <zip update="true" destfile="${uno.package.name}">
+ <zipfileset dir="${dialogs.dir}" includes="${dialog.content.extensions}" prefix="dialogs"/>
+ </zip>
+ </target>
+
+ <target name="-do-uno-package" description="Creates UNO extension pacakge" depends="-uno-package-with-license,-uno-package-with-help,-uno-package-with-dialogs,-uno-package-with-description">
+ <echo message="creating UNO extension package ..."/>
+ <zip update="true" destfile="${uno.package.name}">
+ <fileset dir="${src.dir}" includes="${manifest.package.extensions}" casesensitive="yes"/>
+ <fileset dir="${build.registry.dir}" casesensitive="yes"/>
+ <fileset dir="${src.dir}" includes="description.xml" casesensitive="yes"/>
+ <fileset dir="${dist.dir}" includes="**/*.jar" casesensitive="yes"/>
+ <fileset dir="${images.base.dir}" includes="**" casesensitive="yes"/>
+ <fileset dir="${idl.out.rdb}" includes="**/*.rdb" casesensitive="yes"/>
+ <zipfileset dir="${src.dir}" includes="uno-extension-manifest.xml" fullpath="META-INF/manifest.xml"/>
+ </zip>
+ </target>
+
+ <target name="-post-uno-package">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+
+ <target name="uno-package" description="Creates UNO extension pacakge" depends="jar,images,registry,-delete-uno-package,-pre-uno-package,-do-uno-package,-post-uno-package"/>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+<!-- <target name="uno-deploy" description="Deploys UNO extension package" depends="uno-package">
+ <echo message="deploying UNO extension package ..."/>
+ <echo message="${office.unopkg} gui -f ${uno.package.name}"/>
+ <echo message="${office.soffice} ${uno.package.name}"/>
+ <exec executable="${office.soffice}" dir="${office.program.dir}" failonerror="true">
+ <arg file="${uno.package.name}"/>
+ </exec>
+ </target> -->
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="uno-run" description="Run OpenOffice.org" depends="uno-package,-run-oo"/>
+
+ <!-- subtargets for different office versions -->
+ <target name="-run-oo">
+ <echo message="${office.unopkg} gui -f ${uno.package.name}"/>
+ <exec dir="${office.program.dir}" executable="${office.unopkg}" failonerror="true">
+ <arg value="gui"/>
+ <arg value="-f"/>
+ <arg file="${uno.package.name}"/>
+ </exec>
+ <echo message="${office.soffice}"/>
+ <exec executable="${office.soffice}" dir="${office.program.dir}" failonerror="true">
+ <arg value="${office.startup.options}"/>
+ </exec>
+ </target>
+
+ <!-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
+
+ <target name="uno-debug" description="Debugss UNO extension package in Target Office" depends="uno-package,-oo-debug"/>
+
+ <target name="-oo-debug">
+ <!-- security fail for executing this without netbeans -->
+ <fail unless="netbeans.home">This target can only run inside the NetBeans IDE.</fail>
+ <!-- start debugger and get connection address jpda.address -->
+ <nbjpdastart name="Debug Office" addressproperty="jpda.address" transport="dt_socket">
+ <classpath path="${build.classes.dir}"/>
+ <sourcepath path="${src.dir}"/>
+ </nbjpdastart>
+ <!-- register component in temporary user installation -->
+ <echo message="debugging UNO extension package ..."/>
+ <echo message="${office.unopkg} gui -f ${uno.package.name}"/>
+ <exec dir="${office.program.dir}" executable="${office.unopkg}">
+ <arg value="gui"/>
+ <arg value="-f"/>
+ <arg file="${uno.package.name}"/>
+ <env key="UserInstallation" value="${office.debug.user.directory}"/>
+ </exec>
+ <!-- start Office with debug Java and user installation -->
+ <echo message="starting the Office with ..."/>
+ <echo message="user installation: ${office.debug.user.directory}"/>
+ <echo message="debug options: &quot;-Xdebug&quot; &quot;-Xrunjdwp:transport=dt_socket,address=${jpda.address}&quot;"/>
+ <echo message="${office.soffice}"/>
+ <exec dir="${office.program.dir}" executable="${office.soffice}" failonerror="true">
+ <arg value="-nofirststartwizard"/>
+ <arg value="${office.startup.options}"/>
+ <env key="UserInstallation" value="${office.debug.user.directory}"/>
+ <env key="JAVA_TOOL_OPTIONS" value="&quot;-Xdebug&quot; &quot;-Xrunjdwp:transport=dt_socket,address=${jpda.address}&quot;"/>
+ </exec>
+ </target>
+
+</project>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/genfiles.properties b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/genfiles.properties
new file mode 100755
index 000000000000..e4e5fc11997d
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/genfiles.properties
@@ -0,0 +1,8 @@
+build.xml.data.CRC32=2b754fcd
+build.xml.script.CRC32=0a20deac
+build.xml.stylesheet.CRC32=d5b6853a
+# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
+# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
+nbproject/build-impl.xml.data.CRC32=54a58ff4
+nbproject/build-impl.xml.script.CRC32=25927849
+nbproject/build-impl.xml.stylesheet.CRC32=576378a2@1.32.1.45
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/config.properties b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/config.properties
new file mode 100755
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/config.properties
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/private.properties b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/private.properties
new file mode 100755
index 000000000000..c090eb0e8f9c
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/private/private.properties
@@ -0,0 +1,6 @@
+compile.on.save=false
+do.depend=false
+do.jar=true
+javac.debug=true
+javadoc.preview=true
+user.properties.file=/localuser/qamsc/.netbeans/6.8/build.properties
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project-uno.properties b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project-uno.properties
new file mode 100755
index 000000000000..35a0535e7d02
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project-uno.properties
@@ -0,0 +1,18 @@
+uno.project.type=office.component.project
+project.name=TaskPaneComponent
+registration.classname=com.example.TaskPaneComponent
+external.jar.dir=lib
+idl_types.jar=TaskPaneComponent_IDL_types.jar
+central.registration.class=com.example.CentralRegistrationClass
+# extensions for files that go into the .oxt package; some are also referenced in the manifest
+manifest.package.extensions=**/*.xcu,**/*.xcs,**/*.xdl,**/*.xlb,**/*.xba,**/*.properties,**/*.default
+imgae.extensions=**/*.png,**/*.jpg,**/*.jpeg,**/*.gif
+help.content.extensions=**/*.xhp,**/*.tree,${image.extensions}
+dialog.content.extensions=**/*.xdl,**/*.properties,**/*.default,${image.extensions}
+office.startup.options=
+images.dir=images
+registry.dir=registry
+help.dir=help
+dialogs.dir=dialogs
+licenses.dir=licenses
+description.dir=description
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.properties b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.properties
new file mode 100755
index 000000000000..b6059cf3113c
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.properties
@@ -0,0 +1,67 @@
+application.args=
+application.title=TaskPaneComponent
+application.vendor=qamsc
+build.classes.dir=${build.dir}/classes
+build.classes.excludes=**/*.java,**/*.form,**/*.xcu,**/*.xcs,**/*.idl,**/*manifest.xml
+# This directory is removed when the project is cleaned:
+build.dir=build
+build.generated.dir=${build.dir}/generated
+build.generated.sources.dir=${build.dir}/generated-sources
+# Only compile against the classpath explicitly listed here:
+build.sysclasspath=ignore
+build.test.classes.dir=${build.dir}/test/classes
+build.test.results.dir=${build.dir}/test/results
+debug.classpath=\
+ ${run.classpath}
+debug.test.classpath=\
+ ${run.test.classpath}
+# This directory is removed when the project is cleaned:
+dist.dir=dist
+dist.jar=${dist.dir}/TaskPaneComponent.jar
+dist.javadoc.dir=${dist.dir}/javadoc
+endorsed.classpath=
+excludes=
+file.reference.juh.jar=../../office/slidecopy/openoffice.org/ure/share/java/juh.jar
+file.reference.jurt.jar=../../office/slidecopy/openoffice.org/ure/share/java/jurt.jar
+file.reference.ridl.jar=../../office/slidecopy/openoffice.org/ure/share/java/ridl.jar
+file.reference.unoil.jar=../../office/slidecopy/openoffice.org/basis3.3/program/classes/unoil.jar
+includes=**
+jar.compress=false
+javac.classpath=\
+ ${file.reference.unoil.jar}:\
+ ${file.reference.juh.jar}:\
+ ${file.reference.jurt.jar}:\
+ ${file.reference.ridl.jar}
+# Space-separated list of extra javac options
+javac.compilerargs=
+javac.deprecation=false
+javac.source=1.5
+javac.target=1.5
+javac.test.classpath=\
+ ${javac.classpath}:\
+ ${build.classes.dir}:\
+ ${libs.junit.classpath}
+javadoc.additionalparam=
+javadoc.author=false
+javadoc.encoding=
+javadoc.noindex=false
+javadoc.nonavbar=false
+javadoc.notree=false
+javadoc.private=false
+javadoc.splitindex=true
+javadoc.use=true
+javadoc.version=false
+javadoc.windowtitle=
+meta.inf.dir=${src.dir}/META-INF
+platform.active=default_platform
+run.classpath=\
+ ${javac.classpath}:\
+ ${build.classes.dir}
+# Space-separated list of JVM arguments used when running the project
+# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value
+# or test-sys-prop.name=value to set system properties for unit tests):
+run.jvmargs=
+run.test.classpath=\
+ ${javac.test.classpath}:\
+ ${build.test.classes.dir}
+src.dir=src
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.xml
new file mode 100755
index 000000000000..43c253f3c7e5
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/nbproject/project.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+ <type>org.netbeans.modules.java.j2seproject</type>
+ <configuration>
+ <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
+ <name>TaskPaneComponent</name>
+ <minimum-ant-version>1.6.5</minimum-ant-version>
+ <source-roots>
+ <root id="src.dir"/>
+ </source-roots>
+ <test-roots/>
+ </data>
+ </configuration>
+</project>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu
new file mode 100755
index 000000000000..ba2c8c692d4e
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu
@@ -0,0 +1,23 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<oor:component-data oor:name="CalcWindowState" oor:package="org.openoffice.Office.UI" xmlns:install="http://openoffice.org/2004/installation" xmlns:oor="http://openoffice.org/2001/registry" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+ <node oor:name="UIElements">
+ <node oor:name="States">
+ <node oor:name="private:resource/toolpanel/com.example.TestPanel1" oor:op="replace">
+ <prop oor:name="UIName" oor:type="xs:string">
+ <value xml:lang="en-US">ein Panel</value>
+ </prop>
+ <prop oor:name="Visible" oor:type="xs:boolean">
+ <value>true</value>
+ </prop>
+ </node>
+ <node oor:name="private:resource/toolpanel/com.example.TestPanel2" oor:op="replace">
+ <prop oor:name="UIName" oor:type="xs:string">
+ <value xml:lang="en-US">noch ein Panel</value>
+ </prop>
+ <prop oor:name="Visible" oor:type="xs:boolean">
+ <value>true</value>
+ </prop>
+ </node>
+ </node>
+ </node>
+</oor:component-data>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/Factories.xcu b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/Factories.xcu
new file mode 100755
index 000000000000..90dce8595a1b
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/registry/data/org/openoffice/Office/UI/Factories.xcu
@@ -0,0 +1,35 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<oor:component-data oor:name="Factories" oor:package="org.openoffice.Office.UI" xmlns:oor="http://openoffice.org/2001/registry" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+ <node oor:name="Registered">
+ <node oor:name="UIElementFactories">
+ <node oor:name="com.example.TaskPaneComponent1" oor:op="replace">
+ <prop oor:name="Type">
+ <value>toolpanel</value>
+ </prop>
+ <prop oor:name="Name">
+ <value>com.example.TestPanel1</value>
+ </prop>
+ <prop oor:name="Module">
+ <value/>
+ </prop>
+ <prop oor:name="FactoryImplementation">
+ <value>com.example.TaskPaneComponent</value>
+ </prop>
+ </node>
+ <node oor:name="com.example.TaskPaneComponent2" oor:op="replace">
+ <prop oor:name="Type">
+ <value>toolpanel</value>
+ </prop>
+ <prop oor:name="Name">
+ <value>com.example.TestPanel2</value>
+ </prop>
+ <prop oor:name="Module">
+ <value/>
+ </prop>
+ <prop oor:name="FactoryImplementation">
+ <value>com.example.TaskPaneComponent</value>
+ </prop>
+ </node>
+ </node>
+ </node>
+</oor:component-data>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/CentralRegistrationClass.java b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/CentralRegistrationClass.java
new file mode 100755
index 000000000000..5276f584aa3e
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/CentralRegistrationClass.java
@@ -0,0 +1,140 @@
+/*************************************************************************
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+package com.example;
+
+import com.sun.star.lang.XSingleComponentFactory;
+import com.sun.star.registry.XRegistryKey;
+import java.io.IOException;
+import java.lang.reflect.Method;
+import java.net.JarURLConnection;
+import java.net.URL;
+import java.util.Enumeration;
+import java.util.StringTokenizer;
+import java.util.jar.Attributes;
+import java.util.jar.Manifest;
+
+/**
+ *
+ * @author Marc Neumann
+ */
+public class CentralRegistrationClass
+{
+
+ public static XSingleComponentFactory __getComponentFactory(String sImplementationName)
+ {
+ String regClassesList = getRegistrationClasses();
+ StringTokenizer t = new StringTokenizer(regClassesList, " ");
+ while (t.hasMoreTokens())
+ {
+ String className = t.nextToken();
+ if (className != null && className.length() != 0)
+ {
+ try
+ {
+ Class regClass = Class.forName(className);
+ Method writeRegInfo = regClass.getDeclaredMethod("__getComponentFactory", new Class[]
+ {
+ String.class
+ });
+ Object result = writeRegInfo.invoke(regClass, sImplementationName);
+ if (result != null)
+ {
+ return (XSingleComponentFactory) result;
+ }
+ }
+ catch (Exception ex)
+ {
+ ex.printStackTrace();
+ }
+ }
+ }
+ return null;
+ }
+
+ public static boolean __writeRegistryServiceInfo(XRegistryKey xRegistryKey)
+ {
+ boolean bResult = true;
+ String regClassesList = getRegistrationClasses();
+ StringTokenizer t = new StringTokenizer(regClassesList, " ");
+ while (t.hasMoreTokens())
+ {
+ String className = t.nextToken();
+ if (className != null && className.length() != 0)
+ {
+ try
+ {
+ Class regClass = Class.forName(className);
+ Method writeRegInfo = regClass.getDeclaredMethod("__writeRegistryServiceInfo", new Class[]
+ {
+ XRegistryKey.class
+ });
+ Object result = writeRegInfo.invoke(regClass, xRegistryKey);
+ bResult &= ((Boolean) result).booleanValue();
+ }
+ catch (Exception ex)
+ {
+ ex.printStackTrace();
+ }
+ }
+ }
+ return bResult;
+ }
+
+ private static String getRegistrationClasses()
+ {
+ CentralRegistrationClass c = new CentralRegistrationClass();
+ String name = c.getClass().getCanonicalName().replace('.', '/').concat(".class");
+ try
+ {
+ Enumeration<URL> urlEnum = c.getClass().getClassLoader().getResources("META-INF/MANIFEST.MF");
+ while (urlEnum.hasMoreElements())
+ {
+ URL url = urlEnum.nextElement();
+ String file = url.getFile();
+ JarURLConnection jarConnection = (JarURLConnection) url.openConnection();
+ Manifest mf = jarConnection.getManifest();
+
+ Attributes attrs = (Attributes) mf.getAttributes(name);
+ if (attrs != null)
+ {
+ String classes = attrs.getValue("RegistrationClasses");
+ return classes;
+ }
+ }
+ }
+ catch (IOException ex)
+ {
+ ex.printStackTrace();
+ }
+
+ return "";
+ }
+
+ /** Creates a new instance of CentralRegistrationClass */
+ private CentralRegistrationClass()
+ {
+ }
+}
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/TaskPaneComponent.java b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/TaskPaneComponent.java
new file mode 100755
index 000000000000..0c5fdb782fad
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/TaskPaneComponent.java
@@ -0,0 +1,116 @@
+/*************************************************************************
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+package com.example;
+
+import com.sun.star.awt.XWindow;
+import com.sun.star.frame.XFrame;
+import com.sun.star.uno.XComponentContext;
+import com.sun.star.lib.uno.helper.Factory;
+import com.sun.star.lang.XSingleComponentFactory;
+import com.sun.star.registry.XRegistryKey;
+import com.sun.star.lib.uno.helper.WeakBase;
+import com.sun.star.uno.UnoRuntime;
+
+public final class TaskPaneComponent extends WeakBase
+ implements com.sun.star.ui.XUIElementFactory,
+ com.sun.star.lang.XServiceInfo
+{
+
+ private final XComponentContext m_xContext;
+ private static final String m_implementationName = TaskPaneComponent.class.getName();
+ private static final String[] m_serviceNames =
+ {
+ "com.sun.star.ui.UIElementFactory"
+ };
+
+ public TaskPaneComponent(XComponentContext context)
+ {
+ m_xContext = context;
+ }
+
+ public static XSingleComponentFactory __getComponentFactory(String sImplementationName)
+ {
+ XSingleComponentFactory xFactory = null;
+
+ if (sImplementationName.equals(m_implementationName))
+ {
+ xFactory = Factory.createComponentFactory(TaskPaneComponent.class, m_serviceNames);
+ }
+ return xFactory;
+ }
+
+ public static boolean __writeRegistryServiceInfo(XRegistryKey xRegistryKey)
+ {
+ return Factory.writeRegistryServiceInfo(m_implementationName,
+ m_serviceNames,
+ xRegistryKey);
+ }
+
+ public com.sun.star.ui.XUIElement createUIElement(String ResourceURL, com.sun.star.beans.PropertyValue[] creationArgs) throws com.sun.star.container.NoSuchElementException, com.sun.star.lang.IllegalArgumentException
+ {
+
+ XFrame docFrame = null;
+ XWindow panelParentWindow = null;
+ for (int i = 0; i < creationArgs.length; ++i)
+ {
+ if (creationArgs[i].Name.equals("Frame"))
+ {
+ docFrame = UnoRuntime.queryInterface(XFrame.class, creationArgs[i].Value);
+ } else if (creationArgs[i].Name.equals("ParentWindow"))
+ {
+ panelParentWindow = UnoRuntime.queryInterface(XWindow.class, creationArgs[i].Value);
+ }
+ }
+
+ return new ToolPanelUIElement(m_xContext, docFrame, panelParentWindow);
+
+ }
+
+ // com.sun.star.lang.XServiceInfo:
+ public String getImplementationName()
+ {
+ return m_implementationName;
+ }
+
+ public boolean supportsService(String sService)
+ {
+ int len = m_serviceNames.length;
+
+ for (int i = 0; i < len; i++)
+ {
+ if (sService.equals(m_serviceNames[i]))
+ {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public String[] getSupportedServiceNames()
+ {
+ return m_serviceNames;
+ }
+}
diff --git a/testshl2/workben/dlltest/onefunc.cxx b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanel.java
index 081018cab85f..a28e07d5847b 100644..100755
--- a/testshl2/workben/dlltest/onefunc.cxx
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanel.java
@@ -1,5 +1,4 @@
/*************************************************************************
- *
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* Copyright 2000, 2010 Oracle and/or its affiliates.
@@ -25,27 +24,33 @@
*
************************************************************************/
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
+package com.example;
-#include <stdio.h>
-#include <sal/types.h>
-#include "registerfunc.h"
+import com.sun.star.accessibility.XAccessible;
+import com.sun.star.awt.XWindow;
+import com.sun.star.ui.XToolPanel;
+import com.sun.star.uno.UnoRuntime;
-extern "C" void SAL_CALL firstfunc()
-{
- printf("first func called.\n");
-}
-extern "C" void SAL_CALL secondfunc()
+/**
+ *
+ * @author frank.schoenheit@sun.com
+ */
+public class ToolPanel implements XToolPanel
{
- printf("second func called.\n");
-}
+ ToolPanel( final XWindow i_panelWindow )
+ {
+ m_panelWindow = i_panelWindow;
+ }
-extern "C" void SAL_CALL registerAllTestFunction(FktRegFuncPtr _pFunc)
-{
- if (_pFunc)
+ public XWindow getWindow()
+ {
+ return m_panelWindow;
+ }
+
+ public XAccessible createAccessible( XAccessible i_parentAccessible )
{
- (_pFunc)(&firstfunc, "firstfunc");
- (_pFunc)(&secondfunc, "secondfunc");
+ return UnoRuntime.queryInterface( XAccessible.class, m_panelWindow );
}
+
+ private XWindow m_panelWindow;
}
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanelUIElement.java b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanelUIElement.java
new file mode 100755
index 000000000000..6fb17d17f3d6
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/com/example/ToolPanelUIElement.java
@@ -0,0 +1,153 @@
+/*************************************************************************
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+package com.example;
+
+import com.sun.star.awt.XContainerWindowProvider;
+import com.sun.star.awt.XWindow;
+import com.sun.star.awt.XWindowPeer;
+import com.sun.star.deployment.PackageInformationProvider;
+import com.sun.star.deployment.XPackageInformationProvider;
+import com.sun.star.frame.XFrame;
+import com.sun.star.lang.DisposedException;
+import com.sun.star.lang.XComponent;
+import com.sun.star.lib.uno.helper.ComponentBase;
+import com.sun.star.ui.UIElementType;
+import com.sun.star.ui.XUIElement;
+import com.sun.star.uno.UnoRuntime;
+import com.sun.star.uno.XComponentContext;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+/**
+ *
+ * @author frank.schoenheit@sun.com
+ */
+public class ToolPanelUIElement extends ComponentBase implements XUIElement
+{
+
+ protected final XFrame m_docFrame;
+ protected final XWindow m_parentWindow;
+ private XWindow m_panelRootWindow = null;
+ private Object m_toolPanel = null;
+ XComponentContext context = null;
+
+
+ protected ToolPanelUIElement( XComponentContext _context, final XFrame i_docFrame, final XWindow i_parentWindow )
+ {
+ context = _context;
+ m_docFrame = i_docFrame;
+ m_parentWindow = i_parentWindow;
+ }
+
+ public static String getResourceURLBase()
+ {
+ return "private:resource/toolpanel/com.example.TaskPaneComponent/";
+ }
+
+ // XUIElement overridables
+ public XFrame getFrame() { return m_docFrame; }
+ public short getType() { return UIElementType.TOOLPANEL; }
+ public String getResourceURL() { return getResourceURLBase() + getPanelResourceURLSuffix(); }
+
+ public Object getRealInterface()
+ {
+ synchronized( this )
+ {
+ if ( this.bDisposed || this.bInDispose )
+ throw new DisposedException( new String(), this );
+
+ if ( m_toolPanel == null )
+ m_toolPanel = new ToolPanel( getOrCreatePanelRootWindow() );
+ }
+ return m_toolPanel;
+ }
+
+ // own overridables
+ /** returns the name of the dialog description file of the tool panel, without .xdl suffix
+ */
+ protected String getPanelResourceLocation()
+ {
+ return "TaskPaneComponentUI";
+
+ }
+
+ /** returns the resource URL suffix to use for the tool panel
+ * @return
+ */
+ protected String getPanelResourceURLSuffix()
+ {
+ return "TaskPaneComponentUI";
+ }
+
+
+ // ComponentBase overridables
+ protected void postDisposing()
+ {
+ super.postDisposing();
+ synchronized ( this )
+ {
+ if ( m_panelRootWindow != null )
+ {
+ XComponent panelWindowComp = UnoRuntime.queryInterface( XComponent.class, m_panelRootWindow );
+ panelWindowComp.dispose();
+ m_panelRootWindow = null;
+
+ }
+ m_toolPanel = null;
+ }
+ }
+
+ // helpers
+ synchronized private XWindow getOrCreatePanelRootWindow()
+ {
+ try
+ {
+ XPackageInformationProvider pip = PackageInformationProvider.get(context);
+ String s = pip.getPackageLocation("com.example.TaskPaneComponent");
+
+ String dialogUrl = s + "/toolpanels/" + getPanelResourceLocation() + ".xdl";
+
+ XContainerWindowProvider provider = UnoRuntime.queryInterface(
+ XContainerWindowProvider.class,
+ context.getServiceManager().createInstanceWithContext("com.sun.star.awt.ContainerWindowProvider",context)
+ );
+
+ m_panelRootWindow = provider.createContainerWindow(
+ dialogUrl,
+ "",
+ UnoRuntime.queryInterface( XWindowPeer.class, m_parentWindow ),
+ null
+ );
+
+ }
+ catch ( final Exception e )
+ {
+ Logger.getLogger( ToolPanelUIElement.class.getName() ).log( Level.SEVERE, null, e );
+ }
+ return m_panelRootWindow;
+ }
+}
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/description.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/description.xml
new file mode 100755
index 000000000000..9e32a6e8bfed
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/description.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<description xmlns="http://openoffice.org/extensions/description/2006" xmlns:xlink="http://www.w3.org/1999/xlink">
+ <version value="0.0.1"/>
+ <identifier value="com.example.TaskPaneComponent"/>
+</description>
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/toolpanels/TaskPaneComponentUI.xdl b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/toolpanels/TaskPaneComponentUI.xdl
new file mode 100755
index 000000000000..7820e3d52c59
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/toolpanels/TaskPaneComponentUI.xdl
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE dlg:window PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "dialog.dtd">
+<dlg:window xmlns:dlg="http://openoffice.org/2000/dialog" xmlns:script="http://openoffice.org/2000/script" dlg:id="Dialog1" dlg:left="192" dlg:top="127" dlg:width="174" dlg:height="147" dlg:closeable="true" dlg:moveable="true" dlg:help-url="HID:123456" dlg:withtitlebar="false">
+ <dlg:bulletinboard>
+ <dlg:button dlg:id="CommandButton1" dlg:tab-index="0" dlg:left="6" dlg:top="8" dlg:width="64" dlg:height="20" dlg:value="a wonderful button"/>
+ <dlg:textfield dlg:id="TextField1" dlg:textarea-vertical-align="top" dlg:tab-index="1" dlg:left="6" dlg:top="38" dlg:width="64" dlg:height="59" dlg:value="a wonderful text"/>
+ </dlg:bulletinboard>
+</dlg:window> \ No newline at end of file
diff --git a/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/uno-extension-manifest.xml b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/uno-extension-manifest.xml
new file mode 100755
index 000000000000..d49fe3d726ee
--- /dev/null
+++ b/testautomation/extensions/optional/input/extension_sources/TaskPaneComponent/src/uno-extension-manifest.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<manifest:manifest xmlns:manifest="http://openoffice.org/2001/manifest">
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.uno-component;type=Java"
+ manifest:full-path="TaskPaneComponent.jar"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="registry/data/org/openoffice/Office/UI/Factories.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="registry/data/org/openoffice/Office/UI/CalcWindowState.xcu"/>
+</manifest:manifest> \ No newline at end of file
diff --git a/testautomation/extensions/optional/input/extensions/TaskPaneComponent/TaskPaneComponent.oxt b/testautomation/extensions/optional/input/extensions/TaskPaneComponent/TaskPaneComponent.oxt
new file mode 100755
index 000000000000..5c826dd3541d
--- /dev/null
+++ b/testautomation/extensions/optional/input/extensions/TaskPaneComponent/TaskPaneComponent.oxt
Binary files differ
diff --git a/testautomation/extensions/optional/input/issues/Logging.xcu b/testautomation/extensions/optional/input/issues/Logging.xcu
new file mode 100755
index 000000000000..8bf0f34b6f1b
--- /dev/null
+++ b/testautomation/extensions/optional/input/issues/Logging.xcu
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<oor:component-data xmlns:oor="http://openoffice.org/2001/registry" xmlns:xs="http://www.w3.org/2001/XMLSchema" oor:name="Logging" oor:package="org.openoffice.Office">
+ <node oor:name="Settings">
+ <node oor:name="bw.stv.tvs.logging.DefaultLogger" oor:op="replace">
+ <prop oor:name="DefaultFormatter" oor:type="xs:string">
+ <value>com.sun.star.logging.PlainTextFormatter</value>
+ </prop>
+ <prop oor:name="DefaultHandler" oor:type="xs:string">
+ <value>bw.stv.tvs.logging.UILogHandler</value>
+ </prop>
+ <prop oor:name="LogLevel" oor:type="xs:int">
+ <value>2147483647</value>
+ </prop>
+ <node oor:name="HandlerSettings">
+ <prop oor:name="UIId" oor:type="xs:string">
+ <value>tvs.ui</value>
+ </prop>
+ <prop oor:name="UITitle" oor:type="xs:string">
+ <value>TVS-Logger (bw.stv.tvs.logging.DefaultLogger)</value>
+ </prop>
+ </node>
+ </node>
+ </node>
+</oor:component-data> \ No newline at end of file
diff --git a/testautomation/extensions/optional/input/issues/LoggingOptions.xcs b/testautomation/extensions/optional/input/issues/LoggingOptions.xcs
new file mode 100644
index 000000000000..e87474bba2a2
--- /dev/null
+++ b/testautomation/extensions/optional/input/issues/LoggingOptions.xcs
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<oor:component-schema xmlns:oor="http://openoffice.org/2001/registry" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" oor:name="Logging" oor:package="org.openoffice.Office" xml:lang="en-US">
+ <templates>
+ <group oor:name="LoggerSettings">
+ <group oor:name="HandlerSettings" oor:extensible="true">
+ <info>
+ <desc>Enthält zusätzliche Optionen für den TVS-UILogHandler</desc>
+ </info>
+ <prop oor:name="UITitle" oor:type="xs:string">
+ <value/>
+ </prop>
+ <prop oor:name="UIId" oor:type="xs:string">
+ <value/>
+ </prop>
+ </group>
+ </group>
+ </templates>
+ <component/>
+</oor:component-schema>
diff --git a/testautomation/framework/optional/f_basic_vba-compat.bas b/testautomation/framework/optional/f_basic_vba-compat.bas
index 363e59c70cb4..80b48eb5c1e6 100755
--- a/testautomation/framework/optional/f_basic_vba-compat.bas
+++ b/testautomation/framework/optional/f_basic_vba-compat.bas
@@ -36,11 +36,17 @@ sub main
use "framework\optional\includes\basic_vba-compat_import_nothing.inc"
use "framework\optional\includes\basic_vba-compat_import_disabled.inc"
use "framework\optional\includes\basic_vba-compat_import_enabled.inc"
+ use "framework\optional\includes\basic_vba-compat_thisworkbook.inc"
+ use "framework\optional\includes\basic_vba-compat_application-union.inc"
+ use "framework\optional\includes\basic_vba-compat_xlsm-xlsb.inc"
call hStatusIn( "framework" , "f_basic_vba-compat.bas" )
call tBasicVBACompatImportNothing()
call tBasicVBACompatImportDisabled()
call tBasicVBACompatImportEnabled()
+ call tBasicVBACompatThisWorkBook()
+ call tBasicVBACompatApplicationUnion()
+ call tBasicVBACompatXLSM_XLSB()
call hStatusOut()
end sub
@@ -54,6 +60,10 @@ sub LoadIncludeFiles
use "global\tools\includes\optional\t_basic_organizer_tools.inc"
use "global\tools\includes\optional\t_treelist_tools.inc"
+ use "global\tools\includes\optional\t_stringtools.inc"
+ use "global\tools\includes\optional\t_security_tools.inc"
+ use "global\tools\includes\optional\t_macro_tools.inc"
+ use "global\tools\includes\optional\t_docfuncs.inc"
use "framework\optional\includes\basic_vba_compat_tools.inc"
diff --git a/testautomation/framework/optional/includes/CJK_CollationDialogue_1.inc b/testautomation/framework/optional/includes/CJK_CollationDialogue_1.inc
index 98faef122a4c..0cab687d2f50 100644..100755
--- a/testautomation/framework/optional/includes/CJK_CollationDialogue_1.inc
+++ b/testautomation/framework/optional/includes/CJK_CollationDialogue_1.inc
@@ -52,6 +52,12 @@ testcase tLanguageTest_1
sKeyTypeTChinese = "Numerisch"
sKeyTypeJapanese = "Numerisch"
sKeyTypeKoren = "Numerisch"
+ case 50 :' Slovenian
+ sKeyTypeEnglishUSA = "AlfanumeriÄno"
+ sKeyTypeSChinese = "Nabor znakov"
+ sKeyTypeTChinese = "NumeriÄno"
+ sKeyTypeJapanese = "Nabor znakov"
+ sKeyTypeKoren = "Nabor znakov"
case 55 :' Brazilian
sKeyTypeEnglishUSA = "Alfanumérico"
sKeyTypeSChinese = "Conjunto de caracteres"
@@ -273,6 +279,12 @@ testcase tLanguageTest_2
sKeyTypeTChinese = "Numerisch"
sKeyTypeJapanese = "Numerisch"
sKeyTypeKoren = "Numerisch"
+ case 50 :' Slovenian
+ sKeyTypeEnglishUSA = "AlfanumeriÄno"
+ sKeyTypeSChinese = "Nabor znakov"
+ sKeyTypeTChinese = "NumeriÄno"
+ sKeyTypeJapanese = "Nabor znakov"
+ sKeyTypeKoren = "Nabor znakov"
case 55 :' Brazilian
sKeyTypeEnglishUSA = "numérico"
sKeyTypeSChinese = "numérico"
@@ -494,6 +506,8 @@ testcase tStrokeSort
sKeyTypeSChinese = "Stroke"
case 49 : ' German
sKeyTypeSChinese = "Stroke"
+ case 50 : ' Slovenian
+ sKeyTypeSChinese = "Poteza"
case 55 : ' Brazilian
sKeyTypeSChinese = "Traço"
case 81 : ' Japanese
@@ -582,6 +596,8 @@ testcase tPinyinSort
sKeyTypeSChinese = "Pinyin"
case 49 : ' German
sKeyTypeSChinese = "Pinyin"
+ case 50 : ' Slovenian
+ sKeyTypeSChinese = "Pinjin"
case 55 : ' Brazilian
sKeyTypeSChinese = "Pinyin"
case 81 : ' Japanese
diff --git a/testautomation/framework/optional/includes/CJK_RubyDialogueProposal_1.inc b/testautomation/framework/optional/includes/CJK_RubyDialogueProposal_1.inc
index 39c42fe75b8e..5b03be6151cb 100644..100755
--- a/testautomation/framework/optional/includes/CJK_RubyDialogueProposal_1.inc
+++ b/testautomation/framework/optional/includes/CJK_RubyDialogueProposal_1.inc
@@ -204,6 +204,7 @@ testcase tRubyDialog_4
case 39 : sCharacterStyle = "Testo Ruby"
case 46 : sCharacterStyle = "Rubytext"
case 49 : sCharacterStyle = "Rubys"
+ case 50 : sCharacterStyle = "Rubys"
case 55 : sCharacterStyle = "Rubys"
case 81 : sCharacterStyle = "ãµã‚ŠãŒãª"
case 82 : sCharacterStyle = "윗주 달기" ' not sure TBO
@@ -251,6 +252,7 @@ testcase tRubyDialog_5
case 39 : sCharacterStyle = "Testo Ruby"
case 46 : sCharacterStyle = "Rubytext"
case 49 : sCharacterStyle = "Rubys"
+ case 50 : sCharacterStyle = "Rubys"
case 55 : sCharacterStyle = "Rubys"
case 81 : sCharacterStyle = "ãµã‚ŠãŒãª"
case 82 : sCharacterStyle = "윗주 달기" ' not sure TBO was "ë§ë§"
diff --git a/testautomation/framework/optional/includes/basic_gridcontrol.inc b/testautomation/framework/optional/includes/basic_gridcontrol.inc
index dc96ef30e16c..f2d2f74cbdd4 100644..100755
--- a/testautomation/framework/optional/includes/basic_gridcontrol.inc
+++ b/testautomation/framework/optional/includes/basic_gridcontrol.inc
@@ -54,72 +54,18 @@ testcase tGridcontrolLoad
call sleep 1
printlog "Start the macro, that performs the test"
- printlog "Tools->Macros->Run Macro..."
- ToolsMacrosRunMacro
- Kontext "ScriptSelector"
- if ScriptSelector.exists(10) then
- x = LibraryTreeList.getItemCount
- printlog "Look for library 'gridcontrol'"
- for i = 1 to x
- sTemp = LibraryTreeList.getItemText(i)
- 'printlog "("+i+"/"+x+"): '" + sTemp + "'"
- if (instr(sTemp,"gridcontrol")>0 OR instr(sTemp,"GRIDCONTROL")) then
- a = i
- printlog "Found library ("+i+"/"+x+"): '" + sTemp + "'"
- endif
+ Kontext "GridControlDialogStarter"
+ ShowGridcontrol.typeKeys "<space>"
+ Kontext "GridControlDialog"
+ if GridControlDialog.exists(5) then
+ for i=1 to gridcontrolcontrol.getcolumncount
+ for a=1 to gridcontrolcontrol.getrowcount
+ printlog " " + i + ":"+a+": '" + gridcontrolcontrol.getitemtype (i,a) + "' '" + gridcontrolcontrol.getitemtext (i,a) + "'"
+ next a
next i
- if 0 <> a then
- printlog "Select the library and unfold it"
- LibraryTreeList.select(a)
- LibraryTreeList.typeKeys("+")
- printlog "Go to 'Standard' and unfold"
- LibraryTreeList.typeKeys("<down>")
- LibraryTreeList.typeKeys("+")
- printlog "Go to 'Module1'"
- LibraryTreeList.typeKeys("<down>")
-
- printlog "Select macro name 'VclTestTool'"
- x = ScriptList.getItemCount
- for i = 1 to x
- sTemp = ScriptList.getItemText(i)
- 'printlog "("+i+"/"+x+"): '" + sTemp + "'"
- if "VclTestTool" = sTemp then
- a = i
- printlog "Found macro ("+i+"/"+x+"): '" + sTemp + "'"
- endif
- next i
- if (0 <> a) then
- printlog "Select the macro"
- ScriptList.select(a)
- printlog "Start the macro by pressing the button 'run'"
- ScriptSelector.ok
- printlog "sleep... at least 60 seconds"
- call sleep(60)
- printlog "If macro fails for whatever reason, a message comes up"
- Kontext
- if active.exists() then
- warnlog "" + active.getText
- active.ok
- try
- EditCopy
- warnlog getclipboard()
- catch
- endcatch
- printlog "close basic ide"
- call hCloseDocument()
- printlog "close document"
- call hCloseDocument()
- goto endsub
- endif
-
- else
- warnlog sLocation + "Macro not found: 'Main'"
- endif
- else
- warnlog sLocation + "Library not found: 'gridcontrol'"
- endif
+ GridControlDialog.close
else
- warnlog sLocation + "'Run macro dialog' didn't came up"
+ warnlog "Gridcontrol Dialog did not come up after pressing button"
endif
printlog "clean up"
diff --git a/testautomation/framework/optional/includes/basic_issues.inc b/testautomation/framework/optional/includes/basic_issues.inc
index 0c38e743fb93..3fec49f61fbe 100644..100755
--- a/testautomation/framework/optional/includes/basic_issues.inc
+++ b/testautomation/framework/optional/includes/basic_issues.inc
@@ -54,7 +54,7 @@ function hTestActive( cString as string , iMethod as integer , bExact as boolean
' 1 - 4 = Number of buttons on the dialog
' internal states, if state = 0 we return the buttoncount instead
- const STATE_SUCCESS = 0
+ const STATE_SUCCESS = 0
const STATE_FUZZY_MATCH = -1
const STATE_NO_MATCH = -2
const STATE_IGNORE_MSGBOX = -3
@@ -111,6 +111,17 @@ end function
testcase t_macros()
+ const RESTYPE_1 = 1
+ const RESTYPE_2 = 2
+ const RESTYPE_3 = 3
+
+ const CLOSE_METHOD_OK = 1
+ const CLOSE_METHOD_CANCEL = 2
+ const CLOSE_METHOD_NO = 4
+
+ const REQUIRES_EXACT_MATCH = TRUE
+ const REQUIRES_FUZZY_MATCH = FALSE
+
gApplication = "WRITER"
call hNewDocument()
hInitBasicIDE( "TestIssues" )
@@ -119,113 +130,126 @@ testcase t_macros()
printlog( " ---------- i41695 ------------ " )
hInsertMacroFromFile( "i41695" )
hIDERunMacro()
- hTestActive( "i41695-1", 1 , TRUE )
- hTestActive( "i41695-2", 1 , TRUE )
+ hTestActive( "i41695-1", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "i41695-2", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
printlog( "" )
printlog( " ---------- i83978 ------------ " )
hInsertMacroFromFile( "i83978" )
hIDERunMacro()
- hTestActive( "com.sun.star.container.NoSuchElementException", 1 , FALSE )
+ hTestActive( "NoSuchElementException", CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i82830 ------------ " )
hInsertMacroFromFile( "i82830" )
hIDERunMacro()
- hTestActive( "12D687" , 1 , TRUE )
- hTestActive( "4553207", 1 , TRUE )
+ hTestActive( "12D687" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "4553207", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
if ( gISOLang = "en-US" ) then
printlog( "" )
printlog( " ---------- i81674 ------------ " )
hInsertMacroFromFile( "i81674" )
hIDERunMacro()
- hTestActive( "250" , 1 , FALSE )
- hTestActive( "Yes" , 1 , TRUE )
- hTestActive( "True", 1 , TRUE )
- hTestActive( "On" , 1 , TRUE )
+ hTestActive( "250" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "Yes" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "True", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "On" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
endif
printlog( "" )
printlog( " ---------- i80532 ------------ " )
hInsertMacroFromFile( "i80532" )
hIDERunMacro()
- hTestActive( "-10", 1 , FALSE )
- hTestActive( "1" , 1 , FALSE )
- hTestActive( "-10", 1 , FALSE )
+ hTestActive( "-10", CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "1" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "-10", CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i84040 ------------ " )
hInsertMacroFromFile( "i84040" )
hIDERunMacro()
- hTestActive( "False", 1 , TRUE )
- hTestActive( "False", 1 , TRUE )
+ hTestActive( "False", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "False", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
printlog( "" )
printlog( " ---------- i86265 ------------ " )
hInsertMacroFromFile( "i86265" )
hIDERunMacro()
- hTestActive( "i86265-1", 1 , TRUE )
- hTestActive( "i86265-2", 1 , TRUE )
+ hTestActive( "i86265-1", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+ hTestActive( "i86265-2", CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
printlog( "" )
printlog( " ---------- i92329 ------------ " )
hInsertMacroFromFile( "i92329" )
hIDERunMacro()
- hTestActive( "Return an Array" , 1 )
+ hTestActive( "Return an Array" , CLOSE_METHOD_OK )
printlog( "" )
printlog( " ---------- i97038 ------------ " )
hInsertMacroFromFile( "i97038" )
hIDERunMacro()
- hTestActive( "1900" , 1 , FALSE )
- hTestActive( "2" , 1 , FALSE )
+ hTestActive( "1900" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "2" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i103691 ------------ " )
hInsertMacroFromFile( "i103691" )
hIDERunMacro()
- hTestActive( "Equal" , 1 , FALSE )
+ hTestActive( "Equal" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i103697 ------------ " )
hInsertMacroFromFile( "i103697" )
hIDERunMacro()
- hTestActive( "i103697" , 1 , FALSE )
+ hTestActive( "i103697" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i103990 ------------ " )
hInsertMacroFromFile( "i103990" )
hIDERunMacro()
- hTestActive( "42" , 1 , FALSE )
- hTestActive( "43" , 1 , FALSE )
- hTestActive( "Pi" , 1 , FALSE )
+ hTestActive( "42" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "43" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "Pi" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
printlog( "" )
printlog( " ---------- i107070 ------------ " )
hInsertMacroFromFile( "i107070" )
hIDERunMacro()
- hTestActive( "Dbg_Methods" , 1 , FALSE )
- hTestActive( "Dbg_Methods" , 1 , FALSE )
- hTestActive( "." , 1 , FALSE )
+ hTestActive( "Dbg_Methods" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "Dbg_Methods" , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+ hTestActive( "." , CLOSE_METHOD_OK , REQUIRES_FUZZY_MATCH )
+
+ printlog( "" )
+ printlog( " ---------- i106744 ------------ " )
+ hInsertMacroFromFile( "i106744-1" )
+ hIDERunMacro()
+ hTestActive( "NOT EMPTY" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
+
+ printlog( "" )
+ printlog( " ---------- i106744 ------------ " )
+ hInsertMacroFromFile( "i106744-2" )
+ hIDERunMacro()
+ hTestActive( "NOT EMPTY" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH )
printlog( "" )
printlog( " ---------- MessageBoxes ------------ " )
hInsertMacroFromFile( "MessageBoxes" )
hIDERunMacro()
- if ( hTestActive( "0x" , 1 , TRUE ) > 1 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "1x" , 1 , TRUE ) > 2 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "2x" , 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "3x" , 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "4x" , 4 , TRUE ) > 2 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "5x" , 2 , TRUE ) > 2 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "16" , 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "32" , 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "48" , 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "64" , 1 , TRUE ) > 1 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "128", 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "256", 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
- if ( hTestActive( "512", 2 , TRUE ) > 3 ) then warnlog( "Wrong resource type" )
+
+ if ( hTestActive( "0x" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH ) <> RESTYPE_1 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "1x" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH ) <> RESTYPE_2 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "2x" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "3x" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "4x" , CLOSE_METHOD_NO , REQUIRES_EXACT_MATCH ) <> RESTYPE_2 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "5x" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_2 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "16" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "32" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "48" , CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "64" , CLOSE_METHOD_OK , REQUIRES_EXACT_MATCH ) <> RESTYPE_1 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "128", CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "256", CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
+ if ( hTestActive( "512", CLOSE_METHOD_CANCEL , REQUIRES_EXACT_MATCH ) <> RESTYPE_3 ) then warnlog( "Wrong resource type" )
printlog( "" )
hCloseBasicIDE()
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_application-union.inc b/testautomation/framework/optional/includes/basic_vba-compat_application-union.inc
new file mode 100755
index 000000000000..222b99215f81
--- /dev/null
+++ b/testautomation/framework/optional/includes/basic_vba-compat_application-union.inc
@@ -0,0 +1,132 @@
+'encoding UTF-8 Do not remove or change this line!
+'*******************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : Test VBA compatibility switches
+'*
+'\******************************************************************************
+
+testcase tBasicVBACompatApplicationUnion()
+
+ printlog( "Functionality of Application.Union" )
+ ' Based on issue #i110724
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = TRUE
+ const DOCUMENT_NAME = "vba-application-union.xls"
+ const LIBRARY_NAME = "Standard"
+ const MODULE_NAME = "Module1"
+ const EXPECTED_MACRO_COUNT = 6
+ const MAX_WAIT = 2
+ const RC_FAILURE = -1
+
+ dim macro_identifier( EXPECTED_MACRO_COUNT )
+ macro_identifier( 1 ) = "1: True"
+ macro_identifier( 2 ) = "2: True"
+ macro_identifier( 3 ) = "3: True"
+ macro_identifier( 4 ) = "4: True"
+ macro_identifier( 5 ) = "5: True"
+ macro_identifier( 6 ) = "6: True"
+
+ dim cTestFile as string
+ cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & DOCUMENT_NAME
+
+ dim iMacroPosition as integer
+ dim iCurrentMacro as integer
+ dim iRepeat as integer
+
+ printlog( "Set macro security to low" )
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
+
+ printlog( "Open Tools/Options" )
+ hSetExcelBasicImportMode( IMPORT_EXCEL_MACROS, EXEC_EXCEL_MACROS )
+
+ printlog( "Load the test file" )
+ hFileOpen( cTestFile )
+
+ ToolsMacro_uno
+
+ kontext "Makro"
+ if ( Makro.exists( MAX_WAIT ) ) then
+
+ iMacroPosition = hSelectNodeByName( MakroAus, DOCUMENT_NAME )
+ hExpandNode( MakroAus, iMacroPosition )
+
+ printlog( "Move to node <" & LIBRARY_NAME & ">" )
+ iMacroPosition = hSelectNextNode( MakroAus )
+ if ( not hVerifyNodeName( MakroAus, LIBRARY_NAME ) ) then
+ warnlog( "This is not the expected library" )
+ endif
+
+ printlog( "Move to node <" & MODULE_NAME & ">" )
+ hSelectNextNode( MakroAus )
+ if ( not hVerifyNodeName( MakroAus, MODULE_NAME ) ) then
+ warnlog( "This is not the expected module" )
+ endif
+
+ printlog( "Click <Ausfuehren> to execute the macro" )
+ if ( hClickButton( Ausfuehren ) <> RC_FAILURE ) then
+
+ printlog( "Check for the " & EXPECTED_MACRO_COUNT & " expected messageboxes" )
+ for iCurrentMacro = 1 to EXPECTED_MACRO_COUNT
+
+ printlog( "" )
+ kontext "Active"
+ printlog( iCurrentMacro & ": Check for messagebox: " & macro_identifier( iCurrentMacro ) )
+ if ( Active.exists( MAX_WAIT ) ) then
+
+ if ( Active.getText() = macro_identifier( iCurrentMacro ) ) then
+ printlog( "The expected macro was executed" )
+ else
+ warnlog( "Unexpected macro executed: " & Active.getText() )
+ endif
+ Active.ok()
+
+ else
+ warnlog( "Expected messagebox not displayed within reasonable timeframe" )
+ goto endsub
+ endif
+
+ next iCurrentMacro
+ else
+ warnlog( "Unable to execute macro, the <Run Macro> button is disabled" )
+ kontext "Makro"
+ Makro.close()
+ endif
+ else
+ warnlog( "Failed to open BASIC organizer" )
+ endif
+
+ printlog( "Cleanup" )
+ hCloseDocument()
+ hSetExcelImportModeDefault()
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT )
+
+endcase
+
+
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_import_disabled.inc b/testautomation/framework/optional/includes/basic_vba-compat_import_disabled.inc
index f5576308a6a9..764ba407236a 100755
--- a/testautomation/framework/optional/includes/basic_vba-compat_import_disabled.inc
+++ b/testautomation/framework/optional/includes/basic_vba-compat_import_disabled.inc
@@ -36,12 +36,23 @@ testcase tBasicVBACompatImportDisabled()
printlog( "Test VBA compatibility switch / executable Microsoft(R) Excel(R) Macros" )
printlog( "Test case 2: Import macros but do not set the executable mode" )
-
' This test case is based on the use cases provided in issue #i88690
' Spec: http://specs.openoffice.org/appwide/options_settings/Option_Dialog.odt
+
+ const NODE_COUNT = 78
+
+ const DOCUMENT_POSITION_OFFSET = -7
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = FALSE
+
+ const DOCUMENT_NAME = "vba-test.xls"
+ const MATCH_NONE = 0
+ const MATCH_EXACT = 1
+ const MATCH_PARTLY = 2
dim cTestFile as string
- cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/vba-test.xls"
+ cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & DOCUMENT_NAME
dim cNodeCount as integer
@@ -57,15 +68,6 @@ testcase tBasicVBACompatImportDisabled()
dim iCurrentModule as integer
dim cCurrentModule as string
dim bFound as boolean
-
- ' Depending on the mode of macro import we have differtent basic libraries listed
- const NODE_COUNT_OOO = 78 ' OpenOffice.org
- const NODE_COUNT = 80 ' branded product
-
- const DOCUMENT_POSITION_OFFSET = -7
-
- const IMPORT_EXCEL_MACROS = TRUE
- const EXEC_EXCEL_MACROS = FALSE
printlog( "Set macro security to low" )
hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
@@ -92,9 +94,11 @@ testcase tBasicVBACompatImportDisabled()
printlog( "Verify position of the document node" )
MakroAus.select( cNodeCount + DOCUMENT_POSITION_OFFSET )
- if ( MakroAus.getSelText() <> "vba-test.xls" ) then
- qaerrorlog( "The document node is not at the expected position" )
- endif
+ select case( hCompareSubStrings( MakroAus.getSelText(), DOCUMENT_NAME ) )
+ case MATCH_NONE : warnlog ( "The document is not listed at the expected position" )
+ case MATCH_EXACT : printlog( "The document is at the expected position and writable" )
+ case MATCH_PARTLY : printlog( "The document is at the expected position and write protected" )
+ end select
for iCurrentModule = 2 to 7
@@ -135,7 +139,6 @@ testcase tBasicVBACompatImportDisabled()
hSetExcelImportModeDefault()
hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT )
-
endcase
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_import_enabled.inc b/testautomation/framework/optional/includes/basic_vba-compat_import_enabled.inc
index 3e6450e4c2e7..98173ee8ba48 100755
--- a/testautomation/framework/optional/includes/basic_vba-compat_import_enabled.inc
+++ b/testautomation/framework/optional/includes/basic_vba-compat_import_enabled.inc
@@ -39,22 +39,40 @@ testcase tBasicVBACompatImportEnabled()
' This test case is based on the use cases provided in issue #i88690
' Spec: http://specs.openoffice.org/appwide/options_settings/Option_Dialog.odt
-
- dim cFile as string : cFile = "vba-test.xls"
+
+ ' Depending on the mode of macro import we have differtent basic libraries listed
+ const NODE_COUNT = 78
+
+ const DOCUMENT_POSITION_OFFSET = -7
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = TRUE
+
+ const DOCUMENT_NAME = "vba-test.xls"
+ const MATCH_NONE = 0
+ const MATCH_EXACT = 1
+ const MATCH_PARTLY = 2
dim cTestFile as string
- cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & cFile
+ cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & DOCUMENT_NAME
dim cNodeCount as integer
- ' note that index 0 and 1 are ommitted intentionally
- dim caNodeData( 3 ) as string
- caNodeData( 2 ) = "Modul1"
- caNodeData( 3 ) = "Modul2"
-
- dim caScripts( 3 ) as string
- caScripts( 2 ) = "ConcatFct Ende"
- caScripts( 3 ) = "WriteIt"
+ dim caNodeData( 7 ) as string
+ caNodeData( 0 ) = DOCUMENT_NAME ' The document, not used
+ caNodeData( 1 ) = "Standard" ' The default library, not used
+ caNodeData( 2 ) = "DieseArbeitsmappe"
+ caNodeData( 3 ) = "Modul1"
+ caNodeData( 4 ) = "Modul2"
+ caNodeData( 5 ) = "Tabelle1"
+ caNodeData( 6 ) = "Tabelle2"
+ caNodeData( 7 ) = "Tabelle3"
+
+ ' These are the scripts belonging to each node above. If multiple scripts exist
+ ' they are separated by spaces. Example: "Modul1" has "ConcatFct" and "Ende" scripts.
+ dim caScripts( 7 ) as string
+ caScripts( 3 ) = "ConcatFct Ende"
+ caScripts( 4 ) = "WriteIt"
dim iCurrentModule as integer
dim iCurrentScript as integer
@@ -62,19 +80,10 @@ testcase tBasicVBACompatImportEnabled()
dim cTempString as string
dim bFound as boolean
- ' Depending on the mode of macro import we have differtent basic libraries listed
- const NODE_COUNT_OOO = 74
- const NODE_COUNT = 76
-
- const DOCUMENT_POSITION_OFFSET = -3
-
- const IMPORT_EXCEL_MACROS = TRUE
- const EXEC_EXCEL_MACROS = TRUE
-
printlog( "Set macro security to low" )
hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
- printlog( "Open Tools/Options" )
+ printlog( "Open Tools/Options and set the VBA macro execution mode" )
hSetExcelBasicImportMode( IMPORT_EXCEL_MACROS, EXEC_EXCEL_MACROS )
@@ -96,26 +105,13 @@ testcase tBasicVBACompatImportEnabled()
printlog( "Verify position of the document node." )
MakroAus.select( cNodeCount + DOCUMENT_POSITION_OFFSET )
- cTempString = MakroAus.getSelText()
- if ( cTempString <> cFile ) then
- qaerrorlog( "The filename does not match. File may be read-only." )
- if ( instr( cTempString, cFile ) > 1 ) then
- printlog( "Filename is contained in the UI string." )
- select case ( getAttr( cTestFile ) )
- case 0 : warnlog( "The file appears to be read-only but it is " & _
- "not write-protected on filesystem level." )
- case 1 : printlog( "The file is read-only on filesystem level. Ok." )
- case else
- warnlog( "getAttr() returned unexpected value. 1 or 2 are allowed" )
- printlog( "RC from getAttr() is: " & getAttr( cTestFile ) )
- end select
- else
- qaerrorlog( "The document node is not at the expected position." )
- qaerrorlog( "Object at this position is: " & MakroAus.getSelText() )
- endif
- endif
+ select case( hCompareSubStrings( MakroAus.getSelText(), DOCUMENT_NAME ) )
+ case MATCH_NONE : warnlog ( "The document is not listed at the expected position" )
+ case MATCH_EXACT : printlog( "The document is at the expected position and writable" )
+ case MATCH_PARTLY : printlog( "The document is at the expected position and write protected" )
+ end select
- for iCurrentModule = 2 to 3
+ for iCurrentModule = 2 to 7
printlog( "Look for: " & caNodeData( iCurrentModule ) )
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_import_nothing.inc b/testautomation/framework/optional/includes/basic_vba-compat_import_nothing.inc
index bab6bf1a4b1b..50c59cf88e10 100755
--- a/testautomation/framework/optional/includes/basic_vba-compat_import_nothing.inc
+++ b/testautomation/framework/optional/includes/basic_vba-compat_import_nothing.inc
@@ -38,21 +38,24 @@ testcase tBasicVBACompatImportNothing()
' This test case is based on the use cases provided in issue #i88690
' Spec: http://specs.openoffice.org/appwide/options_settings/Option_Dialog.odt
-
- dim cTestFile as string
- cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/vba-test.xls"
-
- dim cNodeCount as integer
-
- ' Depending on the mode of macro import we have differtent basic libraries listed
- const NODE_COUNT = 74 ' Do not import Microsoft(R) Excel(R) macros at all
- const NODE_COUNT_OOO = 72
- const MACRO_LIST = 0 ' The document library should have no scripts listed
+' Depending on the mode of macro import we have differtent basic libraries listed
+ const NODE_COUNT = 72 ' Do not import Microsoft(R) Excel(R) macros at all
+ const MACRO_LIST = 0 ' The document library should have no scripts listed
const DOCUMENT_POSITION_OFFSET = -1
-
+
const IMPORT_EXCEL_MACROS = FALSE
const EXEC_EXCEL_MACROS = FALSE
-
+
+ const DOCUMENT_NAME = "vba-test.xls"
+ const MATCH_NONE = 0
+ const MATCH_EXACT = 1
+ const MATCH_PARTLY = 2
+
+ dim cTestFile as string
+ cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & DOCUMENT_NAME
+
+ dim cNodeCount as integer
+
printlog( "Set macro security to low" )
hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
@@ -78,9 +81,11 @@ testcase tBasicVBACompatImportNothing()
printlog( "Verify position of the document node" )
MakroAus.select( cNodeCount + DOCUMENT_POSITION_OFFSET )
- if ( MakroAus.getSelText() <> "vba-test.xls" ) then
- qaerrorlog( "The document node is not at the expected position" )
- endif
+ select case( hCompareSubStrings( MakroAus.getSelText(), DOCUMENT_NAME ) )
+ case MATCH_NONE : warnlog ( "The document is not listed at the expected position" )
+ case MATCH_EXACT : printlog( "The document is at the expected position and writable" )
+ case MATCH_PARTLY : printlog( "The document is at the expected position and write protected" )
+ end select
printlog( "Select the last node, this should be the standard Library for the document" )
MakroAus.select( cNodeCount )
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_security_check.inc b/testautomation/framework/optional/includes/basic_vba-compat_security_check.inc
new file mode 100644
index 000000000000..ae26d996db6e
--- /dev/null
+++ b/testautomation/framework/optional/includes/basic_vba-compat_security_check.inc
@@ -0,0 +1,105 @@
+'encoding UTF-8 Do not remove or change this line!
+'*******************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : Test VBA compatibility switches
+'*
+'\******************************************************************************
+
+testcase tBasicVBACompatSecurityCheck()
+
+ printlog( "Test VBA Security feature" )
+ printlog( "VBA macros may not ignore global macro security setting" )
+
+ ' This test case is based on the use cases provided in issue #i109699
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = TRUE
+
+ const MACRO_IDENTIFICATION_MESSAGE = "Clicked"
+ const MACRO_NAME = "CommandButton1_Click"
+
+ const WORK_FILE = "framework/optional/input/vba-compat/Book1.xls"
+
+ dim cTestFile as string : cTestFile = gTesttoolPath & WORK_FILE
+ dim iSecurityLevel as integer
+
+
+ printlog( "Set VBA macro handling to import and execute" )
+ hSetExcelBasicImportMode( IMPORT_EXCEL_MACROS, EXEC_EXCEL_MACROS )
+
+ for iSecurityLevel = GC_MACRO_SECURITY_LEVEL_MEDIUM to GC_MACRO_SECURITY_LEVEL_VERYHIGH
+
+ printlog( "Adjust security level" )
+ hSetMacroSecurityAPI( iSecurityLevel )
+
+ printlog( "Load the test file" )
+ hFileOpen( cTestFile )
+
+ printlog( "Deny macro execution or close macros blocked message" )
+ if ( iSecurityLevel = GC_MACRO_SECURITY_LEVEL_MEDIUM ) then
+ hDenyMacroExecution()
+ else
+ kontext "Active"
+ Active.ok()
+ endif
+
+ printlog( "Try to execute macro via macro organizer" )
+ hMacroOrganizerRunMacro( MACRO_NAME )
+
+ printlog( "Probe for warning message (or macro)" )
+ kontext "Active"
+ if ( Active.exists( 2 ) ) then
+ if ( Active.getText() = MACRO_IDENTIFICATION_MESSAGE ) then
+ warnlog( "Macro was executed though macro execution has been denied" )
+ Active.ok()
+ else
+ printlog( "Macro execution blocked - warning is displayed." )
+ Active.ok()
+ endif
+ else
+ warnlog( "No warning message for blocked macro execution" )
+ endif
+
+ ' recover silently, the warnings above should say it all.
+ kontext "Makro"
+ if ( Makro.exists() ) then Makro.cancel()
+
+ printlog( "Close file" )
+ hDestroyDocument()
+
+ next iSecurityLevel
+
+ printlog( "Reset VBA import options to default" )
+ hSetExcelImportModeDefault()
+
+ printlog( "Reset macro security level to default" )
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT )
+
+endcase
+
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_thisworkbook.inc b/testautomation/framework/optional/includes/basic_vba-compat_thisworkbook.inc
new file mode 100755
index 000000000000..03c52146a8fb
--- /dev/null
+++ b/testautomation/framework/optional/includes/basic_vba-compat_thisworkbook.inc
@@ -0,0 +1,143 @@
+'encoding UTF-8 Do not remove or change this line!
+'*******************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : Test VBA compatibility switches
+'*
+'\******************************************************************************
+
+testcase tBasicVBACompatThisWorkBook()
+
+ printlog( "Functionality of .thisWorkbook" )
+ ' Based on issue #i110672
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = TRUE
+ const DOCUMENT_NAME = "vba-thisworkbook.xls"
+ const LIBRARY_NAME = "Standard"
+ const MODULE_NAME = "Module1"
+ const EXPECTED_MACRO_COUNT = 2
+ const MAX_REPEAT_COUNT = 2
+ const MAX_WAIT = 2
+
+ dim macro_identifier( EXPECTED_MACRO_COUNT )
+ macro_identifier( 1 ) = "Test 1 passed."
+ macro_identifier( 2 ) = "Test 2 passed."
+
+ dim cTestFile as string
+ cTestFile = gTesttoolPath & "framework/optional/input/vba-compat/" & DOCUMENT_NAME
+
+ dim iMacroPosition as integer
+ dim iCurrentMacro as integer
+ dim iRepeat as integer
+
+ printlog( "Set macro security to low" )
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
+
+ printlog( "Open Tools/Options" )
+ hSetExcelBasicImportMode( IMPORT_EXCEL_MACROS, EXEC_EXCEL_MACROS )
+
+ printlog( "Load the test file" )
+ hFileOpen( cTestFile )
+
+ printlog( "Execute the procedure twice to trigger issue 111553" )
+ for iRepeat = 1 to MAX_REPEAT_COUNT
+
+ ToolsMacro_uno
+
+ kontext "Makro"
+ if ( Makro.exists( MAX_WAIT ) ) then
+
+ iMacroPosition = hSelectNodeByName( MakroAus, DOCUMENT_NAME )
+ hExpandNode( MakroAus, iMacroPosition )
+
+ printlog( "Move to node <" & LIBRARY_NAME & ">" )
+ iMacroPosition = hSelectNextNode( MakroAus )
+ if ( not hVerifyNodeName( MakroAus, LIBRARY_NAME ) ) then
+ warnlog( "This is not the expected library" )
+ endif
+
+ printlog( "Move to node <" & MODULE_NAME & ">" )
+ hSelectNextNode( MakroAus )
+ if ( not hVerifyNodeName( MakroAus, MODULE_NAME ) ) then
+ warnlog( "This is not the expected module" )
+ endif
+
+ printlog( "Click <Ausfuehren> to execute the macro" )
+ iMacroPosition = hClickButton( Ausfuehren )
+
+ printlog( "Check for two expected messageboxes" )
+ for iCurrentMacro = 1 to EXPECTED_MACRO_COUNT
+
+ kontext "Active"
+ printlog( "Check for messagebox: " & macro_identifier( iCurrentMacro ) )
+ if ( Active.exists( MAX_WAIT ) ) then
+
+ if ( Active.getText() = macro_identifier( iCurrentMacro ) ) then
+ printlog( "Correct macro executed" )
+ else
+ printlog( "Macro execution error, trying to identify..." )
+ if ( instr( Active.getText(), "BASIC runtime error." ) > 0 ) then
+ if ( iRepeat = MAX_REPEAT_COUNT ) then
+ warnlog( "#i111533 - Cannot execute ThisWorkbook macro twice" )
+ Active.ok()
+ hFileCloseAll()
+ goto endsub
+ else
+ warnlog( "Executing macro failed" )
+ goto endsub
+ endif
+ else
+ warnlog( "Unknown messagebox. Aborting test" )
+ goto endsub
+ endif
+ endif
+
+ Active.ok()
+
+ else
+ warnlog( "Expected messagebox not displayed within reasonable timeframe" )
+ goto endsub
+ endif
+
+ next iCurrentMacro
+ else
+ warnlog( "A macro with the name <" & MODULE_NAME & "> could not be found" )
+ goto endsub
+ endif
+
+ next iRepeat
+
+ printlog( "Cleanup" )
+ hCloseDocument()
+ hSetExcelImportModeDefault()
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT )
+
+endcase
+
+
diff --git a/testautomation/framework/optional/includes/basic_vba-compat_xlsm-xlsb.inc b/testautomation/framework/optional/includes/basic_vba-compat_xlsm-xlsb.inc
new file mode 100755
index 000000000000..cfc8f06072e3
--- /dev/null
+++ b/testautomation/framework/optional/includes/basic_vba-compat_xlsm-xlsb.inc
@@ -0,0 +1,187 @@
+'encoding UTF-8 Do not remove or change this line!
+'*******************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/******************************************************************************
+'*
+'* owner : joerg.skottke@sun.com
+'*
+'* short description : Test VBA compatibility switches
+'*
+'\******************************************************************************
+
+testcase tBasicVBACompatXLSM_XLSB()
+
+ printlog( "Functionality of macros in XLSM/XLSB files" )
+ ' Based on issue #i111007
+
+ const IMPORT_EXCEL_MACROS = TRUE
+ const EXEC_EXCEL_MACROS = TRUE
+
+ const FILE_COUNT = 2
+ const MODULE_COUNT = 7
+
+ const MODULE_NOT_FOUND = 0
+ const MAX_DELAY = 3
+ const RC_TIMEOUT = -1
+
+ const THE_MODULE_THAT_BEHAVES_DIFFERENTLY = 6
+
+ const RELATIVE_PATH = "framework/optional/input/vba-compat/"
+
+ ' We have two files to load, on e .xlsm and one .xlsb
+ dim cFileList( FILE_COUNT ) as string
+ cFileList( 1 ) = "vba-project.xlsm"
+ cFileList( 2 ) = "vba-project.xlsb"
+
+ ' both documents import the same modules
+ dim cTestModuleList( MODULE_COUNT )
+ cTestModuleList( 1 ) = "MyChartModule"
+ cTestModuleList( 2 ) = "MyCodeModule"
+ cTestModuleList( 3 ) = "MyPrivateClassModule"
+ cTestModuleList( 4 ) = "MyPublicClassModule"
+ cTestModuleList( 5 ) = "MySheetModule"
+ cTestModuleList( 6 ) = "MyUserForm"
+ cTestModuleList( 7 ) = "MyWorkbookModule"
+
+ dim cTestFile as string
+ dim iCurrentFile as integer
+ dim iCurrentModule as integer
+
+ printlog( "Set macro security to low" )
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
+
+ printlog( "Open Tools/Options" )
+ hSetExcelBasicImportMode( IMPORT_EXCEL_MACROS, EXEC_EXCEL_MACROS )
+
+ for iCurrentFile = 1 to FILE_COUNT
+
+ cTestFile = gTesttoolPath & RELATIVE_PATH & cFileList( iCurrentFile )
+
+ printlog( "Loading document: " & cTestFile )
+ hFileOpen( cTestFile )
+
+ for iCurrentModule = 1 to MODULE_COUNT
+
+ printlog( "" )
+ printlog( "Tryng to execute macro: " & cTestModuleList( iCurrentModule ) )
+ ToolsMacro_uno
+
+ kontext "Makro"
+ if ( Makro.exists( MAX_DELAY ) ) then
+
+ if ( hSelectNodeByName( MakroAus, cTestModuleList( iCurrentModule ) ) <> MODULE_NOT_FOUND ) then
+
+ printlog( "Execute the default macro <Test> for the current module" )
+
+ if ( hClickButton( Ausfuehren ) <> RC_TIMEOUT ) then
+ if ( iCurrentModule = THE_MODULE_THAT_BEHAVES_DIFFERENTLY ) then
+ ' Fuzzy matching message string
+ hTestMacroType2( cTestModuleList( iCurrentModule ) )
+ else
+ ' Exact matching message string
+ hTestMacroType1( cTestModuleList( iCurrentModule ) )
+ endif
+ else
+ warnlog( "No executable macro found for the current module / <Run> button is disabled" )
+ endif
+ else
+ warnlog( "the expected macro module could not be found" )
+ endif
+ else
+ warnlog( "BASIC Macro organizer did not open" )
+ endif
+
+ next iCurrentModule
+
+ printlog( "Close the document" )
+ hFileCloseAll()
+
+ next iCurrentFile
+
+ hSetExcelImportModeDefault()
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT )
+
+endcase
+
+'*******************************************************************************
+
+function hTestMacroType1( cMessage as string ) as boolean
+
+ ' exact matching
+
+ kontext "Active"
+ if ( Active.exists( 2 ) ) then
+ if ( Active.getText() = cMessage ) then
+ printlog( "Correct macro has been executed" )
+ hTestMacroType1() = true
+ else
+ warnlog( "Incorrect macro executed: " )
+ printlog( "Expected: " & cMessage )
+ printlog( "Found...: " & Active.getText() )
+ hTestMacroType1() = false
+ endif
+
+ Active.ok()
+ WaitSlot()
+
+ else
+ warnlog( "Messagebox missing, macro was not executed" )
+ hTestMacroType1() = false
+ endif
+
+end function
+
+'*******************************************************************************
+
+function hTestMacroType2( cMessage as string ) as boolean
+
+ ' fuzzy matching
+
+ dim iCurrentMessage as integer
+
+ for iCurrentMessage = 1 to 2
+
+ kontext "Active"
+ if ( Active.exists( 2 ) ) then
+ if ( instr( Active.getText() , cMessage ) > 0 ) then
+ printlog( "Correct macro has been executed" )
+ hTestMacroType2() = true
+ else
+ warnlog( "Incorrect macro executed: " )
+ printlog( "Expected: " & cMessage )
+ printlog( "Found...: " & Active.getText() )
+ hTestMacroType2() = false
+ endif
+
+ Active.ok()
+ WaitSlot()
+
+ else
+ warnlog( "Messagebox missing, macro not executed" )
+ hTestMacroType2() = false
+ endif
+ next iCurrentMessage
+
+end function \ No newline at end of file
diff --git a/testautomation/framework/optional/includes/configuration.inc b/testautomation/framework/optional/includes/configuration.inc
index 68c0aaf79082..fba0a6fe6bae 100644..100755
--- a/testautomation/framework/optional/includes/configuration.inc
+++ b/testautomation/framework/optional/includes/configuration.inc
@@ -253,8 +253,8 @@ testcase tToolsOptionsAPIConfiguration
case 07 : iJump = 0 ' Russian
case 30 : iJump = 0 ' Greek
case 31 : iJump = 0 ' Netherlands
- case 33 : iJump = 0 ' French
- case 34 : iJump = 0 ' Spanish
+ case 33 : iJump = 0 ' French
+ case 34 : iJump = 0 ' Spanish
case 35 : iJump = 0 ' Finnish
case 36 : iJump = 0 ' Hungaria
case 37 : iJump = 0 ' Catalan
@@ -263,20 +263,21 @@ testcase tToolsOptionsAPIConfiguration
case 43 : iJump = 0 ' Slowak
case 44 : iJump = 0 ' English (GB)
case 45 : iJump = 0 ' Danish
- case 46 : iJump = 0 ' Swedish
+ case 46 : iJump = 0 ' Swedish
case 47 : iJump = 0 ' Norwegian
case 48 : iJump = 0 ' Polish
case 49 : iJump = 1 ' German
case 51 : iJump = 0 ' Slowak
- case 55 : iJump = 0 ' Portuguese (Brazil)
- case 66 : iJump = 0 ' Thai
+ case 50 : iJump = 0 ' Slovenian
+ case 55 : iJump = 0 ' Portuguese (Brazil)
+ case 66 : iJump = 0 ' Thai
case 81 : iJump = 0 ' Japanese ' disabled, because locale dependant!
case 82 : iJump = 0 ' Korean ' disabled, because locale dependant!
case 86 : iJump = 0 ' Chinese (simplified) ' disabled, because locale dependant!
case 88 : iJump = 0 ' Chinese (traditional) ' disabled, because locale dependant!
case 90 : iJump = 0 ' Turkish
case 91 : iJump = 0 ' Hindi
- case 96 : iJump = 0 ' Arab
+ case 96 : iJump = 0 ' Arab
case 97 : iJump = 0 ' Hebrew
case else : qaErrorlog "The work-dir can't changed to the internal office-work-dir! Please insert the language in this list!"
iJump = 0
diff --git a/testautomation/framework/optional/input/gridcontrol.odt b/testautomation/framework/optional/input/gridcontrol.odt
index b3e5c6fb40bb..d11d70cfbc09 100755
--- a/testautomation/framework/optional/input/gridcontrol.odt
+++ b/testautomation/framework/optional/input/gridcontrol.odt
Binary files differ
diff --git a/testautomation/framework/optional/input/vba-compat/Book1.xls b/testautomation/framework/optional/input/vba-compat/Book1.xls
new file mode 100644
index 000000000000..425c2e0687b0
--- /dev/null
+++ b/testautomation/framework/optional/input/vba-compat/Book1.xls
Binary files differ
diff --git a/testautomation/framework/optional/input/vba-compat/vba-application-union.xls b/testautomation/framework/optional/input/vba-compat/vba-application-union.xls
new file mode 100755
index 000000000000..b1f1be816b7b
--- /dev/null
+++ b/testautomation/framework/optional/input/vba-compat/vba-application-union.xls
Binary files differ
diff --git a/testautomation/framework/optional/input/vba-compat/vba-project.xlsb b/testautomation/framework/optional/input/vba-compat/vba-project.xlsb
new file mode 100755
index 000000000000..9fd88a8e545c
--- /dev/null
+++ b/testautomation/framework/optional/input/vba-compat/vba-project.xlsb
Binary files differ
diff --git a/testautomation/framework/optional/input/vba-compat/vba-project.xlsm b/testautomation/framework/optional/input/vba-compat/vba-project.xlsm
new file mode 100755
index 000000000000..6a8896e18599
--- /dev/null
+++ b/testautomation/framework/optional/input/vba-compat/vba-project.xlsm
Binary files differ
diff --git a/testautomation/framework/optional/input/vba-compat/vba-thisworkbook.xls b/testautomation/framework/optional/input/vba-compat/vba-thisworkbook.xls
new file mode 100644
index 000000000000..f275fd9cca0e
--- /dev/null
+++ b/testautomation/framework/optional/input/vba-compat/vba-thisworkbook.xls
Binary files differ
diff --git a/testautomation/framework/required/includes/printer_administration.inc b/testautomation/framework/required/includes/printer_administration.inc
index bc9838f6063d..a05ecc6b02a1 100644..100755
--- a/testautomation/framework/required/includes/printer_administration.inc
+++ b/testautomation/framework/required/includes/printer_administration.inc
@@ -103,8 +103,6 @@ testcase t_updt_spadmin
warnlog( "SpAdmin is not open, the test cannot continue" )
goto endsub
endif
-
- call TestFonts( CPRINTER )
' wait for the spadmin to open, on failure we end the test
brc = hWaitForSpAdmin()
@@ -270,42 +268,4 @@ sub TestRename( cPrinter as string )
printlog( "" )
-end sub
-
-'*******************************************************************************
-
-sub TestFonts( cPrinter as string )
-
-
- printlog( " * Open 'Fonts...' dialog" )
-
- Kontext "SpAdmin"
- if ( PBFonts.isEnabled() ) then
- PBFonts.click()
- waitslot
-
- printlog( " * Test the font-dialog" )
- Kontext "SPFontNameDLG"
- call dialogtest( SPFontNameDLG )
-
- printlog( " * Press 'Add ...'" )
- PBAdd.click()
- waitslot
-
- printlog( " * Test the import-dialog" )
- kontext "SPFontImportDLG"
- call dialogtest( SPFontImportDLG )
-
- printlog( " * close import dialog" )
- SPFontImportDLG.cancel()
-
- Kontext "SPFontNameDLG"
- printlog( " * close fonts-dialog" )
- SPFontNameDLG.ok()
- waitslot
- else
- printlog( "Fonts... not available, skipping." )
- endif
-
-
-end sub
+end sub \ No newline at end of file
diff --git a/testautomation/framework/tools/includes/CJK_tools.inc b/testautomation/framework/tools/includes/CJK_tools.inc
index bea675f69bc3..e905b55bbebc 100644..100755
--- a/testautomation/framework/tools/includes/CJK_tools.inc
+++ b/testautomation/framework/tools/includes/CJK_tools.inc
@@ -211,6 +211,23 @@ function fGetCountryName( CountryID as Integer ) as String
QAErrorLog "Now, the test does not support for the language " +iSprache
fGetCountryName = ""
end select
+ case 50 : ' Slovenian
+ select case CountryID
+ case 1: fGetCountryName = "angleški (ZDA)"
+ case 33: fGetCountryName = "francoski (Francija)"
+ case 34: fGetCountryName = "Å¡panski (Å panija)"
+ case 39: fGetCountryName = "italijanski (Italija)"
+ case 46: fGetCountryName = "Å¡vedski (Å vedska)"
+ case 49: fGetCountryName = "nemÅ¡ki (NemÄija)"
+ case 55: fGetCountryName = "portugalski (Brazilija)"
+ case 81: fGetCountryName = "japonski"
+ case 82: fGetCountryName = "korejski (RK)"
+ case 86: fGetCountryName = "kitajski (poenostavljeni)"
+ case 88: fGetCountryName = "kitajski (tradicionalni)"
+ case else :
+ QAErrorLog "Now, the test does not support for the language " +iSprache
+ fGetCountryName = ""
+ end select
case 55 : ' Portuguese
select case CountryID
case 1: fGetCountryName = "Inglês (EUA)"
diff --git a/testautomation/framework/tools/input/i18ndata.txt b/testautomation/framework/tools/input/i18ndata.txt
index 5e10d47c33c9..f8b9f88410a9 100755
--- a/testautomation/framework/tools/input/i18ndata.txt
+++ b/testautomation/framework/tools/input/i18ndata.txt
@@ -15,6 +15,7 @@
46=swedish
48=polish
49=german
+50=slovenian
55=portuguese brazilian
81=japanese
82=korean
@@ -36,6 +37,7 @@
46=sv
48=pl
49=de
+50=sl
55=pt-BR
81=ja
82=ko
diff --git a/testautomation/global/input/macros.txt b/testautomation/global/input/macros.txt
index ffe95be431e3..e0423fec3858 100755
--- a/testautomation/global/input/macros.txt
+++ b/testautomation/global/input/macros.txt
@@ -279,3 +279,48 @@ Sub Main
' Uncommenting this should result in an error "Invalid procedure call"
oInstanceErr1 = oSingleton.get( 42 )
End Sub
+
+# ---------------------------------------------------------------------------- #
+
+[i106744-1]
+sub main
+ msgbox test1()
+end sub
+
+Function test1() As String
+
+ Dim foo As String : foo = "astring"
+
+ On Error Resume Next
+ test1 = "GOT ERROR"
+ If IsEmpty(foo) Then
+ test1 = "EMPTY"
+ Else
+ test1 = "NOT EMPTY"
+ End If
+
+End Function
+
+# ---------------------------------------------------------------------------- #
+
+[i106744-2]
+option VBASupport 1
+
+sub main
+ msgbox test1()
+end sub
+
+Function test1() As String
+
+ Dim foo As String : foo = "astring"
+
+ On Error Resume Next
+ test1 = "GOT ERROR"
+ If IsEmpty(foo) Then
+ test1 = "EMPTY"
+ Else
+ test1 = "NOT EMPTY"
+ End If
+
+End Function
+
diff --git a/testautomation/global/input/officeinfo.txt b/testautomation/global/input/officeinfo.txt
index dc334737d048..240e166be84b 100644
--- a/testautomation/global/input/officeinfo.txt
+++ b/testautomation/global/input/officeinfo.txt
@@ -1,6 +1,6 @@
[Current program versions]
-StarOffice=9
-StarSuite=9
+Oracle Open Office=3.2
OpenOffice.org=3.1
BrOffice.org=3.1
+Oracle Open Office=3.2
diff --git a/testautomation/global/sid/e_all.sid b/testautomation/global/sid/e_all.sid
index d88cb9815bb1..b9fa2d9c81e8 100755..100644
--- a/testautomation/global/sid/e_all.sid
+++ b/testautomation/global/sid/e_all.sid
@@ -256,7 +256,7 @@ ViewSnapLinesFront SID_HELPLINES_FRONT
ViewStatusBarVisible .uno:StatusBarVisible
ViewShowImeStatusWindow .uno:ShowImeStatusWindow
ViewShowRuler .uno:ShowRuler
-ViewTaskPane .uno:RightPane
+ViewTaskPane .uno:TaskPane
ViewTaskSlide .uno:LeftPaneImpress
ViewTitle SID_TITLE_MASTERPAGE
ViewToolbarsOptionbar .uno:AvailableToolbars?Toolbar:string=optionsbar
diff --git a/testautomation/global/system/includes/iniinfo.inc b/testautomation/global/system/includes/iniinfo.inc
index 10831114d1e3..8a2807269152 100755
--- a/testautomation/global/system/includes/iniinfo.inc
+++ b/testautomation/global/system/includes/iniinfo.inc
@@ -120,12 +120,14 @@ sub GetIniInformation
gOOoStartupTimeOut = fgetOOoStartupTimeOut()
gOOoShutdownTimeOut = fgetOOoShutdownTimeOut()
call sCheckValgrindStatus()
+ ' set a global path for custom scripts, like basepath, but outside of current environment
gPrivateEnvironmentLocation = getIniValue(gTesttoolIni, "PrivateEnvironment", "Current")
- sTemp = ConvertPath (gTestToolPath + gPrivateEnvironmentLocation + "inc/privateenvironment.inc")
- if fileExists(sTemp) then
- use sTemp
- call getUseFilesPrivateEnvironment
- else
+ if (gPrivateEnvironmentLocation <> "" AND gPrivateEnvironmentLocation <> ".") then
+ if NOT fileExists(gPrivateEnvironmentLocation) then
+ qaErrorLog "[PrivateEnvironment] defined in: '"+gTesttoolIni+"', but the path '"+gPrivateEnvironmentLocation+"'does not exist!"
+ else
+ gPrivateEnvironmentLocation = ""
+ end if
gPrivateEnvironmentLocation = ""
end if
end sub
@@ -334,6 +336,7 @@ sub GetLanguageInformation
case "no_no", "no-no", "no" : iSprache = 47 ' Norwegian
case "pl_pl", "pl-pl", "pl" : iSprache = 48 ' Polish
case "de_de", "de-de", "de" : iSprache = 49 ' German
+ case "sl_si", "sl-si", "sl" : iSprache = 50 ' Slovenian
case "sr_rs", "sr-rs", "sr" : iSprache = 51 ' Serbian (Cyrillic)
case "sh_rs", "sh-rs", "sh" : iSprache = 52 ' Serbian (Latin)
case "pt_br", "pt-br", "br" : iSprache = 55 ' Portuguese (Brazil)
@@ -347,7 +350,6 @@ sub GetLanguageInformation
case "hi_in", "hi-in", "hi" : iSprache = 91 ' Hindi
case "ar_ar", "ar-ar", "ar" : iSprache = 96 ' Arabic
case "he_he", "he-he", "he" : iSprache = 97 ' Hebrew
- case "sl_si", "sl-si", "sl" : iSprache = 386 ' Slovenian
case "zz_zz", "zz-zz", "zz" : iSprache = 01 ' unknown
warnlog "iniinfo.inc::GetLanguageInformation()"
warnlog "- sLanOutIni = " & sLanOutIni & " (unknown language)"
@@ -397,7 +399,8 @@ function ConvertLanguage ( Sprache as String ) as Integer
case "daenisch", "danish" : ConvertLanguage = 45
case "schwedisch", "swedish" : ConvertLanguage = 46
case "norwegian", "norwegisch" : ConvertLanguage = 47
- case "polnisch", "polish" : ConvertLanguage = 48
+ case "polnisch", "polish" : ConvertLanguage = 48
+ case "slovenian", "slovenisch" : ConvertLanguage = 50
case "serbisch kyrillisch", "serbian cyrillic" : ConvertLanguage = 51
case "serbisch latein", "serbian latin" : ConvertLanguage = 52
case "japanisch", "japanese" : ConvertLanguage = 81
@@ -408,7 +411,6 @@ function ConvertLanguage ( Sprache as String ) as Integer
case "tuerkisch", "turkish" : ConvertLanguage = 90
case "arabisch", "arab" : ConvertLanguage = 96
case "catalan", "katalanisch" : ConvertLanguage = 99
- case "slovenian", "slovenisch" : ConvertLanguage = 386
end select
end function
@@ -436,6 +438,7 @@ function GetLanguageText ( iLan ) as String
case 47 : GetLanguageText = "Norwegian"
case 48 : GetLanguageText = "Polnish"
case 49 : GetLanguageText = "German"
+ case 50 : GetlanguageText = "Slovenian"
case 51 : GetlanguageText = "Serbian (Cyrillic)"
case 52 : GetlanguageText = "Serbian (Latin)"
case 55 : GetLanguageText = "Portuguese (Brazil)"
@@ -450,7 +453,6 @@ function GetLanguageText ( iLan ) as String
case 96 : GetLanguageText = "Arabic"
case 97 : GetLanguageText = "Hebrew"
case 99 : GetLanguageText = "Unknown"
- case 386 : GetlanguageText = "Slovenian"
case else : GetLanguageText = "detection failed"
end select
end function
@@ -480,6 +482,7 @@ function ConvertLanguage2 ( sSprache as String, optional bExact ) as Integer
case "no_no", "no-no", "no" : ConvertLanguage2 = 47 ' Norwegian
case "pl_pl", "pl-pl", "pl" : ConvertLanguage2 = 48 ' Polish
case "de_de", "de-de", "de" : ConvertLanguage2 = 49 ' German
+ case "sl_si", "sl-si", "sl" : ConvertLanguage2 = 50 ' Slovenian
case "sr_rs", "sr_rs", "sr" : ConvertLanguage2 = 51 ' Serbian (Cyrillic)
case "sh_rs", "sh_rs", "sh" : ConvertLanguage2 = 52 ' Serbian (Latin)
case "pt_br", "pt-br", "br" : ConvertLanguage2 = 55 ' Portuguese (Brazil)
@@ -493,7 +496,6 @@ function ConvertLanguage2 ( sSprache as String, optional bExact ) as Integer
case "hi_in", "hi-in", "hi" : ConvertLanguage2 = 91 ' Hindi
case "ar_ar", "ar-ar", "ar" : ConvertLanguage2 = 96 ' Arabic
case "he_he", "he-he", "he" : ConvertLanguage2 = 97 ' Hebrew
- case "sl_si", "sl-si", "sl" : ConvertLanguage2 = 386
case "zz_zz", "zz-zz", "zz" : ConvertLanguage2 = 01 ' unknown
case else : if isMissing (bExact) then
printlog "iniinfo.inc::ConvertLanguage2(): Unknown systemlanguage '" & sSprache & "'!"
@@ -535,6 +537,7 @@ function ConvertCodeToLanguage ( sSprache as String ) as Integer
case "2047" : ConvertCodeToLanguage = 47 ' Norwegian
case "1045" : ConvertCodeToLanguage = 48 ' Polish
case "1031" : ConvertCodeToLanguage = 49 ' German
+ case "1060" : ConvertCodeToLanguage = 50 ' Slovenian
case " " : ConvertCodeToLanguage = 55 ' Portuguese (Brazil)
case "3098" : ConvertCodeToLanguage = 51 ' Serbian (Cyriliic)
case "2074" : ConvertCodeToLanguage = 52 ' Serbian (Latin)
@@ -548,7 +551,6 @@ function ConvertCodeToLanguage ( sSprache as String ) as Integer
' case " " : ConvertCodeToLanguage = 91 ' Hindi
case "1025" : ConvertCodeToLanguage = 96 ' Arabic
' case " " : ConvertCodeToLanguage = 97 ' Hebrew
- case "1060" : ConvertCodeToLanguage = 386 ' Slovenian
case else : printlog "iniinfo.inc::ConvertCodeToLanguage(): Num. Code could not be detect or is unknown and will be set to 01 (English (USA))!"
ConvertCodeToLanguage = 01
end select
diff --git a/testautomation/global/system/includes/master.inc b/testautomation/global/system/includes/master.inc
index d349c3737d91..9e693eea445e 100755
--- a/testautomation/global/system/includes/master.inc
+++ b/testautomation/global/system/includes/master.inc
@@ -102,35 +102,6 @@ sub GetUseFiles
gTestToolPath = gRemotePath
end if
-'/// Load private environment dependant settings
-'/// BaseDirectory is the setting from the TestTool application at Extra->Settings->Profile->Base directory
-'/// This path is available in the global variable: gTestToolPath
-'/// The private environment location directory is taken from the file BaseDirectory+errorlog/privateenvironment.txt
-'/// The default file is taken from cvs: qa/qatesttool/errorlog/privateenvironment.txt
-'/// The default content is:
-'/// >[PrivateEnvironment]
-'/// >Current=global/private/
-'/// The path is defined relative to BaseDirectory and put into the global variable: gPrivateEnvironmentLocation
-'/// At the resulting path of BaseDirectory + gPrivateEnvironmentLocation + 'inc/' there has to exist the file: privateenvironment.inc
-'/// with at least the sub: getUseFilesPrivateEnvironment which will get executed
-
- if (gPrivateEnvironmentLocation = "") then
- sPrivateEnvironmentLocation = ConvertPath (gTestToolPath + "errorlog\privateenvironment.txt")
- if fileExists(sPrivateEnvironmentLocation) then
- gPrivateEnvironmentLocation = getIniValue(sPrivateEnvironmentLocation, "PrivateEnvironment", "Current")
- ' TODO: remove trailing path character
- else
- gPrivateEnvironmentLocation = "global/private/"
- end if
- sTemp = ConvertPath (gTestToolPath + gPrivateEnvironmentLocation + "inc/privateenvironment.inc")
- if fileExists(sTemp) then
- use sTemp
- call getUseFilesPrivateEnvironment
- else
- 'qaErrorLog "Private Environment Control File Location specified in '" + sPrivateEnvironmentLocation + "', but the file doesn't exist: '" +sTemp+ "'"
- end if
- end if
-
' Check if environment works with this OOo version
'/// Control the behaviour of the environment via the file qa/qatesttool/global/version.txt:
'/// [EnvironmentVersion]
diff --git a/testautomation/global/system/includes/status.inc b/testautomation/global/system/includes/status.inc
index 49d3a836043a..bf1ba6a74416 100644..100755
--- a/testautomation/global/system/includes/status.inc
+++ b/testautomation/global/system/includes/status.inc
@@ -271,8 +271,7 @@ sub hStatusWriteOutputFirstFile ()
sPlat = "win"
end if
- slVersion() = Split(gProductName, " ") '(15)
- sProduct = slVersion(0)
+ sProduct = gProductName '(15)
' major is from start to 'm'
iPosA = 1
diff --git a/testautomation/global/tools/includes/optional/t_extension_manager_tools.inc b/testautomation/global/tools/includes/optional/t_extension_manager_tools.inc
index c231e6a798e6..ee4d7f55beba 100644..100755
--- a/testautomation/global/tools/includes/optional/t_extension_manager_tools.inc
+++ b/testautomation/global/tools/includes/optional/t_extension_manager_tools.inc
@@ -79,6 +79,7 @@ function hExtensionAddGUI( _path as string, _flags as string ) as integer
'///+<li>-4 = Unknown messagebox before the file Open dialog exists</li>
'///+<li>-5 = Broken dependency warning displayed</li>
'///+<li>-6 = The File Open dialog did not pop up</li>
+ '///+<li>-7 = Unknown and unhandled messagebox. function exit</li>
'///</ul>
'///</ol>
@@ -100,6 +101,7 @@ function hExtensionAddGUI( _path as string, _flags as string ) as integer
'///+<li>Verify that the requested extension exists (filesystem level)</li>
if ( not FileExists( path ) ) then
printlog( CFN & "Requested extension does not exist" )
+ printlog( CFN & path )
hExtensionAddGUI() = -1
exit function
endif
@@ -233,6 +235,8 @@ function hExtensionAddGUI( _path as string, _flags as string ) as integer
else
printlog( CFN & "Unexpected/unknown dialog displayed" )
printlog( Active.getText() )
+ hExtensionAddGUI() = -7
+ exit function
endif
else
if ( instr( flags , "noupdate" ) <> 0 ) then
diff --git a/testautomation/global/tools/includes/optional/t_locale_strings1.inc b/testautomation/global/tools/includes/optional/t_locale_strings1.inc
index 12bc913d3bf4..d3e7708dbd30 100644..100755
--- a/testautomation/global/tools/includes/optional/t_locale_strings1.inc
+++ b/testautomation/global/tools/includes/optional/t_locale_strings1.inc
@@ -371,7 +371,33 @@ function fLocaleString (sReturn as string) as string
sLocaleNumFormLanEng = "Englisch (USA)"
sLocaleNumFormLanLith = "Litauisch"
sLocaleNumFormLanDutch = "Niederländisch (Niederlande)"
-
+
+ case 50 : sLocaleTableHeading = "Glava tabele" ' Slovenian
+ sLocaleTableContents = "Vsebina tabele"
+ sLocaleNumber = "Å tevilo"
+ sLocaleText = "Besedilo"
+ sLocaleCurrency = "Valuta"
+ sLocaleDate = "Datum"
+ sLocaleTime = "ÄŒas"
+ sLocalePercent = "Odstotek"
+ sLocaleScientific = "Znanstveno"
+ sLocaleFraction = "Ulomek"
+ sLocaleBoolean = "Dvojiška vrednost"
+ sLocaleTable = "Tabela"
+ sLocaleCurrencyValue = "10,00 €"
+ sLocaleDateValue = "31.03.06"
+ sLocaleDateOutput = "31.03.06"
+ sLocaleTimeInput = "15:42"
+ sLocaleTimeValue = "15:42:00"
+ slocalePercentValue = "14,00%"
+ sLocaleScientificValue = "1,00E+008"
+ sLocaleBooleanValue = "TRUE"
+ sLocaleLocaleSettings = "angleški (ZDA)"
+ sLocaleScriptType = "Zahodni"
+ sLocaleNumFormLanEng = "angleški (ZDA)"
+ sLocaleNumFormLanLith = "litovski"
+ sLocaleNumFormLanDutch = "nizozemski (Nizozemska)"
+
case 55 : sLocaleTableHeading = "Título da tabela" ' Brazil (Portuguese)
sLocaleTableContents = "Conteudo da table"
sLocaleNumber = "Número"
diff --git a/testautomation/global/tools/includes/optional/t_toolbar_tools1.inc b/testautomation/global/tools/includes/optional/t_toolbar_tools1.inc
index 674ddd7e65e2..0bd7ae50525f 100644..100755
--- a/testautomation/global/tools/includes/optional/t_toolbar_tools1.inc
+++ b/testautomation/global/tools/includes/optional/t_toolbar_tools1.inc
@@ -93,6 +93,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "3D-Settings"
case 46 : fGetToolbarName = "3D-Settings"
case 49 : fGetToolbarName = "3D-Einstellungen"
+ case 50 : fGetToolbarName = "Nastavitve 3D"
case 55 : fGetToolbarName = "3D-Settings"
case 81 : fGetToolbarName = "3D-Settings"
case 82 : fGetToolbarName = "3D-Settings"
@@ -110,6 +111,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Align"
case 46 : fGetToolbarName = "Align"
case 49 : fGetToolbarName = "Ausrichten"
+ case 50 : fGetToolbarName = "Poravnava"
case 55 : fGetToolbarName = "Align"
case 81 : fGetToolbarName = "Align"
case 82 : fGetToolbarName = "Align"
@@ -127,6 +129,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Basic Shapes"
case 46 : fGetToolbarName = "Basic Shapes"
case 49 : fGetToolbarName = "Standardformen"
+ case 50 : fGetToolbarName = "Osnovni liki"
case 55 : fGetToolbarName = "Basic Shapes"
case 81 : fGetToolbarName = "Basic Shapes"
case 82 : fGetToolbarName = "Basic Shapes"
@@ -144,6 +147,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Block Arrows"
case 46 : fGetToolbarName = "Block Arrows"
case 49 : fGetToolbarName = "Blockpfeile"
+ case 50 : fGetToolbarName = "Votle puÅ¡Äice"
case 55 : fGetToolbarName = "Block Arrows"
case 81 : fGetToolbarName = "Block Arrows"
case 82 : fGetToolbarName = "Block Arrows"
@@ -161,6 +165,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Bullets and Numbering"
case 46 : fGetToolbarName = "Bullets and Numbering"
case 49 : fGetToolbarName = "Nummerierung und Aufzählungszeichen"
+ case 50 : fGetToolbarName = "Oznake in oÅ¡tevilÄevanje"
case 55 : fGetToolbarName = "Bullets and Numbering"
case 81 : fGetToolbarName = "Bullets and Numbering"
case 82 : fGetToolbarName = "Bullets and Numbering"
@@ -178,6 +183,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Database Form Design"
case 46 : fGetToolbarName = "Database Form Design"
case 49 : fGetToolbarName = "Datenbank Formularentwurf"
+ case 50 : fGetToolbarName = "Oblikovanje obrazca zbirke podatkov"
case 55 : fGetToolbarName = "Database Form Design"
case 81 : fGetToolbarName = "Database Form Design"
case 82 : fGetToolbarName = "Database Form Design"
@@ -195,6 +201,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Drawing"
case 46 : fGetToolbarName = "Drawing"
case 49 : fGetToolbarName = "Zeichnen"
+ case 50 : fGetToolbarName = "Risba"
case 55 : fGetToolbarName = "Drawing"
case 81 : fGetToolbarName = "Drawing"
case 82 : fGetToolbarName = "Drawing"
@@ -212,6 +219,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Drawing Object Properties"
case 46 : fGetToolbarName = "Drawing Object Properties"
case 49 : fGetToolbarName = "Zeichnungsobjekt-Eigenschaften"
+ case 50 : fGetToolbarName = "Lastnosti risanega predmeta"
case 55 : fGetToolbarName = "Drawing Object Properties"
case 81 : fGetToolbarName = "Drawing Object Properties"
case 82 : fGetToolbarName = "Drawing Object Properties"
@@ -229,6 +237,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Form Design"
case 46 : fGetToolbarName = "Form Design"
case 49 : fGetToolbarName = "Formular Entwurf"
+ case 50 : fGetToolbarName = "Oblikovanje obrazca"
case 55 : fGetToolbarName = "Form Design"
case 81 : fGetToolbarName = "Form Design"
case 82 : fGetToolbarName = "Form Design"
@@ -246,6 +255,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Formatting"
case 46 : fGetToolbarName = "Formatting"
case 49 : fGetToolbarName = "Format"
+ case 50 : fGetToolbarName = "Oblikovanje"
case 55 : fGetToolbarName = "Formatting"
case 81 : fGetToolbarName = "Formatting"
case 82 : fGetToolbarName = "Formatting"
@@ -263,6 +273,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Frame"
case 46 : fGetToolbarName = "Frame"
case 49 : fGetToolbarName = "Rahmen"
+ case 50 : fGetToolbarName = "Okvir"
case 55 : fGetToolbarName = "Frame"
case 81 : fGetToolbarName = "Frame"
case 82 : fGetToolbarName = "Frame"
@@ -280,6 +291,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Insert"
case 46 : fGetToolbarName = "Insert"
case 49 : fGetToolbarName = "Einfügen"
+ case 50 : fGetToolbarName = "Vstavi"
case 55 : fGetToolbarName = "Insert"
case 81 : fGetToolbarName = "Insert"
case 82 : fGetToolbarName = "Insert"
@@ -297,6 +309,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "OLE-Object"
case 46 : fGetToolbarName = "OLE-Object"
case 49 : fGetToolbarName = "OLE Objekt"
+ case 50 : fGetToolbarName = "Predmet OLE"
case 55 : fGetToolbarName = "OLE-Object"
case 81 : fGetToolbarName = "OLE-Object"
case 82 : fGetToolbarName = "OLE-Object"
@@ -314,6 +327,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Standard"
case 46 : fGetToolbarName = "Standard"
case 49 : fGetToolbarName = "Standard"
+ case 50 : fGetToolbarName = "Standardno"
case 55 : fGetToolbarName = "Standard"
case 81 : fGetToolbarName = "Standard"
case 82 : fGetToolbarName = "Standard"
@@ -331,6 +345,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Table"
case 46 : fGetToolbarName = "Table"
case 49 : fGetToolbarName = "Tabelle"
+ case 50 : fGetToolbarName = "Tabela"
case 55 : fGetToolbarName = "Table"
case 81 : fGetToolbarName = "Table"
case 82 : fGetToolbarName = "Table"
@@ -348,6 +363,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "Text Object"
case 46 : fGetToolbarName = "Text Object"
case 49 : fGetToolbarName = "Textobjekt"
+ case 50 : fGetToolbarName = "Besedilni predmet"
case 55 : fGetToolbarName = "Text Object"
case 81 : fGetToolbarName = "Text Object"
case 82 : fGetToolbarName = "Text Object"
@@ -365,6 +381,7 @@ function fGetToolbarName(sToolbar) as String
case 39 : fGetToolbarName = "XML Form Design"
case 46 : fGetToolbarName = "XML Form Design"
case 49 : fGetToolbarName = "XML Formularentwurf"
+ case 50 : fGetToolbarName = "Oblikovanje obrazca XML"
case 55 : fGetToolbarName = "XML Form Design"
case 81 : fGetToolbarName = "XML Form Design"
case 82 : fGetToolbarName = "XML Form Design"
diff --git a/testautomation/global/tools/includes/optional/t_treelist_tools.inc b/testautomation/global/tools/includes/optional/t_treelist_tools.inc
index b459b2c0f4a0..36cfe7370901 100644..100755
--- a/testautomation/global/tools/includes/optional/t_treelist_tools.inc
+++ b/testautomation/global/tools/includes/optional/t_treelist_tools.inc
@@ -356,6 +356,16 @@ function hSelectNodeByName( oControl as object , _name as string ) as integer
iThisNode = iCurrentNode
exit for
endif
+
+ if ( instr( cNodeName, _name ) > 0 ) then
+ if ( instr( cNodeName, "(" ) > 0 ) then
+ printlog( CFN & "Node has readonly marker" )
+ iThisNode = iCurrentNode
+ exit for
+ else
+ qaerrorlog( CFN & "Fuzzy match. This might or might not be the correct node" )
+ endif
+ endif
next iCurrentNode
endcatch
diff --git a/testautomation/global/tools/includes/required/t_doc2.inc b/testautomation/global/tools/includes/required/t_doc2.inc
index fc5efb302231..efd2d2799a0e 100644..100755
--- a/testautomation/global/tools/includes/required/t_doc2.inc
+++ b/testautomation/global/tools/includes/required/t_doc2.inc
@@ -121,6 +121,7 @@ function sMakeReadOnlyDocumentEditable() as boolean
' no action was required (that is: Document was not read-only)
dim iTry as integer
+ dim iWait as integer
dim rc as integer
const CFN = "sMakeReadOnlyDocumentEditable::"
@@ -143,8 +144,27 @@ function sMakeReadOnlyDocumentEditable() as boolean
wait( 1000 )
endif
' ========== Workaround end ==========
-
Kontext "Standardbar"
+ iWait = 0
+ Do
+ if ( Bearbeiten.IsEnabled() ) then
+ try
+ if Bearbeiten.getState( 2 ) = 0 then
+ exit do
+ endif
+ catch
+ if ( VERBOSE ) then printlog "Attempt " & iWait & " to make document readable failed"
+ iWait = iWait + 1
+ wait ( 1000 )
+ endcatch
+ else
+ if ( VERBOSE ) then printlog "Attempt " & iWait & " to make document readable failed"
+ iWait = iWait + 1
+ wait ( 1000 )
+ end if
+ if iWait >= 5 then exit do
+ Loop
+
if ( Bearbeiten.IsEnabled() ) then
if ( Bearbeiten.getState( 2 ) = 0 ) then
diff --git a/testautomation/global/win/dial_d_h.win b/testautomation/global/win/dial_d_h.win
index 1540dbd8743f..ab6183ad7724 100755
--- a/testautomation/global/win/dial_d_h.win
+++ b/testautomation/global/win/dial_d_h.win
@@ -483,6 +483,12 @@ Gruppenliste HID_TEMPLATE_FILTER
Interlace filter:CheckBox:DLG_EXPORT_GIF:CBX_INTERLACED
TransparentSpeichern filter:CheckBox:DLG_EXPORT_GIF:CBX_TRANSLUCENT
+*GridControlDialogStarter ACTIVE
+ShowGridcontrol sym:showGridcontrol
+
+*GridControlDialog sym:gridcontroldialog
+gridcontrolcontrol sym:gridcontrolself
+
*GroupingDlg HID_SC_DPDATEGROUP
AutoStart sc:RadioButton:RID_SCDLG_DPNUMGROUP:RB_AUTOSTART
ManualStart sc:RadioButton:RID_SCDLG_DPNUMGROUP:RB_MANSTART
diff --git a/testautomation/global/win/dial_t_z.win b/testautomation/global/win/dial_t_z.win
index c60e6a72dde7..1f317fd412da 100755
--- a/testautomation/global/win/dial_t_z.win
+++ b/testautomation/global/win/dial_t_z.win
@@ -162,10 +162,6 @@ Vorschau sd:PushButton:DLG_VECTORIZE:BTN_PREVIEW
*UndoRedoBox HID_SVXTBX_UNDO_REDO_CTRL
UndoRedoList svx:ListBox:RID_SVXTBX_UNDO_REDO_CTRL:LB_SVXTBX_UNDO_REDO_CTRL
-*UrlOeffnen sfx2:ModalDialog:RID_URLOPEN
-URL sfx2:Edit:RID_URLOPEN:RID_URLOPEN_URL
-URLText sfx2:Edit:RID_URLOPEN:RID_URLOPEN_URL
-
*Verbinder HID_PAGE_CONNECTION SVX:TABPAGE:RID_SVXPAGE_CONNECTION
Linie1 cui:METRICFIELD:RID_SVXPAGE_CONNECTION:MTR_FLD_LINE_1
Linie2 cui:METRICFIELD:RID_SVXPAGE_CONNECTION:MTR_FLD_LINE_2
diff --git a/testautomation/global/win/edia_d_h.win b/testautomation/global/win/edia_d_h.win
index da39b72e3115..2829054eba2d 100755
--- a/testautomation/global/win/edia_d_h.win
+++ b/testautomation/global/win/edia_d_h.win
@@ -316,7 +316,7 @@ ReplaceWith svx:ComboBox:RID_SVXDLG_SEARCH:ED_REPLACE
ReplaceWithStyle svx:ListBox:RID_SVXDLG_SEARCH:LB_REPLACE
SearchNow svx:PushButton:RID_SVXDLG_SEARCH:BTN_SEARCH
SearchAll svx:PushButton:RID_SVXDLG_SEARCH:BTN_SEARCH_ALL
-Replace svx:PushButton:RID_SVXDLG_SEARCH:BTN_REPLACE
+ReplaceBtn svx:PushButton:RID_SVXDLG_SEARCH:BTN_REPLACE
ReplaceAll svx:PushButton:RID_SVXDLG_SEARCH:BTN_REPLACE_ALL
MatchCase svx:CheckBox:RID_SVXDLG_SEARCH:CB_MATCH_CASE
WholeWordsOnly svx:CheckBox:RID_SVXDLG_SEARCH:CB_WHOLE_WORDS
@@ -454,7 +454,7 @@ HanjaOnly cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_HANJA_ONLY
ReplaceByCharacter cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_REPLACE_BY_CHARACTER
Ignore HID_HANGULDLG_BUTTON_IGNORE
AlwaysIgnore HID_HANGULDLG_BUTTON_IGNOREALL
-Replace HID_HANGULDLG_BUTTON_CHANGE
+ReplaceBtn HID_HANGULDLG_BUTTON_CHANGE
AlwaysReplace HID_HANGULDLG_BUTTON_CHANGEALL
Options HID_HANGULDLG_BUTTON_OPTIONS
Grid HID_HANGULDLG_SUGGESTIONS_GRID
diff --git a/testautomation/global/win/edia_p_s.win b/testautomation/global/win/edia_p_s.win
index a95316d03619..a97b3b3ed8be 100644
--- a/testautomation/global/win/edia_p_s.win
+++ b/testautomation/global/win/edia_p_s.win
@@ -257,6 +257,9 @@ RightFieldCell HID_RELATIONDIALOG_RIGHTFIELDCELL
*Relief SID_GRFFILTER_EMBOSS
LightSource HID_GRFFILTER_EMBOSS_LIGHT
+*RenameAutoFormat HID_SC_REN_AFMT_DLG
+RenameAutoFormatName HID_SC_REN_AFMT_NAME
+
*RenameElement HID_MM_ADD_RENAME_ENTRY
FieldTitle sw:Edit:DLG_MM_ADD_RENAME_ENTRY:ED_FIELDNAME
diff --git a/testautomation/global/win/edia_t_z.win b/testautomation/global/win/edia_t_z.win
index 7ad35334019e..670a872ac657 100755
--- a/testautomation/global/win/edia_t_z.win
+++ b/testautomation/global/win/edia_t_z.win
@@ -2,7 +2,7 @@
TableWindow HID_CTL_TABLEEDIT
Fieldname HID_TABDESIGN_NAMECELL
FieldType HID_TABDESIGN_TYPECELL
-Description HID_TABDESIGN_COMMENTCELL
+Description HID_TABDESIGN_HELPTEXT
*TablesFilter HID_DSADMIN_TABLE_SUBSCRIPTION
Tables HID_DSADMIN_TABLE_SELECTOR
@@ -40,8 +40,8 @@ FinishBtn HID_DLGTABLE_CMDFINISH
CancelBtn HID_DLGTABLE_CMDCANCEL
' not nice solved, but can't do better right now; complains -> TBO
-*Tasks sd:DockingWindow:FLT_RIGHT_PANE_DOCKING_WINDOW
-View HID_SD_TASK_PANE_VIEW_MENU
+*Tasks sd:DockingWindow:FLT_TOOL_PANEL_DOCKING_WINDOW
+View HID_TASKPANE_VIEW_MENU
'? HID_SD_WIN_DOCUMENT
' Master Pages
UsedInThisPresentationPreview HID_SD_TASK_PANE_PREVIEW_CURRENT
diff --git a/testautomation/global/win/spadmin.win b/testautomation/global/win/spadmin.win
index 056a2605ecc9..1e8de27e9b15 100755
--- a/testautomation/global/win/spadmin.win
+++ b/testautomation/global/win/spadmin.win
@@ -67,7 +67,6 @@ PBDefault padmin:PushButton:RID_PADIALOG:RID_PA_BTN_STD
PBRemove padmin:PushButton:RID_PADIALOG:RID_PA_BTN_DEL
PBTestpage padmin:PushButton:RID_PADIALOG:RID_PA_TESTPAGE
PBNewPrinter padmin:PushButton:RID_PADIALOG:RID_PA_BTN_ADD
-PBFonts padmin:PushButton:RID_PADIALOG:RID_PA_BTN_FONTS
*TabSPACommand padmin:TabPage:RID_RTS_COMMANDPAGE
EFlpr padmin:ComboBox:RID_RTS_COMMANDPAGE:RID_RTS_CMD_CB_COMMANDS
diff --git a/testautomation/global/win/tab_a_d.win b/testautomation/global/win/tab_a_d.win
index af6d933aefb4..a3135d80e1dd 100755
--- a/testautomation/global/win/tab_a_d.win
+++ b/testautomation/global/win/tab_a_d.win
@@ -151,6 +151,7 @@ GenauigkeitWieAngezeigt sc:CheckBox:RID_SCPAGE_CALC:BTN_CALC
Suchkriterien sc:CheckBox:RID_SCPAGE_CALC:BTN_MATCH
RegulaererAusdruck sc:CheckBox:RID_SCPAGE_CALC:BTN_REGEX
SpaltenZeilenbeschriftung sc:CheckBox:RID_SCPAGE_CALC:BTN_LOOKUP
+LimitDecimals sc:CheckBox:RID_SCPAGE_CALC:BTN_GENERAL_PREC
*TabBereiche HID_INSERT_SECTION_PAGE
Bereichsliste sw:ComboBox:TP_INSERT_SECTION:ED_RNAME
diff --git a/testautomation/graphics/optional/g_accessability.bas b/testautomation/graphics/optional/g_accessability.bas
index db1e9e68474a..fc03755763b5 100755..100644
--- a/testautomation/graphics/optional/g_accessability.bas
+++ b/testautomation/graphics/optional/g_accessability.bas
@@ -36,6 +36,7 @@ sub main
Call hStatusIn ( "Graphics","g_accessability.bas")
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_accessability.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/g_convertto.bas b/testautomation/graphics/optional/g_convertto.bas
index bdc86266b96e..4a1e76cfe04d 100755..100644
--- a/testautomation/graphics/optional/g_convertto.bas
+++ b/testautomation/graphics/optional/g_convertto.bas
@@ -1,72 +1,73 @@
-'encoding UTF-8 Do not remove or change this line!
-'**************************************************************************
-' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-'
-' Copyright 2000, 2010 Oracle and/or its affiliates.
-'
-' OpenOffice.org - a multi-platform office productivity suite
-'
-' This file is part of OpenOffice.org.
-'
-' OpenOffice.org is free software: you can redistribute it and/or modify
-' it under the terms of the GNU Lesser General Public License version 3
-' only, as published by the Free Software Foundation.
-'
-' OpenOffice.org is distributed in the hope that it will be useful,
-' but WITHOUT ANY WARRANTY; without even the implied warranty of
-' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-' GNU Lesser General Public License version 3 for more details
-' (a copy is included in the LICENSE file that accompanied this code).
-'
-' You should have received a copy of the GNU Lesser General Public License
-' version 3 along with OpenOffice.org. If not, see
-' <http://www.openoffice.org/license.html>
-' for a copy of the LGPLv3 License.
-'
-'/************************************************************************
-'*
-'* Owner : wolfram.garten@sun.com
-'*
-'* short description : Graphics Function: Convert to ...
-'*
-'\******************************************************************
-
-global Ueber_Text_1 as string
-global Ueber_Text_2 as string
-global Ueber_Text_3 as string
-
-sub main
- PrintLog "------------------------- g_convertto test -------------------------"
- Call hStatusIn ( "Graphics","g_convertto.bas")
-
- use "graphics\tools\id_tools.inc"
- use "graphics\optional\includes\global\g_convertto.inc"
-
- PrintLog "-------------------------" + gApplication + "-------------------"
- Call tiModifyConvertToPolygon
- Call tdContextConvertIntoBitmap
- Call tiAendernUmwandelnInKurve
- Call tiAendernUmwandelnInPolygonGrafik
- Call tiAendernUmwandelnIn3D
- Call tiAendernUmwandelnIn3DRotationsKoerper
- Call tiAendernUmwandelnInMetaFile
-
- gApplication = "DRAW"
- PrintLog "-------------------------" + gApplication + "-------------------"
- Call tiModifyConvertToPolygon
- Call tdContextConvertIntoBitmap
- Call tiAendernUmwandelnInKurve
- Call tiAendernUmwandelnInPolygonGrafik
- Call tiAendernUmwandelnIn3D
- Call tiAendernUmwandelnIn3DRotationsKoerper
- Call tiAendernUmwandelnInMetaFile
-
- Call hStatusOut
-end sub
-
-sub LoadIncludeFiles
- use "global\system\includes\master.inc"
- use "global\system\includes\gvariabl.inc"
- gApplication = "IMPRESS"
- Call GetUseFiles
-end sub
+'encoding UTF-8 Do not remove or change this line!
+'**************************************************************************
+' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+'
+' Copyright 2000, 2010 Oracle and/or its affiliates.
+'
+' OpenOffice.org - a multi-platform office productivity suite
+'
+' This file is part of OpenOffice.org.
+'
+' OpenOffice.org is free software: you can redistribute it and/or modify
+' it under the terms of the GNU Lesser General Public License version 3
+' only, as published by the Free Software Foundation.
+'
+' OpenOffice.org is distributed in the hope that it will be useful,
+' but WITHOUT ANY WARRANTY; without even the implied warranty of
+' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+' GNU Lesser General Public License version 3 for more details
+' (a copy is included in the LICENSE file that accompanied this code).
+'
+' You should have received a copy of the GNU Lesser General Public License
+' version 3 along with OpenOffice.org. If not, see
+' <http://www.openoffice.org/license.html>
+' for a copy of the LGPLv3 License.
+'
+'/************************************************************************
+'*
+'* Owner : wolfram.garten@sun.com
+'*
+'* short description : Graphics Function: Convert to ...
+'*
+'\******************************************************************
+
+global Ueber_Text_1 as string
+global Ueber_Text_2 as string
+global Ueber_Text_3 as string
+
+sub main
+ PrintLog "------------------------- g_convertto test -------------------------"
+ Call hStatusIn ( "Graphics","g_convertto.bas")
+
+ use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
+ use "graphics\optional\includes\global\g_convertto.inc"
+
+ PrintLog "-------------------------" + gApplication + "-------------------"
+ Call tiModifyConvertToPolygon
+ ' Call tdContextConvertIntoBitmap
+ Call tiAendernUmwandelnInKurve
+ Call tiAendernUmwandelnInPolygonGrafik
+ 'Call tiAendernUmwandelnIn3D
+ 'Call tiAendernUmwandelnIn3DRotationsKoerper
+ 'Call tiAendernUmwandelnInMetaFile
+
+ gApplication = "DRAW"
+ PrintLog "-------------------------" + gApplication + "-------------------"
+ 'Call tiModifyConvertToPolygon
+ 'Call tdContextConvertIntoBitmap
+ 'Call tiAendernUmwandelnInKurve
+ 'Call tiAendernUmwandelnInPolygonGrafik
+ 'Call tiAendernUmwandelnIn3D
+ 'Call tiAendernUmwandelnIn3DRotationsKoerper
+ 'Call tiAendernUmwandelnInMetaFile
+
+ Call hStatusOut
+end sub
+
+sub LoadIncludeFiles
+ use "global\system\includes\master.inc"
+ use "global\system\includes\gvariabl.inc"
+ gApplication = "IMPRESS"
+ Call GetUseFiles
+end sub
diff --git a/testautomation/graphics/optional/g_crossfading.bas b/testautomation/graphics/optional/g_crossfading.bas
index 52f7ce3acfe0..1520f995e8ab 100755..100644
--- a/testautomation/graphics/optional/g_crossfading.bas
+++ b/testautomation/graphics/optional/g_crossfading.bas
@@ -36,6 +36,7 @@ sub main
Call hStatusIn ( "Graphics","g_crossfading.bas")
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_crossfading.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/g_customshapes.bas b/testautomation/graphics/optional/g_customshapes.bas
index b4e96524deff..f759be72f680 100755..100644
--- a/testautomation/graphics/optional/g_customshapes.bas
+++ b/testautomation/graphics/optional/g_customshapes.bas
@@ -36,6 +36,7 @@ sub main
Call hStatusIn ( "Graphics","g_customshapes.bas" )
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_customshapes.inc"
PrintLog "--------------------- " + gApplication + " -------------------"
diff --git a/testautomation/graphics/optional/g_group.bas b/testautomation/graphics/optional/g_group.bas
index 6cd539ac2577..f8d16e653c9c 100755..100644
--- a/testautomation/graphics/optional/g_group.bas
+++ b/testautomation/graphics/optional/g_group.bas
@@ -36,6 +36,7 @@ sub main
Call hStatusIn ( "Graphics","g_group.bas" )
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_group.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/g_line.bas b/testautomation/graphics/optional/g_line.bas
index 89759e847389..867621aa88b0 100755..100644
--- a/testautomation/graphics/optional/g_line.bas
+++ b/testautomation/graphics/optional/g_line.bas
@@ -34,7 +34,7 @@
sub main
PrintLog "------------------------- g_line test -------------------------"
Call hStatusIn ( "Graphics","g_line.bas")
-
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_line.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/g_ole.bas b/testautomation/graphics/optional/g_ole.bas
index dc8c0490b5aa..6409388ef2f6 100755..100644
--- a/testautomation/graphics/optional/g_ole.bas
+++ b/testautomation/graphics/optional/g_ole.bas
@@ -39,6 +39,7 @@ sub main
Call hStatusIn ( "Graphics","g_ole.bas")
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_ole.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/g_savepictureas.bas b/testautomation/graphics/optional/g_savepictureas.bas
index c34348039db1..e3c5f3fc5b8d 100755..100644
--- a/testautomation/graphics/optional/g_savepictureas.bas
+++ b/testautomation/graphics/optional/g_savepictureas.bas
@@ -39,6 +39,7 @@ sub main
Call hStatusIn ( "Graphics","g_savepictureas.bas" )
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\global\g_savepictureas.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/i_animation.bas b/testautomation/graphics/optional/i_animation.bas
index 64b0921b8db2..6b2c4851a28a 100755..100644
--- a/testautomation/graphics/optional/i_animation.bas
+++ b/testautomation/graphics/optional/i_animation.bas
@@ -36,6 +36,7 @@ sub main
Call hStatusIn ( "Graphics","i_animation.bas")
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\impress\i_animation.inc"
Call tExtrasAnimation
diff --git a/testautomation/graphics/optional/i_saveloadlayout.bas b/testautomation/graphics/optional/i_saveloadlayout.bas
index 2ce62f89c4d7..08fc52a44270 100755..100644
--- a/testautomation/graphics/optional/i_saveloadlayout.bas
+++ b/testautomation/graphics/optional/i_saveloadlayout.bas
@@ -41,11 +41,7 @@ sub main
PrintLog "-------------------------" + gApplication + "-------------------"
Call tSaveLoadLayoutEmpty
Call tSaveLoadLayoutText
- Call tSaveLoadLayoutPicture
- Call tSaveLoadLayoutOutline
- Call tSaveLoadLayoutChart
- Call tSaveLoadLayoutSpreadsheet
- Call tSaveLoadLayoutOLE
+ Call tSaveLoadLayoutContent
Call hStatusOut
end sub
diff --git a/testautomation/graphics/optional/i_slidecopy.bas b/testautomation/graphics/optional/i_slidecopy.bas
index 04c91a4bb10c..cc1ac3f9d7bd 100755..100644
--- a/testautomation/graphics/optional/i_slidecopy.bas
+++ b/testautomation/graphics/optional/i_slidecopy.bas
@@ -38,6 +38,7 @@ sub main
Call hStatusIn ( "Graphics","i_slidecopy.bas")
use "graphics\tools\id_tools.inc"
+ use "graphics\tools\id_tools_2.inc"
use "graphics\optional\includes\impress\i_slidecopy.inc"
PrintLog "-------------------------" + gApplication + "-------------------"
diff --git a/testautomation/graphics/optional/includes/global/export_graphic_2.inc b/testautomation/graphics/optional/includes/global/export_graphic_2.inc
index d4c6f46ed272..67c456201b45 100755..100644
--- a/testautomation/graphics/optional/includes/global/export_graphic_2.inc
+++ b/testautomation/graphics/optional/includes/global/export_graphic_2.inc
@@ -146,7 +146,7 @@ testcase tSVM
hFileOpen (sDocument)
sleep (10)
- sMakeReadOnlyDocumentEditable
+ call fMakeDocumentWritable
hTypeKeys ("<escape><tab>")
fGetSizeXY sx1, sY, TRUE
@@ -763,14 +763,8 @@ qaerrorlog
endif
' check if the document is writable
- if fIsDocumentWritable = false then
- ' make the document writable and check if it's succesfull
- if fMakeDocumentWritable = false then
- warnlog "The document can't be make writeable. Test stopped."
- goto endsub
- endif
- endif
-
+ call fMakeDocumentWritable
+
hTypeKeys ("<escape><tab>")
fGetSizeXY sx1, sy, TRUE
if hCallExport (OutputGrafikTBO + "1" , "BMP - Windows Bitmap (.bmp)", TRUE ) = TRUE then
@@ -948,9 +942,8 @@ testcase tEMF
Filterauswahl.Cancel
goto endsub
endif
- printlog "making doc editable if it is readonly"
- sMakeReadOnlyDocumentEditable
-
+ printlog "making doc editable if it is readonly"
+ call fMakeDocumentWritable
hTypeKeys ("<escape><tab>")
fGetSizeXY sx1, sY, TRUE
if hCallExport (OutputGrafikTBO & "1" , sFilter, TRUE ) = TRUE then
@@ -1139,7 +1132,7 @@ testcase tMET
sleep (10)
printlog "making doc editable if it is readonly"
- sMakeReadOnlyDocumentEditable
+ call fMakeDocumentWritable
hTypeKeys ("<escape><tab>")
fGetSizeXY sx1, sY, TRUE
@@ -1341,7 +1334,7 @@ testcase tWMF
sleep (10)
printlog "making doc editable if it is readonly"
- sMakeReadOnlyDocumentEditable
+ call fMakeDocumentWritable
hTypeKeys ("<escape><tab>")
fGetSizeXY sx1, sY, TRUE
diff --git a/testautomation/graphics/optional/includes/global/g_accessability.inc b/testautomation/graphics/optional/includes/global/g_accessability.inc
index a1385530f124..8d59b0c6b387 100644
--- a/testautomation/graphics/optional/includes/global/g_accessability.inc
+++ b/testautomation/graphics/optional/includes/global/g_accessability.inc
@@ -37,6 +37,7 @@
testcase tEis1549
call hNewDocument
+ call sSelectEmptyLayout
call hTextrahmenErstellen ("Sun",20,20,70,20)
hTypeKeys ("<escape><escape>")
@@ -116,10 +117,16 @@ testcase tEis1549
endcatch
call hCloseDocument
-endcase
+endcase 'tEis1549
testcase tEis1523
call hNewDocument
+
+ printlog "Switching between Draw/Impress"
+ if (UCase(gApplication)) = "IMPRESS" then
+ call sSelectEmptyLayout
+
+ endif
call hTextrahmenErstellen ("A",20,20,30,30)
hTypeKeys ("<escape><escape>")
call hTextrahmenErstellen ("B",10,10,15,15)
@@ -209,7 +216,7 @@ testcase tEis1523
endif
call hCloseDocument
-endcase
+endcase 'tEis1523
testcase tEis1581
dim i as integer
@@ -237,8 +244,11 @@ testcase tEis1581
LayoutsPreview.TypeKeys "<Return>"
sleep (1)
hTypeKeys ("<tab><tab>")
- sleep (1)
- hTypeKeys ("<Return>")
+
+ DocumentImpress.UseMenu
+ hMenuSelectNr(4)
+ hMenuSelectNr(13)
+ hMenuSelectNr(1)
sleep (2)
kontext "GeneralFileDialog"
if GeneralFileDialog.exists then
@@ -255,7 +265,7 @@ testcase tEis1581
Pagelayout_UndoDeleteWarning.ok
endif
sleep (1)
- for i = 1 to 17
+ for i = 1 to 3
kontext "Tasks"
LayoutsPreview.TypeKeys "<RIGHT>"
kontext "Pagelayout_UndoDeleteWarning"
@@ -267,9 +277,12 @@ testcase tEis1581
kontext "Tasks"
LayoutsPreview.TypeKeys "<Return>"
sleep (1)
- hTypeKeys ("<tab><tab><tab>")
+ hTypeKeys ("<tab><tab>")
sleep (1)
- hTypeKeys ("<Return>")
+ DocumentImpress.UseMenu
+ hMenuSelectNr(4)
+ hMenuSelectNr(16)
+ hMenuSelectNr(1)
try
sleep 2
' InsertTitle *OLEObjektEinfuegen/OLEObjektInsert SID_INSERT_OBJECT
@@ -281,4 +294,4 @@ testcase tEis1581
endcatch
endif
call hCloseDocument
-endcase
+endcase 'tEis1581
diff --git a/testautomation/graphics/optional/includes/global/g_arrangealign.inc b/testautomation/graphics/optional/includes/global/g_arrangealign.inc
index 4d79d3c2f829..f9fab5625905 100644
--- a/testautomation/graphics/optional/includes/global/g_arrangealign.inc
+++ b/testautomation/graphics/optional/includes/global/g_arrangealign.inc
@@ -46,7 +46,8 @@ testcase tiDatei_Fuer_Anordnen_Erstellen
dim zaehler as integer
'/// This function creates the document, that will be used as reference and working object inthe following cases :-) ///'
'///'Dim Datei ' somewhere global :-) defined in calling sub! :sub im_107c_ ///
- call hNewDocument '/// new document ///'
+ call hNewDocument
+ call sSelectEmptyLayout '/// new document ///'
if Dir(Datei)<>"" then app.Kill(Datei) ' kill old file
for Zaehler = 1 to 3 '/// create 3 overlapping objects ///'
Kontext
diff --git a/testautomation/graphics/optional/includes/global/g_autocorrection.inc b/testautomation/graphics/optional/includes/global/g_autocorrection.inc
index b0a0326a6f3f..7653d391243f 100644
--- a/testautomation/graphics/optional/includes/global/g_autocorrection.inc
+++ b/testautomation/graphics/optional/includes/global/g_autocorrection.inc
@@ -137,7 +137,7 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean)
ExtensionString = "odg"
end if
- if iSprache = "1" OR iSprache = "33" OR iSprache = "34" OR iSprache = "36" OR iSprache = "39" OR iSprache = "46" OR iSprache = "48" OR iSprache = "49" OR iSprache = "55" then
+ if iSprache = "1" OR iSprache = "33" OR iSprache = "34" OR iSprache = "36" OR iSprache = "39" OR iSprache = "46" OR iSprache = "48" OR iSprache = "49" OR iSprache = "50" OR iSprache = "55" then
sFileName = (ConvertPath ( gTesttoolPath + "graphics\required\input\rightfont" & iSprache & "." + ExtensionString ))
elseif bAsianLan = true then
Printlog "Language-file for Asian language " & iSprache & " is missing. Using standard instead."
@@ -159,7 +159,7 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean)
printlog "File opened: " + sFileName
Sleep 3
- Call sMakeReadOnlyDocumentEditable
+ call fMakeDocumentWritable
if bSimple then
Printlog "- Tools/Autocorrect -single quotes"
@@ -179,6 +179,7 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean)
case 46 : Vorn$ = Chr(8217) : Hinten$ = Chr(8217)
case 48 : Vorn$ = Chr(8216) : Hinten$ = Chr(8217)
case 49 : Vorn$ = Chr(8218) : Hinten$ = Chr(8216)
+ case 50 : Vorn$ = Chr(8216) : Hinten$ = Chr(8217)
case 55 : Vorn$ = Chr(8216) : Hinten$ = Chr(8217)
case 81, 82, 86, 88 : Vorn$ = Chr(8216) : Hinten$ = Chr(8217) ' Asian
case else : Warnlog "- Nothing prepared for this language, but I run: take the warnlogs an insert the numbers here.: "+iSprache
@@ -202,6 +203,7 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean)
case 46 : Vorn$ = Chr(8221) : Hinten$ = Chr(8221)
case 48 : Vorn$ = Chr(8222) : Hinten$ = Chr(8221)
case 49 : Vorn$ = Chr(8222) : Hinten$ = Chr(8220)
+ case 50 : Vorn$ = Chr(8220) : Hinten$ = Chr(8221)
case 55 : Vorn$ = Chr(8220) : Hinten$ = Chr(8221)
case 81, 82, 86, 88 : Vorn$ = Chr(8220) : Hinten$ = Chr(8221) ' Asian
case else : Warnlog "- Nothing prepared for this language: "+iSprache
diff --git a/testautomation/graphics/optional/includes/global/g_clipboard.inc b/testautomation/graphics/optional/includes/global/g_clipboard.inc
index 574db14419e8..9bc85a4bbad1 100644
--- a/testautomation/graphics/optional/includes/global/g_clipboard.inc
+++ b/testautomation/graphics/optional/includes/global/g_clipboard.inc
@@ -216,6 +216,7 @@ testcase tiEditClipboard
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
SetClipboard ""
'/// Create rectangle ///'
diff --git a/testautomation/graphics/optional/includes/global/g_convertto.inc b/testautomation/graphics/optional/includes/global/g_convertto.inc
index a8fc7e5aa37d..8acac43a45fc 100644
--- a/testautomation/graphics/optional/includes/global/g_convertto.inc
+++ b/testautomation/graphics/optional/includes/global/g_convertto.inc
@@ -58,6 +58,7 @@ testcase tiModifyConvertToPolygon
Dim Minanzahl as string
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 3
hTextrahmenErstellen ("This is a text that will be transformed into a Polygon-object", 10,10,60,30)
sleep 1
@@ -207,6 +208,7 @@ testcase tiAendernUmwandelnInKurve
Printlog " ----- ContextConvertIntoCurve testen"
Call hNewDocument '/// New impress document///'
+ Call sSelectEmptyLayout
Call hTextrahmenErstellen ("I test,test,test,test only, if it works for you",20,20,60,30) '/// create textbox///'
sleep 2
@@ -236,6 +238,7 @@ testcase tiAendernUmwandelnInPolygonGrafik
Printlog "- Context/ConvertIntoPolygon"
Call hNewDocument '/// new document ///'
+ Call sSelectEmptyLayout
InsertGraphicsFromFile '/// insert graphic (desp.bmp) ///'
diff --git a/testautomation/graphics/optional/includes/global/g_crossfading.inc b/testautomation/graphics/optional/includes/global/g_crossfading.inc
index e530a28f1339..275f1ee49839 100644
--- a/testautomation/graphics/optional/includes/global/g_crossfading.inc
+++ b/testautomation/graphics/optional/includes/global/g_crossfading.inc
@@ -43,7 +43,8 @@ testcase tCrossfading
dim CounterForX as integer
dim anothercounter as integer
- Call hNewDocument '/// New Impress document ///'
+ Call hNewDocument
+ Call sSelectEmptyLayout '/// New Impress document ///'
gMouseClick 50,50
sleep 1
Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///'
diff --git a/testautomation/graphics/optional/includes/global/g_customshapes.inc b/testautomation/graphics/optional/includes/global/g_customshapes.inc
index 3cd31dac77b6..850356821d2f 100644
--- a/testautomation/graphics/optional/includes/global/g_customshapes.inc
+++ b/testautomation/graphics/optional/includes/global/g_customshapes.inc
@@ -40,6 +40,7 @@ testcase tCustomshapes
'/// Create new document ///'
Call hNewDocument
+ Call sSelectEmptyLayout
if gApplication = "DRAW" then
Kontext "Documentdraw"
else '(Impress)
@@ -646,15 +647,15 @@ testcase tFormatPaintbrush
sleep 1
else '(Impress)
Kontext "DocumentImpress"
- DocumentImpress.Mousedown 20, 20
- DocumentImpress.Mouseup 20, 20
+ DocumentImpress.typekeys("<F6>",true)
+ DocumentImpress.typekeys("<ESCAPE>",true)
+ DocumentImpress.typekeys("<TAB>",true)
sleep 1
kontext "Standardbar"
FormatPaintbrush.Click
kontext "DocumentImpress"
sleep 1
- DocumentImpress.Mousedown 80, 80
- DocumentImpress.Mouseup 80, 80
+ DocumentImpress.typekeys("<TAB>",true)
sleep 1
endif
diff --git a/testautomation/graphics/optional/includes/global/g_demoguide.inc b/testautomation/graphics/optional/includes/global/g_demoguide.inc
index 56dd1f89e294..8da45a872259 100644
--- a/testautomation/graphics/optional/includes/global/g_demoguide.inc
+++ b/testautomation/graphics/optional/includes/global/g_demoguide.inc
@@ -44,6 +44,7 @@ testcase t_Introduction
'///Open new presentation
printlog "Open new presentation"
Call hNewDocument
+ Call sSelectEmptyLayout
'///Open the Gallery
printlog "Open the Gallery"
@@ -136,7 +137,7 @@ testcase t_Introduction
DocumentImpress.TypeKeys "<MOD1 A>"
hOpenContextMenu '(when the object is marked)
hMenuSelectNr(12)
-
+
'///Add Layout "Title Only"
Printlog "Add Layout"
kontext "Tasks"
@@ -144,36 +145,71 @@ testcase t_Introduction
warnlog "Tasks Panel not visible. Opening now."
ViewTaskPane
endif
- Kontext "LayoutsPreview"
+
+ ' enable all items in the task pane.
+ ' may be one item is not enabled due to a previous testrun
+ dim i as integer
+ for i = 1 to 5
+ printlog i
+ View.OpenMenu
+ if ( MenuIsItemChecked(MenuGetItemID(i)) ) then
+ ' do nothing the item is allready displayed
+ else
+ MenuSelect(MenuGetItemId(4))
+ endif
+ hMenuSelectNr(0)
+ 'sleep(1)
+ next
+
+ View.OpenMenu
+ MenuSelect(MenuGetItemId(1))
+ View.OpenMenu
+ MenuSelect(MenuGetItemId(3))
+ View.OpenMenu
+ MenuSelect(MenuGetItemId(4))
+ View.OpenMenu
+ MenuSelect(MenuGetItemId(5))
+
+
LayoutsPreview.TypeKeys "<HOME> <DOWN> <DOWN> <RETURN>"
sleep (5)
'///Add a background
Printlog "Add background"
-
+
Kontext "Tasks"
printlog "Deselect all tabs from view menu in task pane except the needed."
View.OpenMenu
- MenuSelect(MenuGetItemID(5))
+ MenuSelect(MenuGetItemID(5))
View.OpenMenu
- MenuSelect(MenuGetItemID(4))
+ MenuSelect(MenuGetItemID(4))
View.OpenMenu
MenuSelect(MenuGetItemID(3))
View.OpenMenu
MenuSelect(MenuGetItemID(2))
- Kontext "AvailableForUsePreview"
+ sleep(5)
+ View.OpenMenu
+ MenuSelect(MenuGetItemID(1))
+ Tasks.TypeKeys "<TAB>",true
+ Tasks.TypeKeys "<MOD1 HOME>",true
AvailableForUsePreview.TypeKeys "<HOME> <RIGHT> <RETURN>"
- sleep (5)
+ sleep (5)
'///Add a transition effect
Printlog "Add a transition effect"
Kontext "Tasks"
- View.OpenMenu
- MenuSelect(MenuGetItemID(5))
+ sleep(5)
View.OpenMenu
MenuSelect(MenuGetItemID(1))
+ View.OpenMenu
+ MenuSelect(MenuGetItemID(2))
+ View.OpenMenu
+ MenuSelect(MenuGetItemID(3))
+ View.OpenMenu
+ MenuSelect(MenuGetItemID(4))
+
TransitionSound.GetItemCount 'needed for select
Sleep 1
TransitionSound.Select 4
-
+
'///Close the document
Printlog "Close the document"
Call hCloseDocument
@@ -385,7 +421,7 @@ testcase t_DrawingEngine
printlog "Open a drawing"
hFileOpen (Convertpath (gTesttoolPath + "graphics/required/input/Blueprint.odg"))
- Call sMakeReadOnlyDocumentEditable
+ Call fMakeDocumentWritable
'///Select grouped object and enter group
printlog "Select group"
diff --git a/testautomation/graphics/optional/includes/global/g_edit.inc b/testautomation/graphics/optional/includes/global/g_edit.inc
index ef14cd1f477e..6313865b8912 100644
--- a/testautomation/graphics/optional/includes/global/g_edit.inc
+++ b/testautomation/graphics/optional/includes/global/g_edit.inc
@@ -100,39 +100,49 @@ endcase 'tEditDuplicate
'---------------------------------------------------------
testcase tEditFields
- Call hNewDocument
- sleep 3
- InsertFieldsDateFix '/// Insert Date-Fix ///'
- EditSelectAll '/// Select inserted field ///'
- sleep 1
- hTypeKeys "<F2>" '/// Go into edit mode (F2) ///'
- sleep 2
- EditSelectAll '/// Select the date///'
- sleep 2
- EditfieldsDraw '/// Edit -fields///'
- Kontext "FeldbefehlBearbeitenDraw"
- sleep 2
- FeldtypFix.Check '/// check field type fix ///'
- If FeldtypFix.Ischecked then
- Printlog "OK FieldtypeFix checkable"
- else
- warnlog "FieldtypeFix not checkable"
- end if
- FeldtypVariabel.Check '/// check field type variabel///'
- sleep 1
- If FeldtypVariabel.Ischecked then
- Printlog "OK FieldtypeVariabel enabled"
- else
+ Call hNewDocument
+ Call sSelectEmptyLayout
+ sleep 3
+ printlog "insert date-fix"
+ InsertFieldsDateFix
+ printlog "select inserted field"
+ EditSelectAll
+ sleep 1
+ printlog "go into edit mode"
+ hTypeKeys "<F2>"
+ sleep 2
+ printlog "select date"
+ EditSelectAll
+ sleep 2
+ printlog "edit fields"
+ EditfieldsDraw
+ Kontext "FeldbefehlBearbeitenDraw"
+ sleep 2
+ printlog "check field type fix"
+ FeldtypFix.Check
+ If FeldtypFix.Ischecked then
+ Printlog "OK FieldtypeFix checkable"
+ else
+ warnlog "FieldtypeFix not checkable"
+ end if
+ printlog "check field type variable 1"
+ FeldtypVariabel.Check
+ sleep 1
+ If FeldtypVariabel.Ischecked then
+ Printlog "OK FieldtypeVariabel enabled"
+ else
warnlog "FieldtypeVariabel not enabled"
- end if
-' For Zaehler = 1 to FeldtypFormat.GetItemCount
-' FeldTypFormat.Select Zaehler
-' printlog "OK Format ", Zaehler, " = ", FeldtypFormat.GetSelText
-' Next Zaehler
- FeldbefehlBearbeitenDraw.OK '/// close edit fields dialog ///'
- sleep 2
- Call hCloseDocument '/// close document ///'
- sleep 2
+ end if
+ ' For Zaehler = 1 to FeldtypFormat.GetItemCount
+ ' FeldTypFormat.Select Zaehler
+ ' printlog "OK Format ", Zaehler, " = ", FeldtypFormat.GetSelText
+ ' Next Zaehler
+ printlog "close edit fields dialog"
+ FeldbefehlBearbeitenDraw.OK
+ sleep 2
+ printlog "Close Document"
+ Call hCloseDocument
+ sleep 2
endcase 'tEditFields
'--------------------------------------------------------
diff --git a/testautomation/graphics/optional/includes/global/g_find_replace.inc b/testautomation/graphics/optional/includes/global/g_find_replace.inc
index 8dbff683eb83..f49de3b03d35 100644
--- a/testautomation/graphics/optional/includes/global/g_find_replace.inc
+++ b/testautomation/graphics/optional/includes/global/g_find_replace.inc
@@ -69,6 +69,7 @@ testcase tiEditSearchAndReplace
case 47 : ' Norwegian
case 48 : sExpression(1) = "programmu" : sExpression(2) = "programu" ' Polish
case 49 : sExpression(1) = "Texxt" : sExpression(2) = "Schrieb" ' German
+ case 50 : sExpression(1) = "primer" : sExpression(2) = "napakka" ' Slovenian
case 55 : sExpression(1) = "esktava" : sExpression(2) = "norte" ' Portuguese (Brazil)
case 66 : ' Thai
' case 81 : sExpression(1) = "���" : sExpression(2) = "���" ' Japanese
@@ -204,7 +205,7 @@ testcase tiEditSearchAndReplace
SearchFor.SetText sExpression(2) '/// Search for word 2 ///'
ReplaceWith.SetText sExpression(1) '/// Replace with word 1 ///'
- Replace.Click '/// Replace 1 ///'
+ ReplaceBtn.Click '/// Replace 1 ///'
Kontext "Messagebox"
if Messagebox.Exists(4) Then
Kontext "Messagebox"
diff --git a/testautomation/graphics/optional/includes/global/g_format.inc b/testautomation/graphics/optional/includes/global/g_format.inc
index 0674a2f0cd56..2e2f1b0368ff 100644
--- a/testautomation/graphics/optional/includes/global/g_format.inc
+++ b/testautomation/graphics/optional/includes/global/g_format.inc
@@ -48,6 +48,7 @@ testcase tiFormatText
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
'/// create a textbox with text ///'
Call hTextrahmenErstellen ("This is a text, which, I hope, in Staroffice, will be automaticly formatted. Should that not be the case, then it doesn't matter.",20,20,70,20)
WaitSlot (1000)
@@ -699,7 +700,8 @@ testcase tiFormat3D_Effekte
Dim Zaehler as integer
Dim Posi as string
- Call hNewDocument
+ Call hNewDocument
+ Call sSelectEmptyLayout
printlog "new document"
'-----------------------------------RECTANGLE------------------------------------------------------
Call hRechteckErstellen (20,20,60,70) '/// create rectangle ///'
@@ -1187,6 +1189,7 @@ testcase tiFormatAufzaehlungszeichen
PrintLog "- Format/Numbering and Bullets"
Call hNewDocument
+ Call sSelectEmptyLayout
WaitSlot (2000)
Kontext "DocumentImpress"
hTextrahmenErstellen ("Hello <Return><Return>",20,20,60,60)
diff --git a/testautomation/graphics/optional/includes/global/g_group.inc b/testautomation/graphics/optional/includes/global/g_group.inc
index b28029cfb534..3023e673a526 100644
--- a/testautomation/graphics/optional/includes/global/g_group.inc
+++ b/testautomation/graphics/optional/includes/global/g_group.inc
@@ -36,7 +36,8 @@
testcase tiGruppierung
Dim PosX 'Variable fuer PositionX
- Call hNewDocument '/// new document ///'
+ Call hNewDocument
+ Call sSelectEmptyLayout '/// new document ///'
sleep 3
Kontext "DocumentImpress"
sleep 2
diff --git a/testautomation/graphics/optional/includes/global/g_line.inc b/testautomation/graphics/optional/includes/global/g_line.inc
index 3aad4234abd6..55869c258f43 100644
--- a/testautomation/graphics/optional/includes/global/g_line.inc
+++ b/testautomation/graphics/optional/includes/global/g_line.inc
@@ -331,6 +331,7 @@ testcase tLineConnect
end if
Call hNewDocument '/// New Impress / Draw document ///'
+ Call sSelectEmptyLayout
sleep 3
kontext "GraphicObjectbar"
if GraphicObjectbar.Exists then
diff --git a/testautomation/graphics/optional/includes/global/g_load_save.inc b/testautomation/graphics/optional/includes/global/g_load_save.inc
index 9bc422f99ff3..6622c9c7a452 100644
--- a/testautomation/graphics/optional/includes/global/g_load_save.inc
+++ b/testautomation/graphics/optional/includes/global/g_load_save.inc
@@ -302,14 +302,9 @@ testcase tFileOpenImport
Dateiname.SetText (ConvertPath (gTesttoolpath + "graphics\required\input\imsusmap.cgm"))
Oeffnen.Click
Sleep 2
- ' check if the document is writable
- if fIsDocumentWritable = false then
- ' make the document writable and check if it's succesfull
- if fMakeDocumentWritable = false then
- warnlog "The document can't be make writeable. Test stopped."
- goto endsub
- endif
- endif
+
+ call fMakeDocumentWritable
+
kontext "DocumentImpress"
if DocumentImpress.exists(5) then
DocumentImpress.TypeKeys ("<Tab>")
diff --git a/testautomation/graphics/optional/includes/global/g_mediaplayer.inc b/testautomation/graphics/optional/includes/global/g_mediaplayer.inc
index 2382a00b6f0d..01fe8137ef64 100644
--- a/testautomation/graphics/optional/includes/global/g_mediaplayer.inc
+++ b/testautomation/graphics/optional/includes/global/g_mediaplayer.inc
@@ -232,7 +232,7 @@ testcase g_mediaplayer
else
kontext "DocumentDraw"
endif
- hTypeKeys ("<escape><tab>")
+ hTypeKeys ("<escape><tab><tab><tab>")
hOpenContextMenu()
hMenuSelectNr(1)
diff --git a/testautomation/graphics/optional/includes/global/g_ole.inc b/testautomation/graphics/optional/includes/global/g_ole.inc
index 520aa38af8a2..3d30cf52ca85 100644
--- a/testautomation/graphics/optional/includes/global/g_ole.inc
+++ b/testautomation/graphics/optional/includes/global/g_ole.inc
@@ -244,6 +244,7 @@ testcase tOLE_SaveLoad
filename = ConvertPath (gOfficePath + "user\work\oletest." & ExtensionString)
printlog "Create a new document."
Call hNewDocument
+ Call sSelectEmptyLayout
printlog "Insert->Object->OLE Object..."
InsertObjectOLEObject
Kontext "OLEObjektInsert"
@@ -341,7 +342,7 @@ testcase tiOpenOLECrash
FileOpen
sleep 1
Kontext "OeffnenDlg"
- printlog " Use file: graphics\\optional\\input\\generic_de.ppt "
+ printlog " Use file: graphics\optional\input\generic_de.ppt "
oFile = ConvertPath (gTesttoolPath + "graphics\required\input\generic_de.ppt")
Printlog "file: '" + oFile + "'"
Dateiname.SetText (oFile)
@@ -425,7 +426,7 @@ testcase tiOpenOLECrash
printlog "8. Choose OpenOffice.org 2.0 Formular"
Kontext "OLEObjektInsert"
- Objekttyp.Select (3)
+ Objekttyp.Select (4)
sleep (2)
PrintLog " Object: " + Objekttyp.GetSelText + " will be inserted."
printlog "Leave dialog 'Insert OLE Object' with OK"
diff --git a/testautomation/graphics/optional/includes/global/g_savepictureas.inc b/testautomation/graphics/optional/includes/global/g_savepictureas.inc
index 39d7af75e9e9..3888cf31d39e 100644
--- a/testautomation/graphics/optional/includes/global/g_savepictureas.inc
+++ b/testautomation/graphics/optional/includes/global/g_savepictureas.inc
@@ -70,6 +70,7 @@ testcase tContextSaveAsPicture
endif
Call hNewDocument
+ Call sSelectEmptyLayout
setClipboard(" ")
sleep 2
InsertGraphicsFromFile
@@ -303,6 +304,7 @@ testcase tContextSaveAsPicture
hTypeKeys "<DELETE>"
call hCloseDocument
call hNewDocument
+ Call sSelectEmptyLayout
InsertGraphicsFromFile
Kontext "GrafikEinfuegenDlg"
if GrafikEinfuegenDlg.exists(5) then
@@ -368,6 +370,7 @@ testcase tContextSavePictureLinkAsPicture
endif
Call hNewDocument
+ Call sSelectEmptyLayout
setClipboard(" ")
sleep 2
InsertGraphicsFromFile
@@ -725,6 +728,7 @@ endif
hTypeKeys "<DELETE>"
call hCloseDocument
call hNewDocument
+Call sSelectEmptyLayout
InsertGraphicsFromFile
Kontext "GrafikEinfuegenDlg"
if GrafikEinfuegenDlg.exists(5) then
diff --git a/testautomation/graphics/optional/includes/global/g_shaddow.inc b/testautomation/graphics/optional/includes/global/g_shaddow.inc
index 46ac99bb99f0..0a7708086371 100644
--- a/testautomation/graphics/optional/includes/global/g_shaddow.inc
+++ b/testautomation/graphics/optional/includes/global/g_shaddow.inc
@@ -63,6 +63,7 @@ testcase tiShaddow
'/// Open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
'/// Import picture ///'
diff --git a/testautomation/graphics/optional/includes/global/g_stylist.inc b/testautomation/graphics/optional/includes/global/g_stylist.inc
index f82a61b608e6..dc8663425e87 100644
--- a/testautomation/graphics/optional/includes/global/g_stylist.inc
+++ b/testautomation/graphics/optional/includes/global/g_stylist.inc
@@ -57,7 +57,11 @@ testcase tFormatStylistFlyer
if Gestalter.NotExists = false Then
qaErrorLog " - Expected Stylist to be closed; But is Open. Check tests."
else
- hTypekeys "<F11>" '/// open stylist by pressing key [F11] ///'
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypekeys "<F11>" '/// open stylist by pressing key [F11] ///'
+ end if
sleep 1
end if
Kontext "Gestalter"
@@ -200,7 +204,11 @@ testcase tFormatStylistDocuments
printlog " - Close stylist using F11"
Gestalter.Undock
Sleep 1
- hTypeKeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypeKeys "<F11>"
+ end if
Kontext "Gestalter"
if Gestalter.exists then
warnlog " Stylist still exists - closing again"
@@ -661,7 +669,11 @@ testcase tiFormatStylist
TabOptionenNumerierung.Cancel
sleep 1
endif
- hTypeKeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypeKeys "<F11>"
+ end if
sleep 1
Kontext "Gestalter"
if Gestalter.Exists Then Warnlog "- Stylist could not be closed pressing F11"
@@ -866,7 +878,11 @@ testcase tFormatStylist
if (Stylist.NotExists) then
ErrorLog "There is no stylist open, should be."
else
- hTypekeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypekeys "<F11>"
+ end if
Kontext "Stylist"
if (Stylist.Exists) then
ErrorLog "The Stylist should be closed now."
diff --git a/testautomation/graphics/optional/includes/global/g_tables.inc b/testautomation/graphics/optional/includes/global/g_tables.inc
index 2ffff217ba72..1414a857b598 100644
--- a/testautomation/graphics/optional/includes/global/g_tables.inc
+++ b/testautomation/graphics/optional/includes/global/g_tables.inc
@@ -231,7 +231,7 @@ testcase tiTableObjectBar
printlog "Switching between Draw/Impress"
if (UCase(gApplication)) = "IMPRESS" then
Kontext "DocumentImpress"
- DocumentImpress.TypeKeys "<MOD1 A>"
+ DocumentImpress.TypeKeys "<TAB>",3
else
Kontext "DocumentDraw"
DocumentDraw.TypeKeys "<MOD1 A>"
diff --git a/testautomation/graphics/optional/includes/global/gallery.inc b/testautomation/graphics/optional/includes/global/gallery.inc
index c1f8e741cd44..8398395c3653 100644
--- a/testautomation/graphics/optional/includes/global/gallery.inc
+++ b/testautomation/graphics/optional/includes/global/gallery.inc
@@ -469,6 +469,7 @@ testcase tGallery_GalleryView_Preview
case 46 : jpeg_bkg = 2 : iAnimation = 1 : iSound = 17
case 48 : jpeg_bkg = 2 : iAnimation = 1 : iSound = 17
case 49 : jpeg_bkg = 12 : iAnimation = 1 : iSound = 16
+ case 50 : jpeg_bkg = 12 : iAnimation = 1 : iSound = 16
case 55 : jpeg_bkg = 21 : iAnimation = 1 : iSound = 28
case 81 : jpeg_bkg = 21 : iAnimation = 1 : iSound = 10 'FHA TODO: Find out the right numbers for Asian languages.
case 82 : jpeg_bkg = 1 : iAnimation = 17 : iSound = 12
@@ -489,6 +490,7 @@ testcase tGallery_GalleryView_Preview
case 46 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2
case 48 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2
case 49 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2
+ case 50 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2
case 55 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2
case 81 : jpeg_bkg = 2 : iAnimation = 5 : iSound = 2 'FHA TODO: Find out the right numbers for Asian languages.
case 82 : jpeg_bkg = 1 : iAnimation = 5 : iSound = 2
@@ -651,6 +653,7 @@ testcase tGallery_GalleryView_Insert
case 46 : jpeg_bkg = 1 : iAnimation = 2
case 48 : jpeg_bkg = 3 : iAnimation = 1
case 49 : jpeg_bkg = 1 : iAnimation = 2
+ case 50 : jpeg_bkg = 1 : iAnimation = 2
case 55 : jpeg_bkg = 8 : iAnimation = 1
case 81 : jpeg_bkg = 1 : iAnimation = 3
case 82 : jpeg_bkg = 1 : iAnimation = 17
@@ -671,6 +674,7 @@ testcase tGallery_GalleryView_Insert
case 46 : jpeg_bkg = 1 : iAnimation = 2
case 48 : jpeg_bkg = 3 : iAnimation = 1
case 49 : jpeg_bkg = 1 : iAnimation = 2
+ case 50 : jpeg_bkg = 1 : iAnimation = 2
case 55 : jpeg_bkg = 6 : iAnimation = 1
case 81 : jpeg_bkg = 1 : iAnimation = 3
case 82 : jpeg_bkg = 1 : iAnimation = 1
@@ -859,6 +863,7 @@ testcase tGallery_GalleryView_Delete
case 39 : jpeg_bkg = 10 : iAnimation = 1 : iSound = 27
case 46 : jpeg_bkg = 1 : iAnimation = 2 : iSound = 18
case 49 : jpeg_bkg = 1 : iAnimation = 2 : iSound = 17
+ case 50 : jpeg_bkg = 1 : iAnimation = 2 : iSound = 17
case 55 : jpeg_bkg = 8 : iAnimation = 1 : iSound = 30
case 81 : jpeg_bkg = 1 : iAnimation = 3 : iSound = 10
case 82 : jpeg_bkg = 1 : iAnimation = 17 : iSound = 12
diff --git a/testautomation/graphics/optional/includes/global/id_005.inc b/testautomation/graphics/optional/includes/global/id_005.inc
index 2de7907852f1..0741bc82c8a9 100644
--- a/testautomation/graphics/optional/includes/global/id_005.inc
+++ b/testautomation/graphics/optional/includes/global/id_005.inc
@@ -723,7 +723,11 @@ testcase tiFormatStylesAndFormatting
if (Stylist.NotExists) then
ErrorLog "There was no Stylist open, should be."
else
- hTypekeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypekeys "<F11>"
+ endif
Kontext "Stylist"
if (Stylist.Exists) then
ErrorLog "The Stylist should be closed now."
diff --git a/testautomation/graphics/optional/includes/impress/i_animation.inc b/testautomation/graphics/optional/includes/impress/i_animation.inc
index af2a67956e03..471ef1fada85 100644
--- a/testautomation/graphics/optional/includes/impress/i_animation.inc
+++ b/testautomation/graphics/optional/includes/impress/i_animation.inc
@@ -39,7 +39,8 @@
testcase tExtrasAnimation
Printlog "- Tools/Animation"
Dim i
- Call hNewDocument '/// New impress document ///'
+ Call hNewDocument
+ Call sSelectEmptyLayout '/// New impress document ///'
sleep 2
InsertGraphicsFromFile '/// insert graphic file (sample.bmp) ///'
sleep 1
diff --git a/testautomation/graphics/optional/includes/impress/i_pengine2.inc b/testautomation/graphics/optional/includes/impress/i_pengine2.inc
index 6d825baedac5..f10b77f30db3 100644
--- a/testautomation/graphics/optional/includes/impress/i_pengine2.inc
+++ b/testautomation/graphics/optional/includes/impress/i_pengine2.inc
@@ -380,6 +380,7 @@ testcase tiPengine2ObjectsGetsEffects
printlog "Create a new presentation."
Call hNewDocument
+ Call sSelectEmptyLayout
sleep (1)
kontext "Toolbar"
diff --git a/testautomation/graphics/optional/includes/impress/i_saveloadlayout.inc b/testautomation/graphics/optional/includes/impress/i_saveloadlayout.inc
index f8a2b165b104..e5dbf1f53cc2 100644
--- a/testautomation/graphics/optional/includes/impress/i_saveloadlayout.inc
+++ b/testautomation/graphics/optional/includes/impress/i_saveloadlayout.inc
@@ -30,374 +30,146 @@
'* short description: Save & Load testing of Layout -templates.
'*
'**************************************************************************************
-' #1 tSaveLoadLayoutEmpty
-' #1 tSaveLoadLayoutOLE
-' #1 tSaveLoadLayoutText
-' #1 tSaveLoadLayoutOutline
-' #1 tSaveLoadLayoutPicture
-' #1 tSaveLoadLayoutChart
-' #1 tSaveLoadLayoutSpreadsheet
-'\*************************************************************************************
testcase tSaveLoadLayoutEmpty
- goto endsub
Dim NewFileDir as String
NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
- '/// Create New folder in the Work-directory ///'
+ printlog "Create New folder in the Work-directory"
printlog " Will try to create the directory: " + NewFileDir
app.mkdir NewFileDir
- '/// Create a new document, add an empty Layout, Save the document in all available Formats, and open the saved files. ///'
+ printlog "Create a new document, add an empty Layout, Save the document in all available Formats, and open the saved files."
- '/// Make new Presentation ///'
+ printlog "Make new Presentation"
gApplication = "IMPRESS"
Call hNewDocument
- '/// Choose and Insert an empty Layout. ///'
+ printlog "Choose and Insert an empty Layout."
printlog " Choose and Insert an empty Layout."
FormatModifyPage
sleep (1)
kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
+ LayoutsPreview.TypeKeys "<HOME>"
+ kontext "Pagelayout_UndoDeleteWarning"
+ if Pagelayout_UndoDeleteWarning.exists then
Pagelayout_UndoDeleteWarning.ok
end if
kontext "Tasks"
- '/// Press "Enter" to use the layout on the current slide ///'
+ printlog "Press Enter to use the layout on the current slide"
LayoutsPreview.TypeKeys "<RETURN>"
sleep (5)
- '/// Save the document in different formats... ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
+ printlog "Save the document in different formats..."
+ printlog "Close the file."
+ printlog "Load the different files."
call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
- '/// Delete the different files. ///'
+ printlog "Delete the different files."
printlog " Will try to delete the directory: " + NewFileDir
app.rmDir NewFileDir
printlog "tSaveLoadLayoutEmpty ended."
- '/// End the test ///'
+ printlog "End the test"
endcase 'tSaveLoadLayoutEmpty
'****************************************************************************************************
-testcase tSaveLoadLayoutOLE
+testcase tSaveLoadLayoutText
+ printlog "Testing layout with text."
Dim NewFileDir as String
NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
- '/// Create New folder in the Work-directory ///'
- printlog " Will try to create the directory: " + NewFileDir
+ printlog "Create New folder in the Work-directory"
+ printlog " Will try to create the directory: " + NewFileDir
app.mkdir NewFileDir
- '/// Create a new document, add a Layout with an OLE-field, Save the document in all available Formats, and open the saved files. ///'
+ printlog "Create a new document, add a Layout with a Textfield, Save the document in all available Formats, and open the saved files."
- '/// Make new Presentation ///'
+ printlog "Make new Presentation"
gApplication = "IMPRESS"
Call hNewDocument
- '/// Choose and Insert an Layout with an OLE. ///'
- printlog " Choose and Insert an Layout with an OLE."
+ printlog "Choose and Insert an Layout with a Text-field."
FormatModifyPage
sleep (1)
kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
+ LayoutsPreview.TypeKeys "<HOME>"
kontext "Pagelayout_UndoDeleteWarning"
if Pagelayout_UndoDeleteWarning.exists then
Pagelayout_UndoDeleteWarning.ok
end if
kontext "Tasks"
- '/// select the OLE placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>",13)
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- try
- sleep (2)
- kontext "OLEObjektInsert"
- sleep (1)
- OLEObjektInsert.Cancel
- Printlog " Correctly inserted a layout with an 'Insert OLE-Object'-frame."
- catch
- warnlog "Ole wasn't selected :-("
- CALL hCloseDocument
- Goto Endsub
- endcatch
- sleep (5)
-
- '/// Save the document in all available formats... ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
- call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
-
- '/// Delete the different files. ///'
- printlog " Will try to delete the directory: " + NewFileDir
- app.rmDir NewFileDir
-
- printlog "tSaveLoadLayoutOLE ended."
- '/// End the test ///'
-endcase 'tSaveLoadLayoutOLE
-
-'****************************************************************************************************
-
-testcase tSaveLoadLayoutText
- Dim NewFileDir as String
- NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
-
- '/// Create New folder in the Work-directory ///'
- printlog " Will try to create the directory: " + NewFileDir
- app.mkdir NewFileDir
-
- '/// Create a new document, add a Layout with a Textfield, Save the document in all available Formats, and open the saved files. ///'
-
- '/// Make new Presentation ///'
- gApplication = "IMPRESS"
- Call hNewDocument
-
- '/// Choose and Insert an Layout with a Text-field. ///'
- printlog " Choose and Insert an Layout with a Text-field."
- FormatModifyPage
+ printlog "select the Text placeholder and activate it with [Return]"
+ LayoutsPreview.TypeKeys ("<RIGHT>",5)
sleep (1)
- kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
- Pagelayout_UndoDeleteWarning.ok
- end if
- kontext "Tasks"
- '/// select the Text placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>")
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- DocumentImpress.TypeKeys ("<ESCAPE>")
-' LayoutsPreview.TypeKeys "<RETURN>"
+ LayoutsPreview.TypeKeys ("<Return>")
+ sleep (1)
+ kontext "DocumentImpress"
+ DocumentImpress.TypeKeys ("<TAB>")
+ DocumentImpress.TypeKeys ("<Return>")
+ DocumentImpress.TypeKeys ("<ESCAPE>")
sleep (5)
- '/// Save the document in all available formats... ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
+ printlog "Save the document in all available formats..."
+ printlog "Close the file."
+ printlog "Load the different files."
call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
- '/// Delete the different files. ///'
- printlog " Will try to delete the directory: " + NewFileDir
+ printlog "Delete the different files."
+ printlog "Will try to delete the directory: " + NewFileDir
app.rmDir NewFileDir
printlog "tSaveLoadLayoutText ended."
- '/// End the test ///'
endcase 'tSaveLoadLayoutText
'****************************************************************************************************
-testcase tSaveLoadLayoutOutline
+testcase tSaveLoadLayoutContent
Dim NewFileDir as String
NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
- '/// Create New folder in the Work-directory ///'
+ printlog "Create New folder in the Work-directory"
printlog " Will try to create the directory: " + NewFileDir
app.mkdir NewFileDir
- '/// Create a new document, add a Layout with an Outline-field, Save the document in all available Formats, and open the saved files. ///'
+ printlog "Create a new document, add a Layout with a Content-field, Save the document in all available Formats, and open the saved files."
- '/// Make new Presentation ///'
+ printlog "Make new Presentation"
gApplication = "IMPRESS"
Call hNewDocument
- '/// Choose and Insert an Layout with a Outline-field. ///'
- printlog " Choose and Insert an Layout with a Outline-field."
+ printlog "Choose and Insert an Layout with a Content-field."
FormatModifyPage
sleep (1)
kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
+ LayoutsPreview.TypeKeys "<HOME>"
+ kontext "Pagelayout_UndoDeleteWarning"
+ if Pagelayout_UndoDeleteWarning.exists then
Pagelayout_UndoDeleteWarning.ok
end if
kontext "Tasks"
- '/// select the Outline placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>",3)
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- DocumentImpress.TypeKeys ("<ESCAPE>")
- sleep (5)
-
- '/// Save the document in all available formats... ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
- call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
-
- '/// Delete the different files. ///'
- printlog " Will try to delete the directory: " + NewFileDir
- app.rmDir NewFileDir
-
- printlog "tSaveLoadLayoutOutline ended."
- '/// End the test ///'
-endcase 'tSaveLoadLayoutOutline
-
-'****************************************************************************************************
-
-testcase tSaveLoadLayoutPicture
- Dim NewFileDir as String
- NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
-
- '/// Create New folder in the Work-directory ///'
- printlog " Will try to create the directory: " + NewFileDir
- app.mkdir NewFileDir
-
- '/// Create a new document, add a Layout with a Graphic-field, Save the document in all available Formats, and open the saved files. ///'
-
- '/// Make new Presentation ///'
- gApplication = "IMPRESS"
- Call hNewDocument
-
- '/// Choose and Insert an Layout with a Graphic-field. ///'
- printlog " Choose and Insert an Layout with a Graphic-field."
- FormatModifyPage
+ printlog "select the Picture placeholder and activate it with [Return]"
+ LayoutsPreview.TypeKeys ("<RIGHT>",2)
sleep (1)
- kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
- Pagelayout_UndoDeleteWarning.ok
- end if
- kontext "Tasks"
- '/// select the Picture placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>",8)
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- DocumentImpress.TypeKeys ("<ESCAPE>")
- sleep (5)
+ LayoutsPreview.TypeKeys ("<Return>")
+ sleep (1)
+ kontext "DocumentImpress"
+ DocumentImpress.TypeKeys ("<TAB><TAB>")
+ DocumentImpress.TypeKeys ("<Return>")
+ DocumentImpress.TypeKeys ("<ESCAPE>")
+ sleep (5)
- '/// Save the document in all available formats. ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
+ printlog "Save the document in all available formats."
+ printlog "Close the file."
+ printlog "Load the different files."
call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
- '/// Delete the different files. ///'
+ printlog "Delete the different files."
printlog " Will try to delete the directory: " + NewFileDir
app.rmDir NewFileDir 'ConvertPath (gOfficePath + "user\work\LayoutTest\")
printlog "tSaveLoadLayoutPicture ended."
- '/// End the test ///'
endcase 'tSaveLoadLayoutPicture
'****************************************************************************************************
-
-testcase tSaveLoadLayoutChart
- Dim NewFileDir as String
- NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
-
- '/// Create New folder in the Work-directory ///'
- printlog " Will try to create the directory: " + NewFileDir
- app.mkdir NewFileDir
-
- '/// Create a new document, add a Layout for a Chart, Save the document in all available formats, and open the saved files. ///'
-
- '/// Make new Presentation ///'
- gApplication = "IMPRESS"
- Call hNewDocument
-
- '/// Choose and Insert an Layout with a Chart-field. ///'
- printlog " Choose and Insert an Layout with a Chart-field."
- FormatModifyPage
- sleep (1)
- kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
- Pagelayout_UndoDeleteWarning.ok
- end if
- kontext "Tasks"
- '/// select the Chart placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>",6)
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- DocumentImpress.TypeKeys ("<ESCAPE>")
- sleep (5)
-
- '/// Save the document in all available formats. ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
- call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
-
- '/// Delete the different files. ///'
- printlog " Will try to delete the directory: " + NewFileDir
- app.rmDir NewFileDir
-
- printlog "tSaveLoadLayoutChart ended."
- '/// End the test ///'
-endcase 'tSaveLoadLayoutChart
-
-'****************************************************************************************************
-
-testcase tSaveLoadLayoutSpreadsheet
- Dim NewFileDir as String
- NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\")
-
- '/// Create New folder in the Work-directory ///'
- printlog " Will try to create the directory: " + NewFileDir
- app.mkdir NewFileDir
-
- '/// Create a new document, add a Layout containing a Spreadsheet, Save the document in all available Formats, and open the saved files. ///'
-
- '/// Make new Presentation ///'
- gApplication = "IMPRESS"
- Call hNewDocument
-
- '/// Choose and Insert an Layout with a Spreadsheet-field. ///'
- printlog " Choose and Insert an Layout with a Spreadsheet-field."
- FormatModifyPage
- sleep 1
- kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>"
- kontext "Pagelayout_UndoDeleteWarning"
- if Pagelayout_UndoDeleteWarning.exists then
- Pagelayout_UndoDeleteWarning.ok
- end if
- kontext "Tasks"
- '/// select the Spreadsheet placeholder and activate it with [Return] ///'
- LayoutsPreview.TypeKeys ("<RIGHT>",7)
- sleep (1)
- LayoutsPreview.TypeKeys ("<Return>")
- sleep (1)
- kontext "DocumentImpress"
- DocumentImpress.TypeKeys ("<TAB><TAB><TAB>")
- DocumentImpress.TypeKeys ("<Return>")
- DocumentImpress.TypeKeys ("<ESCAPE>")
- sleep (5)
-
- '/// Save the document in all available formats. ///'
- '/// Close the file. ///'
- '/// Load the different files. ///'
- call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below.
-
- '/// Delete the different files. ///'
- printlog " Will try to delete the directory: " + NewFileDir
- app.rmDir NewFileDir 'ConvertPath (gOfficePath + "user\work\LayoutTest\")
-
- printlog "tSaveLoadLayoutSpreadsheet ended."
- '/// End the test ///'
-endcase 'tSaveLoadLayoutSpreadsheet
-
-'-------------------------------------------------------------------------------
-
diff --git a/testautomation/graphics/optional/includes/impress/i_slidecopy.inc b/testautomation/graphics/optional/includes/impress/i_slidecopy.inc
index d7ee257d1bb2..73971c2e889f 100644
--- a/testautomation/graphics/optional/includes/impress/i_slidecopy.inc
+++ b/testautomation/graphics/optional/includes/impress/i_slidecopy.inc
@@ -43,7 +43,8 @@ testcase tiSlideCopyNewPresentation
Dim value13 as string
printlog "This test copies one slide from one presentation to another."
printlog "Make new presentation"
- Call hNewDocument
+ Call hNewDocument
+ Call sSelectEmptyLayout
printlog "Insert three objects: Connector, Door-plate, and Smiley."
printlog "First we Insert a Connector."
@@ -264,11 +265,10 @@ testcase tiSlideCopyDuplicate
Dim value12 as string
Dim value13 as string
dim i as integer
- '/// Make a duplicate of a slide. In the same presentation ///'
- '/// Make new presentation ///'
+ printlog "Make new presentation"
Call hNewDocument
- '/// Insert three objects: Connector, Door-plate, and Smiley ///'
- '1 Insert Connector.
+ Call sSelectEmptyLayout
+ printlog "Insert Connector."
kontext "Toolbar"
sleep 1
try
@@ -289,11 +289,11 @@ testcase tiSlideCopyDuplicate
hTypeKeys "<TAB>", 1
sleep (1)
- 'rename object
+ printlog "rename object"
DocumentImpress.TypeKeys "<SHIFT F10>"
sleep 1
- 'Choose rename.
+ printlog "Choose rename"
if hMenuFindSelect(27027, true, 14) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
@@ -307,11 +307,11 @@ testcase tiSlideCopyDuplicate
kontext "DocumentImpress"
hMouseClick DocumentImpress, 90, 90
- '2 Insert Door-plate.
+ printlog "2 Insert Door-plate"
kontext "Toolbar"
sleep 1
try
- StarShapes.TearOff ' insert connector
+ StarShapes.TearOff
catch
warnlog "bug for GH from FHA; .tearoff doesnt tell success"
endcatch
@@ -328,11 +328,11 @@ testcase tiSlideCopyDuplicate
hTypeKeys "<TAB>", 2
sleep (1)
- 'Rename object
+ printlog "Rename object"
kontext "DocumentImpress"
DocumentImpress.TypeKeys "<SHIFT F10>"
sleep (1)
- 'Choose rename.
+ printlog "Choose rename."
if hMenuFindSelect(27027, true, 15) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
@@ -346,11 +346,11 @@ testcase tiSlideCopyDuplicate
kontext "DocumentImpress"
hMouseClick DocumentImpress, 90, 90
- '3 Insert Smiley.
+ printlog "Insert Smiley."
kontext "Toolbar"
sleep 1
try
- SymbolShapes.TearOff ' insert connector
+ SymbolShapes.TearOff
catch
warnlog "bug for GH from FHA; .tearoff doesnt tell success"
endcatch
@@ -366,10 +366,10 @@ testcase tiSlideCopyDuplicate
hTypeKeys "<TAB>", 3
sleep (1)
- 'rename object
+ printlog "rename object"
DocumentImpress.TypeKeys "<SHIFT F10>"
sleep (1)
- 'Choose rename.
+ printlog "Choose rename"
if hMenuFindSelect(27027, true, 15) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
@@ -383,7 +383,7 @@ testcase tiSlideCopyDuplicate
kontext "DocumentImpress"
hMouseClick DocumentImpress, 90, 90
- '/// Close the bars we opened before. ///'
+ printlog "Close the bars we opened before."
kontext "Connectorsbar"
if Connectorsbar.Exists then Connectorsbar.Close
kontext "SymbolShapes"
@@ -391,22 +391,22 @@ testcase tiSlideCopyDuplicate
kontext "StarShapes"
if StarShapes.Exists then StarShapes.Close
- '/// Copy the slide to the clipboard ///'
+ printlog "Copy the slide to the clipboard"
kontext "Slides"
SlidesControl.TypeKeys "<PAGEUP>"
sleep (1)
SlidesControl.TypeKeys "<SHIFT F10>"
sleep (1)
- 'Choose `Copy`
+ printlog "Choose `Copy`"
if hMenuFindSelect(5711, true, 10) = false then
Warnlog "Context-Menu-entry `Copy` was not found.Therefore the test ends."
Call hCloseDocument
Goto Endsub
endif
- '/// Paste the content from the Clipboard ///'
+ printlog "Paste the content from the Clipboard"
kontext "Slides"
- 'open context-menu choose 'paste'
+ printlog "open context-menu choose 'paste'"
EditPaste
@@ -416,31 +416,31 @@ testcase tiSlideCopyDuplicate
InsertPaste.OK
endif
sleep (2)
- '/// Check if we have two slides, and that the objects exists, and has the right values ///'
+ printlog "Check if we have two slides, and that the objects exists, and has the right values "
kontext "Slides"
SlidesControl.TypeKeys "<PAGEUP>"
- for i = 1 to 2 ' we have two slides, so we do this two times to check everything.
+ for i = 1 to 2
Printlog "Checking objects the " + i + " + time."
kontext "DocumentImpress"
hMouseClick DocumentImpress, 90, 90
- DocumentImpress.TypeKeys "<TAB>" 'Select the first object.
+ DocumentImpress.TypeKeys "<TAB>"
sleep (1)
- 'Bring up the kontext-menu for the object
+
DocumentImpress.TypeKeys "<SHIFT F10>"
sleep 1
- 'Choose rename.
+ printlog "Choose rename"
if hMenuFindSelect(27027, true, 14) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
Goto Endsub
endif
- 'Read out what the name is, and check if its correct.
- kontext "NameDlgObject" '"LinieName" "NameDlgPage"
+ printlog "Read out what the name is, and check if its correct."
+ kontext "NameDlgObject"
value1 = NameField.GetText
- NameDlgObject.OK 'TypeKeys "<Enter>"
+ NameDlgObject.OK
if value1 = "First" then
printlog "First object was found correctly"
@@ -453,14 +453,14 @@ testcase tiSlideCopyDuplicate
sleep (1)
DocumentImpress.TypeKeys "<SHIFT F10>"
- 'Choose rename.
+ printlog "Choose rename"
if hMenuFindSelect(27027, true, 15) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
Goto Endsub
endif
- 'Read out what the name is, and check if its correct.
+ printlog "Read out what the name is, and check if its correct."
kontext "NameDlgObject"
value12 = NameField.GetText
NameDlgObject.OK
@@ -472,20 +472,21 @@ testcase tiSlideCopyDuplicate
endif
hTypeKeys "<ESCAPE>"
- hTypeKeys "<TAB>", 3 'Select the third object.
+ printlog "Select the third object."
+ hTypeKeys "<TAB>", 3
sleep (1)
- 'Bring up the kontext-menu for the object
+ printlog "Bring up the kontext-menu for the object"
DocumentImpress.TypeKeys "<SHIFT F10>"
sleep 1
- 'Choose rename.
+ printlog "Choose rename"
if hMenuFindSelect(27027, true, 15) = false then
Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends."
Call hCloseDocument
Goto Endsub
endif
- 'Read out what the name is, and check if its correct.
+ printlog "Read out what the name is, and check if its correct."
kontext "NameDlgObject"
value13 = NameField.GetText
NameDlgObject.OK
@@ -499,7 +500,7 @@ testcase tiSlideCopyDuplicate
SlidesControl.TypeKeys "<DOWN>"
next i
- '/// Close Presentation. End testcase ///'
+ printlog " Close Presentation. End testcase "
Call hCloseDocument
endcase 'tiSlidecopyDuplicate
diff --git a/testautomation/graphics/optional/includes/impress/i_slidelayer.inc b/testautomation/graphics/optional/includes/impress/i_slidelayer.inc
index d7ee085de381..597762e8cf7e 100644
--- a/testautomation/graphics/optional/includes/impress/i_slidelayer.inc
+++ b/testautomation/graphics/optional/includes/impress/i_slidelayer.inc
@@ -49,6 +49,7 @@ testcase tiInsertExpandSlide
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
'/// create presupposition ///
'///+ View->Master View->Outline View ///'
ViewWorkspaceOutlineView
diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow.inc b/testautomation/graphics/optional/includes/impress/i_slideshow.inc
index 9a8118b0cc54..3a2b56fa5511 100644
--- a/testautomation/graphics/optional/includes/impress/i_slideshow.inc
+++ b/testautomation/graphics/optional/includes/impress/i_slideshow.inc
@@ -970,7 +970,11 @@ testcase tSlideShowSlideTransition
WaitSlot (3000)
try
'/// type key [F11] to open the stylist (to check ending of presenation) ///'
- hTypeKeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypeKeys "<F11>"
+ endif
Sleep (3)
Kontext "Gestalter"
Sleep (3)
diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow2.inc b/testautomation/graphics/optional/includes/impress/i_slideshow2.inc
index 0bc7e9a80654..1b88116f1b5a 100644
--- a/testautomation/graphics/optional/includes/impress/i_slideshow2.inc
+++ b/testautomation/graphics/optional/includes/impress/i_slideshow2.inc
@@ -44,7 +44,8 @@ testcase tPraesentationAnimation
Dim i
Printlog "- Slideshow/Animation"
- Call hNewDocument '/// new document ///'
+ Call hNewDocument
+ Call sSelectEmptyLayout '/// new document ///'
sleep 2
InsertGraphicsFromFile '/// insert graphic ///'
Kontext "OeffnenDlg"
@@ -411,6 +412,7 @@ testcase tSlideShowInteraction
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 5
setStartCurrentPage(TRUE) '/// Set "start with current page to ON ///'
@@ -839,6 +841,8 @@ endcase
testcase tAendernObjektBenennen
Printlog "- Context/Name object"
Call hNewDocument
+ Call sSelectEmptyLayout '/// new document ///'
+
sleep 1
Kontext "DocumentImpress"
if NOT DocumentImpress.Exists then
diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow3.inc b/testautomation/graphics/optional/includes/impress/i_slideshow3.inc
index 0f23f412bddf..0cf806cd74cd 100644
--- a/testautomation/graphics/optional/includes/impress/i_slideshow3.inc
+++ b/testautomation/graphics/optional/includes/impress/i_slideshow3.inc
@@ -43,6 +43,7 @@
testcase tExtrasInteraktion
Printlog " - SlideShow/Interaction"
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
Call hTextrahmenErstellen ("Seite 1",10,10,40,40) '/// create textbox ///'
SlideShowPresentationSettings '/// Set slide show settings ///'
@@ -77,6 +78,7 @@ testcase tExtrasInteraktion
endcatch
hCloseDocument
Call hNewDocument
+ Call sSelectEmptyLayout
Call hRechteckErstellen (50,50,80,80) '/// create rectangle ///'
SlideShowInteraction
Kontext "Interaktion"
diff --git a/testautomation/graphics/optional/includes/impress/i_us2_present.inc b/testautomation/graphics/optional/includes/impress/i_us2_present.inc
index a1c7ab18acb6..6c8fede6a530 100644
--- a/testautomation/graphics/optional/includes/impress/i_us2_present.inc
+++ b/testautomation/graphics/optional/includes/impress/i_us2_present.inc
@@ -168,6 +168,7 @@ testcase i_us2_pres1
SlidesControl.TypeKeys "<HOME>"
SlidesControl.TypeKeys "<PAGEDOWN>", 10
SlidesControl.TypeKeys "<RETURN>"
+call sSelectEmptyLayout
printlog "Insert Smiley, + two circles around the eyes, + two new pupils,"
printlog "placed at some interesteing place inside the circles."
Kontext "Toolbar"
@@ -228,8 +229,6 @@ testcase i_us2_pres1
InsertSlide
printlog " Inserted new slide."
kontext "DocumentImpress"
- EditSelectAll
- DocumentImpress.TypeKeys "<DELETE>"
printlog "Bla bla about everything..."
call hTextrahmenErstellen ("Bla bla about everything...",20,20,70,30)
@@ -237,8 +236,6 @@ testcase i_us2_pres1
InsertSlide
printlog " Inserted new slide."
kontext "DocumentImpress"
- EditSelectAll
- DocumentImpress.TypeKeys "<DELETE>"
printlog "Write text: Q & A"
call hTextrahmenErstellen ("Q & A",20,20,70,30)
DocumentImpress.TypeKeys "<SHIFT HOME>"
@@ -247,8 +244,7 @@ testcase i_us2_pres1
printlog "Add a new slide."
InsertSlide
kontext "DocumentImpress"
- EditSelectAll
- DocumentImpress.TypeKeys "<DELETE>"
+
printlog "Thanks for listening, time for coffee... (ending)"
call hTextrahmenErstellen ("Class dismissed...",20,20,70,30)
diff --git a/testautomation/graphics/optional/includes/impress/i_us_present.inc b/testautomation/graphics/optional/includes/impress/i_us_present.inc
index 9272fda4c2a7..26a17b3a80be 100644
--- a/testautomation/graphics/optional/includes/impress/i_us_present.inc
+++ b/testautomation/graphics/optional/includes/impress/i_us_present.inc
@@ -40,76 +40,108 @@
'\********************************************************************
testcase i_us_presentation1
- dim iPictures as integer
- dim PresentationFile1 as string
- PresentationFile1 = ConvertPath ((ConvertPath (gOfficePath + "user\work\PowerPes1.odp")))
- Call hNewDocument '/// New impress document ///'
- WaitSlot (2000)
- kontext "DocumentImpress"
- '/// 1. ViewMaster: 2nd master - Background: picture (Gallery) ///'
- '/// - 50% Transparency ///'
- '/// - Mosaic 16px x 16px ///'
- '/// - Close Master ///'
-
- '/// Add second Master-Page ///'
- ViewMasterPage
- kontext "Slides"
- SlidesControl.OpenContextMenu(true)
- sleep (2)
- MenuSelect(MenuGetItemID(1)) 'New Master
- sleep (1)
- printlog " Inserted second Master-Slide"
-
- '/// - Background: picture (Gallery) ///'
- Kontext "Gallery"
- if Gallery.Exists(2) then
- warnlog " The Gallery was already visible. Check earlier ran tests for inconsistency."
- sleep (2)
- else
- ToolsGallery
- WaitSlot (2000)
- end if
+ dim iPictures as integer
+ dim PresentationFile1 as string
+ PresentationFile1 = ConvertPath ((ConvertPath (gOfficePath + "user\work\PowerPes1.odp")))
+ printlog "New impress document"
+ Call hNewDocument
+ Call sSelectEmptyLayout
+ WaitSlot (2000)
+ kontext "DocumentImpress"
+ printlog "Add second Master-Page "
+ ViewMasterPage
+ kontext "Slides"
+ SlidesControl.OpenContextMenu(true)
+ sleep (2)
+ printlog "New master"
+ MenuSelect(MenuGetItemID(1))
+ sleep (1)
+ ViewMasterPage
+ kontext "Slides"
+ SlidesControl.OpenContextMenu(true)
+ sleep (2)
+ MenuSelect(MenuGetItemID(1)) 'New Master
+ sleep (1)
+ printlog " Inserted second Master-Slide"
- if gOOO = TRUE then 'OpenOffice.org
- select case iSprache
- case 01 : iPictures = 1 'English
- case else : iPictures = 1 'Unknown
- warnlog "Please insert the entrienumbers for 'Backgrounds'. Language: " + iSprache
- end select
-
- else ' StarOffice...
- select case iSprache
- case 01 : iPictures = 21 'English
- case 07 : iPictures = 28 'Russian
- case 31 : iPictures = 04 'Netherlands
- case 33 : iPictures = 22 'French
- case 34 : iPictures = 12 'Spanish
- case 36 : iPictures = 17 'Hungaria
- case 39 : iPictures = 23 'Italian
- case 46 : iPictures = 09 'Swedish
- case 48 : iPictures = 20 'Polish
- case 49 : iPictures = 11 'German
- case 55 : iPictures = 16 'Portuguese
- case 81 : iPictures = 22 'Japanese
- case 82 : iPictures = 04 'Korean
- case 86 : iPictures = 06 'Simplified
- case 88 : iPictures = 17 'Traditional
- case else : iPictures = 21 'Unknown
+ printlog "set background to picture(Gallery)"
+ Kontext "Gallery"
+ if Gallery.Exists(2) then
+ warnlog " The Gallery was already visible. Check earlier ran tests for inconsistency."
+ sleep (2)
+ else
+ ToolsGallery
+ WaitSlot (2000)
+ end if
+
+ if gOOO = TRUE then 'OpenOffice.org
+ select case iSprache
+ case 01 : iPictures = 1 'English
+ case else : iPictures = 1 'Unknown
warnlog "Please insert the entrienumbers for 'Backgrounds'. Language: " + iSprache
- end select
+ end select
+
+ else ' StarOffice...
+ select case iSprache
+ case 01 : iPictures = 21 'English
+ case 07 : iPictures = 28 'Russian
+ case 31 : iPictures = 04 'Netherlands
+ case 33 : iPictures = 22 'French
+ case 34 : iPictures = 12 'Spanish
+ case 36 : iPictures = 17 'Hungaria
+ case 39 : iPictures = 23 'Italian
+ case 46 : iPictures = 09 'Swedish
+ case 48 : iPictures = 20 'Polish
+ case 49 : iPictures = 11 'German
+ case 55 : iPictures = 16 'Portuguese
+ case 81 : iPictures = 22 'Japanese
+ case 82 : iPictures = 04 'Korean
+ case 86 : iPictures = 06 'Simplified
+ case 88 : iPictures = 17 'Traditional
+ case else : iPictures = 21 'Unknown
+ warnlog "Please insert the entrienumbers for 'Backgrounds'. Language: " + iSprache
+ end select
end if
-
- kontext "Gallery"
- Gallerys.Select (iPictures)
+ kontext "Gallery"
+ Gallerys.Select (iPictures)
+ View.TypeKeys "<HOME><RIGHT><RIGHT>"
+ printlog "OpenContextMenu"
+ View.TypeKeys "<SHIFT F10>"
+ sleep (2)
+ MenuSelect(MenuGetItemID(1))
+ sleep (2)
+ MenuSelect(MenuGetItemID(1))
+ sleep (2)
+ printlog "Check that we really got a copy of the object"
+ kontext "DocumentImpress"
+ DocumentImpress.OpenContextMenu(true)
+ sleep (2)
+ MenuSelect 27353
+ sleep (2)
+ Kontext "ExportierenDlg"
+ if ExportierenDlg.IsVisible(5) then
+ printlog " Gallery-object correctly copied into Slide."
+ ExportierenDlg.Close
+ else
+ warnlog " Doesn't seem like we copied anything from the Gallery... ?"
+ end if
+ kontext "GraphicObjectbar"
+ if GraphicObjectbar.Exists(5) = FALSE then
+ kontext "DocumentImpress"
+ ViewToolbarsPicture
+ end if
+
+ Kontext "Gallery"
View.TypeKeys "<HOME><RIGHT><RIGHT>"
- View.TypeKeys "<SHIFT F10>" 'OpenContextMenu(true)
+ printlog "'OpenContextMenu"
+ View.TypeKeys "<SHIFT F10>"
sleep (2)
MenuSelect(MenuGetItemID(1)) 'Insert
sleep (2)
MenuSelect(MenuGetItemID(1)) 'Copy
sleep (2)
- '/// Check that we really got a copy of the object ///'
+ printlog "Check that we really got a copy of the object "
kontext "DocumentImpress"
DocumentImpress.OpenContextMenu(true)
sleep (2)
@@ -128,32 +160,32 @@ testcase i_us_presentation1
ViewToolbarsPicture
end if
- '/// - 50% Transparency ///'
- WaitSlot (2000)
- kontext "GraphicObjectbar" ' the one with Transparency
- Transparenz.SetText "50"
- sleep (1)
-
- '/// - Mosaic 16px x 16px ///'
- Filter.TearOff
- sleep (1)
- kontext "GraphicFilterBar"
- Mosaic.Click
- WaitSlot (2000)
- kontext "Mosaic"
- Width.SetText "16"
- Height.SetText "16"
- Mosaic.OK
-
- kontext "GraphicFilterBar"
- GraphicFilterBar.Close
-
- ToolsGallery
- WaitSlot (1000)
- kontext "DocumentImpress"
- gMouseClick 50,50
+ printlog " 50% Transparency"
+ WaitSlot (2000)
+ kontext "GraphicObjectbar"
+ Transparenz.SetText "50"
+ sleep (1)
+
+ printlog "Mosaic 16px x 16px"
+ Filter.TearOff
+ sleep (1)
+ kontext "GraphicFilterBar"
+ Mosaic.Click
+ WaitSlot (2000)
+ kontext "Mosaic"
+ Width.SetText "16"
+ Height.SetText "16"
+ Mosaic.OK
+
+ kontext "GraphicFilterBar"
+ GraphicFilterBar.Close
+
+ ToolsGallery
+ WaitSlot (1000)
+ kontext "DocumentImpress"
+ hTypeKeys "<TAB>"
+
sleep (1)
-' DocumentImpress.TypeKeys "<TAB>", 6
FormatPositionAndSize
WaitSlot (1000)
kontext
@@ -164,23 +196,22 @@ testcase i_us_presentation1
SizePosition.TypeKeys "<RIGHT><DOWN>"
TabPositionAndSize.OK
- '/// - Close Master ///'
+ printlog "Close Master"
ViewNormal
WaitSlot (1000)
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile1)
printlog "OK saved at ", PresentationFile1
WaitSlot (1000)
ActiveDeactivateCTLSupport (FALSE)
WaitSlot (2000)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
-endcase
-
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
+endcase 'i_us_presentation1
+'-------------------------------------------------------------------------------
testcase i_us_presentation2
dim PresentationFile1 as string
dim PresentationFile2 as string
@@ -192,12 +223,12 @@ testcase i_us_presentation2
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
- '/// New Slide ///'
+ printlog "New Slide"
kontext "slides"
SlidesControl.TypeKeys "<PAGEDOWN>"
SlidesControl.TypeKeys "<PAGEDOWN>"
@@ -208,21 +239,23 @@ testcase i_us_presentation2
MenuSelect(MenuGetItemID(1)) 'New Slide 'No 2
printlog " Inserted second normal Slide"
- '/// 2. Layouts: Text. Bild: Gallery: Animation - Gif ///'
+ printlog "2. Layouts: Text. Bild: Gallery: Animation - Gif"
Kontext "Tasks"
- LayoutsPreview.TypeKeys "<HOME>" 'to get to the very first position
- LayoutsPreview.TypeKeys "<RIGHT>", 9 'to get to the right position
+ printlog "to get to the very first position"
+ LayoutsPreview.TypeKeys "<HOME>"
+ printlog "'to get to the right position"
+ LayoutsPreview.TypeKeys "<RIGHT>", 9
LayoutsPreview.TypeKeys "<RETURN>"
Sleep (1)
ViewNormal
- '/// 3. Hide Slidepane (Oops! The user were too fast: accidently hide the pane) ///'
+ printlog "3. Hide Slidepane (Oops! The user were too fast: accidently hide the pane)"
kontext "Slides"
SlidesControl.FadeOut
WaitSlot (1000)
- '/// 4. Restore Pane. ///'
+ printlog "4. Restore Pane."
SlidesControl.FadeIn
printlog " Did the 'mistake' to FadeIn/Out the Slidepane"
@@ -233,7 +266,7 @@ testcase i_us_presentation2
DocumentImpress.TypeKeys "<RETURN>"
sleep (1)
- '/// Graphics-Import-dialogue. Select "i_us_large.jpg" ///'
+ printlog "Graphics-Import-dialogue. Select i_us_large.jpg"
Kontext "GrafikEinfuegenDlg"
sleep (2)
Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\i_us_large.jpg")
@@ -242,11 +275,11 @@ testcase i_us_presentation2
WaitSlot (1000)
Kontext "DocumentImpress"
- '/// Deselect graphic ///'
+ printlog "Deselect graphic"
DocumentImpress.MouseDoubleClick 90,90
printlog " Inserted Graphic into the second Slide"
- '/// Change text on the two text-boxes ///'
+ printlog "Change text on the two text-boxes"
DocumentImpress.TypeKeys "<TAB>" 'First text.
DocumentImpress.TypeKeys "<RETURN>" 'To get into edit-mode.
DocumentImpress.TypeKeys "The World has just become a bit easier"
@@ -264,19 +297,18 @@ testcase i_us_presentation2
DocumentImpress.TypeKeys "Energy-efficient"
DocumentImpress.TypeKeys "<ESCAPE><ESCAPE>"
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile2)
printlog "OK saved at ", PresentationFile1
sleep (1)
ActiveDeactivateCTLSupport (FALSE)
sleep (2)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation2
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
-
+'-------------------------------------------------------------------------------
testcase i_us_presentation3
dim PresentationFile2 as string
dim PresentationFile3 as string
@@ -288,12 +320,12 @@ testcase i_us_presentation3
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
- '/// Insert New Slide ///'
+ printlog "Insert New Slide"
kontext "slides"
SlidesControl.TypeKeys "<PAGEDOWN>"
SlidesControl.TypeKeys "<PAGEDOWN>"
@@ -302,7 +334,7 @@ testcase i_us_presentation3
kontext "DocumentImpress"
InsertSlide 'No 3
- '/// 5. Layout. Clip/Text ///'
+ printlog "5. Layout. Clip/Text"
kontext "Tasks"
LayoutsPreview.TypeKeys "<HOME>" 'to get to the very first position
LayoutsPreview.TypeKeys "<RIGHT>", 4 'to get to the right position
@@ -316,8 +348,9 @@ testcase i_us_presentation3
DocumentImpress.TypeKeys "<TAB><RETURN>"
DocumentImpress.TypeKeys "A new form"
- '/// 6. (Fat picture) InsertPictureFromFile: (empty slide) (ev size-fit) ///'
- InsertGraphicsFromFile '/// insert graphic file (i_us_large.jpg) ///'
+ printlog "6. (Fat picture) InsertPictureFromFile: (empty slide) (ev size-fit)"
+ printlog "insert graphic file (i_us_large.jpg)"
+ InsertGraphicsFromFile
WaitSlot (1000)
Kontext "GrafikEinfuegenDlg"
Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\i_us_large.jpg")
@@ -326,29 +359,28 @@ testcase i_us_presentation3
WaitSlot (2000)
Kontext "DocumentImpress"
- '/// The user corrects the picture ///'
+ printlog "The user corrects the picture"
DocumentImpress.MouseDown 50,50
DocumentImpress.MouseUp 50,50
DocumentImpress.TypeKeys "<DOWN>", 30
- '/// Deselect graphic ///'
+ printlog "Deselect graphic"
DocumentImpress.MouseDoubleClick 90,90
printlog " Wrote Text, Inserted Graphic, and moved it in the third Slide"
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile3)
printlog "OK saved at ", PresentationFile3
sleep (1)
ActiveDeactivateCTLSupport (FALSE)
sleep (2)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation3
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
-
+'-------------------------------------------------------------------------------
testcase i_us_presentation4
dim PresentationFile3 as string
dim PresentationFile4 as string
@@ -361,7 +393,7 @@ testcase i_us_presentation4
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
@@ -374,9 +406,10 @@ testcase i_us_presentation4
SlidesControl.TypeKeys "<PAGEDOWN>"
kontext "DocumentImpress"
- InsertSlide 'No 4
+printlog "insert slide no 4"
+InsertSlide
- '/// - Background: picture (Gallery) ///'
+ printlog "Background: picture (Gallery)"
Kontext "Gallery"
if Gallery.Exists(2) then
warnlog " The Gallery was already visible. Check earlier ran tests for inconsistency."
@@ -418,7 +451,7 @@ testcase i_us_presentation4
sleep (1)
MenuSelect(MenuGetItemID(1)) 'Copy
- '/// Check that we really got a copy of the object ///'
+ printlog "Check that we really got a copy of the object"
kontext "DocumentImpress"
DocumentImpress.OpenContextMenu(true)
WaitSlot (1000)
@@ -436,13 +469,13 @@ testcase i_us_presentation4
DocumentImpress.TypeKeys "<UP>", 82
DocumentImpress.TypeKeys "<LEFT>", 130
- '/// Deselect graphic ///'
+ printlog "Deselect graphic"
DocumentImpress.MouseDoubleClick 90,90
- '/// Close the Gallery ///'
+ printlog "Close the Gallery"
ToolsGallery
- '/// Change Text on slide ///'
+ printlog "Change Text on slide"
DocumentImpress.TypeKeys "<TAB>"
DocumentImpress.TypeKeys "<RETURN>"
DocumentImpress.TypeKeys "The process starts to flourish"
@@ -493,19 +526,18 @@ testcase i_us_presentation4
printlog " Inserted fourth slide with Gallery-object."
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile4)
printlog "OK saved at ", PresentationFile4
sleep (1)
ActiveDeactivateCTLSupport (FALSE)
sleep (2)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation4
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
-
+'-------------------------------------------------------------------------------
testcase i_us_presentation5
dim PresentationFile4 as string
dim PresentationFile5 as string
@@ -517,7 +549,7 @@ testcase i_us_presentation5
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
@@ -532,30 +564,29 @@ testcase i_us_presentation5
SlidesControl.TypeKeys "<PAGEDOWN>"
kontext "DocumentImpress"
- '/// 8. New Slide. (Insert Menu) (Duplicate slide) ///'
+ printlog "8. New Slide. (Insert Menu) (Duplicate slide)"
InsertDuplicateSlide 'No 5
- 'Change the text in some way. (the user is making a joke with the audience)
+ printlog "Change the text in some way. (the user is making a joke with the audience)"
gMouseClick 90,90
DocumentImpress.TypeKeys "<TAB>"
DocumentImpress.TypeKeys "<RETURN>"
- EditSelectAll 'DocumentImpress.TypeKeys "<MOD1 A>"
+ EditSelectAll
DocumentImpress.TypeKeys "And does it with strength..."
printlog " Inserted fifth slide with audience-joke."
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile5)
printlog "OK saved at ", PresentationFile5
sleep (1)
ActiveDeactivateCTLSupport (FALSE)
sleep (2)
- '/// Close Document///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation5
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
-
+'-------------------------------------------------------------------------------
testcase i_us_presentation6
dim PresentationFile5 as string
dim PresentationFile6 as string
@@ -567,7 +598,7 @@ testcase i_us_presentation6
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
@@ -581,8 +612,8 @@ testcase i_us_presentation6
SlidesControl.TypeKeys "<PAGEDOWN>"
kontext "DocumentImpress"
- '/// 9. Q&A Slide ///'
- InsertSlide 'No 6
+ printlog "9. Q&A Slide"
+ InsertSlide
WaitSlot (1000)
kontext "DocumentImpress"
DocumentImpress.TypeKeys "<TAB>"
@@ -611,19 +642,18 @@ testcase i_us_presentation6
kontext "DocumentImpress"
printlog " Inserted sixth slide with Q&A."
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile6)
printlog "OK saved at ", PresentationFile6
sleep (1)
ActiveDeactivateCTLSupport (FALSE)
WaitSlot (2000)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation6
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
-
+'-------------------------------------------------------------------------------
testcase i_us_presentation7
dim sFilter as string
@@ -639,7 +669,7 @@ testcase i_us_presentation7
WaitSlot (10000)
else
warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester."
- '/// New impress document ///'
+ printlog "New impress document"
Call hNewDocument
WaitSlot (2000)
end if
@@ -655,7 +685,7 @@ testcase i_us_presentation7
SlidesControl.TypeKeys "<PAGEDOWN>"
kontext "DocumentImpress"
- '/// 10. Ending Slide ///'
+ printlog " inserting Ending Slide"
InsertSlide 'No 7
DocumentImpress.TypeKeys "Ende"
printlog " Inserted ending -slide."
@@ -676,36 +706,35 @@ testcase i_us_presentation7
hTypeKeys "<F5>"
kontext "DocumentPresentation"
- sleep (3)
- DocumentPresentation.TypeKeys "<PAGEDOWN>"
- sleep (2)
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
- sleep (2)
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
+ sleep (10)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
sleep (10)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
- sleep (2)
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
+ sleep (5)
DocumentPresentation.TypeKeys "<PAGEDOWN>"
- sleep (2)
- DocumentPresentation.TypeKeys "<PAGEDOWN>"
- DocumentPresentation.TypeKeys "<PAGEDOWN>"
- sleep (2)
- DocumentPresentation.TypeKeys "<ESCAPE>"
+
if DocumentPresentation.Exists(5) then
+ hTypeKeys "<ESC>"
warnlog " Presentation should have ended. Please inform Automatic Tester."
end if
kontext "DocumentImpress"
- '/// Save Document ///'
+ printlog "Save Document"
call hFileSaveAsKill (PresentationFile7)
printlog "OK saved at ", PresentationFile7
sleep (1)
- '/// Save as Powerpoint-file ///'
+ printlog "Save as Powerpoint-file"
FileSaveAs
Kontext "SpeichernDlg"
Dateiname.SetText sFileName
@@ -719,21 +748,19 @@ testcase i_us_presentation7
printlog "Saved as: " + sFileName
sleep (3)
- '/// Close the office and reload the file ///'
+ printlog "Close the office and reload the file"
FileClose
Kontext "Messagebox"
if Messagebox.Exists(2) then Messagebox.Yes
sleep (3)
- '/// Open the saved file ///'
+ printlog "Open the saved file"
hFileOpen sFileName
printlog "File opened: " + sFileName
sleep (3)
- '/// Close the office-session ///'
+ printlog "Close the office-session"
ActiveDeactivateCTLSupport (FALSE)
sleep (2)
- '/// Close Document ///'
+ printlog "Close Document"
Call hCloseDocument
endcase 'i_us_presentation7
-
-'00oo...//==---...---...---...---....---...---...---...---...---...---...--..--.--.-.-.-.-....---....
diff --git a/testautomation/graphics/required/includes/global/id_002.inc b/testautomation/graphics/required/includes/global/id_002.inc
index 55dec0008ac1..8c729871cbb3 100644
--- a/testautomation/graphics/required/includes/global/id_002.inc
+++ b/testautomation/graphics/required/includes/global/id_002.inc
@@ -232,7 +232,7 @@ testcase tiEditFields
hTypeKeys "<ESCAPE>"
printlog "With a Tab we catch always the Object"
- hTypeKeys "<Tab>"
+ hTypeKeys "<Tab>",3
printlog "Here we enter Edit-Mode and therefore also the right place"
hTypeKeys "<F2>"
printlog "Here we enter Edit-Mode and therefore also the right place"
@@ -406,7 +406,7 @@ testcase tiEditObjectProperties
gMouseDoubleClick 1,1
printlog " select frame "
- hTypekeys "<tab>"
+ hTypekeys "<tab>",3
printlog " Edit->Object->Properties "
kontext
@@ -448,7 +448,7 @@ testcase tiEditObjectEdit
gMouseClick 20,1
printlog " select object "
- hTypekeys "<tab>"
+ hTypekeys "<tab>",3
printlog " Edit->Object->Edit "
EditObjectEdit
@@ -464,7 +464,7 @@ testcase tiEditObjectEdit
endcatch
printlog " select object "
- EditSelectAll
+ hTypekeys "<tab>",3
printlog " Edit->Object->Save Copy As "
EditObjectSaveCopyAs
@@ -531,6 +531,7 @@ testcase tiEditHyperlink
printlog " open application"
hNewDocument
+ Call sSelectEmptyLayout
printlog " Insert->Hyperlink"
InsertHyperlink
WaitSlot (5000)
@@ -555,7 +556,9 @@ testcase tiEditHyperlink
Uebernehmen.Click
Hyperlink.Close
printlog " presupposition to enable edit->hyperlink: <TAB><F2><STRG+a>"
- hTypeKeys "<TAB><F2>"
+ hTypeKeys "<TAB>"
+ hTypeKeys "<F2>"
+ hTypeKeys "<MOD1 SHIFT RIGHT>"
EditSelectAll
try
printlog " Edit->Hyperlink "
diff --git a/testautomation/graphics/required/includes/global/id_005.inc b/testautomation/graphics/required/includes/global/id_005.inc
index 8b19fd601948..94898e620e46 100644
--- a/testautomation/graphics/required/includes/global/id_005.inc
+++ b/testautomation/graphics/required/includes/global/id_005.inc
@@ -923,7 +923,11 @@ testcase tiFormatStylesAndFormatting
ErrorLog "There was no Stylist open, should be."
else
printlog "Close Stylist"
- hTypekeys "<F11>"
+ if lcase(gPlatform) = "osx" then
+ hTypekeys "<mod1 t>"
+ else
+ hTypekeys "<F11>"
+ endif
Kontext "Stylist"
if (Stylist.Exists) then
ErrorLog "The Stylist should be closed now."
@@ -960,6 +964,7 @@ testcase tiFormatGroup
printlog "open application"
Call hNewDocument
+ Call sSelectEmptyLayout
printlog "create 2 rectangles"
hRechteckErstellen ( 10, 10, 20, 20 )
hRechteckErstellen ( 30, 30, 40, 40 )
diff --git a/testautomation/graphics/required/includes/global/id_007.inc b/testautomation/graphics/required/includes/global/id_007.inc
index 3c4c3ca5b08b..242a87f1fce4 100644
--- a/testautomation/graphics/required/includes/global/id_007.inc
+++ b/testautomation/graphics/required/includes/global/id_007.inc
@@ -360,6 +360,7 @@ testcase tdContextDistribution
Call hNewDocument
WaitSlot (3000)
'/// create 3 rectangles ///'
+ Call sSelectEmptyLayout
Call hRechteckErstellen (20,20,30,30)
Call hRechteckErstellen (40,40,50,50)
Call hRechteckErstellen (60,60,70,70)
@@ -430,7 +431,7 @@ testcase tdContextNameObject
Call hRechteckErstellen ( 30, 40, 50, 60 )
sleep 1
'/// select both by spanning a selection with the mouse ///'
- gMouseMove 1,1,95,95
+ gMouseMove 1,1,70,70
sleep 1
'/// Modify->Group ///'
'///+ Modify->Group ///'
@@ -455,6 +456,7 @@ endcase
testcase tdModifyConnectBreak
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
'/// create two rectangles ///'
Call hRechteckErstellen (10,10,30,30)
@@ -483,6 +485,7 @@ endcase
testcase tdModifyShapes
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
'/// create two rectangles ///'
gMouseClick 50,50
@@ -551,6 +554,7 @@ endcase
testcase tdModifyCombineSplit
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
sleep 1
'/// create two rectangles ///'
Call hRechteckErstellen (30,30,50,50)
diff --git a/testautomation/graphics/required/includes/global/id_011.inc b/testautomation/graphics/required/includes/global/id_011.inc
index 0cc7f22708ab..98d574c0f78c 100644
--- a/testautomation/graphics/required/includes/global/id_011.inc
+++ b/testautomation/graphics/required/includes/global/id_011.inc
@@ -45,6 +45,7 @@ testcase tiTextToolbar
'/// open application ///'
Call hNewDocument
+ Call sSelectEmptyLayout
'/// create a textframe with text ///'
hTextrahmenErstellen ("This is a Text, which will be formatted in several ways", 20,20,40,80)
diff --git a/testautomation/graphics/required/includes/global/id_opt_1.inc b/testautomation/graphics/required/includes/global/id_opt_1.inc
index a19a8f27b089..0f0b4bdb9069 100644
--- a/testautomation/graphics/required/includes/global/id_opt_1.inc
+++ b/testautomation/graphics/required/includes/global/id_opt_1.inc
@@ -557,7 +557,7 @@ testcase tToolsOptionsDrawGrid (sApplication as string)
ExitRestartTheOffice
printlog "opening new doc to get the Options"
Call hNewDocument
- hTypeKeys "OpenNewDoc!"
+
printlog "checking states"
ToolsOptions
hToolsOptions (sApplication,"Grid")
diff --git a/testautomation/graphics/required/includes/impress/im_003_.inc b/testautomation/graphics/required/includes/impress/im_003_.inc
index 280dae56b1d1..da2f09187694 100644
--- a/testautomation/graphics/required/includes/impress/im_003_.inc
+++ b/testautomation/graphics/required/includes/impress/im_003_.inc
@@ -227,7 +227,7 @@ testcase tiViewToolbar_1
end if
Kontext "DocumentImpress"
printlog "select graphic "
- EditSelectAll
+ hTypeKeys "<TAB>", 3
sleep 2
Kontext "GraphicObjectbar"
sleep 1
diff --git a/testautomation/graphics/tools/id_tools.inc b/testautomation/graphics/tools/id_tools.inc
index 117fa47725e2..e71c9f7653f0 100644
--- a/testautomation/graphics/tools/id_tools.inc
+++ b/testautomation/graphics/tools/id_tools.inc
@@ -289,10 +289,10 @@ end function
'-------------------------------------------------------------------------------
function fMakeDocumentWritable() as boolean
- printlog " make a document is writeable"
- printlog " <u>parameter:</u>"
- printlog " <u>return:</u>"
- printlog " true if the document can make writeable otherwise false"
+ 'make a document is writeable
+ 'parameter:</u>
+ '<u>return:</u>
+ 'true if the document can make writeable otherwise false
Kontext "Standardbar"
sleep (1)
@@ -310,7 +310,7 @@ function fMakeDocumentWritable() as boolean
printlog "Document is allready writable."
fMakeDocumentWritable = true
endif
-
+ sleep (1)
end function
'-------------------------------------------------------------------------------
diff --git a/testautomation/graphics/tools/id_tools_2.inc b/testautomation/graphics/tools/id_tools_2.inc
index 501965a591d0..681a5ec7161a 100644
--- a/testautomation/graphics/tools/id_tools_2.inc
+++ b/testautomation/graphics/tools/id_tools_2.inc
@@ -1046,3 +1046,18 @@ sub hWalkTheStyles (optional a as integer,optional b as integer)
end sub
'---------------------------------------------------------------------------------------
+sub sSelectEmptyLayout
+ if gApplication = "IMPRESS" then
+ printlog "Changing focus to TaskPane."
+ kontext "Tasks"
+ sleep (1)
+ printlog "Selecting first and empty layout."
+ LayoutsPreview.TypeKeys "<HOME>"
+ sleep (1)
+ LayoutsPreview.TypeKeys "<RETURN>"
+ sleep (1)
+ kontext "DocumentImpress"
+ else
+ printlog "No change of Layout needed."
+ endif
+end sub \ No newline at end of file
diff --git a/testautomation/spreadsheet/optional/includes/arrayconstants/c_arrayconstants.inc b/testautomation/spreadsheet/optional/includes/arrayconstants/c_arrayconstants.inc
index cdb4691eed3a..55c97473902c 100644..100755
--- a/testautomation/spreadsheet/optional/includes/arrayconstants/c_arrayconstants.inc
+++ b/testautomation/spreadsheet/optional/includes/arrayconstants/c_arrayconstants.inc
@@ -92,17 +92,17 @@ testcase tArrayconstants01
kontext "DocumentCalc"
DocumentCalc.TypeKeys ("=" & sFunctionSIN & "({1;2;3}) <MOD1 SHIFT RETURN>")
'///Check that the cellvalue of A4 is "0.84"
- printlog "Check that the cellvalue of A4 is ""0.84"""
+ printlog "Check that the cellvalue of A4 is ""0.8414709848"""
call fCalcSelectRange ("A5")
kontext "DocumentCalc"
DocumentCalc.TypeKeys "=A4<TAB>=B4<TAB>=C4<RETURN>" 'because a part of a matrix is protected we need a helpcell with only the values
- call fCalcCompareCellValue ("A5","0" & sDecimalseperator & "84")
+ call fCalcCompareCellValue ("A5","0" & sDecimalseperator & "8414709848")
'///Check that the cell contents of B4 is "0.91"
- printlog "Check that the cell contents of B4 is ""0.91"""
- call fCalcCompareCellValue ("B5","0" & sDecimalseperator & "91")
+ printlog "Check that the cell contents of B4 is ""0.9092974268"""
+ call fCalcCompareCellValue ("B5","0" & sDecimalseperator & "9092974268")
'///Check that the cell contents of C4 is "0.14"
- printlog "Check that the cell contents of C4 is ""0.14"""
- call fCalcCompareCellValue ("C5","0" & sDecimalseperator & "14")
+ printlog "Check that the cell contents of C4 is ""0.1411200081"""
+ call fCalcCompareCellValue ("C5","0" & sDecimalseperator & "1411200081")
'///In cell A6 enter "={1;2|4;5;6}"
printlog "In cell A6 enter ""={1;2|4;5;6}"""
diff --git a/testautomation/spreadsheet/optional/includes/solver/c_solver.inc b/testautomation/spreadsheet/optional/includes/solver/c_solver.inc
index 623b43e98217..623b43e98217 100644..100755
--- a/testautomation/spreadsheet/optional/includes/solver/c_solver.inc
+++ b/testautomation/spreadsheet/optional/includes/solver/c_solver.inc
diff --git a/testautomation/spreadsheet/required/includes/c_upd_filemenu.inc b/testautomation/spreadsheet/required/includes/c_upd_filemenu.inc
index 2a39ad34911b..32eee7e6040c 100755
--- a/testautomation/spreadsheet/required/includes/c_upd_filemenu.inc
+++ b/testautomation/spreadsheet/required/includes/c_upd_filemenu.inc
@@ -310,6 +310,7 @@ testcase tFileOpenHTML
Call hNewDocument
Printlog " Open File-Open-dialog"
FileOpen
+ waitslot (5)
Kontext "OeffnenDlg"
Printlog " Enter filename spreadsheet/required/input/HTML_Doc_Numberformats_in_table.html"
Dateiname.settext (sTestFile)
@@ -317,7 +318,6 @@ testcase tFileOpenHTML
Call hSelectUIFilter (sTestFilter1)
Printlog " Click on Open"
Oeffnen.Click
- sleep (1)
Kontext "HTMLImportOptions"
Printlog " Use every control on dialog Import Options"
Custom.Check
@@ -325,11 +325,13 @@ testcase tFileOpenHTML
Automatic.Check
DetectSpecialNumbers.Check
HTMLImportOptions.OK
+ sleep (2)
Printlog " Close recent document"
Call hCloseDocument
Printlog " Retry with Calc Web Querry filter"
Printlog " Open File-Open-dialog"
FileOpen
+ waitslot (5)
Kontext "OeffnenDlg"
Printlog " Enter filename spreadsheet/required/input/HTML_Doc_Numberformats_in_table.html"
Dateiname.settext (sTestFile)
@@ -337,7 +339,6 @@ testcase tFileOpenHTML
Call hSelectUIFilter (sTestFilter2)
Printlog " Click on Open"
Oeffnen.Click
- sleep (1)
Kontext "HTMLImportOptions"
Printlog " Use every control on dialog Import Options"
Custom.Check
@@ -345,6 +346,7 @@ testcase tFileOpenHTML
Automatic.Check
DetectSpecialNumbers.Check
HTMLImportOptions.OK
+ sleep (2)
Printlog " Close recent document"
Call hCloseDocument
diff --git a/testautomation/spreadsheet/required/includes/c_upd_formatmenu2.inc b/testautomation/spreadsheet/required/includes/c_upd_formatmenu2.inc
index 46b29a7755df..f85969784c39 100644..100755
--- a/testautomation/spreadsheet/required/includes/c_upd_formatmenu2.inc
+++ b/testautomation/spreadsheet/required/includes/c_upd_formatmenu2.inc
@@ -436,18 +436,17 @@ testcase tFormatAutoFormat
'/// Select second entry in 'Format' – listbox
printlog " Select second entry in 'Format' – listbox"
FormatListe.Select 2
- qaerrorlog "Due to i85043 the rename button and the rename dialog are not testable"
-' '/// Click on 'Rename' – button
-' printlog " Click on 'Rename' – button"
-' AutoFormatRenameCalc.Click
-' Kontext "AutoFormatRenameCalc"
-' Call DialogTest ( AutoFormatRenameCalc )
-' '/// Set format name to 'Newformat'
-' printlog " Set format name to 'Newformat'"
-' FormatName.SetText "Newformat"
-' '/// Close 'Rename AutoFormat' – dialog with 'Cancel'
-' printlog " Close 'Rename AutoFormat' – dialog with 'Cancel'"
-' AutoFormatRenameCalc.Cancel
+ '/// Click on 'Rename' – button
+ printlog " Click on 'Rename' – button"
+ Umbenennen.Click
+ Kontext "RenameAutoFormat"
+ Call DialogTest ( RenameAutoFormat )
+ '/// Set format name to 'Newformat'
+ printlog " Set format name to 'Newformat'"
+ RenameAutoFormatName.SetText "Newformat"
+ '/// Close 'Rename AutoFormat' – dialog with 'Cancel'
+ printlog " Close 'Rename AutoFormat' – dialog with 'Cancel'"
+ RenameAutoFormat.Cancel
Kontext "AutoformatCalc"
'/// Click on 'Delete' – button
printlog " Click on 'Delete' – button"
diff --git a/testautomation/spreadsheet/required/includes/c_upd_viewmenu.inc b/testautomation/spreadsheet/required/includes/c_upd_viewmenu.inc
index 5e8e5c1f0fdb..293418b76c2b 100644..100755
--- a/testautomation/spreadsheet/required/includes/c_upd_viewmenu.inc
+++ b/testautomation/spreadsheet/required/includes/c_upd_viewmenu.inc
@@ -324,13 +324,14 @@ testcase tViewNavigator
Szenarien.Click
Szenarien.Click
'/// Check that the dragmodus has 3 modes
- printlog " Check that the dragmodus has 3 modes"
- Dragmodus.OpenMenu
- waitslot(1000)
- if hMenuItemGetCount <> 3 then
- warnlog "Not enough modes for dragmodus"
- end if
- hMenuSelectNr (0)
+ qaerrorlog "Dragmodus disabled because of unreliability"
+' printlog " Check that the dragmodus has 3 modes"
+' Dragmodus.OpenMenu
+' waitslot(1000)
+' if hMenuItemGetCount <> 3 then
+' warnlog "Not enough modes for dragmodus"
+' end if
+' hMenuSelectNr (0)
'/// Close Navigator
printlog " Close Navigator"
Kontext "Navigator"
diff --git a/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion1.inc b/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion1.inc
index 5285a94e71bc..e58a4a2a94da 100644..100755
--- a/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion1.inc
+++ b/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion1.inc
@@ -75,8 +75,8 @@ testcase tHHNoSelction_1
Kontext "HangulHanjaConversion"
'/// Press Peplace button
- if Replace.IsEnabled then
- Replace.Click
+ if ReplaceBtn.IsEnabled then
+ ReplaceBtn.Click
else
Warnlog "Replace button is disabled !"
HangulHanjaConversion.Close
@@ -140,12 +140,12 @@ testcase tHHNoSelction_2
Kontext "HangulHanjaConversion"
'/// Press Peplace button
- if Replace.IsEnabled then
- Replace.Click
+ if ReplaceBtn.IsEnabled then
+ ReplaceBtn.Click
else
Ignore.Click
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
end if
if HangulHanjaConversion.Exists then HangulHanjaConversion.Close
@@ -194,13 +194,13 @@ testcase tHHNoSelction_3
Kontext "HangulHanjaConversion"
'/// Press Peplace button
- if Replace.IsEnabled then
- Replace.Click
+ if ReplaceBtn.IsEnabled then
+ ReplaceBtn.Click
else
Sleep 1
Ignore.Click
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
end if
@@ -325,16 +325,16 @@ testcase tHHNoSelction_6
Warnlog "Suggestion should be empty !"
end if
try
- Replace.Click
+ ReplaceBtn.Click
Warnlog "Replace button should NOT work !"
AlwaysReplace.Click
Warnlog "Always Replace button should NOT work !"
catch
Ignore.Click
endcatch
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
if HangulHanjaConversion.Exists then HangulHanjaConversion.Close
@@ -388,16 +388,16 @@ testcase tHHNoSelction_7
Warnlog "Suggestion should be empty !"
end if
try
- Replace.Click
+ ReplaceBtn.Click
Warnlog "Replace button should NOT work !"
AlwaysReplace.Click
Warnlog "Always Replace button should NOT work !"
catch
Ignore.Click
endcatch
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -446,11 +446,11 @@ testcase tHHSingleSelction_1
'/// + Press Peplace button
ToolsLanguageHangulHanjaConversion
Kontext "HangulHanjaConversion"
- if Replace.IsEnabled then
- Replace.Click
+ if ReplaceBtn.IsEnabled then
+ ReplaceBtn.Click
Sleep 1
try
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
catch
endcatch
@@ -501,9 +501,9 @@ testcase tHHMultiSelction_1
'/// + Press Peplace button
ToolsLanguageHangulHanjaConversion
Kontext "HangulHanjaConversion"
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
'/// Check if the result is correct
diff --git a/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion2.inc b/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion2.inc
index 1b17e9df8107..2d57bfc19d7e 100644..100755
--- a/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion2.inc
+++ b/testautomation/writer/optional/includes/hangulhanjaonversion/hhConversion2.inc
@@ -88,7 +88,7 @@ testcase tHHConversion_1
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -135,7 +135,7 @@ testcase tHHConversion_2
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -184,7 +184,7 @@ testcase tHHConversion_3
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -233,7 +233,7 @@ testcase tHHConversion_4
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -282,7 +282,7 @@ testcase tHHConversion_5
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -332,7 +332,7 @@ testcase tHHConversion_6
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -378,7 +378,7 @@ testcase tHHConversion_7
Kontext "HangulHanjaConversion"
HanjaAsRubyAbove.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -435,7 +435,7 @@ testcase tHHConversion_8
Kontext "HangulHanjaConversion"
HanjaAsRubyAbove.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -492,7 +492,7 @@ testcase tHHConversion_9
Kontext "HangulHanjaConversion"
HanjaAsRubyBelow.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -549,7 +549,7 @@ testcase tHHConversion_10
Kontext "HangulHanjaConversion"
HanjaAsRubyBelow.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -606,7 +606,7 @@ testcase tHHConversion_11
Kontext "HangulHanjaConversion"
HangulAsRubyAbove.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -663,7 +663,7 @@ testcase tHHConversion_12
Kontext "HangulHanjaConversion"
HangulAsRubyAbove.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -720,7 +720,7 @@ testcase tHHConversion_13
Kontext "HangulHanjaConversion"
HangulAsRubyBelow.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -777,7 +777,7 @@ testcase tHHConversion_14
Kontext "HangulHanjaConversion"
HangulAsRubyBelow.Check
Sleep 1
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -925,7 +925,7 @@ testcase tHHConversion_17
if Word.GetText <> sWord then
Warnlog "Hope get " & sWord & " in Word" & " but get " & Word.GetText
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
HangulHanjaConversion.Close
@@ -974,7 +974,7 @@ testcase tHHConversion_18
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1007,7 +1007,7 @@ testcase tHHConversion_18
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1121,7 +1121,7 @@ testcase tHHConversion_20
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1185,7 +1185,7 @@ testcase tHHConversion_21
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1220,7 +1220,7 @@ testcase tHHConversion_21
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1328,7 +1328,7 @@ testcase tHHConversion_23
ToolsLanguageHangulHanjaConversion
Kontext "HangulHanjaConversion"
for i = 1 to 2
- if Replace.IsEnabled then
+ if ReplaceBtn.IsEnabled then
try
Suggestions.Select 1
catch
@@ -1348,7 +1348,7 @@ testcase tHHConversion_23
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1398,7 +1398,7 @@ testcase tHHConversion_24
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1449,7 +1449,7 @@ testcase tHHConversion_25
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
@@ -1513,7 +1513,7 @@ testcase tHHConversion_26
if NOT HangulHanjaConversion.Exists then
Exit for
end if
- Replace.Click
+ ReplaceBtn.Click
Sleep 1
next i
diff --git a/testautomation/writer/optional/includes/regexp/search.inc b/testautomation/writer/optional/includes/regexp/search.inc
index c14526677f8c..ccd959504900 100755
--- a/testautomation/writer/optional/includes/regexp/search.inc
+++ b/testautomation/writer/optional/includes/regexp/search.inc
@@ -170,6 +170,7 @@ testcase tCallDialog
case 39 : Shortcut = "<Mod1 f>"
case 46 : Shortcut = "<Mod1 f>"
case 49 : Shortcut = "<Mod1 f>"
+ case 50 : Shortcut = "<Mod1 f>"
case 55 : Shortcut = "<Mod1 f>"
case 81 : Shortcut = "<Mod1 f>"
case 82 : Shortcut = "<Mod1 f>"
@@ -474,6 +475,7 @@ testcase tUnderline_Search
case 39: ToggleAttribute(27,"True")
case 46: ToggleAttribute(30,"True")
case 49: ToggleAttribute(28,"True")
+ case 50: ToggleAttribute(15,"True")
case 55: ToggleAttribute(29,"True")
case 88: ToggleAttribute(13,"True")
case else : QAErrorlog "Please adapt test for this language!"
@@ -490,6 +492,7 @@ testcase tUnderline_Search
case 39: ToggleAttribute(35,"True") ' Sottolineato
case 46: ToggleAttribute(40,"True") ' Understruken
case 49: ToggleAttribute(37,"True") ' Unterstrichen
+ case 50: ToggleAttribute(24,"True") ' PodÄrtano
case 55: ToggleAttribute(38,"True") ' Sublinhado
case 88: ToggleAttribute(13,"True")
case else : QAErrorlog "Please adapt test for this language!"
@@ -525,6 +528,7 @@ testcase tUnderline_Replace
case 39: ToggleAttribute(27,"True")
case 46: ToggleAttribute(30,"True")
case 49: ToggleAttribute(28,"True")
+ case 50: ToggleAttribute(15,"True")
case 55: ToggleAttribute(29,"True")
case 88: ToggleAttribute(13,"True")
case else : QAErrorlog "Please adapt test for this language!"
@@ -541,6 +545,7 @@ testcase tUnderline_Replace
case 39: ToggleAttribute(35,"True") ' Sottolineato
case 46: ToggleAttribute(40,"True") ' Understruken
case 49: ToggleAttribute(37,"True") ' Unterstrichen
+ case 50: ToggleAttribute(24,"True") ' PodÄrtano
case 55: ToggleAttribute(38,"True") ' Sublinhado
case 88: ToggleAttribute(13,"True")
case else : QAErrorlog "Please adapt test for this language!"
@@ -788,6 +793,7 @@ testcase tParagraphStyle_Search
Case 39 : Such_Text = "Intestazione"
Case 46 : Such_Text = "Överskrift"
Case 49 : Such_Text = "Ãœberschrift" 'Suchen Absatzformat "Ãœberschrift"
+ Case 50 : Such_Text = "Naslov"
Case 55 : Such_Text = "Título Principal"
Case 81 : Such_Text = "見出ã—"
Case 86 : Such_Text = "标题"
@@ -1625,6 +1631,7 @@ sub Meldungs_Test
Case 39 : Text_In_Meldung = sProduct & " Writer ha cercato fino alla fine del documento. Volete continuare dall'inizio del documento?"
Case 46 : Text_In_Meldung = sProduct & " Writer har sökt till slutet av dokument. Vill du fortsätta sökningen i början av dokumentet?"
Case 49 : Text_In_Meldung = sProduct & " Writer hat bis zum Ende des Dokumentes gesucht. Möchten Sie die Suche am Dokumentanfang fortsetzen?"
+ Case 50 : Text_In_Meldung = sProduct & " Writer je preiskal do konca dokumenta. Ali želite nadaljevati na zaÄetku?"
Case 55 : Text_In_Meldung = sProduct & " Writer pesquisou até o final do documento. Deseja continuar do início?"
Case 81 : Text_In_Meldung = sProduct & " Writer ã¯ã€æ–‡æ›¸æœ«ã¾ã§æ¤œç´¢ã—ã¾ã—ãŸã€‚文書ã®å§‹ã‚ã«æˆ»ã£ã¦ç¶šè¡Œã—ã¾ã™ã‹ã€‚"
Case 82 : Text_In_Meldung = sProduct & " Writerê°€ ë¬¸ì„œì˜ ë까지 검색했습니다. ë¬¸ì„œì˜ ì‹œìž‘ë¶€ë¶„ì—ì„œ ê²€ìƒ‰ì„ ê³„ì†í•˜ê² ìŠµë‹ˆê¹Œ?"
diff --git a/testautomation/writer/optional/includes/stylist/w_stylist.inc b/testautomation/writer/optional/includes/stylist/w_stylist.inc
index 9a8589e34da5..b2e582045f27 100644..100755
--- a/testautomation/writer/optional/includes/stylist/w_stylist.inc
+++ b/testautomation/writer/optional/includes/stylist/w_stylist.inc
@@ -78,69 +78,73 @@ testcase tFormatStylist1
Dim xSize%
Dim ySize%
- printlog "- Format / Stylist : all methods with Navigator as window"
- printlog "New writerdocument"
- Call hNewDocument
- printlog " - Call Stylist with F11"
- printlog "Call stylist with <F11> aand proof all windowmethods at stylist"
- Call wTypeKeys "<F11>"
- Kontext "Stylist"
- if Stylist.NotExists then
- Warnlog "No Stylist with <F11>"
- FormatStylist
- end if
- xPos = Stylist.GetPosX
- yPos = Stylist.GetPosY
- xSize% = Stylist.GetSizeX
- ySize% = Stylist.GetSizeY
-
- printlog " - move Stylist"
- Stylist.Move 10, 10
- Sleep 1
- Stylist.Move 300, 400
- Sleep 1
- Stylist.Move 590, 790
- Sleep 1
- Stylist.Move xPos, yPos
- Sleep 1
-
- printlog " - size Stylist"
- try
- Stylist.Size 300, 400
- catch
- Warnlog "Sizen Stylist doesn't work.. see #i32449"
- endcatch
- Sleep 1
- try
- Stylist.Size xSize%, ySize%
- catch
- Warnlog "Sizen Stylist doesn't work.. see #i32449"
- endcatch
- Sleep 1
-
- printlog " - close Stylist and reopen ( has to be the same size )"
- xPos = Stylist.GetPosX
- yPos = Stylist.GetPosY
- xSize% = Stylist.GetSizeX
- ySize% = Stylist.GetSizeY
- FormatStylist
- Sleep 1
- FormatStylist
- if xPos <> Stylist.GetPosX then Warnlog "x-Pos. has been changed : Not -> "+ xPos + " but -> "+ Stylist.GetPosX
- if yPos <> Stylist.GetPosY then Warnlog "y-Pos. has been changed : Not -> "+ yPos + " but -> "+ Stylist.GetPosY
- if xSize% <> Stylist.GetSizeX then Warnlog "x-Size has been changed : Not -> "+ xSize% + " but -> "+ Stylist.GetSizeX
- if ySize% <> Stylist.GetSizeY then Warnlog "y-Size has been changed : Not -> "+ ySize% + " but -> "+ Stylist.GetSizeY
-
- printlog " - dock Stylist"
- Stylist.Dock
- Sleep 1
- if NOT Stylist.IsDocked then Warnlog "Stylist has not been docked in"
- Stylist.Undock
- Sleep 1
-
- Stylist.Close
- printlog "Close document"
- Call hCloseDocument
+ printlog "- Format / Stylist : all methods with Navigator as window"
+ printlog "New writerdocument"
+ Call hNewDocument
+ printlog " - Call Stylist with F11"
+ printlog "Call stylist with <F11> aand proof all windowmethods at stylist"
+ if lcase(gPlatform) = "osx" then
+ call hTypekeys "<mod1 t>"
+ else
+ Call wTypeKeys "<F11>"
+ end if
+ Kontext "Stylist"
+ if Stylist.NotExists then
+ Warnlog "No Stylist with <F11>"
+ FormatStylist
+ end if
+ xPos = Stylist.GetPosX
+ yPos = Stylist.GetPosY
+ xSize% = Stylist.GetSizeX
+ ySize% = Stylist.GetSizeY
+
+ printlog " - move Stylist"
+ Stylist.Move 10, 10
+ Sleep 1
+ Stylist.Move 300, 400
+ Sleep 1
+ Stylist.Move 590, 790
+ Sleep 1
+ Stylist.Move xPos, yPos
+ Sleep 1
+
+ printlog " - size Stylist"
+ try
+ Stylist.Size 300, 400
+ catch
+ Warnlog "Sizen Stylist doesn't work.. see #i32449"
+ endcatch
+ Sleep 1
+ try
+ Stylist.Size xSize%, ySize%
+ catch
+ Warnlog "Sizen Stylist doesn't work.. see #i32449"
+ endcatch
+ Sleep 1
+
+ printlog " - close Stylist and reopen ( has to be the same size )"
+ xPos = Stylist.GetPosX
+ yPos = Stylist.GetPosY
+ xSize% = Stylist.GetSizeX
+ ySize% = Stylist.GetSizeY
+ FormatStylist
+ Sleep 1
+ FormatStylist
+ if xPos <> Stylist.GetPosX then Warnlog "x-Pos. has been changed : Not -> "+ xPos + " but -> "+ Stylist.GetPosX
+ if yPos <> Stylist.GetPosY then Warnlog "y-Pos. has been changed : Not -> "+ yPos + " but -> "+ Stylist.GetPosY
+ if xSize% <> Stylist.GetSizeX then Warnlog "x-Size has been changed : Not -> "+ xSize% + " but -> "+ Stylist.GetSizeX
+ if ySize% <> Stylist.GetSizeY then Warnlog "y-Size has been changed : Not -> "+ ySize% + " but -> "+ Stylist.GetSizeY
+
+ printlog " - dock Stylist"
+ Stylist.Dock
+ Sleep 1
+ if NOT Stylist.IsDocked then Warnlog "Stylist has not been docked in"
+ Stylist.Undock
+ Sleep 1
+
+ Stylist.Close
+ printlog "Close document"
+ Call hCloseDocument
endcase
@@ -152,64 +156,68 @@ testcase tFormatStylist2
Dim xSize%
Dim ySize%
- printlog "- Format/Stylist : Methods from Stylist as Window between more than one document"
- printlog " New document"
- Call hNewDocument
- printlog "check all methods of Stylist as Window between more than one document"
- Call wTypeKeys "Test the stylist functions"
- printlog " - Call Stylist in first document and check in a second document"
- Sleep 2
- Kontext "Stylist"
- If Not Stylist.Exists then FormatStylist
- Sleep 2
- Call hNewDocument
- Call wTypeKeys "Test the stylist functions"
- Sleep 2
- Kontext "Stylist"
- if Stylist.NotExists then Warnlog "No Stylist in new document"
-
- printlog " - Close all documents and reopen"
- Sleep 2
- Call hCloseDocument
- Sleep 2
- Call hCloseDocument
- Sleep 2
- Call hNewDocument
- Sleep 2
- Call wTypeKeys "Test the stylist functions"
- Kontext "Stylist"
- if Stylist.NotExists then Warnlog "No Stylist in a new document"
-
- printlog " - Dock Stylist in first document and check in a new if docked"
- Sleep 2
- Stylist.Dock
- Sleep 1
- Call hNewDocument
- Call wTypeKeys "Test the stylist functions"
- Kontext "Stylist"
- if NOT Stylist.IsDocked then Warnlog "Stylist is not docked in new document"
-
- printlog " - Close all documents, reopen one and check docked Stylist"
- Call hCloseDocument
- Sleep 2
- Call hCloseDocument
- Sleep 2
- Call hNewDocument
- Kontext "Stylist"
- if NOT Stylist.IsDocked then Warnlog "Stylist is not docked in new document"
-
- printlog " - Close Stylist with <F11>"
- Stylist.Undock
- Sleep 1
- Call wTypeKeys "<F11>"
- Kontext "Stylist"
- if NOT Stylist.NotExists then
- Warnlog "Stylist is still open"
- Stylist.Close
- end if
- printlog "Close document"
- Call hCloseDocument
-
+ printlog "- Format/Stylist : Methods from Stylist as Window between more than one document"
+ printlog " New document"
+ Call hNewDocument
+ printlog "check all methods of Stylist as Window between more than one document"
+ Call wTypeKeys "Test the stylist functions"
+ printlog " - Call Stylist in first document and check in a second document"
+ Sleep 2
+ Kontext "Stylist"
+ If Not Stylist.Exists then FormatStylist
+ Sleep 2
+ Call hNewDocument
+ Call wTypeKeys "Test the stylist functions"
+ Sleep 2
+ Kontext "Stylist"
+ if Stylist.NotExists then Warnlog "No Stylist in new document"
+
+ printlog " - Close all documents and reopen"
+ Sleep 2
+ Call hCloseDocument
+ Sleep 2
+ Call hCloseDocument
+ Sleep 2
+ Call hNewDocument
+ Sleep 2
+ Call wTypeKeys "Test the stylist functions"
+ Kontext "Stylist"
+ if Stylist.NotExists then Warnlog "No Stylist in a new document"
+
+ printlog " - Dock Stylist in first document and check in a new if docked"
+ Sleep 2
+ Stylist.Dock
+ Sleep 1
+ Call hNewDocument
+ Call wTypeKeys "Test the stylist functions"
+ Kontext "Stylist"
+ if NOT Stylist.IsDocked then Warnlog "Stylist is not docked in new document"
+
+ printlog " - Close all documents, reopen one and check docked Stylist"
+ Call hCloseDocument
+ Sleep 2
+ Call hCloseDocument
+ Sleep 2
+ Call hNewDocument
+ Kontext "Stylist"
+ if NOT Stylist.IsDocked then Warnlog "Stylist is not docked in new document"
+
+ printlog " - Close Stylist with <F11>"
+ Stylist.Undock
+ Sleep 1
+ if lcase(gPlatform) = "osx" then
+ call hTypekeys "<mod1 t>"
+ else
+ Call wTypeKeys "<F11>"
+ end if
+ Kontext "Stylist"
+ if NOT Stylist.NotExists then
+ Warnlog "Stylist is still open"
+ Stylist.Close
+ end if
+ printlog "Close document"
+ Call hCloseDocument
+
endcase
' **********************************************************************
@@ -295,7 +303,7 @@ testcase tFormatStylist3
Sleep 1
next i
Stylist.Close
- printlog "Close document"
+ printlog "Close document"
Call hCloseDocument
endcase
@@ -307,31 +315,31 @@ testcase tFormatStylist4
Dim NeuerWert$
printlog "- Format / Stylist : check created Styles"
- printlog "New writerdocument"
- Call hNewDocument
- printlog " - create Paragraph Style in Stylist"
- Call wStyleCreate ( "ATesttool", "Paragraph", true )
- Kontext "Stylist"
- printlog "Check if Style has been added in stylist"
+ printlog "New writerdocument"
+ Call hNewDocument
+ printlog " - create Paragraph Style in Stylist"
+ Call wStyleCreate ( "ATesttool", "Paragraph", true )
+ Kontext "Stylist"
+ printlog "Check if Style has been added in stylist"
if wStyleSelect ( "ATesttool", "Paragraph" ) = false then Warnlog "Paragraph Style has not been found"
- printlog " - Create Character Style in Stylist"
- Call wStyleCreate ( "BTesttool", "Character", true )
- if wStyleSelect ( "BTesttool", "Character" ) = false then Warnlog "Character Style has not been found!"
- printlog " - Create Frame Style in Stylist"
+ printlog " - Create Character Style in Stylist"
+ Call wStyleCreate ( "BTesttool", "Character", true )
+ if wStyleSelect ( "BTesttool", "Character" ) = false then Warnlog "Character Style has not been found!"
+ printlog " - Create Frame Style in Stylist"
Call wStyleCreate ( "CTesttool", "Frame", true )
if wStyleSelect ( "CTesttool", "Frame" ) = false then Warnlog "Frame Style has not been found!"
- printlog " - Create Page Style in Stylist"
- Call wStyleCreate ( "DTesttool", "Page", true )
- if wStyleSelect ( "DTesttool", "Page" ) = false then Warnlog "Page Style has not been found"
+ printlog " - Create Page Style in Stylist"
+ Call wStyleCreate ( "DTesttool", "Page", true )
+ if wStyleSelect ( "DTesttool", "Page" ) = false then Warnlog "Page Style has not been found"
- printlog " - creating Styles should not have been affecting to new documents"
+ printlog " - creating Styles should not have been affecting to new documents"
' To avoid focus problems on unix first close stylist
- Kontext "Stylist"
+ Kontext "Stylist"
if Stylist.Exists then FormatStylist
- Call hNewDocument
- Kontext "Stylist"
+ Call hNewDocument
+ Kontext "Stylist"
if Not Stylist.Exists then FormatStylist
if wStyleSelect ( "ATesttool", "Paragraph" ) = true then Warnlog "Paragraph Style has been found in new document"
@@ -351,32 +359,32 @@ testcase tFormatStylist5
Dim bStyleFound as boolean
printlog "- Format / Stylist : select Style"
- printlog "New writerdocument"
- if bAsianLan = True then
- printlog "- Not in Asian languages!"
- goto endsub
- end if
- Call hNewDocument
- Call wTypeKeys "Dies ist ein formatierter Text <Shift Home>"
- printlog " - format Text"
- FormatCharacter
- Kontext
- Active.SetPage TabFontEffects
- Kontext "TabFontEffects"
- StrikeThrough.Select 2
- Outline.Check
- TabFontEffects.OK
-
- printlog " - adjust to Standard-Format through the Stylist"
- printlog "adjust to Standard-Format through the Stylist"
- FormatStylist
- Kontext "Stylist"
- if Stylist.NotExists then FormatStylist
- 'Get name for 'default' template
- Kontext "TextObjectbar"
- SuchMal = Vorlage.GetSelText
- printlog "Using " & SuchMal & " as 'default'"
- Kontext "Stylist"
+ printlog "New writerdocument"
+ if bAsianLan = True then
+ printlog "- Not in Asian languages!"
+ goto endsub
+ end if
+ Call hNewDocument
+ Call wTypeKeys "Dies ist ein formatierter Text <Shift Home>"
+ printlog " - format Text"
+ FormatCharacter
+ Kontext
+ Active.SetPage TabFontEffects
+ Kontext "TabFontEffects"
+ StrikeThrough.Select 2
+ Outline.Check
+ TabFontEffects.OK
+
+ printlog " - adjust to Standard-Format through the Stylist"
+ printlog "adjust to Standard-Format through the Stylist"
+ FormatStylist
+ Kontext "Stylist"
+ if Stylist.NotExists then FormatStylist
+ 'Get name for 'default' template
+ Kontext "TextObjectbar"
+ SuchMal = Vorlage.GetSelText
+ printlog "Using " & SuchMal & " as 'default'"
+ Kontext "Stylist"
Vorlagenliste.TypeKeys "<Home>"
bStyleFound = false
@@ -394,19 +402,19 @@ testcase tFormatStylist5
Warnlog "Style: " & Suchmal & " has not been found in Stylist"
Call hCloseDocument
goto endsub
- end if
-
- printlog " - check format"
- FormatCharacter
- Kontext
- Active.SetPage TabFontEffects
- Kontext "TabFontEffects"
- if StrikeThrough.GetSelIndex = 2 then Warnlog "Wrong entry selected in StrikeThrough"
- if Outline.IsChecked then Warnlog "Format Outline is still checked"
- TabFontEffects.OK
-
- printlog "Close document"
- Call hCloseDocument
+ end if
+
+ printlog " - check format"
+ FormatCharacter
+ Kontext
+ Active.SetPage TabFontEffects
+ Kontext "TabFontEffects"
+ if StrikeThrough.GetSelIndex = 2 then Warnlog "Wrong entry selected in StrikeThrough"
+ if Outline.IsChecked then Warnlog "Format Outline is still checked"
+ TabFontEffects.OK
+
+ printlog "Close document"
+ Call hCloseDocument
endcase
' **********************************************************************
@@ -463,7 +471,7 @@ testcase tFormatStylist6
TBGestalter.Click ZeichenVorlagen
if Vorlagenliste.GetSeltext <> "Testtool" then 'Go find the entry.
Vorlagenliste.TypeKeys "<Home>"
- For i = 1 to 100
+ For i = 1 to 100
Vorlagenliste.TypeKeys "<Down>"
if Vorlagenliste.GetSeltext = "Testtool" then 'Found it!
i = 102
@@ -483,7 +491,7 @@ testcase tFormatStylist6
if NOT Shadow.IsChecked then Warnlog "Shadow is not checked anymore"
if StrikeThrough.GetSelIndex <> 2 then Warnlog "Wrong entry selection in StrikeThrough"
if Overline.GetSelIndex <> 2 then Warnlog "Overline is not checked anymore"
- if OverlineColor.GetSelIndex <> 6 then Warnlog "Wrong Overline Color selected"
+ if OverlineColor.GetSelIndex <> 6 then Warnlog "Wrong Overline Color selected"
if NOT Outline.IsChecked then Warnlog "Outline is not checked anymore"
if Effects.GetSelIndex <> 3 then Warnlog "Wrong effect selected"
if NOT Blinking.IsChecked then Warnlog "Blinking is not checked anymore"
@@ -542,10 +550,10 @@ testcase tFormatStylist7
i = 102
end if
next i
- if i = 101 then
- warnlog "No Testtool -Stylist found. Check if new stylists can be created. Test ends."
- goto endsub
- end if
+ if i = 101 then
+ warnlog "No Testtool -Stylist found. Check if new stylists can be created. Test ends."
+ goto endsub
+ end if
end if
Vorlagenliste.TypeKeys "<SHIFT F10>" 'Open ContextMenu
Sleep 1
@@ -573,7 +581,7 @@ testcase tFormatStylist7
TBGestalter.Click ZeichenVorlagen
if Vorlagenliste.GetSeltext <> "Testtool" then
- Vorlagenliste.TypeKeys "<Home>"
+ Vorlagenliste.TypeKeys "<Home>"
For i = 1 to 100
Vorlagenliste.TypeKeys "<Down>"
if Vorlagenliste.GetSeltext = "Testtool" then 'Found it!
@@ -614,17 +622,17 @@ testcase tAssigningStyles1
Dim j as integer
Dim bStyleInList as boolean
- printlog "UI and Strings check"
+ printlog "UI and Strings check"
Call hNewDocument
- printlog "Open a new writerdocument"
- printlog "Check if the following strings and only those strings are present:"
- printlog "Clear formatting"
- printlog "Heading 1"
- printlog "Heading 2"
- printlog "Heading 3"
- printlog "Default"
- printlog "Text body"
- printlog "More..."
+ printlog "Open a new writerdocument"
+ printlog "Check if the following strings and only those strings are present:"
+ printlog "Clear formatting"
+ printlog "Heading 1"
+ printlog "Heading 2"
+ printlog "Heading 3"
+ printlog "Default"
+ printlog "Text body"
+ printlog "More..."
Select Case iSprache
Case 01 : sStyles = Array("Clear formatting", "Default", "Heading 1", "Heading 2", "Heading 3", "Text body", "More...")
Case 07 : sStyles = Array("Отменить форматирование", "Базовый", "Заголовок 1", "Заголовок 2", "Заголовок 3", "ОÑновной текÑÑ‚", "Дополнительно...")
@@ -690,17 +698,17 @@ testcase tAssigningStyles2
Dim sTemp as string
printlog "- Apply Style"
- printlog "New writerdocument"
+ printlog "New writerdocument"
Call hNewDocument
- printlog "Insert dummytext"
+ printlog "Insert dummytext"
if wBlindtextEinfuegen = false then
Call hCloseDocument
exit sub
end if
- printlog "Select whole dummytext"
+ printlog "Select whole dummytext"
Call wTypeKeys "<Mod1 A>"
- printlog "Apply style 'Heading 1' through Styles & Formatting combobox"
+ printlog "Apply style 'Heading 1' through Styles & Formatting combobox"
Kontext "Textobjectbar"
for i = 1 to Vorlage.GetItemCount
Vorlage.Select i
@@ -711,7 +719,7 @@ testcase tAssigningStyles2
end if
next i
- printlog "Check if style has been applied to paragraph"
+ printlog "Check if style has been applied to paragraph"
Call wTypeKeys "<Mod1 Home><End>"
Call wTypeKeys "<Left>", 2
@@ -740,17 +748,17 @@ testcase tAssigningStyles3
Call wTypeKeys "<Mod1 A>"
printlog "Format / Character"
FormatCharacter
- Kontext
- Active.Setpage TabFont
- Kontext "TabFont"
+ Kontext
+ Active.Setpage TabFont
+ Kontext "TabFont"
printlog "Apply first font in list and select 2nd Typeface"
- if gAsianSup = True then
- FontWest.Select 1
+ if gAsianSup = True then
+ FontWest.Select 1
StyleWest.Select 2
- else
- Font.Select 1
+ else
+ Font.Select 1
Style.Select 1
- end if
+ end if
TabFont.Ok
printlog "Enter 'MyStyle' in Stylelistbox"
@@ -838,7 +846,7 @@ endcase
testcase tAssigningStyles5
printlog "- Clear formatting: whole paragraph with hard formatting of some characters"
- printlog " - 1. Cursor outside of hard formatted string"
+ printlog " - 1. Cursor outside of hard formatted string"
printlog "Open a new writer document"
Call hNewDocument
printlog "Insert a dummytext"
@@ -848,28 +856,28 @@ testcase tAssigningStyles5
end if
printlog "Highlight first line in dummy text"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Shift End>"
-
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Shift End>"
+
printlog "Format / Bold"
- Kontext "TextObjectbar"
+ Kontext "TextObjectbar"
if Not TextObjectbar.Exists then Call hToolbarSelect ( "FORMATTING", true )
- Fett.Click
- Wait 500
+ Fett.Click
+ Wait 500
printlog "Set cursor outside of bold formatted text"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Down><Right>"
-
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Down><Right>"
+
printlog "Select 'Clear Formatting' in Style-Listbox"
- Kontext "Textobjectbar"
+ Kontext "Textobjectbar"
Vorlage.Select 1
Vorlage.TypeKeys "<Return>"
wait 500
printlog "Check that first line is still bold and has not been reset"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Right>"
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Right>"
Kontext "TextObjectbar"
if Fett.Getstate(2) = 0 then
@@ -877,7 +885,7 @@ testcase tAssigningStyles5
end if
printlog "Close document"
- Call hCloseDocument
+ Call hCloseDocument
endcase
' **********************************************************************
@@ -887,7 +895,7 @@ testcase tAssigningStyles6
Dim iStandard as integer
printlog "- Clear formatting: whole paragraph with hard formatting of some characters"
- printlog " - 2. Cursor inside of hard formatted string"
+ printlog " - 2. Cursor inside of hard formatted string"
printlog "Open a new writer document"
Call hNewDocument
printlog "Insert a dummytext"
@@ -897,34 +905,34 @@ testcase tAssigningStyles6
end if
printlog "Highlight first line in dummy text"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Shift End>"
-
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Shift End>"
+
printlog "Format / Bold"
- Kontext "TextObjectbar"
+ Kontext "TextObjectbar"
if Not TextObjectbar.Exists then Call hToolbarSelect ( "FORMATTING", true )
- Fett.Click
- Wait 500
+ Fett.Click
+ Wait 500
printlog "Point cursor to first highlighted word of bold formatted text"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Right>"
-
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Right>"
+
printlog "Select 'Format / Default Formatting' in Style-Listbox"
- FormatDefaultWriter
+ FormatDefaultWriter
wait 500
printlog "first highlighted word should be set to 'Standard'"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<Right>"
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<Right>"
Kontext "TextObjectbar"
if Fett.Getstate(2) = 1 then
Warnlog "Style 'Bold' has not been reset!"
end if
-
+
printlog "Check that rest of first line is still bold and has not been reset"
- Call wTypeKeys "<Mod1 Home>"
- Call wTypeKeys "<End><Left>"
+ Call wTypeKeys "<Mod1 Home>"
+ Call wTypeKeys "<End><Left>"
Kontext "TextObjectbar"
if Fett.Getstate(2) = 1 then
@@ -932,7 +940,7 @@ testcase tAssigningStyles6
end if
printlog "Close document"
- Call hCloseDocument
+ Call hCloseDocument
endcase
' **********************************************************************
@@ -942,27 +950,27 @@ testcase tAssigningStyles7
printlog "More ..."
printlog "Open a new writer document"
Call hNewDocument
-
+
printlog "Select 'More...' in Style-Listbox"
- Kontext "Textobjectbar"
+ Kontext "Textobjectbar"
Vorlage.Select Vorlage.GetItemCount
Vorlage.TypeKeys "<Return>"
wait 500
printlog "The Stylist should have been opened"
- Kontext "Stylist"
- if Not Stylist.Exists then
- Warnlog "'Styles and Formatting' doesn't open if 'More...' is selected in Style-Listbox"
- else
+ Kontext "Stylist"
+ if Not Stylist.Exists then
+ Warnlog "'Styles and Formatting' doesn't open if 'More...' is selected in Style-Listbox"
+ else
printlog "In Style group listbox 'Automatic' should be selected"
- if Gruppenliste.GetSelIndex <> 5 then
- Warnlog "Seems 'Automatic' is not selected per default in 'Styles and Formatting'"
- end if
- Stylist.Close
- end if
+ if Gruppenliste.GetSelIndex <> 5 then
+ Warnlog "Seems 'Automatic' is not selected per default in 'Styles and Formatting'"
+ end if
+ Stylist.Close
+ end if
printlog "Close document"
- Call hCloseDocument
+ Call hCloseDocument
endcase
' **********************************************************************
diff --git a/testautomation/writer/optional/includes/undo/w_undo_history_1.inc b/testautomation/writer/optional/includes/undo/w_undo_history_1.inc
index f97c7b53be60..43356c09017c 100644..100755
--- a/testautomation/writer/optional/includes/undo/w_undo_history_1.inc
+++ b/testautomation/writer/optional/includes/undo/w_undo_history_1.inc
@@ -84,7 +84,7 @@ testcase tUndoFindAndReplace
'/// Type 'ThisReplacementText' in 'Replace with' field
ReplaceWith.Settext "ThisReplacementText"
'/// Choose Button 'Replace' and close dialog
- Replace.Click
+ ReplaceBtn.Click
wait 500
Kontext "Active"
if Active.Exists then
diff --git a/testautomation/writer/optional/includes/undo/w_undo_history_2.inc b/testautomation/writer/optional/includes/undo/w_undo_history_2.inc
index dd36e286233f..a2f305a45f8c 100644..100755
--- a/testautomation/writer/optional/includes/undo/w_undo_history_2.inc
+++ b/testautomation/writer/optional/includes/undo/w_undo_history_2.inc
@@ -94,7 +94,7 @@ testcase tUndoFindAndReplaceLong
'/// Type 'ThisIsAboutALongTextThatHadToBeReplaced' in 'Replace with' field
ReplaceWith.Settext "ThisIsAboutALongTextThatHadToBeReplaced"
'/// Choose Button 'Replace' and close dialog
- Replace.Click
+ ReplaceBtn.Click
wait 500
Kontext "Active"
if Active.Exists then
@@ -452,7 +452,7 @@ testcase tUndoStyles
Sleep 1
ReplaceWithStyle.Select 4
wait 500
- Replace.Click
+ ReplaceBtn.Click
NewStyle = ReplaceWithStyle.GetSelText
Select Case iSprache
Case 01: StyleText = "Replace style: AUndoHistory -> " & NewStyle
diff --git a/testautomation/writer/required/includes/w_002_.inc b/testautomation/writer/required/includes/w_002_.inc
index 1c86e8f01a47..73de7ba6edeb 100644..100755
--- a/testautomation/writer/required/includes/w_002_.inc
+++ b/testautomation/writer/required/includes/w_002_.inc
@@ -658,7 +658,7 @@ endcase
'---------------------------------------------------
testcase tEditAutotext
- Dim k as integer
+ Dim j as integer
Dim i as integer
Dim CurrentEntryNr as integer
Dim unxAutotextCategorie as integer
@@ -678,6 +678,7 @@ testcase tEditAutotext
end if
PrintLog "Click Categories"
+ Kontext "Autotext"
Bereiche.Click
Sleep 1
Kontext "BereicheBearbeitenAutoText"
@@ -880,8 +881,7 @@ testcase tEditAutotext
if GetDocumentCount = 1 then
Warnlog "The autotext has been edited in current document!"
else
- hUseAsyncSlot( "FileClose" )
-
+ hUseAsyncSlot( "FileClose" )
Kontext "Active"
PrintLog "A message that module has been changed should come up"
if Active.Exists then
@@ -890,11 +890,6 @@ testcase tEditAutotext
Warnlog "Though changing the text module the document could be closed without a query!"
end if
end if
- if wDeleteAutotext("DummyAutotext") = false then
- Warnlog "Unable to delete created autotext"
- end if
- Kontext "Autotext"
- if Autotext.Exists then Autotext.Close
catch
Warnlog "Menu Autotext->'Edit' disabled !"
Kontext "Active"
@@ -908,16 +903,17 @@ testcase tEditAutotext
endcatch
end if
end if
- Kontext "Autotext"
- PrintLog "Close 'Autotext' dialog"
- Autotext.Close
- if wDeleteAutotext("DummyAutotext") = false then
- Warnlog "Unable to delete created autotext"
- end if
- Kontext "Autotext"
- if Autotext.Exists then Autotext.Close
endcatch
+ PrintLog "Close 'Autotext' dialog"
+ Kontext "Autotext"
+ if Autotext.Exists then Autotext.Close
+ if wDeleteAutotext("DummyAutotext") = false then
+ Warnlog "Unable to delete created autotext"
+ end if
+ Kontext "Autotext"
+ if Autotext.Exists then Autotext.Close
+
PrintLog "Close active document"
Call hCloseDocument
endcase
diff --git a/testautomation/writer/required/includes/w_011_.inc b/testautomation/writer/required/includes/w_011_.inc
index 754d4c58e538..61a20821349f 100644..100755
--- a/testautomation/writer/required/includes/w_011_.inc
+++ b/testautomation/writer/required/includes/w_011_.inc
@@ -411,7 +411,9 @@ testcase tZOArea
Call hNewDocument
printlog "Insert a draw object ( rectangle )"
Call wZeichenobjektEinfuegen ( "Rechteck", 30, 30, 50, 60 )
- Call gMouseClick ( 25, 25 )
+ ' Set focus to document
+ Call gMouseMove2 ( 50, 25 )
+ Call gMouseClick ( 50, 25 )
printlog "Select drawing object with shortcut 'Shift F4'"
Call wTypeKeys ( "<Shift F4>" )
@@ -452,6 +454,8 @@ testcase tZORest
Call hNewDocument
printlog "Insert a draw object ( rectangle )"
Call wZeichenobjektEinfuegen ( "Rechteck", 30, 30, 50, 60 )
+ ' Set focus to document
+ Call gMouseMove2 ( 50, 25 )
Call gMouseClick ( 50, 25 )
printlog "Select drawing object with shortcut 'Shift F4'"
Call wTypeKeys ( "<Shift F4>" )
@@ -464,7 +468,7 @@ testcase tZORest
Drehen.Click
wait 500
catch
- Warnlog "#i56594#Shortcut selecting objects doesn't work"
+ Warnlog "Shortcut selecting objects doesn't work"
Call hCloseDocument
goto endsub
endcatch
diff --git a/testautomation/writer/tools/includes/w_locale_strings2.inc b/testautomation/writer/tools/includes/w_locale_strings2.inc
index a679ecbabc04..73b987fb2c7e 100644..100755
--- a/testautomation/writer/tools/includes/w_locale_strings2.inc
+++ b/testautomation/writer/tools/includes/w_locale_strings2.inc
@@ -47,6 +47,7 @@ function wGetLanguageGuessString(sValue as string, iLanguageCount as integer) as
'///swedish 46 ///'
'///polish 48 ///'
'///german 49 ///'
+ '///slovenian 50 ///'
'///german 55 ///'
'///already covered languages in the test document: ///'
@@ -324,6 +325,32 @@ function wGetLanguageGuessString(sValue as string, iLanguageCount as integer) as
ParagraphPreSet = "Absatz ist Deutsch (Deutschland)"
end select
'-----------------------------------------------------------------------
+ Case 50 'Case 50: slovenian
+ Select Case iLanguageCount
+ Case 1: WordPreSet = "Jezik besede je angleški (ZDA)"
+ ParagraphPreSet = "Jezik odstavka je angleški (ZDA)"
+ Case 2: WordPreSet = "Jezik besede je portugalski (Portugalska)"
+ ParagraphPreSet = "Jezik odstavka je portugalski (Portugalska)"
+ Case 3: WordPreSet = "Jezik besede je ruski"
+ ParagraphPreSet = "Jezik odstavka je ruski"
+ Case 4: WordPreSet = "Jezik besede je nizozemski (Nizozemska)"
+ ParagraphPreSet = "Jezik odstavka je nizozemski (Nizozemska)"
+ Case 5: WordPreSet = "Jezik besede je francoski (Francija)"
+ ParagraphPreSet = "Jezik odstavka je francoski (Francija)"
+ Case 6: WordPreSet = "Jezik besede je Å¡panski (Å panija)"
+ ParagraphPreSet = "Jezik odstavka je Å¡panski (Å panija)"
+ Case 7: WordPreSet = "Jezik besede je madžarski"
+ ParagraphPreSet = "Jezik odstavka je madžarski"
+ Case 8: WordPreSet = "Jezik besede je italijanski (Italija)"
+ ParagraphPreSet = "Jezik odstavka je italijanski (Italija)"
+ Case 9: WordPreSet = "Jezik besede je Å¡vedski (Å vedska)"
+ ParagraphPreSet = "Jezik odstavka je Å¡vedski (Å vedska)"
+ Case 10:WordPreSet = "Jezik besede je poljski"
+ ParagraphPreSet = "Jezik odstavka je poljski"
+ Case 11:WordPreSet = "Jezik besede je nemÅ¡ki (NemÄija)"
+ ParagraphPreSet = "Jezik odstavka je nemÅ¡ki (NemÄija)"
+ end select
+ '-----------------------------------------------------------------------
Case 55 'Case 55: Portuguese (Brazil)
Select Case iLanguageCount
Case 1: WordPreSet = "a palavra é Inglês (EUA)"
diff --git a/testautomation/writer/tools/includes/w_tool1.inc b/testautomation/writer/tools/includes/w_tool1.inc
index 2131b1bd7dfd..34b83bc5e97b 100644..100755
--- a/testautomation/writer/tools/includes/w_tool1.inc
+++ b/testautomation/writer/tools/includes/w_tool1.inc
@@ -434,6 +434,8 @@ end sub
'----------------------------------------------------------------
sub sAutopilot_ListboxCombobox(WhichBox as String)
+ Dim iCount as integer
+ iCount = 1
Kontext "AutoPilotListComboBox"
if AutoPilotListComboBox.Exists then
printlog " -Autopilot-Listbox Page 1"
@@ -441,6 +443,18 @@ sub sAutopilot_ListboxCombobox(WhichBox as String)
if TabListboxData.Exists then
Call DialogTest( TabListBoxData )
DataSource.Select 1
+ Do
+ if iCount >= 15 then exit do
+ try
+ Table.Select 1
+ exit do
+ catch
+ wait 500
+ printlog " - attempt " & i & " to select table"
+ iCount = iCount + 1
+ endcatch
+ Loop
+
if Table.GetItemCount > 0 then
Table.Select 1
else
diff --git a/testgraphical/document-pool/demo/CurrentTime.ods b/testgraphical/document-pool/demo/CurrentTime.ods
new file mode 100644
index 000000000000..e027215ddb74
--- /dev/null
+++ b/testgraphical/document-pool/demo/CurrentTime.ods
Binary files differ
diff --git a/testgraphical/document-pool/demo/knownissues.xcl b/testgraphical/document-pool/demo/knownissues.xcl
new file mode 100644
index 000000000000..5cdad159bc35
--- /dev/null
+++ b/testgraphical/document-pool/demo/knownissues.xcl
@@ -0,0 +1,8 @@
+[ps]
+### contains date in it, will fail every time ###
+CurrentTime.ods
+
+[pdf]
+### contains date in it, will fail every time ###
+CurrentTime.ods
+
diff --git a/testgraphical/document-pool/singletest/eis-test.odt b/testgraphical/document-pool/singletest/eis-test.odt
new file mode 100644
index 000000000000..bb9c6a43f623
--- /dev/null
+++ b/testgraphical/document-pool/singletest/eis-test.odt
Binary files differ
diff --git a/testshl2/workben/codegen/w32/makefile.mk b/testgraphical/prechecks/makefile.mk
index d0ab5baf4afb..13796c949ab5 100644
--- a/testshl2/workben/codegen/w32/makefile.mk
+++ b/testgraphical/prechecks/makefile.mk
@@ -24,22 +24,33 @@
# for a copy of the LGPLv3 License.
#
#*************************************************************************
-PRJ=..$/..$/..
-PRJNAME=testshl2
-TARGET=codegen
-# this is removed at the moment because we need some enhancements
-# TESTDIR=TRUE
+PRJ=..
-ENABLE_EXCEPTIONS=TRUE
+PRJNAME=gfxcmp_prechecks
+TARGET=notargetyet
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
-#------------------------------- All object files -------------------------------
+# --- Targets ------------------------------------------------------
+.INCLUDE : target.mk
-# --- Targets ------------------------------------------------------
+.IF "$(VERBOSE)"!=""
+ P_VERBOSE=-verbose
+.ENDIF
+.IF "$(SHOW)"!=""
+ P_JAVA6=-java6
+.ENDIF
+
+# PERLDEBUG=-d:ptkdb
+ALLTAR:
+.IF "$(GUI)"=="WNT" || "$(GUI)"=="OS2"
+ $(PERL) $(PERLDEBUG) softwaretests.pl -printerdriver -imagemagick -ghostscript $(P_VERBOSE) $(P_JAVA6)
+.ELSE
+ $(PERL) $(PERLDEBUG) softwaretests.pl -imagemagick -ghostscript $(P_VERBOSE) $(P_JAVA6)
+.ENDIF
-.INCLUDE : target.mk
+.INCLUDE : $(PRJ)$/util$/makefile.pmk
diff --git a/testgraphical/prechecks/softwaretests.pl b/testgraphical/prechecks/softwaretests.pl
new file mode 100644
index 000000000000..f591fa139879
--- /dev/null
+++ b/testgraphical/prechecks/softwaretests.pl
@@ -0,0 +1,564 @@
+eval 'exec perl -wS $0 ${1+\"$@\"}'
+ if 0;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+# This is a pre check, which checks if some extra software exists
+
+BEGIN
+{
+ # Adding the path of this script file to the include path in the hope
+ # that all used modules can be found in it.
+ $0 =~ /^(.*)[\/\\]/;
+ push @INC, $1;
+}
+
+use strict;
+use English; # $OSNAME, ...
+use Getopt::Long;
+use Cwd;
+use Cwd 'chdir';
+my $cwd = getcwd();
+
+our $help; # Help option flag
+our $version; # Version option flag
+
+# flush STDOUT
+# my $old_handle = select (STDOUT); # "select" STDOUT and save # previously selected handle
+# $| = 1; # perform flush after each write to STDOUT
+# select ($old_handle); # restore previously selected handle
+
+$OUTPUT_AUTOFLUSH=1; # works only if use English is used.
+
+our $sGlobalIniFile;
+our $verbose = 0;
+our $ghostscript;
+our $imagemagick;
+our $java6;
+our $printerdriver;
+
+our $version_info = 'compare.pl';
+
+GetOptions(
+ "ghostscript" => \$ghostscript,
+ "imagemagick" => \$imagemagick,
+ "java6" => \$java6,
+ "printerdriver" => \$printerdriver,
+ "verbose" => \$verbose,
+
+ "help" => \$help,
+ "version" => \$version
+ );
+
+if ($help)
+{
+ print_usage(*STDOUT);
+ exit(0);
+}
+# Check for version option
+if ($version)
+{
+ print STDERR "$version_info\n";
+ exit(0);
+}
+
+# prepare the GlobalIniFile
+
+sub prepare()
+{
+ my $sEnv = "$ENV{PRJ}";
+ if (! $sEnv)
+ {
+ print "Warning: Seems you are not in a makefile.mk environment.\n";
+ $sEnv = "..";
+ }
+ my $sPath = getcwd();
+ $sPath .= "/" . $sEnv;
+ chdir ($sPath);
+ cwd();
+ $sPath = getcwd();
+ my $sInpath = $ENV{INPATH};
+ $sPath .= "/" . $sInpath . "/misc";
+ $sGlobalIniFile = "$sPath/pathes.ini";
+ print "Global Path ini file is: $sGlobalIniFile\n" if ($verbose);
+}
+
+sub unixpath($)
+{
+ my $path = shift;
+ $path =~ s/\\/\//g; # make out of '\' a '/'
+ return $path;
+}
+
+# search for file in a given path list.
+# the path list should be separated as the path variable in the corresponding OS
+sub searchForFileInPath($$)
+{
+ my $sFile = shift;
+ my $sPathList = shift;
+
+ my $sep = ':';
+ if ($OSNAME eq "MSWin32")
+ {
+ $sep = ';';
+ }
+ my @path = split($sep, $sPathList);
+
+ my $sPath;
+ my $startdir;
+ my $bFound = 0;
+ my $olddir = getcwd();
+
+ my $sWindowsHomeDir = unixpath(lc($ENV{WINDIR}));
+
+ foreach $startdir (@path)
+ {
+ my $nCount = 0;
+ #
+ # IMPORTANT: leave out windir path.
+ #
+ if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ my $sPath = unixpath(lc(convertCygwinPath($startdir)));
+ if ($sPath =~ /^$sWindowsHomeDir/ )
+ {
+ print "path: $startdir is windows path leave out.\n" if ($verbose);
+ next;
+ }
+ }
+
+ local *DIR;
+ if (opendir (DIR, $startdir)) # open directory
+ {
+ print "path: $startdir" if ($verbose);
+ chdir ($startdir);
+ cwd();
+ my $myfile;
+ while ($myfile = readdir(DIR)) # get filename
+ {
+ if (-f $myfile ) # is it a file?
+ {
+ $nCount ++;
+ if ($myfile eq $sFile) # is it the real file?
+ {
+ $sPath = $startdir;
+ $bFound = 1;
+ last;
+ }
+ }
+ }
+ closedir(DIR);
+ print " ($nCount)\n" if ($verbose);
+ }
+ if ($bFound == 1)
+ {
+ last;
+ }
+ }
+ chdir ($olddir);
+ cwd();
+
+ return $sPath;
+}
+
+
+prepare();
+# don't remove the inifile, only build clean should do this.
+# if ( -e "$sGlobalIniFile")
+# {
+# unlink($sGlobalIniFile);
+# }
+
+
+# small helper, which replaces the return code
+sub errorAdaption($)
+{
+ my $error = shift;
+ if ($error != 0)
+ {
+ $error = $error / 256;
+ }
+ if ($error > 127)
+ {
+ $error = $error - 256;
+ }
+ return $error;
+}
+
+# for every error we increment this variable by 1
+our $nGlobalErrors = 0;
+
+sub handleError($$)
+{
+ my $error = shift;
+ my $sText = shift;
+ if ($error != 0)
+ {
+ print "ERROR: search for $sText has failed with Errornumber: $error\n";
+ $nGlobalErrors ++;
+ }
+}
+
+sub convertCygwinPath($)
+{
+ my $sPath = shift;
+
+ if ($OSNAME eq "cygwin")
+ {
+ # print "Cygwin Path Patch.\n" if ($verbose);
+ if ($sPath =~ /\/cygdrive\/(.)/)
+ {
+ my $Letter = $1;
+ $sPath =~ s/\/cygdrive\/${Letter}/${Letter}\:/;
+ # print "Cygwin Path Patch: '$sPath'\n" if ($verbose);
+ }
+ }
+ return $sPath;
+}
+
+# append key=value to GlobalIniFile
+sub insertPath($$)
+{
+ my $sKey = shift;
+ my $sValue = shift;
+
+ $sValue = convertCygwinPath($sValue);
+ my $sIniFile = convertCygwinPath($sGlobalIniFile);
+ local *INIFILE;
+ if (open(INIFILE, ">>" . $sIniFile ))
+ {
+ print INIFILE "$sKey=$sValue\n";
+ }
+ close(INIFILE);
+}
+
+sub getFastPath($)
+{
+ my $sKey = shift;
+ my $sValue;
+ local *INIFILE;
+ my $sIniFile = convertCygwinPath($sGlobalIniFile);
+ if (open(INIFILE, $sIniFile))
+ {
+ my $line;
+ while ($line = <INIFILE>)
+ {
+ chomp($line);
+ if ( $line =~ /^$sKey=(.*)$/ )
+ {
+ $sValue = $1;
+ # print INIFILE "$sKey=$sValue\n";
+ }
+ }
+ close(INIFILE);
+ }
+ return $sValue;
+}
+
+sub checkForGhostscript()
+{
+ print "Search for Ghostscript\n" if ($verbose);
+ if ($OSNAME eq "linux" ||
+ $OSNAME eq "solaris")
+ {
+ # search for ghostscript
+ local *GHOSTSCRIPT;
+ if (open(GHOSTSCRIPT, "which gs 2>&1 |"))
+ {
+ my $line;
+ while ($line = <GHOSTSCRIPT>)
+ {
+ chomp($line);
+ print "- $line\n" if ($verbose);
+ }
+ close(GHOSTSCRIPT);
+ }
+ my $error = errorAdaption($?);
+ handleError($error, "Ghostscript");
+ }
+ elsif ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ my $sGSExe = "gswin32c.exe";
+ # my $sGSPath = "C:/gs/gs8.64/bin";
+ my $sGSPath = getFastPath("gs.path");
+ if (! $sGSPath)
+ {
+ $sGSPath = searchForFileInPath($sGSExe, $ENV{PATH});
+
+ if ( ! -e "$sGSPath/$sGSExe")
+ {
+ $nGlobalErrors ++;
+ print "ERROR: search for $sGSPath/$sGSExe failed.\n";
+ print "Please install ghostscript from www.adobe.com to and make it available in \$PATH variable \n";
+ }
+ else
+ {
+ insertPath("gs.path", $sGSPath);
+ insertPath("gs.exe", $sGSExe);
+ }
+ }
+ if ( -e "$sGSPath/$sGSExe" )
+ {
+ print "Found Ghostscript: '$sGSPath'\n" if ($verbose);
+ }
+ }
+ else
+ {
+ print "ERROR: Check for Ghostscript failed, due to unsupported '$OSNAME' environment.\n";
+ $nGlobalErrors ++;
+ }
+}
+
+
+sub checkForPSDriver()
+{
+ # we don't need to check for unix here, due to the fact, unix is per default be able to print in postscript
+ if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ print "Check for postscript driver.\n" if ($verbose);
+ my $sWindowsRoot = $ENV{windir};
+ if (! $sWindowsRoot)
+ {
+ $sWindowsRoot = $ENV{WINDIR};
+ }
+ my $sCrossOfficeDriver = "${sWindowsRoot}/system32/crossoffice.ppd";
+ if ( ! -e "$sCrossOfficeDriver")
+ {
+ print "ERROR: Don't found Postscript driver $sCrossOfficeDriver file\n";
+ $nGlobalErrors ++;
+ print "Take a look on: http://so-gfxcmp.germany.sun.com/docs/further/convwatch/convwatch.html.\n";
+ }
+ }
+}
+
+sub checkForImageMagick()
+{
+ print "Search for Imagemagick\n" if ($verbose);
+ if ($OSNAME eq "linux" ||
+ $OSNAME eq "solaris")
+ {
+ # search for imagemagick
+ local *IMAGEMAGICK;
+ if (open(IMAGEMAGICK, "which convert 2>&1 |"))
+ {
+ my $line;
+ while ($line = <IMAGEMAGICK>)
+ {
+ chomp($line);
+ print "- $line\n" if ($verbose);
+ }
+ close(IMAGEMAGICK);
+ }
+ my $error = errorAdaption($?);
+ handleError($error, "Imagemagick");
+ }
+ elsif ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ my $sImageMagickExe = "convert.exe";
+ # my $sImageMagickPath = "C:/gs/gs8.64/bin";
+ my $sImageMagickPath = getFastPath("imagemagick.path");
+ if (! $sImageMagickPath)
+ {
+ $sImageMagickPath = searchForFileInPath($sImageMagickExe, $ENV{PATH});
+ if ($sImageMagickPath)
+ {
+ if ( ! -e "$sImageMagickPath/$sImageMagickExe")
+ {
+ $nGlobalErrors ++;
+ print "ERROR: search for $sImageMagickPath/$sImageMagickExe failed.\n";
+ print "Please install ImageMagick from www.imagemagick.org to and make it available in \$PATH variable \n";
+ }
+ else
+ {
+ insertPath("imagemagick.path", $sImageMagickPath);
+ # insertPath("gs.exe", $sImageMagickExe);
+ }
+ }
+ else
+ {
+ # next try, search image magick in $PROGRAMFILES
+ my $sPrograms = unixpath($ENV{PROGRAMFILES});
+
+ if (! $sPrograms)
+ {
+ print "There exist no \$PROGRAMFILES path, wrong Windows version?\n";
+ $nGlobalErrors++;
+ }
+ else
+ {
+ local *DIR;
+ if (opendir (DIR, $sPrograms)) # open program directory
+ {
+ my $myfile;
+ while ($myfile = readdir(DIR)) # get a filename
+ {
+ if ($myfile =~ /ImageMagick/)
+ {
+ $sImageMagickPath = $sPrograms . "/" . $myfile;
+ last;
+ }
+ }
+ closedir(DIR);
+ }
+ if (! -e $sImageMagickPath)
+ {
+ print "ImageMagick not found.\n";
+ $nGlobalErrors ++;
+ }
+ else
+ {
+ insertPath("imagemagick.path", $sImageMagickPath);
+ }
+ }
+ }
+
+ }
+ if ( -e "$sImageMagickPath/$sImageMagickExe" )
+ {
+ print "Found ImageMagick: '$sImageMagickPath'\n" if ($verbose);
+ }
+ }
+ else
+ {
+ print "ERROR: not supported environment\n";
+ }
+}
+
+sub checkForJava6()
+{
+ print "Search for Java6\n" if ($verbose);
+ my $javaexe = "java";
+ if ( $ENV{JAVA6} )
+ {
+ $javaexe = $ENV{JAVA6};
+ }
+
+ if ($OSNAME eq "linux" || $OSNAME eq "cygwin")
+ {
+ # search for imagemagick
+ local *JAVA;
+ if (open(JAVA, "$javaexe -version 2>&1 |"))
+ {
+ my $line;
+ while ($line = <JAVA>)
+ {
+ chomp($line);
+ print "- $line\n" if ($verbose);
+ if ( $line =~ /java version "(.*)"/ )
+ {
+ my $javaversion = $1;
+ my @version = split('\.', $javaversion);
+ print "Found Java version: $version[1] the complete version: $javaversion\n" if ($verbose);
+ if ( $version[1] < 6)
+ {
+ print "Wrong Java version, at least Java version 6 is need but found $javaversion.\n";
+ $nGlobalErrors++;
+ print "It is possible to overwrite the java exe with environment variable JAVA6='path'.\n";
+ }
+ else
+ {
+ insertPath("java.exe", $javaexe);
+ }
+ last;
+ }
+ }
+ close(JAVA);
+ }
+ my $error = errorAdaption($?);
+ handleError($error, "Java");
+ }
+ elsif ($OSNAME eq "MSWin32")
+ {
+ my $javaexe = "java";
+ if ( $ENV{JAVA6} )
+ {
+ $javaexe = $ENV{JAVA6};
+ }
+
+ if (! -e $javaexe)
+ {
+ print "Java not found.\n";
+ $nGlobalErrors ++;
+ }
+ else
+ {
+ print "Found Java: '$javaexe'\n" if ($verbose);
+ insertPath("java.exe", $javaexe);
+ }
+ }
+ else
+ {
+ print "ERROR: Java not found.\n";
+ }
+}
+
+# different checks
+print "Environment '$OSNAME'\n" if ($verbose);
+
+if ($printerdriver)
+{
+ checkForPSDriver();
+}
+if ($ghostscript)
+{
+ checkForGhostscript();
+}
+if ($imagemagick)
+{
+ checkForImageMagick();
+}
+if ($java6)
+{
+ checkForJava6();
+}
+
+# return with found errors
+exit($nGlobalErrors);
+
+# ------------------------------------------------------------------------------
+sub print_usage(*)
+{
+ local *HANDLE = $_[0];
+ my $tool_name = basename($0);
+
+ print(HANDLE <<END_OF_USAGE);
+
+Usage: $tool_name [OPTIONS]
+
+ -ghostscript Try to find ghostscript in your environment
+ -imagemagick Try to find imagemagick
+ -java6 Checks for java 1.6.x
+ -printerdriver Try to find printer driver, windows only
+ -verbose be verbose
+
+ -h, --help Print this help, then exit
+ -v, --version Print version number, then exit
+
+END_OF_USAGE
+;
+}
diff --git a/testgraphical/prj/build.lst b/testgraphical/prj/build.lst
new file mode 100755
index 000000000000..45fb77fd81ec
--- /dev/null
+++ b/testgraphical/prj/build.lst
@@ -0,0 +1,7 @@
+gfxcmp testgraphical : instsetoo_native NULL
+gfxcmp testgraphical usr1 - all gfxcmp_mkout NULL
+#gfxcmp testgraphical\prechecks nmake - all gfxcmp_pre NULL
+gfxcmp testgraphical\ui\java\ConvwatchGUIProject nmake - all gfxcmp_java_ui NULL
+gfxcmp testgraphical\ui\java nmake - all gfxcmp_java gfxcmp_java_ui NULL
+# gfxcmp testgraphical\source nmake - all gfxcmp_src gfxcmp_java NULL
+gfxcmp testgraphical\qa\graphical nmake - all gfxcmp_qa gfxcmp_java NULL
diff --git a/testgraphical/prj/d.lst b/testgraphical/prj/d.lst
new file mode 100755
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/testgraphical/prj/d.lst
diff --git a/testgraphical/qa/graphical/Test.java b/testgraphical/qa/graphical/Test.java
new file mode 100644
index 000000000000..8c633dede44c
--- /dev/null
+++ b/testgraphical/qa/graphical/Test.java
@@ -0,0 +1,113 @@
+/*************************************************************************
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+************************************************************************/
+
+package org.openoffice.testgraphical.qa.graphical;
+
+import org.openoffice.Runner;
+import org.openoffice.test.OfficeConnection;
+import static org.junit.Assert.*;
+
+import helper.ProcessHandler;
+import graphical.FileHelper;
+import java.io.File;
+
+public final class Test {
+ @org.junit.Before
+ public void setUp() throws Exception
+ {
+ connection.setUp();
+ }
+
+ @org.junit.After
+ public void tearDown() throws Exception
+ {
+ connection.tearDown();
+ }
+
+ @org.junit.Test
+ public void test()
+ {
+ boolean good = true;
+
+ final String sPerlEXE = System.getenv("PERL");
+ // System.out.println("PERL:=" + sPerlEXE);
+
+ final String sPRJ = System.getenv("PRJ");
+ // System.out.println("PRJ:=" + sPRJ);
+
+ String sShow = "";
+ if (System.getProperty("SHOW") != null)
+ {
+ sShow = "-show";
+ }
+
+ final String sComparePath = FileHelper.appendPath(sPRJ, "source");
+ final String sCompareName = FileHelper.appendPath(sComparePath, "compare.pl");
+
+ File aCompareFile = new File(sCompareName);
+ if (!aCompareFile.exists())
+ {
+ System.out.println("Path to compare.pl is wrong: '" + aCompareFile.getAbsolutePath() + "'");
+ assertTrue(false);
+ }
+
+ final String sConnectionString = connection.getDescription();
+
+ String[] sCommandArray =
+ {
+ sPerlEXE,
+ aCompareFile.getAbsolutePath(),
+ "-creatortype", "pdf",
+
+// If you make changes here, do it also in ../../source/makefile.mk in selftest: target!
+
+ "-pool", "singletest",
+ "-document", "eis-test.odt",
+ // "-pool", "demo",
+ // "-document", "CurrentTime.ods",
+ "-connectionstring", sConnectionString,
+ // "-verbose",
+ sShow
+ };
+
+ ProcessHandler aHandler = new ProcessHandler(sCommandArray);
+ boolean bBackValue = aHandler.executeSynchronously();
+ int nExitCode = aHandler.getExitCode();
+
+ // String sBack = aHandler.getOutputText();
+ if (nExitCode != 0)
+ {
+ good = false;
+ }
+
+ assertTrue(good);
+
+ // Runner.run(
+ // "-sce", "sw.sce", "-xcl", "knownissues.xcl", "-tdoc",
+ // "testdocuments", "-cs", connection.getDescription()));
+ }
+
+ private final OfficeConnection connection = new OfficeConnection();
+}
diff --git a/testshl2/source/testshlrunner/makefile.mk b/testgraphical/qa/graphical/makefile.mk
index c29ff16e7c08..7cb43a6585db 100644
--- a/testshl2/source/testshlrunner/makefile.mk
+++ b/testgraphical/qa/graphical/makefile.mk
@@ -1,7 +1,6 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -22,23 +21,37 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+#***********************************************************************/
+
+.IF "$(OOO_SUBSEQUENT_TESTS)" == ""
+nothing .PHONY:
+ @echo "OOO_SUBSEQUENT_TESTS not given, do nothing."
+.ELSE
+
+PRJ = ../..
+PRJNAME = testgraphical
+TARGET = qa_graphical
+
+.IF "$(OOO_JUNIT_JAR)" != ""
-PRJ = ..$/..
+.IF "$(SHOW)" != ""
+# You will need java6 for this!
+JAVAIFLAGS:=$(JAVAIFLAGS) -DSHOW=1
+.ENDIF
-PRJNAME = TestShl2Runner
-TARGET = TestShl2Runner
+PACKAGE = org/openoffice/testgraphical/qa/graphical
+JAVATESTFILES = Test.java
+JAVAFILES = $(JAVATESTFILES)
+JARFILES = OOoRunner.jar test.jar
+EXTRAJARFILES = $(OOO_JUNIT_JAR)
+.END
-# --- Settings -----------------------------------------------------
.INCLUDE: settings.mk
+.INCLUDE: target.mk
+.INCLUDE: installationtest.mk
-# JARFILES = ridl.jar unoil.jar jurt.jar juh.jar
-# Tip:
-# why 'grep java$$' the $$ is for a real $ and this is for regexp and stays for line end,
-# so we prevent us for compiling *.java~
-JAVAFILES = $(foreach,j,$(shell @ls | grep java$$) $j)
+ALLTAR : javatest
-# --- Targets ------------------------------------------------------
+.END
-.INCLUDE : target.mk
+clean:
diff --git a/testgraphical/references/unxlngi/demo/CurrentTime.ods.pdf b/testgraphical/references/unxlngi/demo/CurrentTime.ods.pdf
new file mode 100644
index 000000000000..a753c03708c7
--- /dev/null
+++ b/testgraphical/references/unxlngi/demo/CurrentTime.ods.pdf
Binary files differ
diff --git a/testgraphical/references/unxlngi/demo/CurrentTime.ods.ps b/testgraphical/references/unxlngi/demo/CurrentTime.ods.ps
new file mode 100644
index 000000000000..aa7455255e2c
--- /dev/null
+++ b/testgraphical/references/unxlngi/demo/CurrentTime.ods.ps
@@ -0,0 +1,576 @@
+%!PS-Adobe-3.0
+%%BoundingBox: (atend)
+%%Creator: (Oracle Open Office 3.2)
+%%For: (ll93751)
+%%CreationDate: (Fri May 12 00:00:14 2000)
+%%Title: (CurrentTime)
+%%LanguageLevel: 2
+%%DocumentData: Clean7Bit
+%%Pages: (atend)
+%%Orientation: (atend)
+%%PageOrder: Ascend
+%%EndComments
+%%BeginProlog
+%%BeginResource: procset PSPrint-Prolog 1.0 0
+/ISO1252Encoding [
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/space /exclam /quotedbl /numbersign /dollar /percent /ampersand /quotesingle
+/parenleft /parenright /asterisk /plus /comma /hyphen /period /slash
+/zero /one /two /three /four /five /six /seven
+/eight /nine /colon /semicolon /less /equal /greater /question
+/at /A /B /C /D /E /F /G
+/H /I /J /K /L /M /N /O
+/P /Q /R /S /T /U /V /W
+/X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore
+/grave /a /b /c /d /e /f /g
+/h /i /j /k /l /m /n /o
+/p /q /r /s /t /u /v /w
+/x /y /z /braceleft /bar /braceright /asciitilde /unused
+/Euro /unused /quotesinglbase /florin /quotedblbase /ellipsis /dagger /daggerdbl
+/circumflex /perthousand /Scaron /guilsinglleft /OE /unused /Zcaron /unused
+/unused /quoteleft /quoteright /quotedblleft /quotedblright /bullet /endash /emdash
+/tilde /trademark /scaron /guilsinglright /oe /unused /zcaron /Ydieresis
+/space /exclamdown /cent /sterling /currency /yen /brokenbar /section
+/dieresis /copyright /ordfeminine /guillemotleft /logicalnot /hyphen /registered /macron
+/degree /plusminus /twosuperior /threesuperior /acute /mu /paragraph /periodcentered
+/cedilla /onesuperior /ordmasculine /guillemotright /onequarter /onehalf /threequarters /questiondown
+/Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla
+/Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis
+/Eth /Ntilde /Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply
+/Oslash /Ugrave /Uacute /Ucircumflex /Udieresis /Yacute /Thorn /germandbls
+/agrave /aacute /acircumflex /atilde /adieresis /aring /ae /ccedilla
+/egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis
+/eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide
+/oslash /ugrave /uacute /ucircumflex /udieresis /yacute /thorn /ydieresis] def
+
+/psp_definefont { exch dup findfont dup length dict begin { 1 index /FID ne
+{ def } { pop pop } ifelse } forall /Encoding 3 -1 roll def
+currentdict end exch pop definefont pop } def
+
+/pathdict dup 8 dict def load begin
+/rcmd { { currentfile 1 string readstring pop 0 get dup 32 gt { exit }
+{ pop } ifelse } loop dup 126 eq { pop exit } if 65 sub dup 16#3 and 1
+add exch dup 16#C and -2 bitshift 16#3 and 1 add exch 16#10 and 16#10
+eq 3 1 roll exch } def
+/rhex { dup 1 sub exch currentfile exch string readhexstring pop dup 0
+get dup 16#80 and 16#80 eq dup 3 1 roll { 16#7f and } if 2 index 0 3
+-1 roll put 3 1 roll 0 0 1 5 -1 roll { 2 index exch get add 256 mul }
+for 256 div exch pop exch { neg } if } def
+/xcmd { rcmd exch rhex exch rhex exch 5 -1 roll add exch 4 -1 roll add
+1 index 1 index 5 -1 roll { moveto } { lineto } ifelse } def end
+/readpath { 0 0 pathdict begin { xcmd } loop end pop pop } def
+
+systemdict /languagelevel known not {
+/xshow { exch dup length 0 1 3 -1 roll 1 sub { dup 3 index exch get
+exch 2 index exch get 1 string dup 0 4 -1 roll put currentpoint 3 -1
+roll show moveto 0 rmoveto } for pop pop } def
+/rectangle { 4 -2 roll moveto 1 index 0 rlineto 0 exch rlineto neg 0
+rlineto closepath } def
+/rectfill { rectangle fill } def
+/rectstroke { rectangle stroke } def } if
+/bshow { currentlinewidth 3 1 roll currentpoint 3 index show moveto
+setlinewidth false charpath stroke setlinewidth } def
+/bxshow { currentlinewidth 4 1 roll setlinewidth exch dup length 1 sub
+0 1 3 -1 roll { 1 string 2 index 2 index get 1 index exch 0 exch put dup
+currentpoint 3 -1 roll show moveto currentpoint 3 -1 roll false charpath
+stroke moveto 2 index exch get 0 rmoveto } for pop pop setlinewidth } def
+
+/psp_lzwfilter { currentfile /ASCII85Decode filter /LZWDecode filter } def
+/psp_ascii85filter { currentfile /ASCII85Decode filter } def
+/psp_lzwstring { psp_lzwfilter 1024 string readstring } def
+/psp_ascii85string { psp_ascii85filter 1024 string readstring } def
+/psp_imagedict {
+/psp_bitspercomponent { 3 eq { 1 }{ 8 } ifelse } def
+/psp_decodearray { [ [0 1 0 1 0 1] [0 255] [0 1] [0 255] ] exch get }
+def 7 dict dup
+/ImageType 1 put dup
+/Width 7 -1 roll put dup
+/Height 5 index put dup
+/BitsPerComponent 4 index psp_bitspercomponent put dup
+/Decode 5 -1 roll psp_decodearray put dup
+/ImageMatrix [1 0 0 1 0 0] dup 5 8 -1 roll put put dup
+/DataSource 4 -1 roll 1 eq { psp_lzwfilter } { psp_ascii85filter } ifelse put
+} def
+%%EndResource
+%%EndProlog
+%%BeginSetup
+%
+%%BeginResource: font ArialMTFID10HGSet1
+%!PS-AdobeFont-1.0-2.53740
+% Creator: SunTypeTools-TT 1.0 gelf
+% Original font name: ArialMT
+30 dict begin
+/PaintType 0 def
+/FontType 3 def
+/StrokeWidth 0 def
+/FontName (ArialMTFID10HGSet1) cvn def
+/XUID [103 0 0 16#44E1DF76 13 16#50429D91 16#0D1ECFCF] def
+/FontMatrix [.001 0 0 .001 0 0] def
+/FontBBox [-664 -324 2028 1037] def
+/Encoding 256 array def
+ 0 1 255 {Encoding exch /.notdef put} for
+ Encoding 0 /glyph0 put
+ Encoding 32 /glyph1 put
+ Encoding 48 /glyph2 put
+ Encoding 49 /glyph3 put
+ Encoding 51 /glyph4 put
+ Encoding 58 /glyph5 put
+ Encoding 80 /glyph6 put
+ Encoding 83 /glyph7 put
+ Encoding 97 /glyph8 put
+ Encoding 101 /glyph9 put
+ Encoding 103 /glyph10 put
+ Encoding 104 /glyph11 put
+ Encoding 116 /glyph12 put
+/CharProcs 14 dict def
+ CharProcs begin
+ /.notdef {} def
+ /glyph0 {
+ 750 0 125 0 625 625 setcachedevice
+ 125 0 moveto
+ 125 625 lineto
+ 625 625 lineto
+ 625 0 lineto
+ 125 0 lineto
+ closepath
+ 140 15 moveto
+ 609 15 lineto
+ 609 609 lineto
+ 140 609 lineto
+ 140 15 lineto
+ closepath
+ fill
+ } bind def
+ /glyph1 {
+ 277 0 0 0 0 0 setcachedevice
+ } bind def
+ /glyph2 {
+ 556 0 41 -12 508 718 setcachedevice
+ 41 353 moveto
+ 41 437 50 505 67 557 curveto
+ 84 608 110 648 145 676 curveto
+ 179 704 222 718 274 718 curveto
+ 313 718 347 711 375 695 curveto
+ 404 680 428 658 447 628 curveto
+ 466 600 481 564 492 522 curveto
+ 502 480 508 424 508 353 curveto
+ 508 269 500 201 482 149 curveto
+ 465 98 439 58 405 30 curveto
+ 371 2 327 -12 274 -12 curveto
+ 206 -12 151 12 112 62 curveto
+ 65 121 41 218 41 353 curveto
+ closepath
+ 131 353 moveto
+ 131 235 145 157 173 118 curveto
+ 200 80 234 60 274 60 curveto
+ 315 60 349 79 376 118 curveto
+ 404 157 417 235 417 353 curveto
+ 417 470 404 549 376 587 curveto
+ 349 626 315 645 273 645 curveto
+ 233 645 201 629 177 594 curveto
+ 147 551 131 470 131 353 curveto
+ closepath
+ fill
+ } bind def
+ /glyph3 {
+ 556 0 108 0 372 718 setcachedevice
+ 372 0 moveto
+ 284 0 lineto
+ 284 560 lineto
+ 263 540 236 520 201 499 curveto
+ 167 479 136 464 108 454 curveto
+ 108 539 lineto
+ 158 562 201 590 237 623 curveto
+ 274 655 300 687 315 718 curveto
+ 372 718 lineto
+ 372 0 lineto
+ closepath
+ fill
+ } bind def
+ /glyph4 {
+ 556 0 41 -12 510 718 setcachedevice
+ 41 188 moveto
+ 129 200 lineto
+ 140 151 157 115 181 93 curveto
+ 205 71 235 60 270 60 curveto
+ 311 60 346 74 375 103 curveto
+ 403 131 417 166 417 209 curveto
+ 417 250 404 283 377 309 curveto
+ 352 335 318 348 277 348 curveto
+ 261 348 240 345 215 338 curveto
+ 225 416 lineto
+ 230 415 235 415 239 415 curveto
+ 276 415 310 424 340 444 curveto
+ 370 463 385 494 385 534 curveto
+ 385 566 374 593 352 614 curveto
+ 331 635 302 646 268 646 curveto
+ 234 646 205 636 182 614 curveto
+ 160 593 145 561 138 517 curveto
+ 50 533 lineto
+ 61 592 85 637 124 670 curveto
+ 162 702 209 718 266 718 curveto
+ 305 718 341 710 374 693 curveto
+ 406 677 432 654 449 625 curveto
+ 466 596 475 565 475 532 curveto
+ 475 501 467 474 450 448 curveto
+ 434 423 409 402 376 387 curveto
+ 419 378 452 357 475 327 curveto
+ 499 296 510 257 510 211 curveto
+ 510 149 488 96 442 52 curveto
+ 396 9 339 -12 269 -12 curveto
+ 207 -12 154 5 113 43 curveto
+ 71 81 48 129 41 188 curveto
+ closepath
+ fill
+ } bind def
+ /glyph5 {
+ 277 0 90 0 190 518 setcachedevice
+ 90 418 moveto
+ 90 518 lineto
+ 190 518 lineto
+ 190 418 lineto
+ 90 418 lineto
+ closepath
+ 90 0 moveto
+ 90 100 lineto
+ 190 100 lineto
+ 190 0 lineto
+ 90 0 lineto
+ closepath
+ fill
+ } bind def
+ /glyph6 {
+ 666 0 77 0 623 715 setcachedevice
+ 77 0 moveto
+ 77 715 lineto
+ 347 715 lineto
+ 394 715 431 713 456 708 curveto
+ 491 703 520 692 544 675 curveto
+ 568 659 587 636 602 606 curveto
+ 616 577 623 544 623 508 curveto
+ 623 448 604 396 565 354 curveto
+ 526 312 457 291 355 291 curveto
+ 171 291 lineto
+ 171 0 lineto
+ 77 0 lineto
+ closepath
+ 171 375 moveto
+ 356 375 lineto
+ 417 375 461 386 487 409 curveto
+ 513 432 525 464 525 505 curveto
+ 525 535 518 561 503 583 curveto
+ 488 604 468 618 443 625 curveto
+ 427 629 398 631 354 631 curveto
+ 171 631 lineto
+ 171 375 lineto
+ closepath
+ fill
+ } bind def
+ /glyph7 {
+ 666 0 44 -12 614 728 setcachedevice
+ 44 229 moveto
+ 134 237 lineto
+ 138 202 148 172 164 149 curveto
+ 179 126 203 108 235 94 curveto
+ 268 80 305 72 345 72 curveto
+ 381 72 413 78 441 88 curveto
+ 469 99 489 114 503 133 curveto
+ 516 151 523 172 523 194 curveto
+ 523 216 517 236 503 253 curveto
+ 491 270 469 284 439 295 curveto
+ 420 302 377 314 312 330 curveto
+ 246 346 200 360 173 375 curveto
+ 140 393 114 415 97 441 curveto
+ 81 468 72 498 72 530 curveto
+ 72 566 82 600 103 632 curveto
+ 123 663 153 687 192 703 curveto
+ 232 719 275 728 324 728 curveto
+ 377 728 424 719 464 702 curveto
+ 505 685 536 660 558 626 curveto
+ 580 594 591 556 593 514 curveto
+ 502 507 lineto
+ 498 552 481 586 453 609 curveto
+ 425 632 383 644 328 644 curveto
+ 270 644 229 634 203 613 curveto
+ 177 592 163 566 163 537 curveto
+ 163 511 172 490 191 473 curveto
+ 209 457 257 440 334 422 curveto
+ 411 405 463 390 492 376 curveto
+ 534 357 564 333 584 304 curveto
+ 604 274 614 240 614 202 curveto
+ 614 164 604 128 582 94 curveto
+ 560 61 529 35 488 16 curveto
+ 447 -2 401 -12 350 -12 curveto
+ 285 -12 231 -2 187 16 curveto
+ 144 35 109 63 84 101 curveto
+ 59 139 46 182 44 229 curveto
+ closepath
+ fill
+ } bind def
+ /glyph8 {
+ 556 0 36 -11 513 530 setcachedevice
+ 404 63 moveto
+ 372 36 340 17 310 5 curveto
+ 280 -5 248 -11 213 -11 curveto
+ 156 -11 112 2 82 30 curveto
+ 51 58 36 93 36 136 curveto
+ 36 162 41 185 53 206 curveto
+ 64 227 80 244 99 256 curveto
+ 117 269 138 279 162 285 curveto
+ 179 290 205 294 240 298 curveto
+ 311 307 363 317 396 329 curveto
+ 397 341 397 348 397 352 curveto
+ 397 387 389 413 372 427 curveto
+ 350 447 316 457 272 457 curveto
+ 231 457 201 450 181 436 curveto
+ 161 421 146 395 137 358 curveto
+ 51 370 lineto
+ 59 407 71 437 89 459 curveto
+ 107 482 133 500 167 512 curveto
+ 201 524 240 530 285 530 curveto
+ 329 530 365 525 393 514 curveto
+ 420 504 440 491 454 475 curveto
+ 467 459 476 439 481 415 curveto
+ 484 400 485 374 485 334 curveto
+ 485 217 lineto
+ 485 135 487 84 491 62 curveto
+ 495 41 502 20 513 0 curveto
+ 421 0 lineto
+ 413 18 407 39 404 63 curveto
+ closepath
+ 396 260 moveto
+ 365 247 317 236 253 227 curveto
+ 217 222 191 216 176 209 curveto
+ 162 203 150 193 142 181 curveto
+ 134 168 129 154 129 139 curveto
+ 129 116 138 96 156 80 curveto
+ 174 65 200 57 234 57 curveto
+ 268 57 298 64 324 79 curveto
+ 351 94 370 114 382 140 curveto
+ 392 160 396 189 396 228 curveto
+ 396 260 lineto
+ closepath
+ fill
+ } bind def
+ /glyph9 {
+ 556 0 36 -11 514 530 setcachedevice
+ 420 166 moveto
+ 511 155 lineto
+ 497 103 471 62 432 32 curveto
+ 393 3 344 -11 283 -11 curveto
+ 208 -11 147 11 103 58 curveto
+ 59 104 36 170 36 254 curveto
+ 36 342 59 409 104 458 curveto
+ 148 506 207 530 278 530 curveto
+ 348 530 404 506 448 459 curveto
+ 492 412 514 346 514 260 curveto
+ 514 255 514 247 514 236 curveto
+ 127 236 lineto
+ 130 180 146 136 175 105 curveto
+ 204 76 240 60 284 60 curveto
+ 316 60 343 68 366 85 curveto
+ 389 103 407 129 420 166 curveto
+ closepath
+ 132 309 moveto
+ 421 309 lineto
+ 418 352 407 385 388 407 curveto
+ 360 440 324 458 279 458 curveto
+ 239 458 206 444 178 417 curveto
+ 150 390 135 354 132 309 curveto
+ closepath
+ fill
+ } bind def
+ /glyph10 {
+ 556 0 32 -210 489 530 setcachedevice
+ 49 -42 moveto
+ 135 -55 lineto
+ 138 -81 148 -101 165 -113 curveto
+ 187 -129 216 -137 254 -137 curveto
+ 294 -137 326 -129 348 -112 curveto
+ 370 -96 385 -74 393 -44 curveto
+ 397 -26 400 10 399 67 curveto
+ 361 22 313 0 256 0 curveto
+ 185 0 130 25 90 77 curveto
+ 52 128 32 190 32 262 curveto
+ 32 311 41 357 59 399 curveto
+ 77 440 103 473 137 496 curveto
+ 170 519 210 530 256 530 curveto
+ 317 530 368 505 408 456 curveto
+ 408 518 lineto
+ 489 518 lineto
+ 489 70 lineto
+ 489 -10 481 -67 464 -101 curveto
+ 448 -134 422 -161 386 -180 curveto
+ 351 -200 307 -210 254 -210 curveto
+ 193 -210 143 -196 104 -168 curveto
+ 67 -140 48 -99 49 -42 curveto
+ closepath
+ 122 268 moveto
+ 122 200 136 151 163 119 curveto
+ 189 88 224 72 264 72 curveto
+ 305 72 338 88 366 119 curveto
+ 393 150 407 199 407 265 curveto
+ 407 329 393 376 365 409 curveto
+ 337 441 303 457 263 457 curveto
+ 224 457 191 441 163 410 curveto
+ 136 378 122 331 122 268 curveto
+ closepath
+ fill
+ } bind def
+ /glyph11 {
+ 556 0 65 0 488 715 setcachedevice
+ 65 0 moveto
+ 65 715 lineto
+ 153 715 lineto
+ 153 458 lineto
+ 194 506 246 530 309 530 curveto
+ 347 530 380 522 409 507 curveto
+ 437 492 458 471 470 444 curveto
+ 482 418 488 379 488 328 curveto
+ 488 0 lineto
+ 400 0 lineto
+ 400 328 lineto
+ 400 372 391 404 372 424 curveto
+ 353 444 326 454 291 454 curveto
+ 265 454 240 448 217 434 curveto
+ 194 421 178 402 168 379 curveto
+ 159 356 153 324 153 283 curveto
+ 153 0 lineto
+ 65 0 lineto
+ closepath
+ fill
+ } bind def
+ /glyph12 {
+ 277 0 17 -6 270 699 setcachedevice
+ 257 78 moveto
+ 270 0 lineto
+ 246 -3 224 -6 204 -6 curveto
+ 172 -6 147 -1 129 8 curveto
+ 112 18 100 31 92 48 curveto
+ 85 64 82 99 82 151 curveto
+ 82 450 lineto
+ 17 450 lineto
+ 17 518 lineto
+ 82 518 lineto
+ 82 646 lineto
+ 169 699 lineto
+ 169 518 lineto
+ 257 518 lineto
+ 257 450 lineto
+ 169 450 lineto
+ 169 146 lineto
+ 169 122 170 105 174 98 curveto
+ 177 91 182 85 189 81 curveto
+ 196 77 206 75 219 75 curveto
+ 229 75 241 76 257 78 curveto
+ closepath
+ fill
+ } bind def
+ end
+/BuildGlyph {
+ exch /CharProcs get exch
+ 2 copy known not
+ {pop /.notdef} if
+ get exec
+} bind def
+/BuildChar {
+ 1 index /Encoding get exch get
+ 1 index /BuildGlyph get exec
+} bind def
+currentdict end
+(ArialMTFID10HGSet1) cvn exch definefont pop
+%%EndResource
+%%DocumentSuppliedResources: font ArialMTFID10HGSet1
+[{
+%%BeginFeature: *PageSize A4
+<</PageSize [595 842] /ImagingBBox null>> setpagedevice
+%%EndFeature
+} stopped cleartomark
+%%EndSetup
+%%Page: 1 1
+%%PageOrientation: Portrait
+%%PageBoundingBox: 18 18 577 824
+%%BeginPageSetup
+%
+%%EndPageSetup
+gsave
+[0.24 0 0 -0.24 18 824] concat
+gsave
+grestore
+gsave
+readpath
+V00EC00ECA003CE07D900A00BC~
+closepath clip newpath
+grestore
+gsave
+readpath
+V00EC00ECA003CE07D900A00BC~
+closepath clip newpath
+1174 280 moveto
+0 0 0 setrgbcolor
+(ArialMTFID10HGSet1) cvn findfont 42 -42 matrix scale makefont setfont
+<536865657431>
+[28 23 23 23 12 0]
+xshow
+grestore
+gsave
+readpath
+V00EC00ECA003CE07D900A00BC~
+closepath clip newpath
+grestore
+gsave
+readpath
+V00EC0C8CA003CE07D900A00BC~
+closepath clip newpath
+grestore
+gsave
+readpath
+V00EC0C8CA003CE07D900A00BC~
+closepath clip newpath
+1174 3256 moveto
+0 0 0 setrgbcolor
+(ArialMTFID10HGSet1) cvn findfont 42 -42 matrix scale makefont setfont
+<5061676520>
+[28 23 23 23 0]
+xshow
+1283 3256 moveto
+<31>
+show
+grestore
+gsave
+readpath
+V00EC0C8CA003CE07D900A00BC~
+closepath clip newpath
+grestore
+gsave
+568 782 moveto
+0 0 0 setrgbcolor
+(ArialMTFID10HGSet1) cvn findfont 367 -367 matrix scale makefont setfont
+<30>
+show
+781 782 moveto
+<3A>
+show
+1050 782 moveto
+<3030>
+[204 0]
+xshow
+1466 782 moveto
+<3A>
+show
+1735 782 moveto
+<3133>
+[204 0]
+xshow
+grestore grestore
+showpage
+%%PageTrailer
+
+%%Trailer
+%%BoundingBox: 0 0 595 842
+%%Orientation: Portrait
+%%Pages: 1
+%%EOF
diff --git a/testgraphical/references/unxlngi/singletest/eis-test.odt.pdf b/testgraphical/references/unxlngi/singletest/eis-test.odt.pdf
new file mode 100644
index 000000000000..cf48e3d3df14
--- /dev/null
+++ b/testgraphical/references/unxlngi/singletest/eis-test.odt.pdf
Binary files differ
diff --git a/testgraphical/references/unxlngi/singletest/eis-test.odt.ps b/testgraphical/references/unxlngi/singletest/eis-test.odt.ps
new file mode 100644
index 000000000000..456905de90b2
--- /dev/null
+++ b/testgraphical/references/unxlngi/singletest/eis-test.odt.ps
@@ -0,0 +1,565 @@
+%!PS-Adobe-3.0
+%%BoundingBox: (atend)
+%%Creator: (StarOffice 9)
+%%For: (ll93751)
+%%CreationDate: (Fri Mar 5 11:50:06 2010)
+%%Title: (eis-test)
+%%LanguageLevel: 2
+%%DocumentData: Clean7Bit
+%%Pages: (atend)
+%%Orientation: (atend)
+%%PageOrder: Ascend
+%%EndComments
+%%BeginProlog
+%%BeginResource: procset PSPrint-Prolog 1.0 0
+/ISO1252Encoding [
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/space /exclam /quotedbl /numbersign /dollar /percent /ampersand /quotesingle
+/parenleft /parenright /asterisk /plus /comma /hyphen /period /slash
+/zero /one /two /three /four /five /six /seven
+/eight /nine /colon /semicolon /less /equal /greater /question
+/at /A /B /C /D /E /F /G
+/H /I /J /K /L /M /N /O
+/P /Q /R /S /T /U /V /W
+/X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore
+/grave /a /b /c /d /e /f /g
+/h /i /j /k /l /m /n /o
+/p /q /r /s /t /u /v /w
+/x /y /z /braceleft /bar /braceright /asciitilde /unused
+/Euro /unused /quotesinglbase /florin /quotedblbase /ellipsis /dagger /daggerdbl
+/circumflex /perthousand /Scaron /guilsinglleft /OE /unused /Zcaron /unused
+/unused /quoteleft /quoteright /quotedblleft /quotedblright /bullet /endash /emdash
+/tilde /trademark /scaron /guilsinglright /oe /unused /zcaron /Ydieresis
+/space /exclamdown /cent /sterling /currency /yen /brokenbar /section
+/dieresis /copyright /ordfeminine /guillemotleft /logicalnot /hyphen /registered /macron
+/degree /plusminus /twosuperior /threesuperior /acute /mu /paragraph /periodcentered
+/cedilla /onesuperior /ordmasculine /guillemotright /onequarter /onehalf /threequarters /questiondown
+/Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla
+/Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis
+/Eth /Ntilde /Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply
+/Oslash /Ugrave /Uacute /Ucircumflex /Udieresis /Yacute /Thorn /germandbls
+/agrave /aacute /acircumflex /atilde /adieresis /aring /ae /ccedilla
+/egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis
+/eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide
+/oslash /ugrave /uacute /ucircumflex /udieresis /yacute /thorn /ydieresis] def
+
+/psp_definefont { exch dup findfont dup length dict begin { 1 index /FID ne
+{ def } { pop pop } ifelse } forall /Encoding 3 -1 roll def
+currentdict end exch pop definefont pop } def
+
+/pathdict dup 8 dict def load begin
+/rcmd { { currentfile 1 string readstring pop 0 get dup 32 gt { exit }
+{ pop } ifelse } loop dup 126 eq { pop exit } if 65 sub dup 16#3 and 1
+add exch dup 16#C and -2 bitshift 16#3 and 1 add exch 16#10 and 16#10
+eq 3 1 roll exch } def
+/rhex { dup 1 sub exch currentfile exch string readhexstring pop dup 0
+get dup 16#80 and 16#80 eq dup 3 1 roll { 16#7f and } if 2 index 0 3
+-1 roll put 3 1 roll 0 0 1 5 -1 roll { 2 index exch get add 256 mul }
+for 256 div exch pop exch { neg } if } def
+/xcmd { rcmd exch rhex exch rhex exch 5 -1 roll add exch 4 -1 roll add
+1 index 1 index 5 -1 roll { moveto } { lineto } ifelse } def end
+/readpath { 0 0 pathdict begin { xcmd } loop end pop pop } def
+
+systemdict /languagelevel known not {
+/xshow { exch dup length 0 1 3 -1 roll 1 sub { dup 3 index exch get
+exch 2 index exch get 1 string dup 0 4 -1 roll put currentpoint 3 -1
+roll show moveto 0 rmoveto } for pop pop } def
+/rectangle { 4 -2 roll moveto 1 index 0 rlineto 0 exch rlineto neg 0
+rlineto closepath } def
+/rectfill { rectangle fill } def
+/rectstroke { rectangle stroke } def } if
+/bshow { currentlinewidth 3 1 roll currentpoint 3 index show moveto
+setlinewidth false charpath stroke setlinewidth } def
+/bxshow { currentlinewidth 4 1 roll setlinewidth exch dup length 1 sub
+0 1 3 -1 roll { 1 string 2 index 2 index get 1 index exch 0 exch put dup
+currentpoint 3 -1 roll show moveto currentpoint 3 -1 roll false charpath
+stroke moveto 2 index exch get 0 rmoveto } for pop pop setlinewidth } def
+
+/psp_lzwfilter { currentfile /ASCII85Decode filter /LZWDecode filter } def
+/psp_ascii85filter { currentfile /ASCII85Decode filter } def
+/psp_lzwstring { psp_lzwfilter 1024 string readstring } def
+/psp_ascii85string { psp_ascii85filter 1024 string readstring } def
+/psp_imagedict {
+/psp_bitspercomponent { 3 eq { 1 }{ 8 } ifelse } def
+/psp_decodearray { [ [0 1 0 1 0 1] [0 255] [0 1] [0 255] ] exch get }
+def 7 dict dup
+/ImageType 1 put dup
+/Width 7 -1 roll put dup
+/Height 5 index put dup
+/BitsPerComponent 4 index psp_bitspercomponent put dup
+/Decode 5 -1 roll psp_decodearray put dup
+/ImageMatrix [1 0 0 1 0 0] dup 5 8 -1 roll put put dup
+/DataSource 4 -1 roll 1 eq { psp_lzwfilter } { psp_ascii85filter } ifelse put
+} def
+%%EndResource
+%%EndProlog
+%%BeginSetup
+%
+%%BeginResource: font TimesNewRomanPSMTFID26HGSet1
+%!PS-AdobeFont-1.0-2.53740
+% Creator: SunTypeTools-TT 1.0 gelf
+% Original font name: TimesNewRomanPSMT
+30 dict begin
+/PaintType 0 def
+/FontType 3 def
+/StrokeWidth 0 def
+/FontName (TimesNewRomanPSMTFID26HGSet1) cvn def
+/XUID [103 0 0 16#2F10B8E9 9 16#7048BAB3 16#9CA4D966] def
+/FontMatrix [.001 0 0 .001 0 0] def
+/FontBBox [-568 -306 2028 1006] def
+/Encoding 256 array def
+ 0 1 255 {Encoding exch /.notdef put} for
+ Encoding 0 /glyph0 put
+ Encoding 45 /glyph1 put
+ Encoding 69 /glyph2 put
+ Encoding 73 /glyph3 put
+ Encoding 83 /glyph4 put
+ Encoding 84 /glyph5 put
+ Encoding 101 /glyph6 put
+ Encoding 115 /glyph7 put
+ Encoding 116 /glyph8 put
+/CharProcs 10 dict def
+ CharProcs begin
+ /.notdef {} def
+ /glyph0 {
+ 777 0 125 0 625 625 setcachedevice
+ 125 0 moveto
+ 125 625 lineto
+ 625 625 lineto
+ 625 0 lineto
+ 125 0 lineto
+ closepath
+ 140 15 moveto
+ 609 15 lineto
+ 609 609 lineto
+ 140 609 lineto
+ 140 15 lineto
+ closepath
+ fill
+ } bind def
+ /glyph1 {
+ 333 0 40 187 292 261 setcachedevice
+ 40 261 moveto
+ 292 261 lineto
+ 292 187 lineto
+ 40 187 lineto
+ 40 261 lineto
+ closepath
+ fill
+ } bind def
+ /glyph2 {
+ 610 0 20 0 587 662 setcachedevice
+ 208 625 moveto
+ 208 364 lineto
+ 354 364 lineto
+ 392 364 417 370 430 381 curveto
+ 447 396 456 422 458 460 curveto
+ 476 460 lineto
+ 476 229 lineto
+ 458 229 lineto
+ 454 262 449 282 444 291 curveto
+ 439 303 429 312 416 318 curveto
+ 402 325 382 328 354 328 curveto
+ 208 328 lineto
+ 208 110 lineto
+ 208 81 210 63 212 57 curveto
+ 215 50 220 45 226 41 curveto
+ 232 38 245 36 263 36 curveto
+ 375 36 lineto
+ 413 36 440 38 457 43 curveto
+ 474 49 490 59 506 74 curveto
+ 526 94 547 125 568 166 curveto
+ 587 166 lineto
+ 530 0 lineto
+ 20 0 lineto
+ 20 18 lineto
+ 43 18 lineto
+ 59 18 74 21 88 29 curveto
+ 98 34 105 42 109 52 curveto
+ 113 62 115 84 115 116 curveto
+ 115 546 lineto
+ 115 588 111 614 102 624 curveto
+ 91 637 71 644 43 644 curveto
+ 20 644 lineto
+ 20 662 lineto
+ 530 662 lineto
+ 538 517 lineto
+ 519 517 lineto
+ 512 551 504 575 496 588 curveto
+ 488 602 476 611 459 618 curveto
+ 446 623 423 625 390 625 curveto
+ 208 625 lineto
+ closepath
+ fill
+ } bind def
+ /glyph3 {
+ 333 0 24 0 308 662 setcachedevice
+ 308 18 moveto
+ 308 0 lineto
+ 24 0 lineto
+ 24 18 lineto
+ 48 18 lineto
+ 75 18 95 25 107 41 curveto
+ 115 52 119 77 119 117 curveto
+ 119 544 lineto
+ 119 578 117 600 113 611 curveto
+ 110 619 103 626 93 632 curveto
+ 79 640 64 644 48 644 curveto
+ 24 644 lineto
+ 24 662 lineto
+ 308 662 lineto
+ 308 644 lineto
+ 284 644 lineto
+ 257 644 238 636 225 620 curveto
+ 217 609 213 584 213 544 curveto
+ 213 117 lineto
+ 213 83 215 62 219 50 curveto
+ 223 42 229 36 240 29 curveto
+ 254 22 269 18 284 18 curveto
+ 308 18 lineto
+ closepath
+ fill
+ } bind def
+ /glyph4 {
+ 556 0 62 -15 502 677 setcachedevice
+ 458 677 moveto
+ 458 448 lineto
+ 440 448 lineto
+ 435 492 424 527 409 553 curveto
+ 394 579 372 600 344 615 curveto
+ 316 630 287 638 257 638 curveto
+ 223 638 195 628 173 607 curveto
+ 151 586 140 563 140 536 curveto
+ 140 516 146 498 161 481 curveto
+ 181 457 229 424 305 383 curveto
+ 367 351 409 325 432 307 curveto
+ 454 290 472 269 484 244 curveto
+ 496 220 502 195 502 168 curveto
+ 502 119 483 76 444 39 curveto
+ 405 3 355 -15 293 -15 curveto
+ 274 -15 256 -13 239 -10 curveto
+ 229 -9 208 -2 177 7 curveto
+ 145 17 125 22 116 22 curveto
+ 108 22 102 20 97 15 curveto
+ 93 10 89 0 86 -15 curveto
+ 68 -15 lineto
+ 68 211 lineto
+ 86 211 lineto
+ 95 164 106 129 121 105 curveto
+ 135 82 157 62 187 46 curveto
+ 216 31 248 22 283 22 curveto
+ 324 22 356 33 380 55 curveto
+ 403 76 415 102 415 131 curveto
+ 415 147 411 164 402 180 curveto
+ 393 197 379 212 360 227 curveto
+ 348 236 313 257 256 289 curveto
+ 200 321 159 346 135 365 curveto
+ 111 384 93 404 81 427 curveto
+ 68 450 62 475 62 502 curveto
+ 62 550 80 591 117 625 curveto
+ 153 660 200 677 256 677 curveto
+ 291 677 328 668 368 651 curveto
+ 386 643 399 639 406 639 curveto
+ 415 639 422 641 427 646 curveto
+ 433 651 437 662 440 677 curveto
+ 458 677 lineto
+ closepath
+ fill
+ } bind def
+ /glyph5 {
+ 610 0 30 0 585 662 setcachedevice
+ 578 662 moveto
+ 585 506 lineto
+ 567 506 lineto
+ 563 534 559 553 552 565 curveto
+ 542 584 529 598 512 607 curveto
+ 496 616 474 620 446 620 curveto
+ 353 620 lineto
+ 353 114 lineto
+ 353 74 357 48 366 38 curveto
+ 378 25 397 18 423 18 curveto
+ 446 18 lineto
+ 446 0 lineto
+ 165 0 lineto
+ 165 18 lineto
+ 188 18 lineto
+ 216 18 236 26 248 43 curveto
+ 255 53 259 77 259 114 curveto
+ 259 620 lineto
+ 179 620 lineto
+ 148 620 126 618 113 613 curveto
+ 97 607 82 596 70 578 curveto
+ 58 561 51 537 48 506 curveto
+ 30 506 lineto
+ 38 662 lineto
+ 578 662 lineto
+ closepath
+ fill
+ } bind def
+ /glyph6 {
+ 443 0 37 -13 415 460 setcachedevice
+ 106 278 moveto
+ 106 212 122 160 154 122 curveto
+ 187 84 225 65 269 65 curveto
+ 298 65 324 74 346 90 curveto
+ 367 106 385 133 400 172 curveto
+ 415 163 lineto
+ 409 118 389 78 355 41 curveto
+ 323 4 282 -13 232 -13 curveto
+ 179 -13 133 7 94 49 curveto
+ 56 90 37 146 37 217 curveto
+ 37 294 56 354 96 396 curveto
+ 135 439 184 460 243 460 curveto
+ 293 460 334 444 367 411 curveto
+ 399 378 415 334 415 278 curveto
+ 106 278 lineto
+ closepath
+ 106 307 moveto
+ 313 307 lineto
+ 312 335 308 355 303 367 curveto
+ 295 385 283 400 267 410 curveto
+ 250 420 234 426 216 426 curveto
+ 189 426 165 416 144 395 curveto
+ 123 374 110 344 106 307 curveto
+ closepath
+ fill
+ } bind def
+ /glyph7 {
+ 389 0 48 -13 354 460 setcachedevice
+ 320 460 moveto
+ 320 308 lineto
+ 304 308 lineto
+ 291 355 276 388 256 405 curveto
+ 237 422 212 431 182 431 curveto
+ 160 431 141 425 127 413 curveto
+ 113 401 106 388 106 373 curveto
+ 106 355 111 339 122 326 curveto
+ 132 313 152 299 183 284 curveto
+ 254 249 lineto
+ 320 217 354 175 354 122 curveto
+ 354 81 338 48 308 23 curveto
+ 277 0 243 -13 204 -13 curveto
+ 177 -13 146 -8 110 0 curveto
+ 100 4 91 5 84 5 curveto
+ 77 5 71 1 66 -6 curveto
+ 50 -6 lineto
+ 50 152 lineto
+ 66 152 lineto
+ 76 107 93 73 119 49 curveto
+ 145 26 173 15 205 15 curveto
+ 228 15 246 21 260 35 curveto
+ 274 48 281 63 281 82 curveto
+ 281 104 274 124 258 139 curveto
+ 242 154 210 173 163 197 curveto
+ 116 220 85 241 70 260 curveto
+ 56 279 48 302 48 331 curveto
+ 48 367 61 398 86 423 curveto
+ 111 448 144 460 184 460 curveto
+ 202 460 223 457 248 449 curveto
+ 265 444 276 441 281 441 curveto
+ 287 441 291 442 293 445 curveto
+ 296 447 300 452 304 460 curveto
+ 320 460 lineto
+ closepath
+ fill
+ } bind def
+ /glyph8 {
+ 277 0 9 -7 279 594 setcachedevice
+ 161 594 moveto
+ 161 447 lineto
+ 265 447 lineto
+ 265 413 lineto
+ 161 413 lineto
+ 161 123 lineto
+ 161 94 165 74 173 64 curveto
+ 182 54 192 49 205 49 curveto
+ 216 49 226 52 236 59 curveto
+ 247 65 254 75 260 88 curveto
+ 279 88 lineto
+ 268 57 251 33 230 17 curveto
+ 210 0 188 -7 166 -7 curveto
+ 151 -7 137 -2 122 5 curveto
+ 108 13 98 25 90 41 curveto
+ 84 56 80 80 80 112 curveto
+ 80 413 lineto
+ 9 413 lineto
+ 9 429 lineto
+ 27 436 45 448 64 465 curveto
+ 83 482 100 502 114 526 curveto
+ 122 538 132 561 145 594 curveto
+ 161 594 lineto
+ closepath
+ fill
+ } bind def
+ end
+/BuildGlyph {
+ exch /CharProcs get exch
+ 2 copy known not
+ {pop /.notdef} if
+ get exec
+} bind def
+/BuildChar {
+ 1 index /Encoding get exch get
+ 1 index /BuildGlyph get exec
+} bind def
+currentdict end
+(TimesNewRomanPSMTFID26HGSet1) cvn exch definefont pop
+%%EndResource
+%%DocumentSuppliedResources: font TimesNewRomanPSMTFID26HGSet1
+%%EndSetup
+%%Page: 1 1
+%%PageOrientation: Portrait
+%%PageBoundingBox: 18 18 577 824
+%%BeginPageSetup
+%
+[{
+%%BeginFeature: *PageSize A4
+<</PageSize [595 842] /ImagingBBox null>> setpagedevice
+%%EndFeature
+} stopped cleartomark
+%%EndPageSetup
+gsave
+[0.24 0 0 -0.24 18 824] concat
+gsave
+1122 184 moveto
+0 0 0 setrgbcolor
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 25 -25 matrix scale makefont setfont
+<4549532D54657374>
+[15 8 14 9 15 11 10 0]
+xshow
+1114 215 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 29 -29 matrix scale makefont setfont
+<4549532D54657374>
+[17 10 16 10 18 13 11 0]
+xshow
+1107 251 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 33 -33 matrix scale makefont setfont
+<4549532D54657374>
+[20 11 19 11 20 15 13 0]
+xshow
+1100 291 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 38 -38 matrix scale makefont setfont
+<4549532D54657374>
+[23 13 20 13 22 17 15 0]
+xshow
+1092 337 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 42 -42 matrix scale makefont setfont
+<4549532D54657374>
+[26 14 23 14 25 19 16 0]
+xshow
+1088 385 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 44 -44 matrix scale makefont setfont
+<4549532D54657374>
+[27 14 24 15 27 19 17 0]
+xshow
+1085 435 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 46 -46 matrix scale makefont setfont
+<4549532D54657374>
+[28 15 26 15 28 20 18 0]
+xshow
+1077 490 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 50 -50 matrix scale makefont setfont
+<4549532D54657374>
+[30 17 28 16 31 22 19 0]
+xshow
+1070 549 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 54 -54 matrix scale makefont setfont
+<4549532D54657374>
+[33 18 30 19 33 24 21 0]
+xshow
+1063 613 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 58 -58 matrix scale makefont setfont
+<4549532D54657374>
+[35 19 33 20 35 26 23 0]
+xshow
+1055 681 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 63 -63 matrix scale makefont setfont
+<4549532D54657374>
+[37 21 35 21 38 28 24 0]
+xshow
+1048 754 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 67 -67 matrix scale makefont setfont
+<4549532D54657374>
+[41 22 37 22 41 30 26 0]
+xshow
+1033 835 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 75 -75 matrix scale makefont setfont
+<4549532D54657374>
+[46 25 42 25 46 33 29 0]
+xshow
+1018 926 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 83 -83 matrix scale makefont setfont
+<4549532D54657374>
+[51 28 46 28 51 37 32 0]
+xshow
+1003 1025 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 92 -92 matrix scale makefont setfont
+<4549532D54657374>
+[56 30 51 31 56 40 36 0]
+xshow
+1003 1127 moveto
+<4549532D54657374>
+[56 30 51 31 56 40 36 0]
+xshow
+989 1236 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 100 -100 matrix scale makefont setfont
+<4549532D54657374>
+[61 33 56 33 61 44 39 0]
+xshow
+974 1354 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 108 -108 matrix scale makefont setfont
+<4549532D54657374>
+[66 36 60 36 66 49 41 0]
+xshow
+959 1481 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 117 -117 matrix scale makefont setfont
+<4549532D54657374>
+[71 39 65 39 71 52 45 0]
+xshow
+929 1625 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 133 -133 matrix scale makefont setfont
+<4549532D54657374>
+[81 44 74 45 81 59 52 0]
+xshow
+900 1788 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 150 -150 matrix scale makefont setfont
+<4549532D54657374>
+[92 50 83 50 92 66 58 0]
+xshow
+870 1969 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 167 -167 matrix scale makefont setfont
+<4549532D54657374>
+[102 56 93 55 102 73 65 0]
+xshow
+840 2168 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 183 -183 matrix scale makefont setfont
+<4549532D54657374>
+[112 61 102 61 112 81 71 0]
+xshow
+811 2386 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 200 -200 matrix scale makefont setfont
+<4549532D54657374>
+[122 67 111 67 122 88 78 0]
+xshow
+766 2630 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 225 -225 matrix scale makefont setfont
+<4549532D54657374>
+[137 75 125 75 137 100 88 0]
+xshow
+722 2901 moveto
+(TimesNewRomanPSMTFID26HGSet1) cvn findfont 250 -250 matrix scale makefont setfont
+<4549532D54657374>
+[153 83 139 84 152 112 96 0]
+xshow
+grestore grestore
+showpage
+%%PageTrailer
+
+%%Trailer
+%%BoundingBox: 0 0 595 842
+%%Orientation: Portrait
+%%Pages: 1
+%%EOF
diff --git a/testgraphical/references/unxlngi/singletest/tolerance.ini_ b/testgraphical/references/unxlngi/singletest/tolerance.ini_
new file mode 100644
index 000000000000..ba027e21452a
--- /dev/null
+++ b/testgraphical/references/unxlngi/singletest/tolerance.ini_
@@ -0,0 +1,4 @@
+# This is the tolerance we will accept if there are problems
+# [eis-test.odt.ps]
+# accept=111
+# page1=111
diff --git a/testgraphical/references/unxsoli/singletest/eis-test.odt.pdf b/testgraphical/references/unxsoli/singletest/eis-test.odt.pdf
new file mode 100644
index 000000000000..96c922f4aa63
--- /dev/null
+++ b/testgraphical/references/unxsoli/singletest/eis-test.odt.pdf
Binary files differ
diff --git a/testgraphical/references/wntmsci/demo/CurrentTime.ods.pdf b/testgraphical/references/wntmsci/demo/CurrentTime.ods.pdf
new file mode 100644
index 000000000000..a753c03708c7
--- /dev/null
+++ b/testgraphical/references/wntmsci/demo/CurrentTime.ods.pdf
Binary files differ
diff --git a/testgraphical/references/wntmsci/demo/CurrentTime.ods.ps b/testgraphical/references/wntmsci/demo/CurrentTime.ods.ps
new file mode 100644
index 000000000000..36b469ce81a3
--- /dev/null
+++ b/testgraphical/references/wntmsci/demo/CurrentTime.ods.ps
@@ -0,0 +1,499 @@
+%!PS-Adobe-3.0
+%%Title: CurrentTime
+%%Creator: PScript5.dll Version 5.2.2
+%%CreationDate: 5/17/2010 15:0:3
+%%For: ll93751
+%%BoundingBox: (atend)
+%%Pages: (atend)
+%%Orientation: Portrait
+%%PageOrder: Special
+%%DocumentNeededResources: (atend)
+%%DocumentSuppliedResources: (atend)
+%%DocumentData: Clean7Bit
+%%TargetDevice: (Generic Printer For MSWord Testing) (1) 1
+%%LanguageLevel: 2
+%%EndComments
+
+%%BeginDefaults
+%%PageBoundingBox: 18 18 577 824
+%%ViewingOrientation: 1 0 0 1
+%%EndDefaults
+
+
+%%BeginProlog
+%%BeginResource: file Pscript_WinNT_ErrorHandler 5.0 0
+/currentpacking where{pop/oldpack currentpacking def/setpacking where{pop false
+setpacking}if}if/$brkpage 64 dict def $brkpage begin/prnt{dup type/stringtype
+ne{=string cvs}if dup length 6 mul/tx exch def/ty 10 def currentpoint/toy exch
+def/tox exch def 1 setgray newpath tox toy 2 sub moveto 0 ty rlineto tx 0
+rlineto 0 ty neg rlineto closepath fill tox toy moveto 0 setgray show}bind def
+/nl{currentpoint exch pop lmargin exch moveto 0 -10 rmoveto}def/=={/cp 0 def
+typeprint nl}def/typeprint{dup type exec}readonly def/lmargin 72 def/rmargin 72
+def/tprint{dup length cp add rmargin gt{nl/cp 0 def}if dup length cp add/cp
+exch def prnt}readonly def/cvsprint{=string cvs tprint( )tprint}readonly def
+/integertype{cvsprint}readonly def/realtype{cvsprint}readonly def/booleantype
+{cvsprint}readonly def/operatortype{(--)tprint =string cvs tprint(-- )tprint}
+readonly def/marktype{pop(-mark- )tprint}readonly def/dicttype{pop
+(-dictionary- )tprint}readonly def/nulltype{pop(-null- )tprint}readonly def
+/filetype{pop(-filestream- )tprint}readonly def/savetype{pop(-savelevel- )
+tprint}readonly def/fonttype{pop(-fontid- )tprint}readonly def/nametype{dup
+xcheck not{(/)tprint}if cvsprint}readonly def/stringtype{dup rcheck{(\()tprint
+tprint(\))tprint}{pop(-string- )tprint}ifelse}readonly def/arraytype{dup rcheck
+{dup xcheck{({)tprint{typeprint}forall(})tprint}{([)tprint{typeprint}forall(])
+tprint}ifelse}{pop(-array- )tprint}ifelse}readonly def/packedarraytype{dup
+rcheck{dup xcheck{({)tprint{typeprint}forall(})tprint}{([)tprint{typeprint}
+forall(])tprint}ifelse}{pop(-packedarray- )tprint}ifelse}readonly def/courier
+/Courier findfont 10 scalefont def end errordict/handleerror{systemdict begin
+$error begin $brkpage begin newerror{/newerror false store vmstatus pop pop 0
+ne{grestoreall}if errorname(VMerror)ne{showpage}if initgraphics courier setfont
+lmargin 720 moveto errorname(VMerror)eq{userdict/ehsave known{clear userdict
+/ehsave get restore 2 vmreclaim}if vmstatus exch pop exch pop PrtVMMsg}{
+(ERROR: )prnt errorname prnt nl(OFFENDING COMMAND: )prnt/command load prnt
+$error/ostack known{nl nl(STACK:)prnt nl nl $error/ostack get aload length{==}
+repeat}if}ifelse systemdict/showpage get exec(%%[ Error: )print errorname
+=print(; OffendingCommand: )print/command load =print( ]%%)= flush}if end end
+end}dup 0 systemdict put dup 4 $brkpage put bind readonly put/currentpacking
+where{pop/setpacking where{pop oldpack setpacking}if}if
+%%EndResource
+userdict /Pscript_WinNT_Incr 230 dict dup begin put
+%%BeginResource: file Pscript_FatalError 5.0 0
+userdict begin/FatalErrorIf{{initgraphics findfont 1 index 0 eq{exch pop}{dup
+length dict begin{1 index/FID ne{def}{pop pop}ifelse}forall/Encoding
+{ISOLatin1Encoding}stopped{StandardEncoding}if def currentdict end
+/ErrFont-Latin1 exch definefont}ifelse exch scalefont setfont counttomark 3 div
+cvi{moveto show}repeat showpage quit}{cleartomark}ifelse}bind def end
+%%EndResource
+userdict begin/PrtVMMsg{vmstatus exch sub exch pop gt{[
+(Dieser Druckauftrag erfordert mehr Speicher, als auf diesem Drucker vorhanden ist. )
+100 500
+(Versuchen Sie es mit einer oder mehreren der folgenden Methoden und drucken Sie dann erneut:)
+100 485(Wählen Sie für das Ausgabeformat die Option "Optimale Portierung".)115
+470
+(Stellen Sie sicher, daß auf der Registerkarte "Geräteeinstellungen" die Angabe für "Verfügbarer Postscript-Speicher" korrekt ist.)
+115 455(Reduzieren Sie die Anzahl der im Dokument verwendeten Schriftarten. )
+115 440(Drucken Sie das Dokument in verschiedenen Teilstücken. )115 425 12
+/Times-Roman showpage(%%[ PrinterError: Low Printer VM ]%%)= true FatalErrorIf}
+if}bind def end version cvi 2016 ge{/VM?{pop}bind def}{/VM? userdict/PrtVMMsg
+get def}ifelse
+105000 VM?
+%%BeginResource: file Pscript_Win_Basic 5.0 0
+/d/def load def/,/load load d/~/exch , d/?/ifelse , d/!/pop , d/`/begin , d/^
+/index , d/@/dup , d/+/translate , d/$/roll , d/U/userdict , d/M/moveto , d/-
+/rlineto , d/&/currentdict , d/:/gsave , d/;/grestore , d/F/false , d/T/true ,
+d/N/newpath , d/E/end , d/Ac/arc , d/An/arcn , d/A/ashow , d/D/awidthshow , d/C
+/closepath , d/V/div , d/O/eofill , d/L/fill , d/I/lineto , d/-c/curveto , d/-M
+/rmoveto , d/+S/scale , d/Ji/setfont , d/Lc/setlinecap , d/Lj/setlinejoin , d
+/Lw/setlinewidth , d/Lm/setmiterlimit , d/sd/setdash , d/S/show , d/LH/showpage
+, d/K/stroke , d/W/widthshow , d/R/rotate , d/L2? false/languagelevel where{pop
+languagelevel 2 ge{pop true}if}if d L2?{/xS/xshow , d/yS/yshow , d/zS/xyshow ,
+d}if/b{bind d}bind d/bd{bind d}bind d/xd{~ d}bd/ld{, d}bd/bn/bind ld/lw/Lw ld
+/lc/Lc ld/lj/Lj ld/sg/setgray ld/ADO_mxRot null d/self & d/OrgMx matrix
+currentmatrix d/reinitialize{: OrgMx setmatrix[/TextInit/GraphInit/UtilsInit
+counttomark{@ where{self eq}{F}?{cvx exec}{!}?}repeat cleartomark ;}b
+/initialize{`{/Pscript_Win_Data where{!}{U/Pscript_Win_Data & put}?/ADO_mxRot ~
+d/TextInitialised? F d reinitialize E}{U/Pscript_Win_Data 230 dict @ ` put
+/ADO_mxRot ~ d/TextInitialised? F d reinitialize}?}b/terminate{!{& self eq
+{exit}{E}?}loop E}b/suspend/terminate , d/resume{` Pscript_Win_Data `}b U `
+/lucas 21690 d/featurebegin{countdictstack lucas[}b/featurecleanup{stopped
+{cleartomark @ lucas eq{! exit}if}loop countdictstack ~ sub @ 0 gt{{E}repeat}
+{!}?}b E/snap{transform 0.25 sub round 0.25 add ~ 0.25 sub round 0.25 add ~
+itransform}b/dsnap{dtransform round ~ round ~ idtransform}b/nonzero_round{@ 0.5
+ge{round}{@ -0.5 lt{round}{0 ge{1}{-1}?}?}?}b/nonzero_dsnap{dtransform
+nonzero_round ~ nonzero_round ~ idtransform}b U<04>cvn{}put/rr{1 ^ 0 - 0 ~ -
+neg 0 - C}b/irp{4 -2 $ + +S fx 4 2 $ M 1 ^ 0 - 0 ~ - neg 0 -}b/rp{4 2 $ M 1 ^ 0
+- 0 ~ - neg 0 -}b/solid{[]0 sd}b/g{@ not{U/DefIf_save save put}if U/DefIf_bool
+2 ^ put}b/DefIf_El{if U/DefIf_bool get not @{U/DefIf_save get restore}if}b/e
+{DefIf_El !}b/UDF{L2?{undefinefont}{!}?}b/UDR{L2?{undefineresource}{! !}?}b
+/freeVM{/Courier findfont[40 0 0 -40 0 0]makefont Ji 2 vmreclaim}b/hfRedefFont
+{findfont @ length dict `{1 ^/FID ne{d}{! !}?}forall & E @ ` ~{/CharStrings 1
+dict `/.notdef 0 d & E d}if/Encoding 256 array 0 1 255{1 ^ ~/.notdef put}for d
+E definefont !}bind d/hfMkCIDFont{/CIDFont findresource @ length 2 add dict `{1
+^ @/FID eq ~ @/XUID eq ~/UIDBase eq or or{! !}{d}?}forall/CDevProc ~ d/Metrics2
+16 dict d/CIDFontName 1 ^ d & E 1 ^ ~/CIDFont defineresource ![~]composefont !}
+bind d
+%%EndResource
+%%BeginResource: file Pscript_Win_Utils_L2 5.0 0
+/rf/rectfill , d/fx{1 1 dtransform @ 0 ge{1 sub 0.5}{1 add -0.5}? 3 -1 $ @ 0 ge
+{1 sub 0.5}{1 add -0.5}? 3 1 $ 4 1 $ idtransform 4 -2 $ idtransform}b/BZ{4 -2 $
+snap + +S fx rf}b/rs/rectstroke , d/rc/rectclip , d/UtilsInit{currentglobal{F
+setglobal}if}b/scol{! setcolor}b/colspA/DeviceGray d/colspABC/DeviceRGB d
+/colspRefresh{colspABC setcolorspace}b/SetColSpace{colspABC setcolorspace}b
+/resourcestatus where{!/ColorRendering/ProcSet resourcestatus{! ! T}{F}?}{F}?
+not{/ColorRendering<</GetHalftoneName{currenthalftone @/HalftoneName known{
+/HalftoneName get}{!/none}?}bn/GetPageDeviceName{currentpagedevice @
+/PageDeviceName known{/PageDeviceName get @ null eq{!/none}if}{!/none}?}bn
+/GetSubstituteCRD{!/DefaultColorRendering/ColorRendering resourcestatus{! !
+/DefaultColorRendering}{(DefaultColorRendering*){cvn exit}127 string
+/ColorRendering resourceforall}?}bn>>/defineresource where{!/ProcSet
+defineresource !}{! !}?}if/buildcrdname{/ColorRendering/ProcSet findresource `
+mark GetHalftoneName @ type @/nametype ne ~/stringtype ne and{!/none}if(.)
+GetPageDeviceName @ type @/nametype ne ~/stringtype ne and{!/none}if(.)5 ^ 0 5
+-1 1{^ length add}for string 6 1 $ 5 ^ 5{~ 1 ^ cvs length 1 ^ length 1 ^ sub
+getinterval}repeat ! cvn 3 1 $ ! ! E}b/definecolorrendering{~ buildcrdname ~
+/ColorRendering defineresource !}b/findcolorrendering where{!}{
+/findcolorrendering{buildcrdname @/ColorRendering resourcestatus{! ! T}{
+/ColorRendering/ProcSet findresource ` GetSubstituteCRD E F}?}b}?
+/selectcolorrendering{findcolorrendering !/ColorRendering findresource
+setcolorrendering}b/G2UBegin{findresource/FontInfo get/GlyphNames2Unicode get
+`}bind d/G2CCBegin{findresource/FontInfo get/GlyphNames2HostCode get `}bind d
+/G2UEnd{E}bind d/AddFontInfoBegin{/FontInfo 8 dict @ `}bind d/AddFontInfo{
+/GlyphNames2Unicode 16 dict d/GlyphNames2HostCode 16 dict d}bind d
+/AddFontInfoEnd{E d}bind d/T0AddCFFMtx2{/CIDFont findresource/Metrics2 get ` d
+E}bind d
+%%EndResource
+end
+%%EndProlog
+
+%%BeginSetup
+statusdict begin (%%[ ProductName: ) print product print ( ]%%)= flush end
+[ 1 0 0 1 0 0 ] false Pscript_WinNT_Incr dup /initialize get exec
+featurebegin{
+%%BeginNonPPDFeature: JobTimeout 0
+0 /languagelevel where{pop languagelevel}{1}ifelse 2 ge{1 dict dup/JobTimeout 4 -1 roll put setuserparams}{statusdict/setjobtimeout get exec}ifelse
+%%EndNonPPDFeature
+}featurecleanup
+
+featurebegin{
+%%BeginNonPPDFeature: WaitTimeout 300
+300 /languagelevel where{pop languagelevel}{1}ifelse 2 ge{1 dict dup/WaitTimeout 4 -1 roll put setuserparams}{statusdict/waittimeout 3 -1 roll put}ifelse
+%%EndNonPPDFeature
+}featurecleanup
+
+featurebegin{
+%%BeginFeature: *InputSlot ManualFeed
+
+<< /ManualFeed true /Policies << /ManualFeed 1 >> >> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *Duplex None
+
+<</Duplex false /Tumble false
+ /Policies << /Duplex 1 /Tumble 1 >>
+>> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *PageRegion A4
+<</PageSize [595 842] /ImagingBBox null>> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *Resolution 1200x1200dpi
+
+ 1 dict dup /HWResolution [1200 1200] put setpagedevice
+%%EndFeature
+}featurecleanup
+1 setlinecap 1 setlinejoin
+/mysetup [ 72 1200 V 0 0 -72 1200 V 18 824.0003 ] def
+%%EndSetup
+
+userdict begin /ehsave save def end
+%%Page: 1 1
+%%PageBoundingBox: 18 18 577 824
+%%EndPageComments
+%%BeginPageSetup
+/DeviceRGB dup setcolorspace /colspABC exch def
+mysetup concat colspRefresh
+%%EndPageSetup
+
+0 0 0 1 scol 22500 VM?
+11 dict begin
+/FontName /TTEC2o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1ae15c03974a1a9b3c172d5d01da698bb3e9bd8fb187
+15ad84bc85cd145093e29e1b226d167407e1f00a6529c34100fe35097c0d
+b5af1eda9d93c4fbe9bd86433be0237415462af5d09911e8c9f42535e5d2
+2dd429d16a06629077406afc7b7c534dc9e9e045cc02be968fa94e480676
+cb53f625f5f575a27ab6d08d5c839bcfee5628e5ccd4d4605b7fec3a76bb
+28738163f3b82fd887dfecdc22fecb045a567be6d3b5a147b633e25bed18
+40c3e8e2f2258801243cf18236f06a8992b5a43fdca766d185ec61f2b174
+d769605817b24a47643e089d8814e415ab639130ea66e36890bd761d0a8f
+5d374c4904ff82dfe0f21c18dee922bc8376caeba56e25b6c9ddbd670491
+72036f023f43bf7830df38d0c36ef5d7184a77d3822cb988db6213ddd19d
+879129e1b8f3a8dafd1d138bec6d1ded9fbbb5b4294072df1f12a135929c
+9a45aea5ebc051f8d6514ccf32b2acbd84dfcbcce5469c945c93be1929e7
+f9fca6965e31a4328311b483ac44acb3daed602b089ab4fe0f74705bb07b
+21067988ba7246b0dd96c23046cbbc2414fdb62ca2e102c041d24e977418
+1bd25e1bd6f500cad2b24572a49f549bf2e59a693759d0acb7c42c2caaa6
+f940204c5d06b53cc4847dac692da2e938bf86283692a51a631279087ecd
+19b56062b53f44ca8d3025a1c25c7aed9b406e9d9fed5a13ff540359abc6
+0a0a444273d3bf793cb00c3158c1050a0a026d200bf4d34f0237233c5b80
+ee79e7cad72f335228314e3461cd05ef2f3826bc1c5c43a92b0551e00b19
+ebeea73ef66820f36ee61ad9be6012c65138a13ef4cd7745cb966af72d76
+d42781dc5aaf5f69753ae6bd324bf42ec9cee010ff5f487dfaf1eea51f2f
+43488c9a9115ceda9b959465b3ae6f1e94ede9ce7867344484db692e5423
+962fa13ffb0073691e3a193f217e588ec12fcad5e3c7a2da41073813b4e4
+99a784d26534294d71d117a87c98a814df39bf6fc01fac1bf8f73960775b
+0a4ed51d90d942c14585b424223f30c4f93ee07bd3c05dd7f36271b10cc0
+914af6e94e4451befc31d1557802dad903b71eb5189c18fadd8ba9ce4ff0
+c2d750518bfca7c652b5c5d314a35fefb8e62e62632d0168c97718779689
+97abcc8e922914102cc46e07874511d23c143f7c2440a81b012532995272
+f01ae7b4d8f66ffac047ba7ddcf4b156ce29e19491ceb0af30494c5755e6
+16eb123ec1f237fa5d36c4a03de9e90000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTEC2o00 findfont /Encoding get
+dup 1 /S put
+dup 2 /h put
+dup 3 /e put
+dup 4 /t put
+dup 5 /one put
+pop
+Pscript_WinNT_Incr begin
+%%BeginResource: file Pscript_Text 5.0 0
+/TextInit{TextInitialised? not{/Pscript_Windows_Font & d/TextInitialised? T d
+/fM[1 0 0 1 0 0]d/mFM matrix d/iMat[1 0 0.212557 1 0 0]d}if}b/copyfont{1 ^
+length add dict `{1 ^/FID ne{d}{! !}?}forall & E}b/EncodeDict 11 dict d/bullets
+{{/bullet}repeat}b/rF{3 copyfont @ ` ~ EncodeDict ~ get/Encoding ~ 3 ^/0 eq{&
+/CharStrings known{CharStrings/Eth known not{! EncodeDict/ANSIEncodingOld get}
+if}if}if d E}b/mF{@ 7 1 $ findfont ~{@/Encoding get @ StandardEncoding eq{! T}{
+{ISOLatin1Encoding}stopped{! F}{eq}?{T}{@ ` T 32 1 127{Encoding 1 ^ get
+StandardEncoding 3 -1 $ get eq and}for E}?}?}{F}?{1 ^ ~ rF}{0 copyfont}? 6 -2 $
+! ! ~ !/pd_charset @ where{~ get 128 eq{@ FDV 2 copy get @ length array copy
+put pd_CoverFCRange}if}{!}? 2 ^ ~ definefont fM 5 4 -1 $ put fM 4 0 put fM
+makefont Pscript_Windows_Font 3 1 $ put}b/sLT{: Lw -M currentpoint snap M 0 - 0
+Lc K ;}b/xUP null d/yUP null d/uW null d/xSP null d/ySP null d/sW null d/sSU{N
+/uW ~ d/yUP ~ d/xUP ~ d}b/sU{xUP yUP uW sLT}b/sST{N/sW ~ d/ySP ~ d/xSP ~ d}b/sT
+{xSP ySP sW sLT}b/sR{: + R 0 0 M}b/sRxy{: matrix astore concat 0 0 M}b/eR/; , d
+/AddOrigFP{{&/FontInfo known{&/FontInfo get length 6 add}{6}? dict `
+/WinPitchAndFamily ~ d/WinCharSet ~ d/OrigFontType ~ d/OrigFontStyle ~ d
+/OrigFontName ~ d & E/FontInfo ~ d}{! ! ! ! !}?}b/mFS{makefont
+Pscript_Windows_Font 3 1 $ put}b/mF42D{0 copyfont `/FontName ~ d 2 copy ~ sub 1
+add dict `/.notdef 0 d 2 copy 1 ~{@ 3 ^ sub Encoding ~ get ~ d}for & E
+/CharStrings ~ d ! ! & @ E/FontName get ~ definefont}b/mF42{15 dict ` @ 4 1 $
+FontName ~ d/FontType 0 d/FMapType 2 d/FontMatrix[1 0 0 1 0 0]d 1 ^ 254 add 255
+idiv @ array/Encoding ~ d 0 1 3 -1 $ 1 sub{@ Encoding 3 1 $ put}for/FDepVector
+Encoding length array d/CharStrings 2 dict `/.notdef 0 d & E d 0 1 Encoding
+length 1 sub{@ @ 10 lt{! FontName length 1 add string}{100 lt{FontName length 2
+add string}{FontName length 3 add string}?}? @ 0 FontName @ length string cvs
+putinterval @ 3 -1 $ @ 4 1 $ 3 string cvs FontName length ~ putinterval cvn 1 ^
+256 mul @ 255 add 3 -1 $ 4 ^ findfont mF42D FDepVector 3 1 $ put}for & @ E
+/FontName get ~ definefont ! ! ! mF}b/mF_OTF_V{~ ! ~ ! 4 -1 $ ! findfont 2 ^ ~
+definefont fM @ @ 4 6 -1 $ neg put 5 0 put 90 matrix R matrix concatmatrix
+makefont Pscript_Windows_Font 3 1 $ put}b/mF_TTF_V{3{~ !}repeat 3 -1 $ !
+findfont 1 ^ ~ definefont Pscript_Windows_Font 3 1 $ put}b/UmF{L2?
+{Pscript_Windows_Font ~ undef}{!}?}b/UmF42{@ findfont/FDepVector get{/FontName
+get undefinefont}forall undefinefont}b
+%%EndResource
+end reinitialize
+F /F0 0 /0 F /TTEC2o00 mF
+/F0SA7 F0 [167 0 0 -167 0 0 ] mFS
+F0SA7 Ji
+4696 1120 M <010203030405>[111 93 93 93 46 0]xS
+3600 VM?
+
+currentfile eexec
+9e67edc6b841305d5d10e5a53359c38b0291a4f57acae0c56237cee47bc1
+d85570b1414b43fc17ea6b4843d55ac9afa7067f1a7091b4594d913de276
+a8772313a65fcd26ba87b9a05d166b03e17f03277dd8efccb02a7d4c1be6
+177e723f7aa9e190ce43dd1df2bf2988559fa94bfa641911cece0e747ceb
+9b660904152a628a244fd923b311f5c4a5fe7c546e8d37afebee19511e85
+7ff39e7ff6c4792d53badbc7a555b283f38f31e279752d4342dd5f00e99d
+ba2152623e1e346ef7276b3265bc6cc3a37e315df96fd5d085e519b5cf03
+fb27cf9385ba7058ff6c83c880bff9c4fbd2947bdc5c671ae82a44177042
+f439578104f7c75f2ba09f3a578b522774bde2cbc6643d623a5e689df5bd
+359ed5f335c5b979036b99e788351b92cb83205fff7dfc1b4880b7c6f468
+edd5346a15139d558c3bc6afd4767b4d9529a0b1aa4767bc65f3a158d720
+6b2b276cc6eb3b50ea5319f6a5b9f96114b77ee5ff8b0d84786036821196
+10d2ea5e2af2f62d8e94dfa5e9d87f303e6969e9121676a20da78c247202
+97cf246bcdca069951c2ca4294017dbf317ba60a54367a75dcb0c005394f
+2e21d22fc8f1ca437c52566a26569f6f218d87831bbb59f9d7ce80d28c89
+c77c8ae2b608c786ebca7c5c5a7b7ded13c1007bc6484e8151dc558cb6f0
+6056b74666e6cdb8c0ccdc65044d55b68497ebec08ea9f2c661760595438
+8dfea6f0743c11811fd26f2837f954ef0a99db60eb9c3e1b523e0762deec
+c717a44bfc75d4b55b7b8719218283ecd5e23ccbcc9bc1893cd9dda88922
+be1f24e77c46fbafd369868830f7ac384a338b2dde52ac79f83047febbb7
+a1adfd3f3ea13de8dbb63607beec48b0b5957be43431e98c34591c3ce646
+5c30ed78f1a8d521a4349671263c640e277d310adf33cae19cfdc350adff
+14c02e0b73c1a80c0b97e5974cd751a144d34ca579b5cb81d8e0f230dbb8
+2d306f969dbd71108cc52e7338359ca95bc1873c1c91be7b51240fc14001
+98c8f64796e991eea99e27eba7bdac1f2296da2c6db2cdbcc4d7538af40d
+5cd881a349dbc71725ab9bf815736c339b0f5aec8f6c4ca0438ecca51f39
+130895a4e7fd438813034129b8a838589b370000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTEC2o00 findfont /Encoding get
+dup 6 /P put
+dup 7 /a put
+dup 8 /g put
+dup 9 /space put
+pop
+4696 13024 M <0607080309>[111 93 93 93 0]xS
+5132 13024 M <05>S
+19800 VM?
+11 dict begin
+/FontName /TTBC013398o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1add2c77631f898ffcae76502bbe5e22d7ef71c602e1
+9e22c890817f47e70d08803467d31dd4454c7e898bf1e600f73ba7788118
+7a31575a7bde4b80b1052323a8cd8606039f631424bead9a04865f2b6ccd
+563650769cf3b9f4ec66fa0b354b1389beaff83c6934509010d5c85f025f
+31060982b13953fa166bd5a265f4594dd80728aad8dbc710567ddbed093f
+27b08481959f39d5ea87844272e351c3b107807046866c6efdb34ab1a02a
+4560b58fd36e23b92ffe3af9cc87a0bcbebea7877536640c59261a3a850a
+0941a1da1349cafaf520ac0b488e6dd848ded092875c1ddfbb53986369d2
+ea38f05fc71a0f819904a116f9de8d4281e77df87763452fd42258656862
+4ee87f6acc7b7e1de1128cffce1168ba4f0f231290002f98b6bd2bc60a37
+f305d9515113ceba5d077871c967bffa3d810d8b4355895fdb320c155536
+880c517ea5384f01027eae42fb1a1cf3b4105a4bd7287b950000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTBC013398o00 findfont /Encoding get
+dup 1 /one put
+dup 2 /five put
+pop
+F /F1 0 /0 F /TTBC013398o00 mF
+/F1S5BA F1 [1466 0 0 -1466 0 0 ] mFS
+F1S5BA Ji
+1459 3161 M <0102>[815 0]xS
+900 VM?
+
+currentfile eexec
+9e67edc6b841305af19a6e4bb2a230e3e9efc9b96f464cd2cec0584bfa5d
+e6b6c8bf4fb2bca3ff5c4ffdcb930b9549cfaa6d954b63169b356002d4a2
+065b3dad6c77543f2f4c58aba309a5f2e2cec5372d5eb49ba5adffe6ec0d
+ed20ee879de2476ee6f4099e560589a666b9194b6bf7f0128e1a3afd80ec
+9f40a396884744c1962e90eba74a9cd4a32f9fdd0782f0c6b6d12f732bee
+20b6ac0c3bfba90b08742c53ddc1970000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTBC013398o00 findfont /Encoding get
+dup 3 /colon put
+pop
+3123 3161 M <03>S
+900 VM?
+
+currentfile eexec
+9e67edc6b841305af19a6e4bb2a230e3e9efc9b96f464cd2cec0584bfa5d
+e6b6c8bf4fb2bca3ff5c4ffdcb930b9549cfaa6d954b63169b356002d4a2
+065b3dad6c77543f2f4c58abba975b6391782ae96f027086c2b7fc4d3f90
+351b67f8a2fc2116477655cf0dff5a6bf15f1a3d629270d6af26f69b32a3
+312831823f86f43a0ab84649de6044d445b8ed1fbd9a8f026fbac386a0e1
+c5428153a9d4e786021ed524ba1216a3b8ab60edfbf05959d5558b762ca6
+ffa65d882d930f795bc1903885698b5558100097185b7cacdbe4413bc735
+faa8d6a05f03b5bcb23f73372cbb5f7cd01ce3e3bb2e524201be263c6e0c
+f04205a026405c90467d80e06d42e97c1af53a494a1c86c7a93c034ec9a1
+58c34d868fc499aa20961ab79c8fd94237c294a6d7569b8cddbab704dca3
+ab7466244b990000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTBC013398o00 findfont /Encoding get
+dup 4 /zero put
+pop
+4201 3161 M <0404>[815 0]xS
+5865 3161 M <03>S
+900 VM?
+
+currentfile eexec
+9e67edc6b841305af19a6e4bb2a230e3e9efc9b96f464cd2cec0584bfa5d
+e6b6c8bf4fb2bca3ff5c4ffdcb930b9549cfaa6d954b63169b356002d4a2
+065b3dad6c77543f2f4c58abb474233ea80ce809e35265271e29a645609a
+f19523b459da829c3beb337f4e916de7baa7dd40e381e60e1d68dd6dc672
+318ee6d51a4977d970db3ae073fa94a7f5afcd21e06e8476d782a2865dd3
+2a9c235bd5f3c5f1f327252a54d27bae21d8962686e2aa6912c72c946bed
+83223cfc201da7c3f18870a82efce4ad7f1c996c4d99903969225ed21444
+37bc8415a6f4b6d44e30c3d0e47b6d6945d1536311137281dee93fc9a238
+a6036c912e79e0ebe6ecb3d20cd3093cccd00d504fa49f3c0efe04da2103
+3e167528183bdb7896175c77778fde8f0d0b65cb28281e8869747cde7f28
+94c91c302ba109d3ae45ff70f1999a40d8e9a33bd9ce6b8b22961db9c435
+a39d612dba6c4fcc51231f651c91bd0b0724b13d8d8e0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTBC013398o00 findfont /Encoding get
+dup 5 /three put
+pop
+6943 3161 M <0405>[815 0]xS
+LH
+(%%[Page: 1]%%) =
+%%PageTrailer
+
+%%Trailer
+%%BoundingBox: 18 18 577 824
+%%DocumentNeededResources:
+%%DocumentSuppliedResources:
+%%+ procset Pscript_WinNT_ErrorHandler 5.0 0
+%%+ procset Pscript_FatalError 5.0 0
+%%+ procset Pscript_Win_Basic 5.0 0
+%%+ procset Pscript_Win_Utils_L2 5.0 0
+%%+ procset Pscript_Text 5.0 0
+Pscript_WinNT_Incr dup /terminate get exec
+ehsave restore
+%%Pages: 1
+(%%[LastPage]%%) =
+%%EOF
+ \ No newline at end of file
diff --git a/testgraphical/references/wntmsci/singletest/eis-test.odt.pdf b/testgraphical/references/wntmsci/singletest/eis-test.odt.pdf
new file mode 100644
index 000000000000..0654d52c11a8
--- /dev/null
+++ b/testgraphical/references/wntmsci/singletest/eis-test.odt.pdf
Binary files differ
diff --git a/testgraphical/references/wntmsci/singletest/eis-test.odt.ps b/testgraphical/references/wntmsci/singletest/eis-test.odt.ps
new file mode 100644
index 000000000000..968c7b3cbd44
--- /dev/null
+++ b/testgraphical/references/wntmsci/singletest/eis-test.odt.ps
@@ -0,0 +1,1984 @@
+%!PS-Adobe-3.0
+%%Title: eis-test
+%%Creator: PScript5.dll Version 5.2.2
+%%CreationDate: 5/17/2010 13:9:19
+%%For: ll93751
+%%BoundingBox: (atend)
+%%Pages: (atend)
+%%Orientation: Portrait
+%%PageOrder: Special
+%%DocumentNeededResources: (atend)
+%%DocumentSuppliedResources: (atend)
+%%DocumentData: Clean7Bit
+%%TargetDevice: (Generic Printer For MSWord Testing) (1) 1
+%%LanguageLevel: 2
+%%EndComments
+
+%%BeginDefaults
+%%PageBoundingBox: 18 18 577 824
+%%ViewingOrientation: 1 0 0 1
+%%EndDefaults
+
+
+%%BeginProlog
+%%BeginResource: file Pscript_WinNT_ErrorHandler 5.0 0
+/currentpacking where{pop/oldpack currentpacking def/setpacking where{pop false
+setpacking}if}if/$brkpage 64 dict def $brkpage begin/prnt{dup type/stringtype
+ne{=string cvs}if dup length 6 mul/tx exch def/ty 10 def currentpoint/toy exch
+def/tox exch def 1 setgray newpath tox toy 2 sub moveto 0 ty rlineto tx 0
+rlineto 0 ty neg rlineto closepath fill tox toy moveto 0 setgray show}bind def
+/nl{currentpoint exch pop lmargin exch moveto 0 -10 rmoveto}def/=={/cp 0 def
+typeprint nl}def/typeprint{dup type exec}readonly def/lmargin 72 def/rmargin 72
+def/tprint{dup length cp add rmargin gt{nl/cp 0 def}if dup length cp add/cp
+exch def prnt}readonly def/cvsprint{=string cvs tprint( )tprint}readonly def
+/integertype{cvsprint}readonly def/realtype{cvsprint}readonly def/booleantype
+{cvsprint}readonly def/operatortype{(--)tprint =string cvs tprint(-- )tprint}
+readonly def/marktype{pop(-mark- )tprint}readonly def/dicttype{pop
+(-dictionary- )tprint}readonly def/nulltype{pop(-null- )tprint}readonly def
+/filetype{pop(-filestream- )tprint}readonly def/savetype{pop(-savelevel- )
+tprint}readonly def/fonttype{pop(-fontid- )tprint}readonly def/nametype{dup
+xcheck not{(/)tprint}if cvsprint}readonly def/stringtype{dup rcheck{(\()tprint
+tprint(\))tprint}{pop(-string- )tprint}ifelse}readonly def/arraytype{dup rcheck
+{dup xcheck{({)tprint{typeprint}forall(})tprint}{([)tprint{typeprint}forall(])
+tprint}ifelse}{pop(-array- )tprint}ifelse}readonly def/packedarraytype{dup
+rcheck{dup xcheck{({)tprint{typeprint}forall(})tprint}{([)tprint{typeprint}
+forall(])tprint}ifelse}{pop(-packedarray- )tprint}ifelse}readonly def/courier
+/Courier findfont 10 scalefont def end errordict/handleerror{systemdict begin
+$error begin $brkpage begin newerror{/newerror false store vmstatus pop pop 0
+ne{grestoreall}if errorname(VMerror)ne{showpage}if initgraphics courier setfont
+lmargin 720 moveto errorname(VMerror)eq{userdict/ehsave known{clear userdict
+/ehsave get restore 2 vmreclaim}if vmstatus exch pop exch pop PrtVMMsg}{
+(ERROR: )prnt errorname prnt nl(OFFENDING COMMAND: )prnt/command load prnt
+$error/ostack known{nl nl(STACK:)prnt nl nl $error/ostack get aload length{==}
+repeat}if}ifelse systemdict/showpage get exec(%%[ Error: )print errorname
+=print(; OffendingCommand: )print/command load =print( ]%%)= flush}if end end
+end}dup 0 systemdict put dup 4 $brkpage put bind readonly put/currentpacking
+where{pop/setpacking where{pop oldpack setpacking}if}if
+%%EndResource
+userdict /Pscript_WinNT_Incr 230 dict dup begin put
+%%BeginResource: file Pscript_FatalError 5.0 0
+userdict begin/FatalErrorIf{{initgraphics findfont 1 index 0 eq{exch pop}{dup
+length dict begin{1 index/FID ne{def}{pop pop}ifelse}forall/Encoding
+{ISOLatin1Encoding}stopped{StandardEncoding}if def currentdict end
+/ErrFont-Latin1 exch definefont}ifelse exch scalefont setfont counttomark 3 div
+cvi{moveto show}repeat showpage quit}{cleartomark}ifelse}bind def end
+%%EndResource
+userdict begin/PrtVMMsg{vmstatus exch sub exch pop gt{[
+(Dieser Druckauftrag erfordert mehr Speicher, als auf diesem Drucker vorhanden ist. )
+100 500
+(Versuchen Sie es mit einer oder mehreren der folgenden Methoden und drucken Sie dann erneut:)
+100 485(Wählen Sie für das Ausgabeformat die Option "Optimale Portierung".)115
+470
+(Stellen Sie sicher, daß auf der Registerkarte "Geräteeinstellungen" die Angabe für "Verfügbarer Postscript-Speicher" korrekt ist.)
+115 455(Reduzieren Sie die Anzahl der im Dokument verwendeten Schriftarten. )
+115 440(Drucken Sie das Dokument in verschiedenen Teilstücken. )115 425 12
+/Times-Roman showpage(%%[ PrinterError: Low Printer VM ]%%)= true FatalErrorIf}
+if}bind def end version cvi 2016 ge{/VM?{pop}bind def}{/VM? userdict/PrtVMMsg
+get def}ifelse
+105000 VM?
+%%BeginResource: file Pscript_Win_Basic 5.0 0
+/d/def load def/,/load load d/~/exch , d/?/ifelse , d/!/pop , d/`/begin , d/^
+/index , d/@/dup , d/+/translate , d/$/roll , d/U/userdict , d/M/moveto , d/-
+/rlineto , d/&/currentdict , d/:/gsave , d/;/grestore , d/F/false , d/T/true ,
+d/N/newpath , d/E/end , d/Ac/arc , d/An/arcn , d/A/ashow , d/D/awidthshow , d/C
+/closepath , d/V/div , d/O/eofill , d/L/fill , d/I/lineto , d/-c/curveto , d/-M
+/rmoveto , d/+S/scale , d/Ji/setfont , d/Lc/setlinecap , d/Lj/setlinejoin , d
+/Lw/setlinewidth , d/Lm/setmiterlimit , d/sd/setdash , d/S/show , d/LH/showpage
+, d/K/stroke , d/W/widthshow , d/R/rotate , d/L2? false/languagelevel where{pop
+languagelevel 2 ge{pop true}if}if d L2?{/xS/xshow , d/yS/yshow , d/zS/xyshow ,
+d}if/b{bind d}bind d/bd{bind d}bind d/xd{~ d}bd/ld{, d}bd/bn/bind ld/lw/Lw ld
+/lc/Lc ld/lj/Lj ld/sg/setgray ld/ADO_mxRot null d/self & d/OrgMx matrix
+currentmatrix d/reinitialize{: OrgMx setmatrix[/TextInit/GraphInit/UtilsInit
+counttomark{@ where{self eq}{F}?{cvx exec}{!}?}repeat cleartomark ;}b
+/initialize{`{/Pscript_Win_Data where{!}{U/Pscript_Win_Data & put}?/ADO_mxRot ~
+d/TextInitialised? F d reinitialize E}{U/Pscript_Win_Data 230 dict @ ` put
+/ADO_mxRot ~ d/TextInitialised? F d reinitialize}?}b/terminate{!{& self eq
+{exit}{E}?}loop E}b/suspend/terminate , d/resume{` Pscript_Win_Data `}b U `
+/lucas 21690 d/featurebegin{countdictstack lucas[}b/featurecleanup{stopped
+{cleartomark @ lucas eq{! exit}if}loop countdictstack ~ sub @ 0 gt{{E}repeat}
+{!}?}b E/snap{transform 0.25 sub round 0.25 add ~ 0.25 sub round 0.25 add ~
+itransform}b/dsnap{dtransform round ~ round ~ idtransform}b/nonzero_round{@ 0.5
+ge{round}{@ -0.5 lt{round}{0 ge{1}{-1}?}?}?}b/nonzero_dsnap{dtransform
+nonzero_round ~ nonzero_round ~ idtransform}b U<04>cvn{}put/rr{1 ^ 0 - 0 ~ -
+neg 0 - C}b/irp{4 -2 $ + +S fx 4 2 $ M 1 ^ 0 - 0 ~ - neg 0 -}b/rp{4 2 $ M 1 ^ 0
+- 0 ~ - neg 0 -}b/solid{[]0 sd}b/g{@ not{U/DefIf_save save put}if U/DefIf_bool
+2 ^ put}b/DefIf_El{if U/DefIf_bool get not @{U/DefIf_save get restore}if}b/e
+{DefIf_El !}b/UDF{L2?{undefinefont}{!}?}b/UDR{L2?{undefineresource}{! !}?}b
+/freeVM{/Courier findfont[40 0 0 -40 0 0]makefont Ji 2 vmreclaim}b/hfRedefFont
+{findfont @ length dict `{1 ^/FID ne{d}{! !}?}forall & E @ ` ~{/CharStrings 1
+dict `/.notdef 0 d & E d}if/Encoding 256 array 0 1 255{1 ^ ~/.notdef put}for d
+E definefont !}bind d/hfMkCIDFont{/CIDFont findresource @ length 2 add dict `{1
+^ @/FID eq ~ @/XUID eq ~/UIDBase eq or or{! !}{d}?}forall/CDevProc ~ d/Metrics2
+16 dict d/CIDFontName 1 ^ d & E 1 ^ ~/CIDFont defineresource ![~]composefont !}
+bind d
+%%EndResource
+%%BeginResource: file Pscript_Win_Utils_L2 5.0 0
+/rf/rectfill , d/fx{1 1 dtransform @ 0 ge{1 sub 0.5}{1 add -0.5}? 3 -1 $ @ 0 ge
+{1 sub 0.5}{1 add -0.5}? 3 1 $ 4 1 $ idtransform 4 -2 $ idtransform}b/BZ{4 -2 $
+snap + +S fx rf}b/rs/rectstroke , d/rc/rectclip , d/UtilsInit{currentglobal{F
+setglobal}if}b/scol{! setcolor}b/colspA/DeviceGray d/colspABC/DeviceRGB d
+/colspRefresh{colspABC setcolorspace}b/SetColSpace{colspABC setcolorspace}b
+/resourcestatus where{!/ColorRendering/ProcSet resourcestatus{! ! T}{F}?}{F}?
+not{/ColorRendering<</GetHalftoneName{currenthalftone @/HalftoneName known{
+/HalftoneName get}{!/none}?}bn/GetPageDeviceName{currentpagedevice @
+/PageDeviceName known{/PageDeviceName get @ null eq{!/none}if}{!/none}?}bn
+/GetSubstituteCRD{!/DefaultColorRendering/ColorRendering resourcestatus{! !
+/DefaultColorRendering}{(DefaultColorRendering*){cvn exit}127 string
+/ColorRendering resourceforall}?}bn>>/defineresource where{!/ProcSet
+defineresource !}{! !}?}if/buildcrdname{/ColorRendering/ProcSet findresource `
+mark GetHalftoneName @ type @/nametype ne ~/stringtype ne and{!/none}if(.)
+GetPageDeviceName @ type @/nametype ne ~/stringtype ne and{!/none}if(.)5 ^ 0 5
+-1 1{^ length add}for string 6 1 $ 5 ^ 5{~ 1 ^ cvs length 1 ^ length 1 ^ sub
+getinterval}repeat ! cvn 3 1 $ ! ! E}b/definecolorrendering{~ buildcrdname ~
+/ColorRendering defineresource !}b/findcolorrendering where{!}{
+/findcolorrendering{buildcrdname @/ColorRendering resourcestatus{! ! T}{
+/ColorRendering/ProcSet findresource ` GetSubstituteCRD E F}?}b}?
+/selectcolorrendering{findcolorrendering !/ColorRendering findresource
+setcolorrendering}b/G2UBegin{findresource/FontInfo get/GlyphNames2Unicode get
+`}bind d/G2CCBegin{findresource/FontInfo get/GlyphNames2HostCode get `}bind d
+/G2UEnd{E}bind d/AddFontInfoBegin{/FontInfo 8 dict @ `}bind d/AddFontInfo{
+/GlyphNames2Unicode 16 dict d/GlyphNames2HostCode 16 dict d}bind d
+/AddFontInfoEnd{E d}bind d/T0AddCFFMtx2{/CIDFont findresource/Metrics2 get ` d
+E}bind d
+%%EndResource
+end
+%%EndProlog
+
+%%BeginSetup
+statusdict begin (%%[ ProductName: ) print product print ( ]%%)= flush end
+[ 1 0 0 1 0 0 ] false Pscript_WinNT_Incr dup /initialize get exec
+featurebegin{
+%%BeginNonPPDFeature: JobTimeout 0
+0 /languagelevel where{pop languagelevel}{1}ifelse 2 ge{1 dict dup/JobTimeout 4 -1 roll put setuserparams}{statusdict/setjobtimeout get exec}ifelse
+%%EndNonPPDFeature
+}featurecleanup
+
+featurebegin{
+%%BeginNonPPDFeature: WaitTimeout 300
+300 /languagelevel where{pop languagelevel}{1}ifelse 2 ge{1 dict dup/WaitTimeout 4 -1 roll put setuserparams}{statusdict/waittimeout 3 -1 roll put}ifelse
+%%EndNonPPDFeature
+}featurecleanup
+
+featurebegin{
+%%BeginFeature: *InputSlot ManualFeed
+
+<< /ManualFeed true /Policies << /ManualFeed 1 >> >> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *Duplex None
+
+<</Duplex false /Tumble false
+ /Policies << /Duplex 1 /Tumble 1 >>
+>> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *PageRegion A4
+<</PageSize [595 842] /ImagingBBox null>> setpagedevice
+%%EndFeature
+}featurecleanup
+featurebegin{
+%%BeginFeature: *Resolution 1200x1200dpi
+
+ 1 dict dup /HWResolution [1200 1200] put setpagedevice
+%%EndFeature
+}featurecleanup
+1 setlinecap 1 setlinejoin
+/mysetup [ 72 1200 V 0 0 -72 1200 V 18 824.0003 ] def
+%%EndSetup
+
+userdict begin /ehsave save def end
+%%Page: 1 1
+%%PageBoundingBox: 18 18 577 824
+%%EndPageComments
+%%BeginPageSetup
+/DeviceRGB dup setcolorspace /colspABC exch def
+mysetup concat colspRefresh
+%%EndPageSetup
+
+0 0 0 1 scol 25200 VM?
+11 dict begin
+/FontName /TTA55o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066084a75e287a6b21
+7d5ead11cee92565651ea4f1d618325c70b09fa582d2eca5e5c5deea3be0
+b1103a2db20dd69d0ed4b12a762ee64108282b8d83f8d25f9b0608098b16
+460b06a011c4da3f1e637f7ceebc2c8c5e93750ddf750a5c367617f3ede0
+a6cce86a134ca76a529adbcaeb6269451c7420c09daca772307efbb571ee
+ca3a4465c4c2c3d07e2e4a4d48c613544563cea572138daa08d3f5cf8000
+48b9a9565dad61504d768972a63af0d028d75c4659f9cca991fb4b69a2bd
+6e431e8b0e6a12e9dcc103601275d759cab9eeadc4460c47826081779cba
+93705992909858e7649b160152d7bf68815571de7b523535e3f769594f22
+6903dcade6a25b8812844738e33c7cb6fcaee97f7e0d8603cd3dc3ff06a8
+773abda4287715d753d213526621e7b9bd20a1d7c760b92a1abcd504356e
+4d33dafc982a531bd06a84380c708eb3650d88f88d440ded48d8d3ce7678
+a965d8469f5931134fe32d1a371bfd25667b18e588de27003a6758c36c0e
+a3d1550756abfd014ccbd822aebd05c03521ded77a70cbc5a58c47def657
+79dab92fed044a48697ae300bc4ea5a33620bfcde234c944b214a9c2d562
+d369051015084e6cbf286344a22b3f1003133679dc6962df21405aa70d6b
+725b8f8a37436c2f12a9cf0eb097dbda2dd417b2c2e6eb0ac571bc00b5e5
+93817cce74217395cc079c8222746172fd669a96cb65e23828a2a4b1ff2c
+93428a8c2738b0c42e14b93725d2907b0352a41c50fef53b7a13daeb06b6
+d1f339ee6f2cd8c8fa1154c733b17a2f3ac716ad02da5459abfc16b83ab3
+9fc018038386e7065f68be925cebb5f86a1112a2657cd4c5a741c5e7b520
+be2a0dfcf072d331964cb6065f51531606db141ad04b59b2aea886c83024
+feccd6a378c41dc2bacf17907885e03384773ce94735dc19022f0d171df4
+4322ad309a02ddf3455ba4c822cddaa3b0b0552dbdd354bbd279223a6b54
+a55fd4b0d5570543709083a26e944bce2feb3c09d9ea02a4851b70bf4a24
+7892c3d0bb0483daae9b9a9dc5acd3955a9e213c7ca9b51bc1a3a97eae3e
+67abaf6e26d68e27bbfd9a05b30474a1ef758ed08ae5423f0e430efdf23a
+6149cf11ecd234c9d48aca961f1cdaafa375f9e488605876fc32ad44b2da
+abb0e23a05b2e35412aef4dc77dbae93b2bc47f7b284d5f3e12dbc56a1fa
+971a5c5be62ef903e4f54edd9dddea7c3908546ff5dd4bda3079624a9a22
+9cbb4c84ac0b4f68a19b24a88d2068b8074c21eb35ef43789a3588b32710
+4558187555465bfed7858029c1f7f30f942ae86dff06d1f8f2da8cf8b330
+a1260fb9bb4648d8fccfc12f295164eac890dea6d03091bd25c91db21856
+e1023ae08ea96af37790bcab40398f35122b6287f3e0ba266b563cd5e09b
+117b848b20d986fc6f08d53a5115263e91e84448ce2052e731ba5ac2274a
+3cfe116473da78d88a3980ab570e9d8afe870905da9620ef3c55b859f825
+a7239fd31d4a6a5ea67381a26e68dd48a07d7b2e9396ebd861b3f55e04a2
+b0cb2a2dc1c20e2919cd3981883acea06c47700adc875197fd05cf4dee96
+e3847d7e7cad37e3d62536f36bf7e9b39fed99c8e18564b030417d7c46d7
+73edfc7c97506df2ee5dadc76b03c19d17444c5d529641aa20fd07d50f62
+85d1ea902c58baa75ed6f2236c1904605a89c333160a190d92068c03982a
+8bfc3b3968487f940314478274337863c0e7c797435dab9758bb85240e4a
+59345b67492edfe7a3c00d6626c663bf7577f4012bcdc438fd37e32f5785
+cd124fab0681605098048f77aec3819aab4de3ba73bfea197c50c4284225
+3008b38a77151400eeeaf84ea6d1e8a26f9463baef55137b53a4460000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA55o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+Pscript_WinNT_Incr begin
+%%BeginResource: file Pscript_Text 5.0 0
+/TextInit{TextInitialised? not{/Pscript_Windows_Font & d/TextInitialised? T d
+/fM[1 0 0 1 0 0]d/mFM matrix d/iMat[1 0 0.212557 1 0 0]d}if}b/copyfont{1 ^
+length add dict `{1 ^/FID ne{d}{! !}?}forall & E}b/EncodeDict 11 dict d/bullets
+{{/bullet}repeat}b/rF{3 copyfont @ ` ~ EncodeDict ~ get/Encoding ~ 3 ^/0 eq{&
+/CharStrings known{CharStrings/Eth known not{! EncodeDict/ANSIEncodingOld get}
+if}if}if d E}b/mF{@ 7 1 $ findfont ~{@/Encoding get @ StandardEncoding eq{! T}{
+{ISOLatin1Encoding}stopped{! F}{eq}?{T}{@ ` T 32 1 127{Encoding 1 ^ get
+StandardEncoding 3 -1 $ get eq and}for E}?}?}{F}?{1 ^ ~ rF}{0 copyfont}? 6 -2 $
+! ! ~ !/pd_charset @ where{~ get 128 eq{@ FDV 2 copy get @ length array copy
+put pd_CoverFCRange}if}{!}? 2 ^ ~ definefont fM 5 4 -1 $ put fM 4 0 put fM
+makefont Pscript_Windows_Font 3 1 $ put}b/sLT{: Lw -M currentpoint snap M 0 - 0
+Lc K ;}b/xUP null d/yUP null d/uW null d/xSP null d/ySP null d/sW null d/sSU{N
+/uW ~ d/yUP ~ d/xUP ~ d}b/sU{xUP yUP uW sLT}b/sST{N/sW ~ d/ySP ~ d/xSP ~ d}b/sT
+{xSP ySP sW sLT}b/sR{: + R 0 0 M}b/sRxy{: matrix astore concat 0 0 M}b/eR/; , d
+/AddOrigFP{{&/FontInfo known{&/FontInfo get length 6 add}{6}? dict `
+/WinPitchAndFamily ~ d/WinCharSet ~ d/OrigFontType ~ d/OrigFontStyle ~ d
+/OrigFontName ~ d & E/FontInfo ~ d}{! ! ! ! !}?}b/mFS{makefont
+Pscript_Windows_Font 3 1 $ put}b/mF42D{0 copyfont `/FontName ~ d 2 copy ~ sub 1
+add dict `/.notdef 0 d 2 copy 1 ~{@ 3 ^ sub Encoding ~ get ~ d}for & E
+/CharStrings ~ d ! ! & @ E/FontName get ~ definefont}b/mF42{15 dict ` @ 4 1 $
+FontName ~ d/FontType 0 d/FMapType 2 d/FontMatrix[1 0 0 1 0 0]d 1 ^ 254 add 255
+idiv @ array/Encoding ~ d 0 1 3 -1 $ 1 sub{@ Encoding 3 1 $ put}for/FDepVector
+Encoding length array d/CharStrings 2 dict `/.notdef 0 d & E d 0 1 Encoding
+length 1 sub{@ @ 10 lt{! FontName length 1 add string}{100 lt{FontName length 2
+add string}{FontName length 3 add string}?}? @ 0 FontName @ length string cvs
+putinterval @ 3 -1 $ @ 4 1 $ 3 string cvs FontName length ~ putinterval cvn 1 ^
+256 mul @ 255 add 3 -1 $ 4 ^ findfont mF42D FDepVector 3 1 $ put}for & @ E
+/FontName get ~ definefont ! ! ! mF}b/mF_OTF_V{~ ! ~ ! 4 -1 $ ! findfont 2 ^ ~
+definefont fM @ @ 4 6 -1 $ neg put 5 0 put 90 matrix R matrix concatmatrix
+makefont Pscript_Windows_Font 3 1 $ put}b/mF_TTF_V{3{~ !}repeat 3 -1 $ !
+findfont 1 ^ ~ definefont Pscript_Windows_Font 3 1 $ put}b/UmF{L2?
+{Pscript_Windows_Font ~ undef}{!}?}b/UmF42{@ findfont/FDepVector get{/FontName
+get undefinefont}forall undefinefont}b
+%%EndResource
+end reinitialize
+F /F0 0 /0 F /TTA55o00 mF
+/F0S64 F0 [100 0 0 -100 0 0 ] mFS
+F0S64 Ji
+4483 738 M <0102030405060708>[61 30 57 35 61 44 39 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA56o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206689a2c7f31c3571c
+8737a397efefad52089b0a63555d3209d1f3499e5f079b0179d26bd1a32a
+7bf160e83323b466debc925db378cff20fe2ba66a466a4d8e1d2a6615e05
+93a54552fe19a6e69b359af73bdf13ed8417dc9fc8dc3f18af93902e4197
+b017bff7f07009d52cf468581f6a23267d555fa25bef058e1ac4f1bf710a
+4067b25bf8ed2fd76a56a21222c35beb89a1e778c0ca1c10db6fad771b1b
+85771340b80523ff61971323b189e5cd4f8666eabccd1bd2aa658224cc84
+a8652949369fd109f7da580efd0ef48637981305ef31dd2654b818529b95
+81188e00d73117aaf12858765156a2ee8b290fc3b1ad7f8500e5fdf3a784
+bcd5a3d1d8613b692b3fc5d88ba80b961c093aca30c05de21307a42665dd
+567218faaf8e7531b8658b777053fa437955fab3db6bcc47bf877b55850b
+26ca2a1d2ae2f655f6939da944107009b124d97feab6b504be5d1d142fd6
+e7a2e0b1e5c51daf94eb93a43ce9ae7ebc4afba0c6dde00967e5ff15f6e7
+87af9d25ee37e13ab42bd3c6163335570877ec27d2e0b8a87083b7bd4e51
+f5a164659aec160554f0cf11eb2f253844b0a6adc1748c633f16f0ab1885
+3f25a36b4e80c4f742f83568920975e061327bf0a3a77e99b0bf948a068d
+18a4723ea71d7048424ac7b39260fd0717446fc6916cd997742d088d4258
+d4301cef2f3cc8c632d9c0aea984131a59c77315ff1e282c26d745f499cb
+4ad480715a91553e4dd0345774bdac173e3db6dab78f559da4b3ec76c473
+5d24af2afecb96535a5a6c956453f5ed7f00fdfff68025fd6667ffa85b3e
+fc5bafa39cfbdba93d1e9054b5581daa9d37bbfba4f602f3766d61f275aa
+7aa663a22d807494bff21a562eae0507e64bc74dc8d1a2f052b626539a73
+5d1a5832e7a89e886eb4db30ccac44725ef80f8215d2115764ff1dec4cf2
+4bfa1f30c36e3da7b69915d30cde7e205e8a9e780bdacc60f3bb715b00e8
+221669692a26d568e581e1b318334ac68fc818b4aae56f9bcb7c4dc7b749
+a083c67c5df50e02ddf9fbe5ab022acd31204913f32d7a8b47242c2de557
+cb452815625cb986e010e03c757188e99acdcff88b435c229c9fa7e762f4
+2823b4b32bbad7aefa65cca11515b4bd335afea1638e7ef8da3fa7f84626
+25c39e1a2ed855c06cc5f62152d2eafe46b9d11dca17173ec0955b1452af
+531f67fabb234bd217a9aba25d1dcd411f90829c70932706ad453c184066
+f3981f10ec9d212029aec5fdbdbc0ee51d1808c0a7d911c3f039d4f5368d
+0b8f0fbe6b67b888119a7f7bc24558be741e57ea649bf1d03f8a555aa600
+a90a69e471b6d8014264f1e3efa6c74e2a2f694c36bcaa713d16a2279073
+748d853fa087e61ef3db613d9112c861655a99de6a3e4a707c8d450eb68a
+0a6959ce43b5437f338ef9f90a4a2f1611ac157c105a68770e2d00af10df
+882fd6b4f100ecc610515e037112a012e306c2e6b684cc837e815971ed26
+6fcc6fa7f2fb5f83cb06d835731a5034e683ceb10e5402f41eddbd8302e1
+df211165be9eff0f2c296eb85d7ea8c667d86fc1a620504f5158dfb898e4
+72f7c46964e2ceaf85c9a892eff29d25bcc1e5297aa679976919f6c839f3
+d0f54de71a531116f4ed682f527c7f53d5c164517db6f807c1d20d37c022
+c5bd5e6a8da424c3e3d47689fb71fa07290f52db51c37d64b83207fca5a6
+9833ba0c2c3ab8c4d8d171c040863605ee1122166d712ad8c04475341da5
+86b1a501e0dae2d6726daac4b640945778ffc53c567618e47993dbba3ffa
+82fbed8bd9f9eb3f0145870cb80b4429e582595ab561bcbb6dc15c889e3e
+ac002d4fef28fd1b9422c142dfe50ababb2be2f385bd343ae40000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA56o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F1 0 /0 F /TTA56o00 mF
+/F1S75 F1 [117 0 0 -117 0 0 ] mFS
+F1S75 Ji
+4454 869 M <0102030405060708>[70 40 65 39 71 50 47 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA57o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206118c660a9cbf6d8e
+4b94826b96ececa9599a7609dcee16efe1179b77c1b7f46a95a0ab7c17a5
+697836677e08c4eee7e9abfc4070a184ceafafef2726ec95228791901739
+e45003466c73dbc8c43a9c04969dbcfd8dd8cf15a19004cee3a14a49be6e
+b91213a5ee7b0d2d584078f374b74774ed505dcdc8983311c8f8e03e9edb
+9df6842ada6e161ed6a5b011b3f1c7320ded247da6deb3cd17a7ec0f397b
+2415ea072df14348131a70acc1f7c7fbbfd3870b5f41e98d030d413cb08a
+2845f8f1c697e10d8ac363d896f70864686afbee40d592ff2a9e75e3e361
+06444d8ee582de9d325fb883a53b6c68d362eaceeafa7048afa7430ccc45
+572995e53aad2bd2386c32d72665fe9d6964f038c062b01a43757a9ab52e
+2cd852d6146f2232dfa51ead4a2b44b01c5832d54b88ed54c258aed0171b
+b62cc9a580de1309215b9be7403d782f2bf09d2a9edd0f657647fdc4900a
+22c529490ca9a42be2400c61acc09f4db4f7d500159c7a4e4e3ad5d4f112
+0507ba0052d9818e041afe07325886343f03c99f60cc1601307e85a68685
+691790d16bdb7d487a68e6e15d211ebeac2443efbed31a5512d98cacfdff
+e34d638fdb613469cffd654f12c888fb2923930f739325fb86060b4acae3
+c1e5a887d8703feda1156c4d73c0e21813d748154bb54f8c24c1daf24601
+8792c263771d62affb085a58adbf11ab9599cb9dcda256cfe6909ffa616e
+53434e3627483cb07b06d46eef74e18d985429a9e1ab75b933114b58082c
+22cf52f6c86824e52d1ec597c6250f14a100499af35f259be3e328da8e47
+483a34be21f28bc8a3262a528199b63a9791d53121a622873f5e6987e883
+930912abd47d820cb61501acb111bb4b004abc7bd88ab6b8245fb7ed6917
+8a29a82d445ee37eefda5c108e2e5729338da717589f1aaf4bb384d05de0
+f8094fc57f0b38379014638d4e690feb342a7767052f75d630b35a14c266
+846a0a255e7012750b989aec755b5f382e79a9417c6fc1e67dd51ff6db64
+6105edd0f9db04526a56c1dafc9a5c3b2eec3e8b9cc15e6eaf81df891db3
+1e4a1578f50ae8b34485e77abb15bc441dfe8dbe345c23f8378de08d802e
+6b1fd78d7f06217fcaf8737778d271c391cc56f2111f7600b59d683316dd
+dc1c3721f4e1bf984f1c1922b989a852ea83eb7cc9e907fefaffab3777b5
+5b0f4b31ef5995c2e4d1f076a36c6dac984dab1fe574f6c30f9883f3adb3
+8104eba28e817d1c8845c2e339509afb6916f2e74a26335df0f2389652cb
+b97a144bd0b34d282501f1ac84ec15b8ab7208be238220a6d45443928c3e
+678a651ed615ab2419886ecb8170bca1de483c4bf773a2ace74003476dd4
+9cfa70f78ddb9b2d832b6da5cde76b8286c581c6e0855333f24c4a849b3b
+0591099e36178aecee54d3a7d3aee7c2af5c84555f6a2b6d0090938f6a48
+177c4e5d34c0287c6b8c4a0dd59ad7ed951e296d122a8f174da1497fb317
+2426125f25cb184a7e89665539ecbc53e89416e28a146b933ab891ce7291
+db110571cc559ac79a8f06534d3aeb78af1fd90c1a62ee315df8e9ea58e1
+3003e4784c9354d1de15ee86207c70f572629fa6b62cad886aa18a39c2e9
+f2dd802c49542b085b88afcaae2ea3b3aca61ba5ffd9f4e3d2c1e9bdd3cf
+d5669196623887a7a2016ef55d22f6b5d791e1b787bd8c234d2c715ce9b4
+0bcd0dee3a9ddcbb71bb1ddbf2a76cd4fb4f0d7d2b786a28905989ae899a
+669a081cb20699ac39b91b6fc7a98870cabd07f2d54d666e66bf182334a9
+236157ad4379069afadc84bc9438bf76ca41bd153d38f64b5af32421d933
+0f54c7855f00031060c388dc4ef54a67ef866969cf47a6e684367c794f0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA57o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F2 0 /0 F /TTA57o00 mF
+/F2S85 F2 [133 0 0 -133 0 0 ] mFS
+F2S85 Ji
+4424 1019 M <0102030405060708>[80 45 74 45 81 59 51 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA58o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066a6b46d2cf1728ab
+cda123ebf188b9a6b8b24cbe57d2fdc0fb1465e42a4a57f1b5de50d12264
+c2c52885376894a97a3c08ba53166de08d794b16c034e3260814dc36d7d5
+bd49c3cd5a16d882e9a1adc9ffc8fa13e3d736dd14a0f59c0e23b738cd57
+789aa9c1769a2a0780fc2c19fc708dfc6073d95f7be838edfc03cbae144a
+378d7cf48890570309de33ee5d7cb65a04e574605763d16439afa2291a11
+03067d6228112b327dcf9ec9ffb4b4c5842fb3d130ce409f5838ceea1dfe
+56bf53695ba7e626b7e902e190dea669301951796a841a0bedb5e51d3c09
+3e882413436423ef296308bdbd1ac60b84bc70376ea86c1b07062f7a204c
+573da34342995ae05ec7dbf7853f2e5f9b9842c8ec74fa1d38c508ef3e13
+c69f19b5dfaa844e9cc5e3d791f36fae0adfc6a6e90069792294e2170e4d
+ac265f7c0fdb3301ac4b0ff5ec185b21826fc4ac759a856acb923365268c
+2939a33c5bb257385b099f89737dc9f92a81ffee9fd40483dc6e9e1918ce
+cb7dc0141b3fb52a6f9326e075efd4c5296c39718ff35463da3ad067d02a
+96d8b41a02f84adff5bb4f6950fbca87a3db27261f99d049c78ce3d75510
+788b537af73800fc21501b72ac3cfea52b9d86946fa2d807b50640efc784
+9492f277cbb4a451bccf504badbb0f5e0a8f6bb116d8c16ec3522fcaa2e1
+466cdd96ab803f47d4c8c206b5676909ece2e6db8dd88afacd31b9f5a670
+5daa6dbf84d3f053ba4261a8d3707311fa9d46bda5ae891aea4ad6b70360
+08628f733151a4f2262aadabac443b4dce72ce55c62968cc0205bca2e296
+41c53ad39c339efcc6ff63a56440b6109c071289a18024596d0840bc634b
+fd0076c39db41e96443f89d1d79f6c796b3df419f8d19b9abebd474cba56
+f1b0be6e75199399666b1e5c297418a5e05575a85f4f596615ffdb47ea6f
+79933ed05fba1911a87ec7985fe0acc52c074888943175fa52470b364398
+3a99eead59369a00556ee687c9ceed2e8a95d9dc1790034d2fa6a19919d1
+a43f10bcae5e14ef4ad036c7f44cb63f99f9a2cf4970b5760fa073a6c970
+eefd0ce5d2fa46af1b542149afe26804a834ac0a7f727ef8649d6af07667
+2724e5f7b6b25744e674bf9a5086196b7834df64bc3bcab2cd70a1fcc492
+b3e7afc80f72e3a84aa5d3e5c3c902d6032f41da6ae5e7340944e1f4bfb6
+85fc826248d897cff0897e4c590258f8df6c84c891f3b46abeabe0411cac
+70b9abd20ef4324819bc49b28fb3df7e25381d9d21c276fc908aaabdc532
+6621c5cdcb3dc3dfa758584a9b8f86e7070ade12bfdd54b1f56947eb98a5
+a46745809b0edafabd19192517147c68d4dcd55b2bcd924955d09d8a363c
+596a4e5f0b18e23813e70d5231def676dff793ad0f4af3ca4b279d5276c2
+adcdb87b00531a4ebeed39d836f09861386999c622bffdd5df501c7e7844
+6b559037fce2e95221391d4223368d705bb40bbe7d1a7a7f15c49686a9fe
+418d72a2b9fff5bcd68b058633580ea72709a3d95779a06821f56d70febb
+a767246ff6c567e7d4f3cf63c69551a37652aced5441e9e5df350d931420
+916a69ef9a880108df611eec29d502d08b073b78271c1b151774392639b7
+5cdbdc2045bd3a6f81086d8500e50d195207f3b4c289539cebaa82ee9d83
+05552788b36623ab12f103176a73856bfa4e6be9cc9897fc305b86829b30
+2c0b7287e514ef5e9b10733ed95ecf1b51121b9ad99f9becada0c85c7c1d
+c8fe8e896c083bf9daebb69e529af516c09562c6bc8b50eef72f33b81e7f
+08a88ff5be58bfccbd42f96a582ff3d3ba11218f82d121040d0fc501dd3c
+fef1e5d184c959108f096bbd543980458a682ea0ad0b62ba31ceb3560000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA58o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F3 0 /0 F /TTA58o00 mF
+/F3S96 F3 [150 0 0 -150 0 0 ] mFS
+F3S96 Ji
+4395 1188 M <0102030405060708>[92 50 83 50 91 68 57 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA59o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22061485d7d0c2a0dbf2
+930a8f5918a6862051241b27b50bcdabfaf3447ec6b9abe16f841c5bb191
+f22797fcdf6a8c8ff86f049be5c0235027cd0afec26ca4ec8f456e5fdca3
+48ec1263f3379ff320dac2de3bf289d44a586dbc7321cc21f6970a30ec04
+4c81bfe4cc4aad0c34c941050be71d47d6b71b17cdc52f5f4929234df4ce
+8e8dda53ba1756d68ff2998920764c753c787ce2aad2b7318beedaf154cd
+ed062e47828b15606957a37f2ed31c497b84f23af55a4be8ec19ec290bc0
+8b8a36d4f76ed450f2b6bd24d1ab0cb9733ded98d13d121ed6e61bea7f25
+535d7bb636e41d1e6c85066ad25a4129078090ff449da4901c333fff5a65
+3b109d418559dfcad8a3b95343e32949626ae79e1b9b76f34e85f8ad1d02
+45224ae5469e6de5f8ebe918e4243c58795f146dcd8fdb345ced4febbb37
+49447b9005b7e9da42f5d30c4760fc2fc25f01bd6cabee8635bc3b354b51
+4640db9cc5a1ffc3b043e11b946b86dba33ae4d62a6868a0563918626a9c
+ab48b3a26ac63b32314dd3e73ffdb937da9fd8641213b6e421733bc26d75
+4436a44bb0374923869ba9d9e3ad5d720963b321d55c8a69622f6e513484
+cb56406691e8ebff011186c94bda3ae6d73b1ee31e0ab7a00d1ddc0a0add
+9162daa7d98b701e411ef69cba5bab29143d51a6621fdbbc6c2786715312
+6abed7ad07ee21ea4aa2604ae9801151304692738429383a6be9e2420d35
+36706494a215bbc41a8b0720608803753eb09b8da2232ed01b25984e1ad2
+2ced31325125ae4f61f6c40c003e081c25e1648f36c734b9206e82780ff2
+d6890dfdba56a76379cb87ccd6a207a3e96ea78cf156ef86936224d070be
+a4af0e4c33a1e9016db6a04374dfefe1190ff69f20c89991541c22cbeae9
+d716460f215a5e3cf1b3da78cd2fa5c732024001c91382dfb9cc28268f71
+6097460b697b27d156c66591da3701476c10f4a699da79d411353d984a44
+335227370be063f904c2ed3046c105d07d009f5586a254627bc02cc60086
+5ce2c25952b4ed43a867b1e4de7312dade167ead9739792765d1987c094b
+611be118f5392f62b207aebe1855cf31d6cd93e85627a1314bfe1c99231b
+3f5fcc8cdc99e8c843f553f264d4a676e700104c4f98640d95f912bb5c2f
+21d3fd8ef0fa3759139bf3e24238c7571aae8f3db149822f24233c25d03b
+e95c19deb5e0fb30f5ce473f81cfbcf25a3998b511c61e1c788aa5653bca
+a78621a572a576df9bd271e38ad6de59995df949aa857ec90ddaaa3972bc
+abecf967125d88bf8cd80f5864010b927ee8a77909505e8a0d84ac430ac7
+7c3568384caf36adccc0b4c083fa19dc61f5a35f9f51adef83a1e4410507
+9f1238fe26633516e27aa116a1ed20889fc23c2e803a34d17ca4a328b654
+df8bf4312ed207b24abe6b205f401b2239a29154f251a6ef7a5a8481640c
+c92819cd1aec2d6cec4964d9230d8011a9908efe0a14f825cf3bfbe84d7f
+bbfb539c127c84611cb20e0a59301a13b4a5d279c763a2f7a718f99073ae
+5f18d7c7e8c9d8f4baa8ef33941cf41620bab2ebf6b55d781ec3b2bf7157
+74e3ec25418d93decaf162f96cdf0d6f96e81997358c0e1cab62af3bcb24
+86904a0858a07eabd803e5379b03c650af98500509eadef2b1afcc03dc34
+e669c1b996554c6ef76b1a40f130d9d342411fb9b5ce422e71166545e4c6
+70a2abdaf7a4fd819d3ea3c501917eca68803f09af97fc95618a36048ad9
+93647725ffd4bbc4fbbda3258b92047db2c9309e51efc433257e23c84274
+90d257dfb2ce98ad682743094f1ea6342930f3b9dcda8ce2d665e08f7aa3
+fa4df153a7da21f64c2eeb74351ae8cea832987cf187ad483d67900000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA59o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F4 0 /0 F /TTA59o00 mF
+/F4SA7 F4 [167 0 0 -167 0 0 ] mFS
+F4SA7 Ji
+4365 1376 M <0102030405060708>[101 57 92 56 102 74 65 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Ao00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066ef7ec7adad4e5d3
+8b2e433d08a0dc640353a02ece412a4b09d5e6d3465f6bc5e74216dd072f
+3e9e3f8ddd853f280cb37ec60c99e5ebfc757e7be973819b39ff8196497e
+472a63fdfc05e286e46365bf4d55ef237a062467084640c98e5d0dbea864
+ebd8683f644b0d7c6923a28af309cb98a3be6e046ced7cb900f4631b119b
+65be6103be27edf87e4f495d1753cd8bd59e99bbebd2e1d600fe9e2d5ae7
+db029e32176da132e72f490d02728cdfd28b8be9472520c524363b527f9d
+91b3224e223789c3aa5422aaade5dd21796ca05e253143fddcea8d000ef4
+bbfa338c920b5c025a3475b44b9ebf0dec8b8bc9fd1a4f4328f1dcfc041b
+902792f9477fda833b0962748e3261db32d775f63eca2c99bd863edb9c3a
+e5e06bc0886cb9de7e91161055143943d5b9ffe3d69894eff59942c6e6bd
+14f1764dff5ac5f1b0bb60812e6ef1f4935a5443092a15cf32a4b18e21e9
+aa333e356f31f450f888aa11c25480a796202faf03196243a7fa68bac329
+1dbb3b0d7ad4c7f80f66f8462e44d066c558c16e377fe342997ea31c3c00
+c0903389a580aa761d9ae539521a4cc09f2cb49232385ffcc7126415f498
+5289dd79d836c4d11ac344119b7755cb406f12c2bc0c6abd598754be166c
+9e62e0c1f0c55e8e205273db43574b4ce35677439575aa7cce8b1860f212
+3803d6a99b5f928e00536bdb35d7f77b9caac62936e902762921648e9189
+4586de6c61e572732b0d097683bdf4e2f7a0b9332efd48b15de3d934c324
+6d96fd969ba4abcef9b28563b45c266aeac1782cfe4ef1d3baac42796450
+3e0ecef9b80d20a51c757eb8eb8b4cb3832f1bdaf75d336748a3bf5746b5
+48d93f3a13fbd0e29d974ad5991ef5e14ee409d385d59d83fb9413950468
+ea2b09a608b72a0b7bd60ecb9814cce7d920b22d387e867a23cebcf54958
+ac985c6433b3a65b5778543daea52a9beae38bc838995895bb2262772b07
+7a4e0cdb87633287eb320b56d652895b12f39927dd54104579c497fd1c47
+25bc223e54ce3fcaa22faca351346c4979209419ec33264b1578034461b9
+d2b2359f310d3bb0578f30e5b729009d6372fcb1d6430e282de232363d67
+5eac59c4a6704836aa6e274473d2f6220a627c9ab5747fc3115ac948180f
+549b305bcc2895ca1de60aea55332b2b180b36831ab380b7c2f421ca5689
+7b173ac0ceb1e4198cb47b8c626057eb4319bb9b2505f3a6c9f4638f14e3
+f07c1d915d490174d7b6deccda599a3aa67af1adb52192c2b0591f52ae78
+78527f69baf10ad6bea8d1d50898e4f5795717bcc90cd5f9078caeea6760
+ff12a1ca76439be0385cdc3c7af7905a904828638c51121648265d99c5b0
+16781fd791060dcfe4a611b15e5c42e92c1a31fd40f8873c79b438041899
+50070799a04d114ac98dbadf46a8023a4413aad03c2546cda40fdff6afd3
+70572d90a7709336daa37491ef98c376a836250a37818621b0ab50401e5c
+137004bda09e99ab2726dea1b4b17afc11a04c20cbb9e12f70bc3cfe4304
+83bba0e3079cdc0a27ebffd6701cb4908f0e2afc384d7a9ef77170216a6c
+acfb8842c9c700734705a3828d0f43b2bc2d378b16678b9daa7e20a62217
+5e41ce1d9a669d4a4accf73231cb66c4671642c6bc2a5cfeb84e58d51344
+3e4ee31aa83dad85b034293d42f390cb9f6949729a019ef973fd4d2a5bde
+aa3b3d2d41de3daf5b11c02eca9ae7441215e0c44319c090873208fa32f3
+caf24b4b92d67e744e8234207efaf0cd03066ec4d84ac8e0f71138fa5ecf
+d4a87a60a2b5be428d95e0fe40147782a1cb875c53e84ba042387a35a687
+e9e02f0a7a934069d2dc97971f43b809d0a358a5a92991cc279b4d0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Ao00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F5 0 /0 F /TTA5Ao00 mF
+/F5SAF F5 [175 0 0 -175 0 0 ] mFS
+F5SAF Ji
+4350 1576 M <0102030405060708>[107 58 97 59 107 77 69 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Bo00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066baeb5dbea4fa9a3
+71fbf5607f4335673d842c1fb7de714eadcb044948b7458d4cd4d22f303c
+51e1270d84994826f6a1a17ea11bc730d40426ace8a29926f3e4fc00e701
+a90ee9f5cc95cf95beb409d15d258fa32a3a904d0f959273e6eda6f0df7d
+08ac5dc01d384b162e5ca1aa8a3b1f45c0ed44717a8b1d92a54ad496aa6d
+86c578d27a9aa506dcbe25e7181a98e99c355dd06cac8f9f8c2edc1a6278
+1b861b29d71b1ead02638aa086f77942c6cae5fa9678321e48be7a95b860
+56566e58dacbfcaa51dcc09cb1f7c4cc3f34dcbd2f5e33dfe4222fd8b18c
+36bf74b5d48df7344cd4cf4972bc08ffa6f62ca6bc4b0eee26ece563b33f
+5ca6f0c377d134cd7f31c4802763cdd756c01b5ec85fb2a1a641d7aee478
+26402f527ffe707d36f6f6f90c180dd922dcef1c5cc10cd1d26c916f8362
+190f7100cd97d6feca5604bc997f8cd99b7c0b44a5c4660d832949eaa19b
+bf9aa919275db8306def142a4cbdf5689c190b4b9e9d510a319270245dc2
+16e5f52217d490e714fed8e83d29d12c55f7f01e2ad235fd852f2ea19ddf
+ebc7ac1d32552815089539f04b30e775082de5a863ff0365f5607b7bfac8
+2887ef522be1490075f821f4d5ef5ece2687458ac2e87c1d503fbf3795b9
+47ae1ba5d480635a873473d7551abebec664e312e7b242f60c471eeb4e88
+b86d6d27d6d71a55196e112a1bad2d00f428d7258ecf7541a70894b2c812
+db5b402a617cb11d25510f8ed3109a74271835139e732abe651d81c5cfa3
+52703ee63da6b2dcf5929a3724c661f23e316c04cd73a3a2072f56390b79
+a7500ce8575d6fdd9221b5347ec45bb7759729a220a37b6144b41fdd5b3f
+12d49a9caf57421edada1a5752f216108d2c32e40f5cab75fae02f7f3b27
+2834e35707f4788f3c70190d486b5b5baa19ad85e3f694abed01aeab1f05
+2a7b0b54b2531eb9cb1ef43e53eeb0f5969812ca7fec824a63bd8fbfc78f
+46adcf490959cdaa80dafecbc397b558f027a97de9c3fb9b55ed5fde50ae
+324323479715e14a95a4c955116c967c7bda2119923fb71f1f1021a74f1d
+69d17e1ab09ec97586d63f267583c43b22d528f2b57c25c53e4e0b07bf8e
+25bbbf3477821da145bd30c01373afff39e2baef768e0425857900d83ee1
+dd635c2f317258a2fab349a733300a24ada26a77464995e7e0bf2c24de2f
+cd756fba3610d79b0f69be5682362fdb0dd6d159b27578deeea4b892db05
+55f50cfc5390f24fc67ddd9035f72675329677af64cff7b051a1a34288a4
+9ce551925ab6ec27b552fc677d566a2f18c75ad8002b2ffa6b0ec56d20fb
+8f27087eb5ba673deedbb7f3e588c740f85682d3ea2ab618978f7037f659
+7da162957e953a97236acbbd757ac4b73bd8e60d34d178102477c0574175
+28662b96fbecd33dd786db3773f3771459fd92b1e25a149601d8fdbd7a6c
+f1de6aa1a61da61494f8c7a8f8df88b09c72a9d70a51ef10704a324e8756
+5fecf5c04e72193933506c7a0b3d55a6d59e2c6a4ec96ec0070deeaf6abb
+50f0d29fa90b9523fe30374b73444bf11dfa093827100f92fa75909a7fa1
+107d966ea3f4ce988cd246845975e87332e5e277e693f0588f2ca55c1e06
+8b1a6b5e2914a40743a964c92356393c742272e9eec81ea0fd77d8ddf90d
+2a48f011233c6b0d65a1398bc12459cfc161bc15c22ff325a0aa41b29d3a
+0c652a52b449502683b5a11c5a5072af5aab99ca2e7b5be106b03f066826
+5b2bd317ea19358bb92fdad766daad1cf9cbc8c81d33da27c41b0be7c252
+378efa2dd77d639f6eeab6e738ed470c5a9c2ff96956aab708cf0129f182
+19a5599cef850ffd465071e2d44b2347d401f82fade624e4dee38b0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Bo00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F6 0 /0 F /TTA5Bo00 mF
+/F6SB7 F6 [183 0 0 -183 0 0 ] mFS
+F6SB7 Ji
+4336 1785 M <0102030405060708>[112 62 101 61 113 80 71 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Co00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb220616fc35b8e91f4411
+2ea3e18d75348a1b570035ada3ca7681f0d5845dd9dfec3cd6f29f9d0c50
+ad262fb16bc30f7723e63f783c20889eb90751dc023bfb4ede4165eb655b
+6163541eb0a9d146f382dfcad00d5398d12bb905725708a55921dbcfafc8
+fffddc36649a4d606ea08acc886b1ec07e6d5790eb9723c3b8c8bd327929
+5acebb70c048f1bb55874dd9bbc0815f7617c4031ef813c968dfb3b69a59
+12039471551dfc475d116d9f62ab9713c351ff48ffa5a9b6c0602990b34a
+985e118ccf9b853ec6313649c6ddf17b10ef6ca51360a0c19710daa58695
+4c14858082820bb3985a8117932627679a0ff497e1724d5b0f0994bca28c
+3d9b57615a601a25cfb1496187e3697596c87670600397a0b03d87cfe888
+e5ae783f0ac78a0198392285b47056cd96dad15fa8a95954b0d04fb1cc64
+c39402320e2f365dd118708e1c8f9c0019f4ca95d3a33bbc5fc700cb2806
+02b2b4de764f0a55eebed1277f9b5c71caf3f119ca24285d2f736386aa92
+a2ca367d9a6b3201f578278a52ad274c4478fea87dc93b97df73cdcc7a2b
+b55205f2c859608e06cb37bdf8f2be8e75cf505eb0e77781e321de98f410
+bfb42b5fa970a743ecf7ac2a3d8e49c32db746f11b0c52f823e249843257
+48412382bef94b64cddc4841d3c8214a8e56aec81c12e9d5f456d1641c36
+c477ffc722b09b1b8fa301f977ba6abc218f2fbd39419917d82bdcc1a5bc
+4f781865006f56faab8321f0e3c9b4e358a871dde55e36c46a402005856f
+4f83816a420730bd83e5d894fad1879bf93f10325a8830777decaa17d3aa
+1493a38cc7684235778bdbdb719f1297b854156d101885b96e98b7222c1b
+fc11cfc18c25b03a173b05d53c5f4385aab31a2864f702402ad84ca18eed
+c09937a2b31097d8b07ae55b8d1038a7ce9b3c70b6fc88db42d0bda799fa
+fd17d6868c14ac40abd445c91f03b5b3a13367024e0edd28408aeb40e05e
+732a268432a78cc7095b6807fb6d97562db7fb82b53277cc12062b50b480
+33ed74b2b39e9f35727a6cb20a7b35c92be650a1bc35252c7761aa55c6c8
+8442073108bcdb015fa7d8fabc5ea6ff2bd0c372403feb12da4ef9adf970
+6efc84b2a0b531345ae34d9d3699feb3675889d6ed757255a911d766f0a4
+dd34c57301bbe1265e3883c7697ff7116c5a9cff89e8bf96cb16513a1e86
+f6b1239f76daddfa3ed680db35a2881d3fa08b9ba64f09d1971958ce62ee
+de4a1c4f9e69ee0674dbe1ec200a7d1d76c52ad7f5025d5f812273f18ff8
+6af9f5fa5bff055c25c590e50fe8eddb3feb6ccd8e0d9fd0ac0916658f5c
+0a618bf4cfdaf2d1451f29869de7771b66a4909f7139825334d97db11f15
+a9359cc2d5012c57fc9122b248da66fcd042370313d1729e9ae288203470
+1b92f8e155c72aa48e38f01dd3651f516effdfc5bb75d612072f7d02aafc
+86b606522e2a5f952f9c62762b208b30be4b59130b141db083f35a9d315a
+0578a98ed4d0ecb7c5bbb7ea94d5f66568e12c754a1d91c199c8ccb95299
+c4bc3e6e2e3ffd9384e9bc392900389dda064e849fedb5d38bdddfafd0fc
+7ebaead7941293d3f85ab533a79fcc2286dce859b663142ce0b16a99750b
+e0a02cca5a6e4cd7e0d46fd1fac9c833bbbf33d307c3741f54ab210bb4e2
+ba0077d05abcdc9334e07f77dff7cf6515f2418dc5a93043d4777ac91af8
+f4cf77a24e14042d3046797038b4fbfd7d430563657ac56608c6f98b3769
+2b75a71bdc4781c16bf3f738a1d3ffbd5ae9e99f3c691ea52f311236b669
+d7d0689268d10d2d90ca9d06b88097b2d72ea20c75109f87768b2d489e67
+2330db7f78701b56cfa5e5b02eb6375b2df4e612630504bff664125a0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Co00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F7 0 /0 F /TTA5Co00 mF
+/F7SC8 F7 [200 0 0 -200 0 0 ] mFS
+F7SC8 Ji
+4306 2012 M <0102030405060708>[122 67 111 67 122 89 77 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Do00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066cadc506161c23a7
+07cdaf743386c9822f1c3d4f1494deef8094aecfa106d5bdcefc2934aeea
+6c4639fba0af1e13157a96336c8af33c57c65e0fcefc246506268822e518
+cddff1357a1dac1553af2b7cc7c807b2848594a4ec5eb543f2401ec4a3aa
+5c3198e4b670c8cdbca93390ddfde52b91b320ee408da449cdbbe4b8a5a6
+9160a65140185ee849eac0bbedbac799f4d0a8bcbb61f53c0a60fa06e396
+e2db21c286f13dee961e86c199cb40f7b489412d0e75822c3ebe0db17eed
+df59427be23998af0d97ec9f6e15cf937e9aeeeebc5ac671d2ae3d35819b
+1d21b24d78783e94bd21c2e3f61c52b62d334162bb9a14504c229f656c89
+872fe3863d2e9b6ab97a470713023e22e8f9517cc057c317547c546577c2
+9a4a39657b10568ba08dd8579b011d4bf5ab42a847852edc43d265df501f
+05326c3804b1fad0ffa31e7629b54edce59163ad88f88804675e68747d16
+6286211a0f76666185aec30ca45784112a93bcf0ed930a554114ea2958dc
+be58bb93a657e161193a0114f2d16b2ac7418cbecdddd7b9afc10673c246
+c814cfbbc49e88044ac141baad415809ee06676d000c2c7ac663be935b1f
+04bdf1e27fe903d292f49ed28429a6a8750e734895bd4e681f33f7e0e615
+78282e452fdefdcbd93b89248f3172b927b1563a4b580f303f294847beba
+b5b8ab0693692817badaa8d4ba9bd3a17c5b0db7f8c36f52f388261cd797
+54b5bb730849e083e1cbc9a0c7c4597bc0dad77a79d35fc6f4e0ea162d68
+4fe21b3223dfa8df1137cb37a8bad1f221f869428f779bafa584bce859a3
+646ab50caa39997b3fc3ebedef9109e7b32efd180b3633b5cc562cdd7ee9
+68789ac1dc8a27261c09aaf09f69c61ee63c380913bf4baf6944d8166a5b
+54b8ffdf78fe6875854d17898d53f0fddfe5f913e41f9657452f7c93805a
+ecc771b74975813179e3a181d2f7268c6adfb1c923067e737fca7bd5c060
+c67755410ec3faf0265d0483f5c66a31bdb89ae87239d3bd8bd49b4be079
+2565bd4da3eeacab81135a4fe96733e47faec3fc5c1165e25a5f5c19e24e
+589a1ba2cb960ab30bf2cbf442b12c3a75d752b8cc667aeb891f34329e41
+e6a35cd058c9a5d8d78a6bd7e9687606108239def2530636fa2a02d3091d
+8abd4583482272bf522b3ed2eb217f1c209621fd8eab075683819b077977
+ddc380731182d2d34bffc8f253ba4cdec4c054bc489682c39287cb8e3ebb
+1c49c50617994d8169ce00e67f617d5ebf7a7c5390a3096424bb3854294d
+a66805215beb03aa892ba9019872ac2c3cdd408b7a3f4d9ad3af3cdaa284
+bba725d0d16636c723507f53258a97d77cc8f9dae0eaf1dcb7a6f58c0bce
+5339f3cf6c1e85164624363e4b267f471170d417d307080d11dded682cce
+378cbcf8fb1f98a78960b4a37c917346fe6da893d512ad58b1f33ec6ee88
+201aadcf068877609c68922e6eaf21524367ed9cb711f1b4d225ba8c6302
+dcd23f934979a2cdf99e5f99fa661adc0117169415a20660498de8046bde
+1bf97171d5a06cf380771f4b0356847bf466fbc7ae3998fc87ccfb05e624
+1179a30746391da63a4e2a19a38680c7a5e276ca15712c7eb2afe8430882
+eabd46f019c882f82fbbd86195810899a0c676b9f322309d945cf5010cb5
+bbce1a15392d78c20880a4edf30404c1005656b0bd33dc31b1624ade0b5e
+ebc291cbed766f163e47554522396d59734bc0bdc46f207b9e9b62b94a14
+8039b5a3ed8720863aa1d0774c2738767018cc6469e35aa9f2ae6409842a
+8d18ecc86eb37249e60b6056542f605e123c1276e606b6ca246111b2b5ab
+1ee684f1c915e1b2a8b783e7138f7bbc48542315461ddf686d17970000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Do00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F8 0 /0 F /TTA5Do00 mF
+/F8SD9 F8 [217 0 0 -217 0 0 ] mFS
+F8SD9 Ji
+4277 2258 M <0102030405060708>[133 71 121 73 132 96 84 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Eo00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206689a2c7f31f86d83
+ec215dc15546bab381b4f0b8cf598b3de4c3de3f6a106e539cdb0f64c685
+e8ce98b2286105e954732793d04f8c77bb313fbaa17485daeba6e5c4f6f5
+d01696085413cf6d9ad5a061c2eeb124bbb8b99bc879c0521034f10efed3
+37a6d5850e031ec2caee80822c71fef24a88e5787fe50f5de916d2d6a3a2
+e380f8898b9210c3a198ca0f76bbedf8fded493125b69a924475869668fc
+861cfc389477f13d02bb3d0d067c2e164b56613d248570c4482ef87c54ef
+4d4d50dee5f62984f8581aa288b09bf7e231e844c7f50e25f78f7e6ed700
+18dc53b8a138090dc053e18ddfbff6cd6d885a3703a59e298001310379f9
+be660008ea82c80f1447f0a7945d0745faad0b0830ff465a65c587c5e996
+95495f5911387ba8aca425ea35b80e043de79bce76252042b0cde47cf891
+4efa923553835ff41a7b627bf6123dc1f6206fb88246c428e4983733f82c
+fcb24f89ed1b6607ec6726f43950e1a20ae46bc4181f0abe0ea39caf020a
+6119f6355ecb87c1b45b72b4af80d27a3801a6e1fb792c77fe9db23d751a
+0c0c62f748e06896b179fdcbbfb2a8ee05fb52f687f43a5c018505f0649b
+5f257546b1037a8de164aef8fa06294cd4f6e058aa2f040c3cc1e6440341
+4fd43acafd408d15070730b8d5a49a1f524d57a23730fd79727c21e905f5
+a653c7bedeeeaeba7382fb9cc6b703f29f89ac4da5f8721c0752c884473e
+c3f30e16b7eda908f68fc34f96f25faa76585ac41846682c52e2ff9f40d3
+3a61fddd2ec477641be661f5bc7e51018abde3e7f3dca6c64425c9025bbf
+7577dc758aaeb5e3aeddc592c365d50985ed3d387f80c73b28185997ae1b
+2e1a77b025b36f91df6ad12be854fe79727317fcc10fcff99549233530bc
+22beaca0960ba7e2c092be4e9af0f630b6e7f22fd0d30c1f21cec9418066
+eb5e81abbdcfe85696bfec4cc7746886880c04eb0b333a42fc1f077dd7cf
+7d4d808e690a15cfea75a4998c592c52967a33da837ae0569142330069fe
+babc011d29826fcdd1d64a2cf3112b20d98aa16e1b4d1574bd8e124bd7f0
+169c402f37a7cfc53921608cdecfd58447b3b98447edcbf69e5c5ddd2c8d
+cd73f297c5901858a9552c530528872bbaf2dd6215fe304cb767529af72c
+67b145b0ac5b1308c855a307bd78548fcfcaa6eef3057280ae00a90e0dd6
+fe6c0b5d68783be52dac797c2cb6e7243331d7e9ebab2beb54d02a87571a
+43fda71b3e15f97b5c965bbce78ec8e6efff04ca44fe2c4aaee2d981f02d
+af6c1a696b6c86fd2b8ebfbe5b3dc92813be6ce95a41134640e27643a851
+55ca711bad0cb9a26482e5a8f6ca3b067e43ad332c21c148b0ed92d55bae
+9ef93397577adc025f36f6ae10d59caf488ee9b6d6bbe3c55b6447c7cb7a
+d26e7ebdb2992907b685a7e703d3024baa3b0787e89de76fea8b46d2b473
+d6733b40d4e41923d6b923b190103fdabcedd8e701ccb843a760aeea1096
+212590c5a281a108951ea4cdbc2e6c7114724b5c1021d593605618a4d7fa
+df5bf17a2e5f267bb62ae421b46d3edb9f8856438664637da5bfc861128f
+c5639ea03dc7290c690436bce7820156c0be99100274f97054877a573ddc
+9c0be5dfd7cef8f7c8aba68ac05b9ce1b81180c001bd7841349c9587ba21
+d9b158599b672a7c42238e7eef628da1a88b539886a6b9f6c241a53ff44c
+adadc01d0ef7469509c740afb7fee4eb2a75ef8e78072229b90cd292fa96
+6f94bf659328d23cc7f22253a06cd3b0d2db36646f58084a622904a66fe7
+9b6260f400bac49be0e74934869dca984af60e898905b07ce5e37e729c0e
+5806c2b93ef7a09edbaaec50e5e49e7f9673a9f463df5eb51feb0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Eo00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F9 0 /0 F /TTA5Eo00 mF
+/F9SE9 F9 [233 0 0 -233 0 0 ] mFS
+F9SE9 Ji
+4247 2523 M <0102030405060708>[142 78 129 79 141 104 90 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA5Fo00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22061485d7d0c2a6275d
+8da901d4c90b764c07b7b55a308444fa1e7a528df157b5f3a3c98718c51b
+b8405ef3fea9ef7db06034e263d395c70f718a4b588bc1590b987df93e7a
+72c230091e534b07a2ee7b4cf1641847bfc6d3721c80ad7d67f7b7e7952f
+5297e4c939a240bef9367734ebdb25f95d2e914d53ed710482d6c0ef0e7e
+a5d569ebc4ead0daec244491f71d5c6c5279d1c62599dfcd2e5b8f1a98c0
+883cd198bd7c7cb5d8583f6eb5bdadc1509f1e07e8a60fdd5ac1f91fa8bc
+bd3db3de11f798d327c54f9bab256e9b64ee974c431c601574ba9f16f705
+f849859f9b81fe926d3ad64dc715c4fcdd03547669c72c29ff6d9db7ba0c
+9c8eb6ad87836223789881c8c054a785683e679ff620f747733cf8a65f41
+f41804649ac29633168ee70c441958e03b3d857aef37fe2f4b61a4356640
+8d39bf06df627a1cafbec8c90cd5d4b9e17ddbc0ef8b838887991521beec
+7745da33772b5f1dfee80a89ef3058868878ef1abe7131a1a337abf0c241
+12546185d043c9a89bc0790368cab51d11bde95d9f893797a1bf7da358eb
+b681c63b922a074a5be052b91f0bfc31090ca4d6f266f70f4f4c27ff2774
+475b69301570f64e2a775e961246ba51d1ef37716621dce50b155078fb60
+cd81d9c133641423778e3f899bb102dfc5f28f20894bf5850e57425324a5
+7adf1ee9ed235f80dd53251e24d53992b184dea9bd5644be6d3c7128f61b
+469e5b03866cf5d090fb847d437ca106ceeffd41a20c2feb6f018fe69b81
+d2e1bf7a084a6c95ea8f102ad81b5e02812d7c36395f11ceb3fac49adfe3
+f918e5bcefe4b1425c469dd7e3c57de7a680d6999078510cdf1a2741efaa
+af2995071314fb018448d7dcb5109391cbc69507d206d6eaf1cf74b28403
+00aaf32adeddf5070b80f9831083be56864cb84d7c80f60df6d1f534dd88
+90245a330c13b34b0b487f7c126489e4faebade7b1d12ffc058bbf48baff
+67fb0722a453db48756058436e565969dec48ad212ff410e07d51fa23d54
+f180e530efae113004f42d300251c04eda6317f01db9cc54808622ddb708
+2e4238aed2e5aabad836d08a599bb57a43faef2e1f3e4cabedd2dec9843c
+2eec92fafe755341b5c2b0aa3fa058da19b178a041ac3cdf161f1df3c506
+110fdd73c18af469090aefad97f6732e4478506a901883d1809359513d7c
+bb2aff861ff164e85a79fa1fae05fbcd6c4b3248c4d7d9dcf3ff4ea043b0
+9e9a8b73f108ec6873d7de2af19598798a1e2948797270ca9d680070b2c4
+cff9e32bf2417a6813098943ff603482c834a38ba8d10b16a26e195b41f1
+66dc801fe2ff73ad06165e3c48281bba7c5ac6c6c09774362af43726f85c
+ac8fad3dccff8c7008a3bf70265abe55a724af89b740b3b8f464ad66db80
+06ff96f44b70a5630729600bf74ff96218dd3865fd472776f0cc56bc02f2
+62f60450c4041afbe70d278e7fe87b4956c3a414c9efc1ef733bf317f984
+644729023b633fee715f438df1b36d5f021bb0c018b838570c1ab4a47378
+6cf297596d0831c0ecef9dadb1ce6f90210c8498ddce915d60d9d0ddf317
+0415d5788b83c3883ff9968c9875b2f8f9be67d847b07a4143605e9cdd26
+f84486d0d8014ce92ecfb99bb11ccfc40efe0019383cf75e02f132b9c552
+6da2286619ef4904b9537885b4fc108a295fc33213cfbead8cf919c20b7a
+42e5d1e389899e132428f143d5ad323c4890fd80deea0e1133dd64149eda
+5ac5c123e24807ecc7ec529e5b5fe77fcf4d199f4ac1f2c37fa1f70e36f5
+a52faf5e28918a4dec9abceb374a2167601194c2b5b44beeb01e3203a82a
+0378af4be9359d36b99521b6b93da7a297b1dc05c54edaa035b5b10000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA5Fo00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F10 0 /0 F /TTA5Fo00 mF
+/F10SFA F10 [250 0 0 -250 0 0 ] mFS
+F10SFA Ji
+4218 2806 M <0102030405060708>[153 83 139 83 153 111 97 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA60o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb220669f64824a95af9e1
+b7462e8101f23040cd414ad1ad5fc3ea20cd2b3e75f6ba5e360e7705bc89
+b2e3bf9d3e15ae90366dd842e27734d8f0e0c27a6a076b2c59fadff0ec12
+8400f2a8d05c969a3b3817ad9f981ccf8ee6cca8c5236ec32d047c5cb595
+b4e3e2bcdb983d7b14810f4c5567975b7decfa08dcb923d4ef76014e6ece
+7119e297986961f7aba4ad98225ea6c1ed25b02f4a2f325595b8cddd4d10
+085bce5d2dbf77aa0a40181d2bcafae4abe0b0128ec44e173da86ed26fd2
+b266135f3566bab3a73a2358120237add2d0efb4b62380f68a275d6ea766
+2305076aabafd83c161527b9200a8c64465680e8d626f3c9662f5aa9927d
+69882070a476dd23399cbdf49c8f6da83cb53ffbc2ab9189fb529a614652
+75d93d4a2af2a4bd529a88a496b70b6abc1a72d91cf0087faf95bb6a9b12
+a1d3f5c69427ec3b5117326196458bebc4a07bf2ac9228381defb84d565a
+104d1a6587062d03ac3c58f6ddbe8979cfa3de980a675af65c303b63e181
+a015445a27b3cb04b1635773e8f0c3b6c95b8a844b69db30b74ee4b6f1d3
+8c9439aa9754161e65b5d4ce67f0809e34167542666410a3f9c56253809a
+8dec6dbcabf721c0d5ca6261144924a302842e973846e6f6f50494bbf814
+4049c7cfac9be4774d06653114914308033c25e328af5a4ab42541699492
+fdc3cb7a1c287c3b623230b9f083ec48e34f2857a7bffd03e90700183d0b
+0f8310b4ada2d2064bae1b46c72cfe83ad9e0e818d1d0f3baf70c228817b
+9ec38a785de8d17ba5093765b4bf6c22d6ba40a9f9d80eadad352b33befa
+92a99829ff3f7d917dff22e221617c80860b8057a91ca0397ec4147f73d7
+7713b73da270437a982c2db0a0a45ea60d7108c3ee6c998c56999226149e
+dc27ff93a4562b508c2b2d36b7504f4ccfa9f27c57aba776456575e451d9
+510ba43a472fe0cf34cbca5b5d83b4976d9390b7fc6dabf21c227f4963c2
+24f01d8f5ce06ed8e31b293a57a762c62db3ae155710d0c792a78014ab1f
+b0d4ba14f48fc5c0150aab1cd18e90e4a1b826a36d25a13d61a73e353db2
+ab6c52f562b648f98112997686d7f9cc9b091e8780e3bfe7695bb967d0c5
+9924aea5d79734572c3568f27a4b53722882803cccb3eb6bf8e71374963a
+3a89239361796eb6432d4dc63601f05b78a250ce6ec031c412c56d5e243a
+7ed5cfb66b44c571d5ecc8b5be209ae1a00acfcb08d949bbc5c382e3de92
+eef300faa0b505282e9b58e82301f42dc79752c3673cdeac3996534c25a9
+56ac8bcaabcd5982f6cad6b059332ab3b7dfeb8e74c4a6fcf11f9f7595e8
+6be17bbfeb1d1f4e1552f684259ef3bf25443dc82c98a4e5670a9da1bc38
+1daa61f7e58e768fb26ac57cf76c1854ab05917d6e3f366d241a3118c31a
+b39e31597d4f8b4591a5725ec081d83ad3c9229db25a508a9fbc5030fecf
+4b86a246d210caf9969a2cf191db0d4ba5944d0dec317f71a58bc7654817
+e703e9af9eb4e6941db44b1344e631067ac9301a3b5639ca77329a8a733d
+e53350ebbaa58635ccb16892e56162a564e59ba132f921477e1bb7f5b84f
+6d9a131024895857a972d3dd125fa7ab1492486dbb3c219b989cdf51f557
+c15999460b08993c599587689f6af0650574123a6d97e293acf6f48b3f84
+2a159a71bebc068ff5a5c890ab433080e70a734d75f2b1a3c4c110f871cf
+8a1a31b8491a83841e02734057361ef04c844da7cb24ab011ccfdfc7e8c0
+5afc3cc8e268965810b6d6a441e2076da2f739651cae11715fc8409f735b
+c4c553c2d12cb4744a448d135031effd4b5b0611810744e162e8b81d512c
+63faf3d2c4c02803cfc42511419ed72b575a70ff89e1e8cdc387ff0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA60o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F11 0 /0 F /TTA60o00 mF
+/F11S10B F11 [267 0 0 -267 0 0 ] mFS
+F11S10B Ji
+4188 3109 M <0102030405060708>[163 89 148 89 162 119 103 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA61o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066a6b46d2cf1e31c8
+8c173203a6107d2397cabd68bbc408288f57dcdcf1ba25462a21c2a280fd
+4872197251257cb1b5a68147f0eab49c590d0fc4f101316f75d4d0196e5a
+ac34d7d2e9511628ac0fd24e6ff645e5c987e3cd80b41ff91b50316539f1
+945b229cc2b0fd7a67a73172bf84134051c7dbf945bf36c21b55175b1c6b
+b36f0672f5737fffba364f88ea1255b73fa8ee6092bff85991d33cdca1a4
+a4cc23e5faf71e692c5041decff1e6b04eae13e98ece29596770a98c895b
+225dec5dd89035c2f378a13bab71727eefbdc0cbca7c5ef8cb35ce7c1e21
+a20987e02b1872227ac2149890a99f33e4c14ffa2a0f7f6af0b4d8d559b7
+7d52407f6fb4707a7902fb4d0930e09b142a87df214434e7c49a95b20a64
+91cdd7994b2d38bd136500f36657f6ecc27d53eaec93089e292291d9296b
+891d30464a04dee7e4c852933e00e3309305809538c0c3b9a9edd7626aaf
+6ca17228f379260e938512ceda67808ce4982b30312c8c2473d4a1727cc2
+742d35ab6730e4a615192f13708fd9c9e9fb65aa18e78a1698d1390dd1b4
+8d828d743ccaaaba22181d326cae273cfea381ae1305943dcd8fccac4d04
+f7a53d9dc5f61d9c6b34f33c79abceb357e6540cbe4b49b0cfce43f93f59
+8f0efa3ab63f515cefec093c13ec8df9b98f4502475bd4859ae19d8a2a2e
+1ff887cfd300ad50dc620ba7996ab2d06a330c6004fedb3d71958efa0451
+176c4b1e3afcb48c6560f0e4fe8a302c7bbbd2fe83a4bb54a114a1883058
+48dc2965f310a9d6f4ee9ac19a486b987fdd9ff596013b708e29af08ebc0
+44dc8fa57633da7ec675fa00a692161401fa16244c96460f74549e8daebb
+940f454dfc96316f14ebd9fb9c1d86e487175c282f8c5b3008e378695789
+fee70e0ba828400cc3fd62f10bba3e50ae17105c7189ce026e907621fd87
+07a4cd89b4516b5af98a1addbef0ee4bfccd1f306835b2fbe716187f3570
+5ebfb0e16f98cd24a78c82434903f09e5b0e78c02a43d38bbe6f221dc88b
+adf8efdb08e0ebe4608d4f4392d4d9ecfda871039e0049f0881bbd5722d9
+3d3f784c628ee9910cf824854095a75255953ac6376e83dd085b6741d35f
+604b09473df889906ecfd22a9bc759cdc9d1ee7abfc75213b1d495e4663d
+4e722b58de4d50671c19cbc3a4dbd20ed5e0c6567ad69a0c5203a619ff58
+ee3ed1a9d77f10d64a36ba6f89a629f9ffa2a4f1fd2bf2affb4204d5437b
+540625d7daa43bb790183fbf524d914ac18817aeb295da7b40b97d3d4b89
+54977054e0ddb9e00c4679651b905db04b1bbcb4017e4a666154f3c2ac92
+5db40a171cec499af9da1858234e5e15c4c6590c5b2eb366c9d11b3ff86a
+937e896a0b8d42e1aef576893360709ff76bbb3baa4bee49dbf2f56b84e9
+d2ff6ab36add7128d2864d0958598d86c99eaa799662120463dcfe373e94
+c803657a95a5aa31d66e4631f1a09f9a47bd8b287975a71b42900bd8699b
+9730e1bf655c0f68dea05dad22d99852e444d801a2ff17de73e9ad49a996
+c6b23cce82b661b50776d1be87cf5e16c7c88302824f56dd9eb5ece935f4
+f9a43384878fa1d5634f727ac6a6dbadb51afedcede5e3832e91dda9b171
+399d4f7542589aa47f800feb7172c33a426b58499488facaa1a51ed5a8de
+3acf21da23664db141de8dc183042b73a96ed18089c0bb4a890614cd3a2f
+3c4911c131221865dec83302116d31ad9527433038ffc8d0f96f234ef5e8
+ac69c6d1f5b9aeb3f4a0bc248700ba99bf64aeb07bc7f3f368512c77aacb
+5ac234f9386079b6a20d9998967044c40a948a9eb53c6ba443c39797f1b4
+c0f6d1903d61beff8fbb0ff303f0217db50d3bf6b4b8fad466d1ed0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA61o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F12 0 /0 F /TTA61o00 mF
+/F12S12C F12 [300 0 0 -300 0 0 ] mFS
+F12S12C Ji
+4128 3447 M <0102030405060708>[183 100 167 100 183 132 117 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA62o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb22066a6b46d2cf1e31c8
+8d680a80f464f13349e5689a189f13dd0689e85869e2bbd27eb19374eb38
+071897af922bc3f8ff6b7c3fca4ab2bbe308e84badd13a5b927c626da36b
+1037fa38a19ada6ac72cbaa7ce1cb85eb111d32a1ef92b11aa069b0a273b
+48c617c3358281f67bd01a76b549470528570b0c4d05b950a91475fe2981
+7a0c2bb0b286c50881f2f950fa93bf9806ec786b46525ecce59f4443e75d
+5d7985890e7128177ef8e802f1813332aa8684a83067f590407c2dde2d71
+73e14b887b636aadc7fab122b657dabd4046c48129a3af1103f40a16259a
+eddaf0f051e1753a1f3e3689e35deb19a06b2f3b85dbcc93ba0d60c5ff6d
+68160e7e1c576a9ffa0ab3bfa64730821ccf4ea1fc95e15fc102c355d570
+338a9b5072b4ccbf1cf9392f81cc77cb641160315c4e0633ba976fd4745b
+687108d2dcbc28a4223c53f842f8f3732d98ccfe0db81dc11ae752887cbf
+9b3a755f12ce22a69d74d5627e1cdfe96f7b6170185a428fbecea6dde1d4
+319929e215abd940ad9817fbd2dafbfcf71a02213753bc2f771deb3397a4
+52bc2eccf72e56e569d6c9d14d3ddb28217c69a621fd8f214394d87cf834
+3f530aa72a28658956515e3a70acdda0f82ac1648b1522aa1c30473fb36f
+b54a6abc080c88bef7463200bc3b84fca38f4d5e1e3fb1f8a7793a202cc4
+44b5ac108f2f5d1fc9330975186f2c35636f0eb5e5c4e8d7e20ec2407ba2
+0ab60aac449ae735447a0bd83c9f649a025f215ca3d2c0a063233d231c80
+f2d81d46c475c8eac6103d9711ce1dd986645286fe0a7d6bdd0b854799c6
+2078e169bc4bdeaf54fe41e9feab27467ea91ce80a9ea2526c0305727a5c
+1f010c7bc04e3e1e2719c2c67f2beec0d90c6248f7062d3a86223dbf2f4e
+6dd858ad111e2fac402858eced9ea7c78d239b791f448448cbff2b9b8fd0
+d7d373837195d94f69ef6acb0b58825d45f9494231f949f9338ea5ac1fe5
+e78a485fe2d456bcfbfc77d6875ad95413cc0b05f2fd0b1d5d87bb45adff
+aa97135b0699ae511381c1092d5c9f658f33bff078fdea96425ffd5320c2
+675fc8b58b96f02b8a63c8b0031843430324f55d36c42d9e4a242afffbf3
+f5f5ef2d79584cd9961d62978d8f5b5ab9394b9ba4e9cef9befe2c720a3a
+15e7a4213221320284bfa64ef6eac7907d86a6c4b4a25747ef60d73f889a
+5fbeb0cfcefd06df792a9221ea8d7a63d331c8c120d95b148eff4395527a
+cd9279d0cfe32ecada854c38c85dae0bd54edc6631aee3a5c563a5553fe1
+487e1b6474dc60916f5c26baf2f306695972475809fadd8178ebe0b3e6b4
+98995f5e2f34779a6bcf317ff8e18af39b8ea02426259c38610fa7d4b994
+247e4d1a70374fbfeaed6fddee1b0814535125d0501ee6d5852181262ae9
+c50e8e99460ce2a96929e426dccf8cedfbebcb7845fdac62512145a65636
+4f48c63755a860ed7f0619f80ba6d057960d0ef012c5c2e8389a89e5d32e
+b8a80d3bf67ef8d84d2c2ceafaaae987ec4030146eb511ad6b2a729bc2ca
+f48cc2d0534b88bca04cd2d60814a46528d0e5e02e933552f1cecb6c5b58
+8fd53c5a53f3092ade44eeb11b399f6a3b90c52fae04861e23ef6d113547
+56f5ead2292e1b05a3fb7c85d6911a556f26a22c15a58c3fa5e46886bae4
+8d0a6baf057d60f763b1901866542e20425cc12e0203575c7f133ab80ffe
+5b222bb798ea64c93abdf1b85010d562e35b3f24064614df3942d90e6c83
+0ed5570bef45451e1d1c5fe32cb9efca3ac8e3a6abacc7c75c02db4ff81a
+51e792507e2d45b4685f270e703d63e15e0c7dabacc30e7ac546fcbb588f
+1043bf9214d0606f29b5e11013bde03b272216c8f7e0b98f8ae9da0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA62o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F13 0 /0 F /TTA62o00 mF
+/F13S14D F13 [333 0 0 -333 0 0 ] mFS
+F13S14D Ji
+4069 3823 M <0102030405060708>[203 111 185 111 204 147 129 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA63o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206158487fb3119fa92
+a8a86034818e39ec9fc196fd03660d0897479998880acfaf10dbf270706c
+28fa707ce4dad00c8e93cc045f9a10f475da3df377bf5ded23dfbab06e55
+cc7d6cf560ab7dcb7eefb7cf36eb09d88933abf76e7e0394c20619811a51
+443bbfa69c436e08988379dbefa860397a3f0d85b5036475ef5b3ba59810
+143f3e33c935c2c9125c1df9354d17924ca77a47a34ec1c15611c5ac9f6b
+56e9758d7af90235b8ed96875cb14e2323abefd86a36c74bc59eeac84fe0
+d013f3515cc05c7e5f694e9fbbd43f931d6afe14238301aaad0a3c19b198
+b1efec19f875db470cd5db8b58d1a9715b2e1082fcb22755ed511d03db7d
+026c3e0b9897db3d94a72b9cccc5a6460baa0834eb22c9cd4a783353c578
+013ecb0f00144828def066ba832978414b051ff879bd7aa2b1e60ed7b068
+7564600d3b11ee13d514044212f44c470186e217cebcd796acbfb8f18a5a
+b262054a3ae208111ea1daec5d7c42d978501a3a924f6acdcabc5c2483b6
+9a708086b1f1477f78736e10664014b5f7278c223ad56498da95a4be6335
+a2ec179f528e57e99e177cdc7ee01f27e41cd84d37adfac2dc7bdb9272a0
+7ad37ac91ea2c5b6801d3f62417e87cfad0f483e9bd45e55c4cb4911f711
+a55886fea6300530aef55669bf62569d023c1ddd2ba2d038296ba4b6234e
+6a7fd36a75b2a372f98a1ed02aacaf6506c2b8deb73aff137aa589043226
+cb1929a8d09ad7dfff5312d1c5a3c5a13b48af57c294857ccdfbe5fd00fe
+24562fa7040ce5c75ab6ec8362b0fc8de4e7d7e6faeb8b3fecd5928ee6b7
+95c15c7fde8a021278bd25aa236c5e7b91421aaa11710145547210fc9ea4
+5cad7bf0899e082aad912fc701a087a9bd85560095b9fa079316ae4ff508
+e33daca2e55f687982dc50603d7311a9cbe39ab38a73f5ec2b4fd3b46775
+951c0082b5f434756251fb779103b284771c9be4047024d30194d9c338ad
+2b1958e7137e74fd3cf1753a68f030d1e48a99a92131937a7f494fd3bdd0
+e707409d2eec84e68de07225866f2401a10cdbf19d28ce0e2254161604a4
+4e74cf7c6279d55d39a548121129b619067b8d68db383f32a065bb526c24
+b02ef9a9c354d4def81020323ea06c93d647e6fa2f221b047a7ecc8198e3
+cc5e16865013bac7a20500895114c5d97de0c9a3726f288a42254e2204fa
+14ba9d4fb8f1b4bb44841d3d70a6d754b193d701d66543798ab1d3e4dee4
+9e89b21b31f1c07a07ab948a70bde185c4101d3c9e361eb67c255f3bc5a9
+0c89f81def08d4180b0d5e8d0b212e545485fea50427de790af06413e931
+4233d87df73e012d343f71b3a4e0da09ad443e47b0bb230cb7cdeff909ca
+ce2f15b2e2e1807fde167179540fd7e916b69f0d277cf0f91af017925581
+d9a1d66c86d7834f2af841ce657288cbdfcb6c0d07abdf6a0699fb8f73fb
+f5d08ee287c3ce53312842e813ab4675b0d072e1d152f7758cec3abe9f68
+62252ceea015b7587db6c081fed9efae5da5380a3ecac1f0a5391245c28c
+9f6d1f20fa547aea71f89fcba2d979a0215776dd62d4790f202b36db791e
+ad6e7b6dce1612ca4ac3d02d4aaf9322d34ebd6c37e0bdeb11b9c82bdc97
+5ea90afe2d06ef815b2ed0581666f7e3bc9466a68d51e1bd00c8ae6bb94f
+d0fe97fdc276f28d5b9c0200492cc41d53f21336bb0e660e1b2758da5452
+bf6f0638b9e50224c3073622767433c92a9ad7a79b1abcacfab68a0e70cb
+5353fc54f6987b13d84d79b5d954f7b3603ff942fafc4460564d4582bbc1
+3ca21e59a5556335ecc99f3b78a254c52ed6a79ead46d6280e91a5641e67
+a85529b255e42dd69656fdef1ece30227b328d980fe6082bb624960000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA63o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F14 0 /0 F /TTA63o00 mF
+/F14S16F F14 [367 0 0 -367 0 0 ] mFS
+F14S16F Ji
+4010 4238 M <0102030405060708>[225 121 204 122 223 164 142 0]xS
+4010 4659 M <0102030405060708>[225 121 204 122 223 164 142 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA64o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb220616fc35b8e91f4411
+23fc68c58b5f46a1f1275e177c6aa9c2eed0243cce590e527cd2227f8444
+14cf47b571f571784ce9573c21d7d38a8b1f3b5c5b80564c328122627f3f
+ac24de4871f2b61b498c1035317868d10aec4be63ce71d6eb7894d350070
+e2d3bb54ff08c43ee722e479e9be36817aeb0f94485e836a5e505477047d
+94ef6bb481178e2636db057ffe2bd6ba3de8544935b3d2c20e99196d9bb1
+847ed930b62c48bee95c908968e4c681545cc28f60f97ed41399a3615689
+6de5fdb9d0a5f0abd2fdb820eaad1a8f08dad1b1f440e099959ed4d516db
+48ae31477b68fa2908927032ac27a55ac3cf78a5e7be83075d2065f47e20
+a3a47beb91299bf9bbae879b26794c0e5cb4e680ec7a6dd1498e36f1fbee
+8a4d52c01ae62ed702f0c1f83b39a7129db168e37b5dae7b92d5622ce8a8
+91120de77d44f809ad1e6cf23ac58bcc4b46524801cee0f6fc7c68d33c86
+0d7ff13d43bc160567ebe1da324107967ed860c79364f8e8ad1ad7f0b0bf
+36f35eb2d1ea1fada92cd8ca58106c9f57f5d9ec3562775df931dd704510
+02b9edb700fbe3f89ecc31417ec84400756e2a243bc34393908dcca3c0b5
+4dec679d743a79ce99a4c11236b9738f04e0cb5af2f57ca5fcc258a0a24d
+60805661bfc9dcad4e514d5089a67ed3f9f73e39b2c1e8e0f9a48d7ae38a
+cf0c1822d730ac58cc5ed4094b96b1d42bd7a4a1493f712a6d160a6d71df
+28e64d9e168b21f188b034c1163c75b0e237fcd7fde9216848d62075c3c0
+3e332de3d9078a9adafb3667a456abb812ff43738c70ab9954d70541a0ad
+823bef3acad4b39195cea348d88a6992440ae3a11e65bac8009eff46d52f
+ab715920e8be65cc950b41190fc3ec3eb9710ef499cdcb28b288771a148c
+2c68140fbe14229148989e5f0f57de39659865c5514eb54cf7960fb50c34
+5fe43eaf66c115e73c8c7c344c0bf8af82c6f3ec5bc2d4804a8c30bb135c
+783b2b4d782235e4734c4cda9fccb033396448b2bb417d58a06168044397
+92b816cab67386e1bee2d4a4fe0f1581ab509613c5658f55e769a7eb49e3
+a89a6d57c389cb0882d32528e2545f8a48eb3838b63974e74181d68d27fb
+91149cb2c362e7c1abaec89872358cd66895a6eda09a1fa84c234ab03c7e
+8bf1e84996115a76012491925771a863d27c46408ffadc375419dd7a90b8
+943b79131747572117d6d98eab875f4a70036f7012be1a9fabd106401489
+e16c198b1fa9fa9b5ed0b0445f00fdbd577ac1534112f51510f74bd87bc2
+73929005be30c102d63b7251697512806da51bdec65b624d8391f29dea66
+9374ff3b6eb2b580e2735de61a835243095fea770d56c0643c0fa15e47ec
+3a2ae9c8deecae7bde01e68ac2ec108fe23f3370c2823598a291cb7dcf13
+e8174b1c55f58b1721904f7f72fd3badd8bd0c65694608b7cc260c5c4801
+53e32fc0d340ab604ac10fa5ce26c0d03745524deb9fd8cc7f9a1bcd050c
+e0cb6a842dfed52761259fae8ca2e2ffa8e52fb637f2db6aeaec66c1017b
+64d6432884399931893f49fc96b719c7650db46ef7743e6ae5e062c39912
+5cc41866ba23c2ce5af2dd0896514145a2aca6d4ff8e71d169b064cacb3f
+2cab77b34b2e7b6efa103a0500bf02453e327ddc59edbc07a8feec4d25e9
+dc9d86f7c65bc872188da32ed8a0edaf431cc32abb5672fb61256d55b6a8
+9da111703d609d59f8bf4a34cfaf1cff1b711314b8cd50b3eb61e99b9fcc
+03e121448636749c1289a892ef822771f7637305eec6f2a799ee0f4ab30d
+f3599ff553d7697408c67abad9f8131e141e2d65623d89574472c5baaacb
+df67ea90065c766f01ef39449eff529461df1673cf8d8d818ac87a760000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA64o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F15 0 /0 F /TTA64o00 mF
+/F15S190 F15 [400 0 0 -400 0 0 ] mFS
+F15S190 Ji
+3951 5112 M <0102030405060708>[244 133 222 135 243 178 156 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA65o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206179c29b10360f66c
+a9dee7eaab7087c8834ade2a458dcbc6003210ab90663c579b16d5f2ce6c
+289056f18bbbaa7aa904d32ae457b267501aa32481206d0540c6bba57505
+8694477f31f801722d806719a2a318e17e8430363366539a22b2558b1534
+bba96abc799d72b761a18b2c5ca22c2a3c6303914df51cf07491bf3b7244
+369fcc5da2eab0caee099fbbb0e2f438e76541ae37f9f3d119c621e5a51c
+a572a7c5b40ecf16281499ddc4df140e69be0f21ab05feaa553a96fb69c8
+d9b701aa432358791f0efb0ab57c37135b2c1d1012b3a87c88a1e8a1a275
+3eed718bcc969bf3d5875adb9c8b2200564fdea69b4caeb28e464106e61f
+c5187d0970a0e7c36c269bce3bdbfbf22fd4f1bc331689d1530bb268af25
+c45973a5bec46df80df4f0508ec729d165203925c00b1c73901afdee68bd
+1847b34a10e20895dda626c43113a6e11c32bcd477c84badbe23b0ca40a9
+4f0a0701a2edf14b4c675f538f80b98275c1f2c13cafbf673b46324465b3
+544c4a0dd3800d84bbfef594166bddfe875cbaaa9516fe53048319233ad7
+d73686dae086514c82a1d552d1b8f3a6df1b791fd32a6a283bdd970fd71c
+850f34658e75c599798ab218c3156a8605bcf9d515ddc1b8d0005576767f
+a29d14f78c241c98bbfcb13a5cfab805430803fa2c55076ee34a5eb931a6
+a0662c544d59541670e9590e47ff41453b3c561c78d712d270fceafa35b9
+0713c96a1ef5fabcde661f0989d01a640511c47de583b8057d975c2a1730
+9a663389f271616151f02c0eb8e072251bf1146ef961ce587d4a486c6848
+549f331b2ba7c9088f24fa105c4f2389debbb3c7d4368b838809bd4198d4
+b617b420fa507c503ae5c217e416b927495842333a8e251fc075be16e338
+51d62287e9a272f4843f62241e508b952d45ea728574320b996861f06f83
+5e8028a69dc579fc660dcc6afa67f4f47f94455cd2b29d326b7cda83b9ce
+b204d080adce1134af535bfd59b989a29b9b84e3c73b5f1a87068b892236
+23efc8cb6f5677417d1d3cddd5d367fc20895ab7671d1e997b5f12668062
+c18059ecef3fe26c4b8a8103bcaf8767f1311bc2866b2fd0432208e63020
+f41007d7a9a43bf0a30eff53903299c2d88fd59163f9b7415653cbee5a60
+2c50c607edbf1bca3157aa3a013c4377c3b5088ff717e794ba8949e91a85
+e204ffd57976d7de79e70409e3a6cd0c180455719ed09ebc5888a175dc20
+735e3c69484fec32ad88014bdc0100e62455a6ce6be23b6e306948c9ec8d
+98ba3e89a4858f7c4537908e733840cb3897529efe2bdda4192cae694ea7
+80edfc2c1f75d01b1a9c911e839f0776b7556e85348979159c2c1c9f1051
+141da74db4bed5098c80ff84d5187ca88570bc6f512f9a204d093cd6bbfb
+438fe9d062a41575a6f8a5f7b44f9c82faac321ab9f4850c0803148cad84
+b339e314ffdb7c8dec381e0fdf3c3757d83102e26259909c380537f66182
+fbbf656daf939e7db6c69bfcf79fd281931f02ea1f33730f42d735b18496
+d6d9f08ebcfe70c55d966f671b28e9fd10e1b4151782eeeaf357f95a4319
+0d5b124f60c9a9c9af2d2a3f5c594f00628c46f13637d205428c4ce1dc88
+22e4d41e9fde4b177dd60e7be2fcf8d14d1f99a996ffdb71d712f22a91ef
+8060d241b397dccad9198e5134d69c2ebb566cd530fc7c29a7a70d2bcf7a
+d30c7215b65c686e676e1dd88311cb0d35d2e3c13e5a7bc1df44275fb7b0
+8a801c63f17e987643c7ed845713454afda90c825f0af5d8945429115a8f
+cc65d3c2372ee22d1eb7764484ab397862e8c448479d4fdc5ca1d18abf5e
+6b0b717dc116123298a80f59db58fa03af2027b2efbb59e115c30f0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA65o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F16 0 /0 F /TTA65o00 mF
+/F16S1B1 F16 [433 0 0 -433 0 0 ] mFS
+F16S1B1 Ji
+3892 5602 M <0102030405060708>[264 144 241 145 264 192 169 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTA66o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb2206689a2c7f31fa5794
+54a6cc5be7a453c42c272f1015ef94322c3929a0ddefb938ab1522150251
+fdd9f6b70f2e773d4f8663aeccb0bfc787064307fa1dd2f8bc4dfd5c7205
+d9853547485a8d4f01ac00b1b09d2057d65671f1ecfa41c8223a5108e94e
+eed8977391d4cdf5cc5898097984dcead7d3ea18561ddcbf4d05252b668a
+16e0b09a7b46807271a79103ee35cd33f3f5562733fc8557b69e1eb31acf
+17667bc44a27417541c228ececeab7e30fbda792ffb1d12490b7a763dd92
+7feae2dd8a29c69e1c33dc198ff3d1cfced187c07e67b604ae0d38df8d9c
+f97994f52049867475193872d41dd75f54fd685f66a9ed9804118499b261
+00ec06d93e56caf1ea7fd932421a7b807451acdfe8b949268673a769babd
+2fe767a6b050b34ff782968242657ff47cb62cf2a1616c809340e4fe22eb
+ad2944863557a13c39e581d23eac63f64dfc9276c0341b148f86cc6d3116
+6bd106f158615eeefc789238bf3b2f9ecfdc343e3afe48ff47146aa2af53
+d3879ea5dd09f2a25db26346d5a113284a48541d9a940e9f8b9ad98596f0
+c788a3dcbf41c177bc55bba52512f887b2c5e8776efb804942e49ecfa60e
+10b3e0a6a136e6da02b00b7a95bf805508eb0275a9e243b68c49a8554717
+3a1f750f860d6b50681d877660e47696b6a9f70ee9642d77678d8513fcc5
+da51a824f7a7a163b3416ae572593eb6e32392e6c4699995a1da11cc29c5
+ef52cbe73f49a3159c031ac87bbb2336e3d2618537c01288ad3c11f8f837
+aea942a32f1a9388126758aed7558987937ba918bb20896e46f8b80493b7
+827603e8e11953a56e2d406baf573f366a6c325d9585a36232356c876d22
+38917e0806d2de7624cfb33d7c2a6da2aae20ad18a8d5738d747b5cea624
+0bd371cfd8e59232a1b8f953aafa3065d393ffc28479fcf15350375753e3
+d8d4169d64023ad9200881d358cad783a45a67ae18f81263f801df120e8c
+a9cd4636fd19024f4d7d50d84a4dbef10941e5b86650d89013c4aadf1206
+411b1c84e45f3baf8b5984fa9c5043dda578b736a14bcbdc7551a0fe7e62
+2e5055da5e7b6df296d868970d9589482e54edfdcd380850b2877f30d6dc
+3fb72877575c1851710095b46311a4c3dd769809e100ab6dba6e80f4313e
+6417460d7d99dbb9002e876ece579b6479c49d248050c5530883c07e5720
+b72e1543a51f7878463a760d7160da57b2c7cdda23684ba394f4fe456487
+8e26926386884961ff02a917786958ace479e4d34b42174558ba65e5feb2
+3708dc192d0ee9ffe2fc272aff62b3caf0276f66d18f838fdc15adea9faf
+86c6e87e48c9997dd940d6a3a46063406a40f2f44758df815aa75453a10d
+254f082d5abf98176fc8340a575a47b93d3bc46bbb2790d9fe6d9fd518a6
+fb3b4fe9331f2ba68762cc21c15e4a429217f86a26e802597785c3354878
+653c0c48ae31cd5eafca143ebe4a5ea475b5f10e658ed07cbc1266547d12
+d0c62598e3f3e802e53d0b99164ce825ac5165aa3e9fd4761c5451182e60
+1937322daaa63777230f33f9d45d638d32f5cf61868cbdbaf3b056cd9bf2
+b496a029387dbf63cd6cc636c2cbf3ce0c07e518c521f7b4fbd7b619f4d0
+7e9ffdeec465771a9ca8e9069f52eaa88cad66d47092ac1f5f52be036aed
+d2d6f36153e22fa251aaf8b10da257dd14cb46163723013df097ffd16c33
+ddb8d3a4dd2fc6545550e4081ae70de8cc65a83f220212744bfb58cd2cd7
+29b17f2b842e4138a307cfa37adaaf9178ee510e2fd3d3f43b7efb0ba3f7
+a59e6ebeb4f2a35e908016cdf0383304b2cbfd02769cfd5ac9d8eba752f2
+ee6b8cf7287ba98fd5b2cb0e61647483659cb6b97f1ac442dac87c0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTA66o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F17 0 /0 F /TTA66o00 mF
+/F17S1D3 F17 [467 0 0 -467 0 0 ] mFS
+F17S1D3 Ji
+3832 6132 M <0102030405060708>[284 156 259 156 285 207 181 0]xS
+25200 VM?
+11 dict begin
+/FontName /TTBC3E32E0o00 def
+/FontMatrix [1 2048 div 0 0 1 2048 div 0 0 ] def
+/Encoding 256 array 0 1 255 {1 index exch /.notdef put} for def
+/PaintType 0 def
+/FontType 1 def
+/FontBBox { 0 0 0 0 } def
+AddFontInfoBegin
+AddFontInfo
+AddFontInfoEnd
+currentdict
+end
+
+currentfile eexec
+9e67edc6f3ddb54d987dfb0ad4392351758f10eff40ef287a1387512b853
+046f6e589e2c97d48fdb38d54b68757f1dc48a239a5da408c2bfd473eac0
+3ab6b0025b87770e5f3b06904c282a51ee189ce871258447b47d83c5fad2
+326aa26e4c7f0ff21a841a463c859f102729802bbfa6ac0c2766f6b09317
+a247f37b339b99b7588bee2e861ed9de7a8990c512001ce21da50f4516f7
+553cc5df31ac42402c2b4e2b106773ccdac45a8dee89d3d35ce4f9afb022
+79592359efd5293f35df57216c84236a1347e922a61c45691be2c137b65f
+08f4b3113b88e58dce4bd559387db7a00fe16460e5ab8fc835ea6ed9b938
+610bff26bc7ddabb1af7195ef7e654ee14a569bb220669f64824a95d9550
+e6b732d24163e5f1f14c0d8e68bffa74a7e923785ab628ea1b858f9c8898
+aa3a6a215f95d69b979cf88a88e66315daccf6b3e567737c55e3cf437e98
+6959eca072eb5947c0a09809b4d3d5430005f3fa1b9f519f0635d2e185f7
+4e1eec5a19e358c5609375ecd636499ee362b08643e4c00019c76096365d
+ae34a30b033cf6378a4a47f08172f46c61310b971071ca9fcd6dcd1b9ad6
+63809fcecd4cd2183f3a5a9de5c683838022bd1362f59a5b864d29a4d185
+4ca19a30f903bb33d1ca039f71e2039cc453297c2bae1af6d32d72092a4c
+b00fc35b50397d28064e83425bcb8aa2802cb275252b0e70d9983b36eab5
+6caeb1305e4f95ac5edc55b2d2ec626088c80766ae22d5f2ed6bd822b754
+d1c1004291d98617b4ea4915642deb170ab38bcf01dbc7d461b8c4bbde17
+e6745cf0bc1d064418fbed78f744269daef38817c6f073c543dbdf219dd0
+1846e629428c6636dcc0d80038222a8ef4fe9a380b2f0e6e2c4bca8c39fe
+f4a6d3b66af29ba79996bdb5389abf14ec305653c6de8e1b55effb93dcf6
+6bcb0eec3c735bf981b03907a3ffcb25b51f3f6b7632ca38e91975702745
+98993eaef2ad15901aa3ef965171e4a386b664bd21f943b3482afd2c1412
+151ad3e78b340945c8c5faadab4d79d6b3e1017cb933af412dcbfb368b7f
+4790d99ab75ad1715248a31296f12d99ae05aceaa4d28ac45fb01ed9abdf
+c7eb1ecb1de617a14454f6ba1578cbefdadcd3684cc47b453c763c730436
+8f32d78e11012ea6d3d16ca5bf67951a742d405591ac3ee6d5164e890891
+e10c21777eb10661f8c88e5bfa6326d51a8ca574f3321b5cc05631bf331a
+ed2f169a77e8ddecba5e03eb7df19b634f20a0353685b98668fb79295051
+ce2ccd8487a1d0da7d9bb3dd3cb1e3df220fc81841cbd0b3719fbfa27809
+379e5f3e7900be85b9e2bee893085d9bd17b9cb7174367d80bc06d7cb841
+566f2ac1d0e5a1f01dc1cdf58195977393929340b5746f4bc1f3e3ee6f5f
+df3941a5deb99672255cabaac0ea3657a449c28267bc9dbd448fdfe12b52
+fe91ed89405246fe3b6d63c89536f8659fe660ae005adbf01c3c2729913d
+2117f8e2dec91751be554a057dd7998e15b9d02377d6a6d5c83b1091fb8b
+1c7c358f13b4dc00839db3fe4cb9163f5ffc725b1561a2d3e4faab96bd11
+bcc159c4be2dda581cd695dd41635fee2c8b1e5d8dd4b35a59bdcc368ab5
+9bb2ce9799ca98dffa60212f587b7f99b3788f3b052c7a83d31ede5e21cf
+ccedc821552ae0faee16444c26e489d37034f8ba4c811ea5728bc16dcf9a
+217958e8f745e87c917536ff3899b13d00bf631cc449eda3934a726bce8a
+154519d6192fe111443b7d039f3844f6a95bc56142d31970ed4a8e7936b0
+0ff7c795cc2bdb4b82616d7fe32c0a76ed3dc837b238905ebe9cf2d9bb7c
+62bf9ef3fd62d6adbd8928e5cfcc6e01ece9fdc2496b7eaed14d0dd56d31
+123b9ff1712c0e67d00c73ae48d61688a2bb8dcbf8a5a8523aea76f8f107
+554df15d3fc6db019c97efcd6c3cc837a222851ed21e92e0c658a556f7ee
+52268c8787600227471918fa7e32d787c76277b7eda00bfa4fcd5730b724
+20333168b0b79fa2ae46c639399cfae05eb45df153448d831698d38be55e
+1aab21503e8011f9889d8ed64e9d29ac7e298f1136d7cabda06b452c1257
+5d655523016b8302cf0e2d66b310f6ee0cb7e725752b4f2c346b89f98453
+b2abcad50dac1dea9c9d842fd37a409b73621d99599d9d6fc10d2441de0f
+808e63bed2a5d2c2f6b34098aa3facbf6d379b4d1575008ba866446ca1b6
+8aa5d4961e3c2f05b4beb6fc4695f7dea133aba05385434a26db160000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+0000000000000000000000000000000000000000000000000000000000000000
+cleartomark
+/TTBC3E32E0o00 findfont /Encoding get
+dup 1 /E put
+dup 2 /I put
+dup 3 /S put
+dup 4 /hyphen put
+dup 5 /T put
+dup 6 /e put
+dup 7 /s put
+dup 8 /t put
+pop
+F /F18 0 /0 F /TTBC3E32E0o00 mF
+/F18S215 F18 [533 0 0 -533 0 0 ] mFS
+F18S215 Ji
+3713 6730 M <0102030405060708>[326 177 296 178 325 238 206 0]xS
+/F18S258 F18 [600 0 0 -600 0 0 ] mFS
+F18S258 Ji
+3595 7407 M <0102030405060708>[366 200 334 200 367 266 232 0]xS
+/F18S29B F18 [667 0 0 -667 0 0 ] mFS
+F18S29B Ji
+3477 8158 M <0102030405060708>[407 222 371 222 407 295 260 0]xS
+/F18S2DD F18 [733 0 0 -733 0 0 ] mFS
+F18S2DD Ji
+3358 8987 M <0102030405060708>[448 243 409 244 447 325 285 0]xS
+/F18S320 F18 [800 0 0 -800 0 0 ] mFS
+F18S320 Ji
+3239 9893 M <0102030405060708>[489 266 445 266 489 355 310 0]xS
+/F18S384 F18 [900 0 0 -900 0 0 ] mFS
+F18S384 Ji
+3062 10906 M <0102030405060708>[549 300 500 300 550 399 350 0]xS
+/F18S3E8 F18 [1000 0 0 -1000 0 0 ] mFS
+F18S3E8 Ji
+2884 12034 M <0102030405060708>[610 334 555 333 611 444 388 0]xS
+LH
+(%%[Page: 1]%%) =
+%%PageTrailer
+
+%%Trailer
+%%BoundingBox: 18 18 577 824
+%%DocumentNeededResources:
+%%DocumentSuppliedResources:
+%%+ procset Pscript_WinNT_ErrorHandler 5.0 0
+%%+ procset Pscript_FatalError 5.0 0
+%%+ procset Pscript_Win_Basic 5.0 0
+%%+ procset Pscript_Win_Utils_L2 5.0 0
+%%+ procset Pscript_Text 5.0 0
+Pscript_WinNT_Incr dup /terminate get exec
+ehsave restore
+%%Pages: 1
+(%%[LastPage]%%) =
+%%EOF
+ \ No newline at end of file
diff --git a/testgraphical/source/CallExternals.pm b/testgraphical/source/CallExternals.pm
new file mode 100644
index 000000000000..a0a3b1ae716a
--- /dev/null
+++ b/testgraphical/source/CallExternals.pm
@@ -0,0 +1,539 @@
+package CallExternals;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use English;
+use warnings;
+use strict;
+use loghelper;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.29 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&callphp &getPHPExecutable &ExecSQL &callperl &getPerlExecutable &calljava &setJavaExecutable &getJavaExecutable &setToolsPath &quote &quoteIfNeed &set_logfile &close_logfile );
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+# ------------------------------------------------------------------------------
+# small helper, which replaces the return code
+sub errorAdaption($)
+{
+ my $error = shift;
+ if ($error != 0)
+ {
+ $error = $error / 256;
+ }
+ if ($error > 127)
+ {
+ $error = $error - 256;
+ }
+ return $error;
+}
+# ------------------------------------------------------------------------------
+# helper to call external php with popen
+sub callphp($$$)
+{
+ local *IN_FILE;
+ my $phpexe = shift;
+ my $phpprogram = shift;
+ my $sParams = shift;
+ my $line;
+ my $error;
+ my @result;
+
+ # print "Will send: $phpexe $sParams\n";
+ # log_print("CALLPHP: $phpexe $phpprogram $sParams\n");
+# if (open(IN_FILE, "$phpexe $sParams 2>&1 |"))
+ if (open(IN_FILE, "$phpexe $phpprogram $sParams |"))
+ {
+ while ($line = <IN_FILE>)
+ {
+ chomp($line);
+ # $line .= " ";
+ push(@result, $line);
+ # print "callphp output: $line\n";
+ }
+ close(IN_FILE);
+ $error = errorAdaption($?);
+ }
+ else
+ {
+ print "callphp(): Can't popen '$phpexe' with parameter: '$sParams'\n";
+ $error = 1;
+ }
+ return $error, @result;
+}
+
+# ------------------------------------------------------------------------------
+sub getPHPExecutable()
+{
+ my $phpexe;
+ if ($OSNAME eq "solaris")
+ {
+ $phpexe = "php5";
+ }
+ elsif ($OSNAME eq "linux")
+ {
+ if ( -e "/usr/bin/php5") # Suse :-(
+ {
+ $phpexe = "php5";
+ }
+ elsif ( -e "/usr/bin/php") # Gentoo
+ {
+ $phpexe = "php";
+ }
+ else
+ {
+ print "getPHPExecutable(): no php exec found.\n";
+ }
+ }
+ elsif ( $OSNAME eq "MSWin32" )
+ {
+ $phpexe = "C:/programme/php/php.exe";
+ # add second try (xampp)
+ if (! -e $phpexe)
+ {
+ $phpexe = "C:/xampp/php/php.exe";
+ }
+ }
+ elsif ( $OSNAME eq "cygwin" )
+ {
+ $phpexe = "/cygdrive/c/programme/php/php";
+ }
+ else
+ {
+ print "getPHPExecutable(): unknown environment. ($OSNAME)\n";
+ }
+ if (! $phpexe)
+ {
+ print "getPHPExecutable(): ERROR: php executable not found.\n";
+ exit(1);
+ }
+ return $phpexe;
+}
+# ------------------------------------------------------------------------------
+# helper to call external java with popen
+sub calljava($$$)
+{
+ local *IN_FILE;
+ my $javaexe = shift;
+ my $sParams = shift;
+ my $sDebug = shift;
+ my $line;
+ my $error = 1;
+
+ if (! $javaexe)
+ {
+ log_print("ERROR: javaexe not set.\n");
+ return;
+ }
+ if (! $sDebug)
+ {
+ $sDebug = "";
+ }
+ $javaexe = quoteIfNeed($javaexe);
+ log_print ("CALLJAVA: $javaexe $sDebug $sParams\n");
+ if (open(IN_FILE, "$javaexe $sDebug $sParams 2>&1 |"))
+ {
+ while ($line = <IN_FILE>)
+ {
+ chomp($line);
+ log_print ("- $line\n");
+ }
+ close(IN_FILE);
+ $error = errorAdaption($?);
+ }
+ else
+ {
+ log_print ("calljava(): Can't popen '$javaexe' with parameter '$sParams'\n");
+ $error = 1;
+ }
+ return $error;
+}
+
+# ------------------------------------------------------------------------------
+sub getPerlExecutable()
+{
+ my $perlexe;
+ if ( $ENV{PERL} )
+ {
+ $perlexe = $ENV{PERL};
+ }
+ elsif ( $ENV{PERLEXE} )
+ {
+ $perlexe = $ENV{PERLEXE};
+ }
+ else
+ {
+ if ($OSNAME eq "MSWin32")
+ {
+ $perlexe="C:/xampp/perl/bin/perl.exe";
+ if (! -e $perlexe)
+ {
+ $perlexe="r:/btw/perl/bin/perl";
+ }
+ if (! -e $perlexe)
+ {
+ $perlexe="C:/Programme/Perl/bin/perl.exe";
+ }
+ }
+ elsif ($OSNAME eq "cygwin")
+ {
+ $perlexe = "perl";
+ }
+ elsif ($OSNAME eq "solaris")
+ {
+ $perlexe="/so/env/bt_solaris_intel/bin/perl";
+ }
+ elsif ($OSNAME eq "linux")
+ {
+ $perlexe="/so/env/bt_linux_libc2.32/DEV300/bin/perl";
+ }
+ else
+ {
+ log_print "WARNING: Use only the fallback of perl executable.\n";
+ $perlexe = "perl"; # FALLBACK
+ }
+ }
+ if ( ! -e $perlexe)
+ {
+ log_print "getPerlExecutable(): There exist no perl executable.\n";
+ exit(1);
+ }
+ return $perlexe;
+}
+# ------------------------------------------------------------------------------
+# helper to call external perl with popen
+sub callperl($$$)
+{
+ local *IN_FILE;
+ my $perlexe = shift;
+ my $perlprogram = shift;
+ my $sParams = shift;
+ my $line;
+ my $error;
+
+ log_print("CALLPERL: $perlexe $perlprogram $sParams\n");
+# if (open(IN_FILE, "$perlexe $sParams 2>&1 |"))
+ if (open(IN_FILE, "$perlexe $perlprogram $sParams |"))
+ {
+ while ($line = <IN_FILE>)
+ {
+ chomp($line);
+ log_print ("- $line\n");
+ }
+ close(IN_FILE);
+ $error = errorAdaption($?);
+ }
+ else
+ {
+ log_print ("Can't popen '$perlexe' with parameter: '$sParams'\n");
+ $error = 1;
+ }
+ return $error;
+}
+# ------------------------------------------------------------------------------
+our $sJavaExecutable;
+sub setJavaExecutable($)
+{
+ $sJavaExecutable = shift;
+}
+
+# sub getJava14()
+# {
+# my $sJava14;
+# if ($OSNAME eq "MSWin32")
+# {
+# if ($sJavaExecutable)
+# {
+# $sJava14 = $sJavaExecutable;
+# }
+# else
+# {
+# # HARDCODE!
+# $sJava14 = "C:\\Programme\\Java\\j2re1.4.2_10\\bin\\java.exe";
+# }
+# }
+# else
+# {
+# if ($sJavaExecutable)
+# {
+# $sJava14 = $sJavaExecutable;
+# }
+# else
+# {
+# # HARDCODE!
+# $sJava14 = "/opt/java14/bin/java";
+# }
+# }
+# if ( ! -e $sJava14 )
+# {
+# log_print ("Java14 not found. Is searched in '$sJava14'\n");
+# # exit(1);
+# return "";
+# }
+# return $sJava14;
+# }
+# ------------------------------------------------------------------------------
+sub getJava15()
+{
+ my $sJava15;
+ if ($sJavaExecutable)
+ {
+ $sJava15 = $sJavaExecutable;
+ }
+ else
+ {
+ if ($OSNAME eq "MSWin32")
+ {
+ # HARDCODE!
+ $sJava15 = "C:\\Programme\\Java\\jre1.5.0_22\\bin\\java.exe";
+ if ( ! -e $sJava15)
+ {
+ $sJava15 = "C:\\Program Files\\Java\\jre6\\bin\\java.exe";
+ }
+ if ( ! -e $sJava15)
+ {
+ $sJava15 = "C:\\Java\\jdk1.6\\bin\\java.exe";
+ }
+ }
+ elsif ($OSNAME eq "cygwin")
+ {
+ $sJava15 = "java";
+ }
+ else
+ {
+ # HARDCODE!
+ if ($OSNAME eq "solaris")
+ {
+ $sJava15 = "/usr/bin/java";
+ }
+ else
+ {
+ $sJava15 = "/usr/bin/java";
+ if ( ! -e $sJava15 )
+ {
+ $sJava15 = "/opt/java15/bin/java";
+ }
+ }
+ }
+ if ( ! -e $sJava15 )
+ {
+ log_print ("Java15 not found. Is searched in '$sJava15'\n");
+ # exit(1);
+ return "";
+ }
+ }
+ return $sJava15;
+}
+# ------------------------------------------------------------------------------
+sub getJava16()
+{
+ my $sJava16;
+ if ($sJavaExecutable)
+ {
+ $sJava16 = $sJavaExecutable;
+ }
+ else
+ {
+ if ($OSNAME eq "MSWin32")
+ {
+ # HARDCODE!
+ $sJava16 = "C:\\Programme\\Java\\jre1.6.0_16\\bin\\java.exe";
+ if ( ! -e $sJava16)
+ {
+ $sJava16 = "C:\\Program Files\\Java\\jre6\\bin\\java.exe";
+ }
+ if ( ! -e $sJava16)
+ {
+ $sJava16 = "C:\\Java\\jdk1.6\\bin\\java.exe";
+ }
+ # }
+ }
+ elsif ($OSNAME eq "cygwin")
+ {
+ # $sJava16 = "java";
+ $sJava16 = "C:/Program Files/Java/jdk1.6.0_16/bin/java.exe";
+ }
+ else
+ {
+ # HARDCODE!
+ if ($OSNAME eq "solaris")
+ {
+ $sJava16 = "/usr/bin/java";
+ }
+ else
+ {
+ $sJava16 = "/usr/bin/java";
+ if ( ! -e $sJava16 )
+ {
+ $sJava16 = "/opt/java16/bin/java";
+ }
+ }
+ }
+ if ( ! -e $sJava16 )
+ {
+ log_print ("Java16 not found. Is searched in '$sJava16'\n");
+ # exit(1);
+ return "";
+ }
+ }
+ return $sJava16;
+}
+
+# ------------------------------------------------------------------------------
+sub getJavaExecutable()
+{
+ return getJava16();
+}
+
+# ------------------------------------------------------------------------------
+# this function is a helper for parameters
+# if quotes the whole string with 'STR' or "STR" and replace quotes in it's content for the right.
+sub singleQuote($)
+{
+ my $sStr = shift;
+ if ( $OSNAME eq "MSWin32")
+ {
+ # we are MSWin32 (quote \" stronger)
+ # $sStr =~ s/\'/\"/g;
+ $sStr =~ s/\'/\\\"/g;
+ return "\"" . $sStr . "\"";
+ }
+ else
+ {
+ if (index($sStr, "'") >= 0)
+ {
+ # replace all single quotes ("'") by "\""
+ $sStr =~ s/\'/\"/g;
+ }
+ }
+ return "'" . $sStr . "'";
+}
+
+sub quote($)
+{
+ my $sName = shift;
+ return "\"" . $sName . "\"";
+}
+
+sub quoteIfNeed($)
+{
+ my $sName = shift;
+ if (-1 != index($sName, " "))
+ {
+ return quote($sName);
+ }
+ return $sName;
+}
+
+
+# ------------------------------------------------------------------------------
+our $sToolsPath;
+sub setToolsPath($)
+{
+ my $sNewPath = shift;
+ $sToolsPath = $sNewPath;
+}
+
+sub ExecSQL($)
+{
+ my $sSQL = shift;
+
+ my $error;
+ my @aResult;
+ my $sSQLDirect;
+ if ($sToolsPath)
+ {
+ $sSQLDirect = $sToolsPath;
+ $sSQLDirect .= "/";
+ }
+ $sSQLDirect .= "sql_direct.php";
+
+ # select(undef, undef, undef, 0.060);
+ # log_print("ExecSQL: $sSQL\n");
+ # sleep (1);
+ ($error, @aResult) = callphp(getPHPExecutable(), $sSQLDirect, singleQuote($sSQL));
+ if ($error)
+ {
+ log_print ("ExecSQL: An Error occured.\n");
+ log_print ("PHP: " . getPHPExecutable() . "\n");
+ log_print ("SQL Statement: " . singleQuote($sSQL) . "\n");
+ # exit(1);
+ }
+ # select(undef, undef, undef, 0.125);
+ # sleep (1);
+ return @aResult;
+}
+
+# ------------------------------------------------------------------------------
+# helper to call external php with popen
+# sub callexe($$$)
+# {
+# local *IN_FILE;
+# my $exe = shift;
+# my $program = shift;
+# my $sParams = shift;
+# my $line;
+# my $error;
+# my @result;
+#
+# $exe = quoteIfNeed($exe);
+# $program = quoteIfNeed($program);
+#
+# # print "Will send: $exe $sParams\n";
+# # log_print("CALLEXE: $exe $program $sParams\n");
+# if (open(IN_FILE, "$exe $program $sParams |"))
+# {
+# while ($line = <IN_FILE>)
+# {
+# chomp($line);
+# # $line .= " ";
+# push(@result, $line);
+# # print "callphp output: $line\n";
+# }
+# close(IN_FILE);
+# $error = errorAdaption($?);
+# }
+# else
+# {
+# print "Can't popen '$exe' with parameter: '$sParams'\n";
+# $error = 1;
+# }
+# return $error, @result;
+# }
+
+1;
diff --git a/testgraphical/source/ConvwatchHelper.pm b/testgraphical/source/ConvwatchHelper.pm
new file mode 100644
index 000000000000..8f157641b1f4
--- /dev/null
+++ b/testgraphical/source/ConvwatchHelper.pm
@@ -0,0 +1,574 @@
+package ConvwatchHelper;
+
+use English;
+use warnings;
+use strict;
+use Cwd;
+use Cwd 'chdir';
+
+use CallExternals;
+use stringhelper;
+use filehelper;
+use oshelper;
+use loghelper;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.39 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&getQADEVToolsPath &setProjectRoot &getProjectRoot &checkForStop &getSofficeExe &setINPATH);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+# ------------------------------------------------------------------------------
+our $tempprefix;
+
+# sub getTempDir()
+# {
+# my $sTempDir;
+# if (! $tempprefix)
+# {
+# if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+# {
+# # $tempdir = "C:/gfxcmp/temp";
+# $tempprefix = "//so-gfxcmp-lin/gfxcmp-data/wntmsci/temp";
+# }
+# elsif ($OSNAME eq "linux")
+# {
+# $tempprefix = "/net/so-gfxcmp-lin/export/gfxcmp/data/unxlngi/temp";
+# }
+# elsif ($OSNAME eq "solaris")
+# {
+# # $tempdir = "/space/gfxcmp/temp";
+# $tempprefix = "/net/so-gfxcmp-lin/export/gfxcmp/data/unxsoli/temp";
+# }
+# else
+# {
+# print "Error: This environment isn't supported yet.\n";
+# exit(1);
+# }
+# }
+# $sTempDir = $tempprefix;
+# return $sTempDir;
+# }
+# ------------------------------------------------------------------------------
+# in filehelper
+# our $programprefix;
+#
+# sub getProgramPrefix($)
+# {
+# my $sDBDistinct = shift;
+#
+# my $sProgramPrefix;
+# if (! $programprefix)
+# {
+# if ($OSNAME eq "MSWin32")
+# {
+# # $programprefix = "C:/gfxcmp/programs";
+# $programprefix = "C:/gp";
+# }
+# elsif ($OSNAME eq "linux")
+# {
+# $programprefix = "/space/gfxcmp/programs";
+# }
+# elsif ($OSNAME eq "solaris")
+# {
+# $programprefix = "/space/gfxcmp/programs";
+# }
+# else
+# {
+# print "Error: This environment isn't supported yet.\n";
+# exit(1);
+# }
+# }
+# $sProgramPrefix = appendPath($programprefix, substr($sDBDistinct, 0, 19));
+# return $sProgramPrefix;
+# }
+# ------------------------------------------------------------------------------
+sub getQADEVToolsPath()
+{
+ my $sNewPath = appendPath(getToolsPrefix(), "qadev");
+ $sNewPath = appendPath($sNewPath, "scripts");
+ $sNewPath = appendPath($sNewPath, "gfxcmp_ui");
+ return $sNewPath;
+}
+
+# in filehelper
+# our $toolsprefix;
+#
+# sub getToolsPrefix()
+# {
+# my $sToolsPrefix;
+# if (! $toolsprefix)
+# {
+# if ($OSNAME eq "MSWin32")
+# {
+# $toolsprefix = "C:/gfxcmp/tools";
+# }
+# elsif ($OSNAME eq "linux")
+# {
+# $toolsprefix = "/space/gfxcmp/tools";
+# }
+# elsif ($OSNAME eq "solaris")
+# {
+# $toolsprefix = "/space/gfxcmp/tools";
+# }
+# else
+# {
+# print "Error: This environment isn't supported yet.\n";
+# exit(1);
+# }
+# }
+# $sToolsPrefix = $toolsprefix;
+# return $sToolsPrefix;
+# }
+# ------------------------------------------------------------------------------
+our $sProjectRoot;
+sub setProjectRoot($)
+{
+ $sProjectRoot = shift;
+ log_print "\$sProjectRoot := $sProjectRoot\n";
+}
+sub getProjectRoot()
+{
+ if ($sProjectRoot)
+ {
+ return $sProjectRoot;
+ }
+ die "setProjectRoot(PATH) not set.\n";
+}
+
+our $sINPATH;
+sub setINPATH($)
+{
+ $sINPATH = shift;
+}
+sub getINPATH()
+{
+ if ($sINPATH)
+ {
+ return $sINPATH;
+ }
+ die "setINPATH(PATH) not set.\n";
+}
+our $dataprefix;
+
+# sub getDataPrefix()
+# {
+# my $sDataPrefix;
+# if (! $dataprefix)
+# {
+# if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+# {
+# # $dataprefix = "C:/gfxcmp/data";
+# # $dataprefix = "//so-gfxcmp-lin/gfxcmp-data/wntmsci";
+# $dataprefix = getProjectRoot();
+# }
+# elsif ($OSNAME eq "linux")
+# {
+# # $dataprefix = "/space/gfxcmp/data";
+# # $dataprefix = "/net/so-gfxcmp-lin/export/gfxcmp/data/unxlngi";
+# $dataprefix = getProjectRoot();
+# }
+# elsif ($OSNAME eq "solaris")
+# {
+# # $dataprefix = "/space/gfxcmp/data";
+# # $dataprefix = "/net/so-gfxcmp-lin/export/gfxcmp/data/unxsoli";
+# $dataprefix = getProjectRoot();
+# }
+# else
+# {
+# print "Error: This environment isn't supported yet.\n";
+# exit(1);
+# }
+# $dataprefix = appendPath(getProjectRoot(), getINPATH());
+# $dataprefix = appendPath($dataprefix, "data");
+# }
+# $sDataPrefix = $dataprefix;
+# return $sDataPrefix;
+# }
+
+# ------------------------------------------------------------------------------
+
+# sub _shortsleep($)
+# {
+# # sleep 1;
+# select(undef, undef, undef, 0.333);
+# }
+#
+# sub _waitInSeconds($)
+# {
+# my $nLength = shift;
+# my $i;
+# my $j;
+#
+# for ($j=0;$j<$nLength;$j++)
+# {
+# for ($i=0;$i<$j;$i++)
+# {
+# print ".";
+# }
+# for ($i=$j;$i<$nLength;$i++)
+# {
+# print " ";
+# }
+# _shortsleep( 1 );
+# print "\r";
+# }
+#
+# for ($j=0;$j<=$nLength;$j++)
+# {
+# for ($i=0;$i<$j;$i++)
+# {
+# print " ";
+# }
+# for ($i=$j;$i<$nLength;$i++)
+# {
+# print ".";
+# }
+# _shortsleep( 1 );
+# print "\r";
+# }
+# }
+#
+# sub wait30seconds()
+# {
+# _waitInSeconds(20);
+# _waitInSeconds(20);
+# }
+
+sub checkForStop($)
+{
+ my $sStopFilename = shift;
+ my $sStopFilePath;
+ if ($OSNAME eq "MSWin32")
+ {
+ $sStopFilePath = "C:/temp/";
+ }
+ else
+ {
+ $sStopFilePath = "/tmp/";
+ }
+ my $sStopFile = $sStopFilePath . $sStopFilename;
+ if ( -e "$sStopFile" )
+ {
+ print "Stop of Convwatch tool forced!\n";
+ unlink($sStopFile);
+ exit(2);
+ }
+}
+
+# ----------------------------------------------------------------------------------------
+sub readdirectory($$$);
+
+sub readdirectory($$$)
+{
+ my $startdir = shift;
+ my $sUserParameter = shift;
+ my $hook = shift;
+
+ my $myfile;
+
+ local *DIR;
+ chdir $startdir;
+ cwd();
+
+ my $nCountFiles = 0;
+ if (opendir (DIR, $startdir)) # Directory oeffnen
+ {
+ while ($myfile = readdir(DIR))
+ { # ein filename holen
+ #if (! -l $myfile) # not a link
+ #{
+ if (-d $myfile ) # is a directory
+ {
+ if ( -l $myfile)
+ {
+ next;
+ }
+ # if ( $myfile eq "help" ||
+ # $myfile eq "presets" ||
+ # $myfile eq "registry" ||
+ # $myfile eq "uno_packages" ||
+ # $myfile eq "lib" ||
+ # $myfile eq "user_tree" )
+ # {
+ # next;
+ # }
+
+ if ($myfile ne "." && $myfile ne "..")
+ {
+ my $sNewStartDir = appendPath($startdir, $myfile); # neuen Directorystring erstellen
+ # if ($sNewStartDir =~ "^\/proc" ||
+ # $sNewStartDir =~ "^\/dev" ||
+ # $sNewStartDir =~ "^\/udev" ||
+ # $sNewStartDir =~ "lost+found" )
+ # {
+ # next;
+ # }
+ # my $sNewSUserParameter = $sUserParameter . $myfile ."/";
+ # do a recursive call
+ # $nCountFiles++;
+ my $nFileCount = readdirectory($sNewStartDir, $sUserParameter, $hook);
+ # workOnDir($sNewDir, $nFileCount);
+ $nCountFiles += $nFileCount;
+
+ chdir ($startdir); # zurueckwechseln.
+ cwd();
+ }
+ }
+ else
+ {
+ # File must exist, be a regular file and must not be the $onlyOnFile
+ if (-f $myfile)
+ {
+ # print STDERR " $startdir" . "$myfile\n";
+ $nCountFiles++;
+ # workOnFile($startdir, $myfile, $destdir);
+ $hook->($startdir, $myfile, $sUserParameter);
+ }
+ }
+ #}
+ #else
+ #{
+ # print STDERR "linked file: $dir/$myfile\n";
+ #}
+ }
+ closedir(DIR);
+ }
+ else
+ {
+ print STDERR "could not open $startdir\n";
+ }
+ return $nCountFiles;
+}
+
+our $lcl_sSofficeBinPath;
+our $lcl_sSofficeBinName;
+
+sub searchSofficeBin($$$)
+{
+ my $currentDir = shift;
+ my $currentFile = shift;
+ my $sUserParameter = shift;
+
+ if ($currentFile eq $sUserParameter)
+ {
+ my $sSourceFilename;
+ $sSourceFilename = appendPath($currentDir, $currentFile);
+
+ if ( -e "$sSourceFilename" )
+ {
+ $lcl_sSofficeBinPath = $currentDir;
+ $lcl_sSofficeBinName = $currentFile;
+ }
+ }
+}
+
+# our $lcl_sUnoPkgPath;
+#
+# sub searchUnoPkgBin($$$)
+# {
+# my $currentDir = shift;
+# my $currentFile = shift;
+# my $sUserParameter = shift;
+#
+# if ($currentFile eq $sUserParameter)
+# {
+# my $sSourceFilename;
+# $sSourceFilename = appendPath($currentDir, $currentFile);
+# if ( -e "$sSourceFilename" )
+# {
+# $lcl_sUnoPkgPath = $currentDir;
+# }
+# }
+# }
+
+# our $lcl_sJARPath;
+
+# sub searchJARFile($$$)
+# {
+# my $currentDir = shift;
+# my $currentFile = shift;
+# my $sUserParameter = shift;
+#
+# if ($currentFile eq $sUserParameter)
+# {
+# my $sSourceFilename;
+# $sSourceFilename = appendPath($currentDir, $currentFile);
+# if ( -e "$sSourceFilename" )
+# {
+# $lcl_sJARPath = $currentDir;
+# }
+# }
+# }
+
+# return the PATH, where the file was found
+# sub searchForJAR($$)
+# {
+# my $sPathToInstallOffice = shift;
+# my $sJARFileName = shift;
+#
+# my $sCurrentPath = cwd();
+#
+# $lcl_sJARPath = "";
+# readdirectory(${sPathToInstallOffice}, ${sJARFileName}, \&searchJARFile);
+#
+# chdir $sCurrentPath;
+# cwd();
+#
+# return $lcl_sJARPath;
+# }
+
+# sub getUnoPkg($)
+# {
+# my $sPathToInstallOffice = shift;
+#
+# my $sUnoPkgName = "unopkg.bin";
+# if (isWindowsEnvironment())
+# {
+# $sUnoPkgName = "unopkg.exe";
+# }
+#
+# my $sCurrentPath = cwd();
+#
+# $lcl_sUnoPkgPath = "";
+# readdirectory(${sPathToInstallOffice}, ${sUnoPkgName}, \&searchUnoPkgBin);
+#
+# chdir $sCurrentPath;
+# cwd();
+#
+# return ($lcl_sUnoPkgPath, $sUnoPkgName);
+# }
+
+sub getSofficeExe($)
+{
+ my $sPathToOffice = shift;
+
+ my $sSofficeExeName = "soffice";
+ if (isWindowsEnvironment())
+ {
+ $sSofficeExeName = "soffice.exe";
+ }
+
+ my $sCurrentPath = cwd();
+
+ $lcl_sSofficeBinPath = "";
+ $lcl_sSofficeBinName = "";
+ readdirectory(${sPathToOffice}, ${sSofficeExeName}, \&searchSofficeBin);
+
+ chdir $sCurrentPath;
+ cwd();
+
+ return ($lcl_sSofficeBinPath, $lcl_sSofficeBinName);
+}
+
+# sub checkOfficeAlreadyInstalled($)
+# {
+# my $sOfficePath = shift;
+#
+# my $sCurrentPath = cwd();
+#
+# $lcl_sSofficeBinPath = "";
+# my $sOldOfficePath = appendPath($sOfficePath, "program");
+# if ( -d "$sOldOfficePath" )
+# {
+# $sOldOfficePath = appendPath($sOldOfficePath, "soffice.bin");
+# if ( -e $sOldOfficePath )
+# {
+# return 1;
+# }
+# }
+# else
+# {
+# if (isWindowsEnvironment())
+# {
+# my $sThreeLayerOffice = appendPath($sOfficePath, "Sun");
+# $sThreeLayerOffice = appendPath($sThreeLayerOffice, "StarOffice 9");
+# $sThreeLayerOffice = appendPath($sThreeLayerOffice, "program");
+# $sThreeLayerOffice = appendPath($sThreeLayerOffice, "soffice.bin");
+#
+# if ( -e "$sThreeLayerOffice" )
+# {
+# return 1;
+# }
+# }
+# else
+# {
+# my $sThreeLayerOffice = appendPath($sOfficePath, "staroffice9");
+# $sThreeLayerOffice = appendPath($sThreeLayerOffice, "program");
+# $sThreeLayerOffice = appendPath($sThreeLayerOffice, "soffice.bin");
+# if ( -e "$sThreeLayerOffice" )
+# {
+# return 1;
+# }
+# }
+# }
+#
+# # soffice.bin not found in fast path
+# readdirectory($sOfficePath, "soffice.bin", \&searchSofficeBin);
+# chdir $sCurrentPath;
+# cwd();
+#
+# if ( $lcl_sSofficeBinPath ne "" )
+# {
+# return 1;
+# }
+# return 0;
+# # this is the old check
+# # my $sOfficePathCheck = appendPath(${sPathToInstallOffice}, "program");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "soffice.bin");
+# # if ( -e $sOfficePathCheck )
+# # {
+# # return 1;
+# # }
+# #
+# # # check path system of tree layer office
+# # if ( isWindowsEnvironment() )
+# # {
+# # $sOfficePathCheck = appendPath(${sPathToInstallOffice}, "Sun");
+# # if ( ! -e $sOfficePathCheck)
+# # {
+# # # could be an OpenOffice.org
+# # return 0;
+# # }
+# # else
+# # {
+# #
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "StarOffice 9");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "program");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "soffice.bin");
+# # if ( -e $sOfficePathCheck )
+# # {
+# # return 1;
+# # }
+# # print "Error: There exist no Office, maybe an unsupported version?\n";
+# # }
+# # }
+# # elsif ( isUnixEnvironment() )
+# # {
+# # $sOfficePathCheck = appendPath(${sPathToInstallOffice}, "staroffice9");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "staroffice9");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "program");
+# # $sOfficePathCheck = appendPath($sOfficePathCheck, "soffice.bin");
+# # if ( -e $sOfficePathCheck )
+# # {
+# # return 1;
+# # }
+# # print "Error: There exist no Office, maybe an unsupported version?\n";
+# # }
+# # else
+# # {
+# # print "Error: There exist no Office, maybe an unsupported version?\n";
+# # }
+# # return 0;
+# }
+
+1;
diff --git a/testgraphical/source/compare.pl b/testgraphical/source/compare.pl
new file mode 100644
index 000000000000..4aef877dc2b7
--- /dev/null
+++ b/testgraphical/source/compare.pl
@@ -0,0 +1,408 @@
+eval 'exec perl -wS $0 ${1+\"$@\"}'
+ if 0;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+BEGIN
+{
+ # Adding the path of this script file to the include path in the hope
+ # that all used modules can be found in it.
+ $0 =~ /^(.*)[\/\\]/;
+ push @INC, $1;
+ # print "PATH: " . $1 . "\n";
+}
+
+# my $e;
+# foreach $e (keys %ENV)
+# {
+# print "$e := $ENV{$e}" . "\n";
+# }
+
+use strict;
+use graphical_compare;
+use ConvwatchHelper;
+use filehelper;
+use timehelper;
+use loghelper;
+
+use Cwd;
+use File::Basename;
+use Getopt::Long;
+use English; # $OSNAME, ...
+use File::Path;
+use Cwd 'chdir';
+
+our $help; # Help option flag
+our $version; # Version option flag
+# our $test;
+
+# our $MAJOR;
+# our $MINOR;
+# our $cwsname;
+our $pool;
+our $document;
+our $creatortype;
+our $prepareonly = 0;
+our $force;
+our $verbose = 0;
+our $show = 0;
+our $connectionstring;
+
+# Prototypes
+sub print_usage(*);
+sub prepare();
+sub CompareFiles($$);
+
+# flush STDOUT
+# my $old_handle = select (STDOUT); # "select" STDOUT and save # previously selected handle
+# $| = 1; # perform flush after each write to STDOUT
+# select ($old_handle); # restore previously selected handle
+
+$OUTPUT_AUTOFLUSH=1; # works only if use English is used.
+
+our $version_info = 'compare.pl';
+
+GetOptions(
+# "MAJOR=s" => \$MAJOR,
+# "MINOR=s" => \$MINOR,
+# "cwsname=s" => \$cwsname,
+ "pool=s" => \$pool,
+ "document=s" => \$document,
+ "creatortype=s" => \$creatortype,
+ "prepareonly=s" => \$prepareonly,
+ "connectionstring=s" => \$connectionstring,
+
+ "force" => \$force,
+ "verbose" => \$verbose,
+ "show" => \$show,
+
+# "test" => \$test,
+ "help" => \$help,
+ "version" => \$version
+ );
+
+if ($help)
+{
+ print_usage(*STDOUT);
+ exit(0);
+}
+# Check for version option
+if ($version)
+{
+ print STDERR "$version_info\n";
+ exit(0);
+}
+
+if ($prepareonly)
+{
+ $force=1;
+}
+
+prepare();
+if ($connectionstring)
+{
+ setConnectionString($connectionstring);
+}
+
+my $sDocumentPool = appendPath(getProjectRoot(), "document-pool");
+# print "ProjectRoot: " . getProjectRoot() . "\n";
+if ($ENV{DOCUMENTPOOL})
+{
+ if ( -d $ENV{DOCUMENTPOOL})
+ {
+ print "overwrite default Documentpool: '$sDocumentPool'\n";
+ print " with \$ENV{DOCUMENTPOOL}: $ENV{DOCUMENTPOOL}\n";
+ $sDocumentPool = $ENV{DOCUMENTPOOL};
+ }
+ else
+ {
+ print "Given \$DOCUMENTPOOL doesn't exist.\n";
+ }
+}
+
+my $err = 0;
+my $nCompareTime = getTime();
+
+# if we want to check one file, give -pool and -document
+# if we want to check the whole pool, give -pool
+# if we want to check all, call without parameters
+if ($pool)
+{
+ if ($document)
+ {
+ $err = SingleDocumentCompare( $sDocumentPool,
+ $pool,
+ $document,
+ $creatortype,
+ $prepareonly,
+ $show
+ );
+ }
+ else
+ {
+ $err = CompareFiles($sDocumentPool, $pool);
+ }
+}
+else
+{
+ local *DIR;
+ if (opendir (DIR, $sDocumentPool)) # Directory oeffnen
+ {
+ my $myfile;
+ while ($myfile = readdir(DIR))
+ { # ein filename holen
+ if ($myfile eq "." ||
+ $myfile eq "..")
+ {
+ next;
+ }
+ my $sDocumentPath = appendPath($sDocumentPool, $myfile);
+ if ( -d $sDocumentPath )
+ {
+ $err += CompareFiles($sDocumentPool, $myfile);
+ }
+ elsif ( -f $sDocumentPath )
+ {
+ print "Warning: the file '$myfile' will not compared.\n";
+ }
+ }
+ closedir(DIR);
+ }
+ # my $sPool = "eis-chart";
+ # $err += CompareFiles($sDocumentPool, "eis-chart");
+ # $err += CompareFiles($sDocumentPool, "eis-impress");
+ # $err += CompareFiles($sDocumentPool, "eis-writer");
+ # $err += CompareFiles($sDocumentPool, "eis-calc");
+
+}
+
+printTime(endTime($nCompareTime));
+exit ($err);
+
+# ------------------------------------------------------------------------------
+
+sub CompareFiles($$)
+{
+ my $sDocumentPath = shift;
+ my $sPool = shift;
+ my %aFailedHash;
+ my $startdir = appendPath($sDocumentPath, $sPool);
+
+ local *DIR;
+ if (opendir (DIR, $startdir)) # Directory oeffnen
+ {
+ my $myfile;
+ while ($myfile = readdir(DIR))
+ { # ein filename holen
+ if ($myfile eq "knownissues.xcl")
+ {
+ next;
+ }
+ my $sAbsoluteFile = appendPath($startdir, $myfile);
+ if (-f $sAbsoluteFile)
+ {
+ my $nIssue;
+ my $sIssueText;
+ ($nIssue, $sIssueText) = checkForKnownIssue($startdir, $myfile);
+ if ($nIssue == 0)
+ {
+ $err = SingleDocumentCompare(
+ # "/net/so-gfxcmp-documents.germany.sun.com/export/gfxcmp/document-pool", # $documentpoolpath,
+ $sDocumentPool,
+ $sPool, # $documentpool,
+ $myfile, # $documentname);
+ $creatortype, # $destinationcreatortype,
+ $prepareonly,
+ $show
+ );
+ $aFailedHash{$myfile} = $err;
+ }
+ else
+ {
+ print "$myfile [KNOWN ISSUE: #$sIssueText#]\n";
+ }
+ }
+ }
+ closedir(DIR);
+ }
+
+ print "***** State for graphical compare of pool: '$sPool' ******\n";
+ my $nErrorCount = 0;
+ my $file;
+ foreach $file (keys %aFailedHash)
+ {
+ if ($aFailedHash{$file} != 0)
+ {
+ print "Failed: $file\n";
+ $nErrorCount++;
+ }
+ }
+ print "Whole unit: ";
+ if ($nErrorCount > 0)
+ {
+ print "PASSED.FAILED\n";
+ }
+ else
+ {
+ print "PASSED.OK\n";
+ }
+ print "************************************************************\n";
+ return $nErrorCount;
+}
+# ------------------------------------------------------------------------------
+# return issue number if file exists in knownissues.xcl file
+sub checkForKnownIssue($$)
+{
+ my $startdir = shift;
+ my $myfile = shift;
+
+ if ($force)
+ {
+ return 0,"";
+ }
+
+ my $sKnownIssueFile = appendPath($startdir, "knownissues.xcl");
+ my $sIssueText = "unknown";
+ local *ISSUES;
+ my $nIssue = 0;
+ my $sCurrentSection;
+
+ if (open(ISSUES, $sKnownIssueFile))
+ {
+ my $line;
+ while ($line = <ISSUES>)
+ {
+ chomp($line);
+ if ($line =~ /\[(.*)\]/ )
+ {
+ $sCurrentSection = $1;
+ next;
+ }
+ if ($sCurrentSection eq $creatortype)
+ {
+ if ($line =~ /\#\#\# (.*) \#\#\#/ )
+ {
+ $sIssueText = $1;
+ }
+ if ($line =~ /^${myfile}$/ )
+ {
+ $nIssue = 1;
+ last;
+ }
+ }
+ }
+ close(ISSUES);
+ }
+ return $nIssue, $sIssueText;
+}
+# ------------------------------------------------------------------------------
+sub prepare()
+{
+ # directory structure:
+ # documents will be found in
+ # ../document-pool/eis-tests
+
+ # references will be found in
+ # ../references/unxlngi/eis-tests
+ # ../references/wntmsci/eis-tests
+
+ # output goes to
+ # ../unxlngi6.pro/misc
+
+ if ($verbose)
+ {
+ setVerbose();
+ }
+
+ # TEST
+ if (!$ENV{INPATH})
+ {
+ if ($OSNAME eq "linux")
+ {
+ # just for debug
+ setINPATH("unxlngi6.pro");
+ }
+ }
+ else
+ {
+ setINPATH($ENV{INPATH});
+ }
+
+ if (! $creatortype)
+ {
+ $creatortype= "ps";
+ }
+
+ my $cwd = getcwd();
+ print "Current Directory: $cwd\n" if ($verbose);
+ my $sProjectBase;
+ if ($ENV{PRJ})
+ {
+ # print "cwd:=$cwd\n";
+ # print "PRJ:=$ENV{PRJ}\n";
+ $sProjectBase = appendPath($cwd, $ENV{PRJ});
+ }
+ else
+ {
+ $sProjectBase = dirname($cwd);
+ }
+ if ($OSNAME eq "cygwin")
+ {
+ $sProjectBase = `cygpath -w $sProjectBase`;
+ chomp($sProjectBase);
+ $sProjectBase = unixpath($sProjectBase);
+ # print "cygwin patch \$sProjectBase := $sProjectBase\n";
+ }
+ # print "Project base path: $sProjectBase\n";
+ setProjectRoot($sProjectBase);
+
+
+ # TEST TEST TEST
+ # exit (0);
+}
+# ------------------------------------------------------------------------------
+sub print_usage(*)
+{
+ local *HANDLE = $_[0];
+ my $tool_name = basename($0);
+
+ print(HANDLE <<END_OF_USAGE);
+
+Usage: $tool_name [OPTIONS]
+
+ -pool Give pool name out of document-pool directory.
+ But all documents list in knownissues.xcl will not check.
+ -document Give a single document to test, the known issue list will ignored.
+ -creatortype=s s:ps create postscript files via print to file.
+ s:pdf create PDF file via export to pdf.
+ -h, --help Print this help, then exit
+ -v, --version Print version number, then exit
+
+END_OF_USAGE
+;
+}
diff --git a/testgraphical/source/cwstestresult.pl b/testgraphical/source/cwstestresult.pl
new file mode 100644
index 000000000000..63c68c827dbd
--- /dev/null
+++ b/testgraphical/source/cwstestresult.pl
@@ -0,0 +1,208 @@
+:
+eval 'exec perl -wS $0 ${1+"$@"}'
+ if 0;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+#
+# cwstestresult.pl - publish results of CWS tests to EIS
+#
+
+use strict;
+use Getopt::Long;
+use Cwd;
+
+#### module lookup
+my @lib_dirs;
+BEGIN {
+ if ( !defined($ENV{SOLARENV}) ) {
+ die "No environment found (environment variable SOLARENV is undefined)";
+ }
+ push(@lib_dirs, "$ENV{SOLARENV}/bin/modules");
+ push(@lib_dirs, "$ENV{COMMON_ENV_TOOLS}/modules") if defined($ENV{COMMON_ENV_TOOLS});
+}
+use lib (@lib_dirs);
+
+use Cws;
+
+#### global #####
+( my $script_name = $0 ) =~ s/^.*\b(\w+)\.pl$/$1/;
+
+my $is_debug = 1; # enable debug
+my $opt_master; # option: master workspace
+my $opt_child; # option: child workspace
+my $opt_milestone; # option: milestone
+my $opt_testrunName; # option: testrunName
+my $opt_testrunPlatform; # option: testrunPlatfrom
+my $opt_resultPage; # option: resultPage
+
+
+#### main #####
+
+my $arg_status= parse_options();
+testresult($arg_status);
+exit(0);
+
+#### subroutines ####
+
+sub testresult
+{
+ my $status = shift;
+ # get master and child workspace
+ my $masterws = $opt_master ? uc($opt_master) : $ENV{WORK_STAMP};
+ my $milestone = $opt_milestone ? $opt_milestone : $ENV{UPDMINOR};
+ my $childws = $opt_milestone ? undef : ( $opt_child ? $opt_child : $ENV{CWS_WORK_STAMP} );
+
+ if ( !defined($masterws) ) {
+ print_error("Can't determine master workspace environment.\n"
+ . "Please initialize environment with setsolar ...", 1);
+ }
+
+ if ( !defined($childws) && !defined($milestone) ) {
+ print_error("Can't determine child workspace environment or milestone.\n"
+ . "Please initialize environment with setsolar ...", 1);
+ }
+ if ( !defined($opt_resultPage) ) {
+ $opt_resultPage="";
+ }
+ my $cws = Cws->new();
+ if ( defined($childws) ) {
+ $cws->child($childws);
+ }
+ $cws->master($masterws);
+ my $eis = $cws->eis();
+
+ no strict;
+ my $result='';
+
+ if ( defined($childws) ) {
+ $opt_resultPage=SOAP::Data->type(string => $opt_resultPage);
+ my $id = $cws->eis_id();
+ if ( is_valid_cws($cws) ) {
+ $result=$eis->submitTestResult($id,$opt_testrunName,$opt_testrunPlatform, $opt_resultPage, $status);
+ } else {
+ print STDERR "cws is not valid";
+ }
+ } else {
+ $opt_resultPage=SOAP::Data->type(string => $opt_resultPage);
+ $result=$eis->submitTestResultMWS($masterws,$milestone,$opt_testrunName,$opt_testrunPlatform, $opt_resultPage, $status);
+ }
+
+ exit(0)
+}
+
+
+sub is_valid_cws
+{
+ my $cws = shift;
+
+ my $masterws = $cws->master();
+ my $childws = $cws->child();
+ # check if we got a valid child workspace
+ my $id = $cws->eis_id();
+ if ( !$id ) {
+ print_error("Child workspace '$childws' for master workspace '$masterws' not found in EIS database.", 2);
+ }
+ return 1;
+}
+
+sub parse_options
+{
+ # parse options and do some sanity checks
+ Getopt::Long::Configure("no_ignore_case");
+ my $help = 0;
+ my $success = GetOptions('h' => \$help,
+ 'M=s' => \$opt_master,
+ 'm=s' => \$opt_milestone,
+ 'c=s' => \$opt_child,
+ 'n=s' => \$opt_testrunName,
+ 'p=s' => \$opt_testrunPlatform ,
+ 'r=s' => \$opt_resultPage );
+ if ( $help || !$success || $#ARGV < 0 || (!defined($opt_testrunName)) || ( !defined($opt_testrunPlatform)) ) {
+ usage();
+ exit(1);
+ }
+
+ print "$opt_master\n";
+ print "$opt_milestone\n";
+ print "$opt_child\n";
+ print "$opt_testrunName\n";
+ print "$opt_testrunPlatform\n";
+ print "$opt_resultPage\n";
+
+ if ( defined($opt_milestone) && defined($opt_child) ) {
+ print_error("-m and -c are mutually exclusive options",1);
+ }
+
+ return $ARGV[0];
+}
+
+# sub print_message
+# {
+# my $message = shift;
+#
+# print STDERR "$script_name: ";
+# print STDERR "$message\n";
+# return;
+# }
+
+sub print_error
+{
+ my $message = shift;
+ my $error_code = shift;
+
+ print STDERR "$script_name: ";
+ print STDERR "ERROR: $message\n";
+
+ if ( $error_code ) {
+ print STDERR "\nFAILURE: $script_name aborted.\n";
+ exit($error_code);
+ }
+ return;
+}
+
+sub usage
+{
+ print STDERR "Usage: cwstestresult[-h] [-M masterws] [-m milestone|-c childws] <-n testrunName> <-p testrunPlatform> <-r resultPage> statusName\n";
+ print STDERR "\n";
+ print STDERR "Publish result of CWS- or milestone-test to EIS\n";
+ print STDERR "\n";
+ print STDERR "Options:\n";
+ print STDERR "\t-h\t\t\thelp\n";
+ print STDERR "\t-M master\t\toverride MWS specified in environment\n";
+ print STDERR "\t-m milestone\t\toverride milestone specified in environment\n";
+ print STDERR "\t-c child\t\toverride CWS specified in environment\n";
+ print STDERR "\t-n testrunName\t\tspecifiy name of the test\n";
+ print STDERR "\t-p testrunPlatform\tspecify platform where the test ran on\n";
+ print STDERR "\t-r resultPage\t\tspecify name of attachment or hyperlink\n";
+ print STDERR "\t\t\t\tfor resultPage\n";
+
+
+ print STDERR "\nExample:\n";
+ print STDERR "\tcwstestresult -c mycws -n Performance -p Windows -r PerfomanceTestWindows.html ok\n";
+}
diff --git a/testgraphical/source/cwstestresulthelper.pm b/testgraphical/source/cwstestresulthelper.pm
new file mode 100644
index 000000000000..37a5315445af
--- /dev/null
+++ b/testgraphical/source/cwstestresulthelper.pm
@@ -0,0 +1,268 @@
+package cwstestresulthelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use English;
+use warnings;
+use strict;
+use Cwd;
+use Cwd 'chdir';
+
+use stringhelper;
+use loghelper;
+use oshelper;
+use filehelper;
+use CallExternals;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&cwstestresult);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+sub cwstestresult($$$$$$)
+{
+ my $sStatus = shift;
+ my $sDBdistinct = shift;
+ my $sourceversion = shift;
+ my $destinationversion = shift;
+
+ my $sSOLARENV; # = getSolenvPath();
+ my $nSOLARENV_fake = 0;
+ my $sCOMMON_ENV_TOOLS;
+ my $nCOMMON_ENV_TOOLS_fake = 0;
+
+ my $MAJOR;
+ my $MINOR;
+ # we need an extra state in DB
+ # if this state is given here, we need to add information in cws back.
+ if ( ! $sSOLARENV)
+ {
+ my @MAJORMINOR=split('_', $sourceversion);
+ if ($#MAJORMINOR < 1)
+ {
+ print "Failure with sourceversion '$sourceversion' not splitable.\n";
+ return;
+ }
+ $MAJOR=$MAJORMINOR[0]; # DEV300, OOH310, ...
+ $MINOR=$MAJORMINOR[1]; # m45, ...
+ if (getEnvironment() eq "wntmsci")
+ {
+ $sSOLARENV="o:/$MAJOR/ooo.$MINOR/solenv";
+ if (! -e $sSOLARENV)
+ {
+ # fallback to old before ause103 (treeconfig)
+ $sSOLARENV="o:/$MAJOR/src.$MINOR/solenv";
+ }
+ }
+ elsif (getEnvironment() eq "unxlngi" ||
+ getEnvironment() eq "unxsoli")
+ {
+ $sSOLARENV="/so/ws/$MAJOR/ooo.$MINOR/solenv";
+ # automount
+ system("ls -al $sSOLARENV >/dev/null");
+ sleep(1);
+ if (! -e $sSOLARENV)
+ {
+ # fallback to old before ause103 (treeconfig)
+ $sSOLARENV="/so/ws/$MAJOR/src.$MINOR/solenv";
+ }
+ }
+ else
+ {
+ log_print("cwstestresult(): This environment is not supported.");
+ return;
+ }
+ }
+ if ( !defined($ENV{SOLARENV}) || length($ENV{SOLARENV}) == 0 )
+ {
+ $ENV{SOLARENV} = $sSOLARENV;
+ log_print(" SOLARENV is: $ENV{SOLARENV} faked\n");
+ $nSOLARENV_fake = 1;
+ }
+ if ( ! $sCOMMON_ENV_TOOLS)
+ {
+ if (isWindowsEnvironment())
+ {
+ $sCOMMON_ENV_TOOLS="r:/etools";
+ }
+ elsif (isUnixEnvironment() )
+ {
+ $sCOMMON_ENV_TOOLS="/so/env/etools";
+ # automount
+ system("ls -al $sCOMMON_ENV_TOOLS >/dev/null");
+ sleep(1);
+ }
+ else
+ {
+ log_print("cwstestresult(): This environment is not supported. (variable COMMON_ENV_TOOLS not set.)");
+ return;
+ }
+ }
+ if ( !defined($ENV{COMMON_ENV_TOOLS}) || length($ENV{COMMON_ENV_TOOLS}) == 0 )
+ {
+ $ENV{COMMON_ENV_TOOLS} = $sCOMMON_ENV_TOOLS;
+ log_print( "COMMON_ENV_TOOLS is: $ENV{COMMON_ENV_TOOLS} faked\n");
+ $nCOMMON_ENV_TOOLS_fake = 1;
+ }
+
+ # if ( !defined($ENV{WORK_STAMP}) )
+ # {
+ # $ENV{WORK_STAMP} = $MAJOR;
+ # log_print( " WORK_STAMP is: $ENV{WORK_STAMP} faked\n");
+ # }
+ # if ( !defined($ENV{UPDMINOR}) )
+ # {
+ # $ENV{UPDMINOR} = $MINOR;
+ # log_print( " UPDMINOR is: $ENV{UPDMINOR} faked\n");
+ # }
+
+ my $nWORK_STAMP_fake = 0;
+ my $nUPDMINOR_fake = 0;
+
+ if ( !defined($ENV{WORK_STAMP}) || length($ENV{WORK_STAMP}) == 0 )
+ {
+ $ENV{WORK_STAMP} = $MAJOR;
+ log_print(" WORK_STAMP is: $ENV{WORK_STAMP} faked\n");
+ $nWORK_STAMP_fake = 1;
+ }
+ if ( !defined($ENV{UPDMINOR}) || length($ENV{WORK_STAMP}) == 0 )
+ {
+ $ENV{UPDMINOR} = $MINOR;
+ log_print(" UPDMINOR is: $ENV{UPDMINOR} faked\n");
+ $nUPDMINOR_fake = 1;
+ }
+
+ # my $sStatus = "ok";
+ # if ($nFailure == 0)
+ # {
+ # $sStatus = $sInfo;
+ # }
+ # elsif ($nFailure == 1)
+ # {
+ # $sStatus = "failed";
+ # }
+ # elsif ($nFailure == 2)
+ # {
+ # $sStatus = "incomplete";
+ # }
+
+ # system("cwstestresult -c mycws -n Performance -p Windows ok");
+ my $sPerlProgram = appendPath($sSOLARENV, "bin/cwstestresult.pl");
+ # if ( -e "cwstestresult.pl" )
+ # {
+ # # use a local version instead
+ # $sPerlProgram = "cwstestresult.pl";
+ # }
+ # else
+ # {
+ # my $currentdir =cwd();
+ # log_print( "We are in $currentdir\n");
+ # }
+
+ my $sPerlParam;
+ # $sPerlParam = " -m $MAJOR"; # master CWS
+ $sPerlParam .= " -c $destinationversion"; # name of CWS
+ $sPerlParam .= " -n ConvWatch"; # ConvWatch need to be capitalised for cwstestresult
+ my $sCWSEnv;
+ if (isWindowsEnvironment())
+ {
+ $sCWSEnv = "Windows";
+ }
+ elsif (getEnvironment() eq "unxlngi")
+ {
+ $sCWSEnv = "Linux";
+ }
+ elsif (getEnvironment() eq "unxsoli")
+ {
+ $sCWSEnv = "SolarisX86";
+ }
+ else
+ {
+ log_print("cwstestresult(): This environment is not supported. (getEnvironment() returns wrong value?)");
+ return;
+ }
+ $sPerlParam .= " -p " . $sCWSEnv;
+ $sPerlParam .= " -r http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/status_new.php?distinct=$sDBdistinct";
+
+ $sPerlParam .= " ";
+ $sPerlParam .= $sStatus;
+
+
+ # my $sSetcwsAndPerl = "setcws $destinationversion; " . getPerlExecutable();
+
+ my $err = callperl(getPerlExecutable(), $sPerlProgram, $sPerlParam);
+ if ($err != 0)
+ {
+ log_print( "Can't call cwstestresult.pl\n");
+ }
+ if ($nSOLARENV_fake == 1)
+ {
+ $ENV{SOLARENV} = "";
+ undef( $ENV{SOLARENV} );
+ $nSOLARENV_fake = 0;
+ # if ( defined($ENV{SOLARENV}) )
+ # {
+ # print "SOLARENV always defined.\n";
+ # }
+ }
+ if ($nCOMMON_ENV_TOOLS_fake == 1)
+ {
+ $ENV{COMMON_ENV_TOOLS} = "";
+ undef( $ENV{COMMON_ENV_TOOLS} );
+ $nCOMMON_ENV_TOOLS_fake = 0;
+ }
+
+ if ( $nWORK_STAMP_fake == 1 )
+ {
+ # undef($ENV{WORK_STAMP});
+ $ENV{WORK_STAMP} = "";
+ undef($ENV{WORK_STAMP});
+ $nWORK_STAMP_fake = 0;
+ }
+ if ( $nUPDMINOR_fake == 1 )
+ {
+ $ENV{UPDMINOR} = "";
+ undef($ENV{UPDMINOR});
+ $nUPDMINOR_fake = 0;
+ }
+
+
+}
+
+
+1;
diff --git a/testgraphical/source/dbhelper.pm b/testgraphical/source/dbhelper.pm
new file mode 100644
index 000000000000..0f5c0d5bb5ea
--- /dev/null
+++ b/testgraphical/source/dbhelper.pm
@@ -0,0 +1,209 @@
+#
+# # ------------------------------------------------------------------------------
+#
+# sub DB_INSERT_INTO_TABLE_STATUS()
+# {
+# # my $sDocID = shift;
+# # my $sDBDistinct = shift;
+#
+# my $sHostname = hostname;
+#
+# my $sSQL = "INSERT INTO status (docid, dbdistinct2, hostname)";
+# $sSQL .= " VALUES ($docid, '$dbdistinct', '$sHostname')";
+# ExecSQL($sSQL);
+# }
+# sub DB_UPDATE_TABLE_STATUS_SET_INFO($)
+# {
+# # my $sDocID = shift;
+# # my $sDBDistinct = shift;
+# my $sInfo = shift;
+#
+# # my $sHostname = hostname;
+#
+# my $sInsertSQL = "UPDATE status SET info='$sInfo' WHERE docid=$docid AND dbdistinct2='$dbdistinct'";
+# ExecSQL($sInsertSQL);
+# }
+#
+# sub DB_UPDATE_TABLE_DOCUMENTS_SET_STATE_INFO($$)
+# {
+# # my $sDocID = shift;
+# my $sStatus = shift;
+# my $sError = shift;
+#
+# my $sSQL = "UPDATE documents";
+# $sSQL .= " SET state='" . $sStatus . "'";
+# $sSQL .= ",info='" . $sError . "'";
+# $sSQL .= " WHERE docid=$docid";
+# ExecSQL($sSQL);
+# }
+# sub DB_UPDATE_TABLE_STATUS_SET_STATE($)
+# {
+# # my $sDocID = shift;
+# my $sStatus = shift;
+#
+# my $sSQL = "UPDATE status";
+# $sSQL .= " SET state='" . $sStatus . "'";
+# $sSQL .= " WHERE docid=$docid";
+# ExecSQL($sSQL);
+# }
+#
+# # sub DB_UPDATE_TABLE_STATUS_SET_STATE_FAILED()
+# # {
+# # DB_UPDATE_TABLE_STATUS_SET_STATE("FAILED-FAILED");
+# # }
+# # ------------------------------------------------------------------------------
+# # sub getDBConnectionString()
+# # {
+# # # return "server:jakobus,db:jobs_convwatch,user:admin,passwd:admin";
+# # return "server:unoapi,db:jobs_convwatch,user:convwatch,passwd:convwatch";
+# # }
+# # ------------------------------------------------------------------------------
+# sub getSourceInfo($)
+# {
+# my $sDBStr = shift;
+#
+# my $sSourceVersion;
+# if ( $sDBStr =~ / sourceversion='(.*?)',/ )
+# {
+# $sSourceVersion = $1;
+# log_print( "sSourceVersion: $sSourceVersion\n");
+# }
+# if (! $sSourceVersion)
+# {
+# log_print( "Error: no value for sourceversion found.\n");
+# return;
+# }
+# my $sSourceName;
+# if ( $sDBStr =~ / sourcename='(.*?)',/ )
+# {
+# $sSourceName = $1;
+# log_print( "sSourceName: $sSourceName\n");
+# }
+# my $sSourceCreatorType;
+# if ( $sDBStr =~ / sourcecreatortype='(.*?)',/ )
+# {
+# $sSourceCreatorType = $1;
+# log_print( "sSourceCreatorType: $sSourceCreatorType\n");
+# }
+# return $sSourceVersion, $sSourceName, $sSourceCreatorType;
+# }
+# # ------------------------------------------------------------------------------
+# sub getDestinationInfo($)
+# {
+# my $sDBStr = shift;
+#
+# my $sDestinationVersion;
+# if ( $sDBStr =~ / destinationversion='(.*?)',/ )
+# {
+# $sDestinationVersion = $1;
+# log_print( "sDestinationVersion: $sDestinationVersion\n");
+# }
+# if (! $sDestinationVersion)
+# {
+# log_print( "Error: no value for destinationversion found.\n");
+# return;
+# }
+# my $sDestinationName;
+# if ( $sDBStr =~ / destinationname='(.*?)',/ )
+# {
+# $sDestinationName = $1;
+# log_print( "sDestinationName: $sDestinationName\n");
+# }
+# my $sDestinationCreatorType;
+# if ( $sDBStr =~ / destinationcreatortype='(.*?)',/ )
+# {
+# $sDestinationCreatorType = $1;
+# log_print( "sDestinationCreatorType: $sDestinationCreatorType\n");
+# }
+# return $sDestinationVersion, $sDestinationName, $sDestinationCreatorType;
+# }
+# # ------------------------------------------------------------------------------
+# # sub getMailAddress($)
+# # {
+# # my $sDBStr = shift;
+# # my $sMailAddress = "";
+# # if ( $sDBStr =~ / mailfeedback='(.*?)',/ )
+# # {
+# # $sMailAddress = $1;
+# # log_print( "sMailAddress: $sMailAddress\n");
+# # }
+# # return $sMailAddress;
+# # }
+#
+# # sub getDocumentInfo($)
+# # {
+# # my $sDBStr = shift;
+# #
+# # my $sDocumentPoolPath;
+# # if ( $sDBStr =~ / documentpoolpath='(.*?)',/ )
+# # {
+# # $sDocumentPoolPath = $1;
+# # log_print( "sDocumentPoolPath: $sDocumentPoolPath\n");
+# # }
+# # if (! $sDocumentPoolPath)
+# # {
+# # log_print( "Error: no value for documentpoolpath found.\n");
+# # return;
+# # }
+# # my $sDocumentPool;
+# # if ( $sDBStr =~ / documentpool='(.*?)',/ )
+# # {
+# # $sDocumentPool = $1;
+# # log_print( "sDocumentPool: $sDocumentPool\n");
+# # }
+# # if (! $sDocumentPool)
+# # {
+# # log_print( "Error: no value for documentpool found.\n");
+# # return;
+# # }
+# # my $sDocumentName;
+# # if ( $sDBStr =~ / name='(.*?)',/ )
+# # {
+# # $sDocumentName = $1;
+# # log_print( "sDocumentName: $sDocumentName\n");
+# # }
+# # return $sDocumentPoolPath, $sDocumentPool, $sDocumentName;
+# # }
+#
+# sub getDistinct($)
+# {
+# my $sDBStr = shift;
+# my $sDBDistinct;
+# if ( $sDBStr =~ / dbdistinct2='(\S*?)',/ )
+# {
+# $sDBDistinct = $1;
+# log_print( "dbdistinct2: $sDBDistinct\n");
+# }
+# return $sDBDistinct;
+# }
+#
+# sub getIDInfo($)
+# {
+# my $sDBStr = shift;
+# # my $dbdistinct;
+#
+# my $sDBDistinct = getDistinct($sDBStr);
+# # if ( $sDBStr =~ / dbdistinct2='(\S*?)',/ )
+# # {
+# # $sDBDistinct = $1;
+# # log_print( "dbdistinct2: $sDBDistinct\n");
+# # }
+# if (! $sDBDistinct)
+# {
+# log_print( "Error: no dbdistinct given.\n");
+# return;
+# }
+# my $sDocID;
+# if ( $sDBStr =~ / docid=(\S*?),/ )
+# {
+# $sDocID = $1;
+# log_print( "docid: $sDocID\n");
+# }
+# if (! $sDocID)
+# {
+# log_print( "Error: no docid given.\n");
+# return;
+# }
+# return $sDBDistinct, $sDocID;
+# }
+#
diff --git a/testgraphical/source/filehelper.pm b/testgraphical/source/filehelper.pm
new file mode 100644
index 000000000000..ed1be35cf124
--- /dev/null
+++ b/testgraphical/source/filehelper.pm
@@ -0,0 +1,358 @@
+package filehelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use strict;
+use warnings;
+use strict;
+use English; # $OSNAME, ...
+use stringhelper;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&dospath &unixpath &appendPath &appendClass &setPrefix &getToolsPrefix &rmkdir &getJavaPathSeparator &getJavaFileDirSeparator &getFromPathes &convertCygwinPath);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+
+# ------------------------------------------------------------------------------
+# helper, to change all file separators
+sub dospath($)
+{
+ my $sPath = shift;
+ if ($OSNAME eq "MSWin32")
+ {
+ # make out of '/' a '\'
+ $sPath =~ s/\//\\/g;
+ }
+ else
+ {
+ }
+ return $sPath;
+}
+
+sub unixpath($)
+{
+ my $sPath = shift;
+ if ($OSNAME ne "MSWin32")
+ {
+ # make out of '\' a '/'
+ $sPath =~ s/\\/\//g;
+ }
+ else
+ {
+ }
+ return $sPath;
+}
+
+# ------------------------------------------------------------------------------
+# sub getGlobalInstSet()
+# {
+# my $sJumbo;
+# if ($OSNAME eq "MSWin32")
+# {
+# # $sJumbo = "\\\\so-gfxcmp-lin\\jumbo_ship\\install";
+# $sJumbo = "\\\\jumbo.germany.sun.com\\ship\\install";
+# }
+# elsif ($OSNAME eq "cygwin")
+# {
+# $sJumbo = "//jumbo.germany.sun.com/ship/install";
+# }
+# else
+# {
+# $sJumbo = "/net/jumbo.germany.sun.com/ship/install";
+# }
+# return $sJumbo;
+# }
+
+# ------------------------------------------------------------------------------
+# sub getSolarisLockFile()
+# {
+# my $sSolarisLockFile = "/tmp/.ai.pkg.zone.lock-afdb66cf-1dd1-11b2-a049-000d560ddc3e";
+# return $sSolarisLockFile;
+# }
+#
+# sub checkForSolarisLock()
+# {
+# if ($OSNAME eq "solaris")
+# {
+# # wait until the internal installer lock is gone
+# while ( -e getSolarisLockFile() )
+# {
+# while ( -e getSolarisLockFile() )
+# {
+# log_print( "Warning: Wait active until installer lock is gone. \n");
+# sleep 1;
+# }
+# sleep 5;
+# }
+# log_print( "[ok], lock is gone.\n");
+# }
+# }
+#
+# sub deleteSolarisLock()
+# {
+# if ($OSNAME eq "solaris")
+# {
+# sleep 1;
+# unlink getSolarisLockFile();
+#
+# sleep 1;
+# if ( -e getSolarisLockFile() )
+# {
+# # try delete the file as super user?
+# `sudo rm -f getSolarisLockFile()`;
+# sleep 1;
+# }
+# }
+# }
+
+# ------------------------------------------------------------------------------
+sub appendPath($$)
+{
+ my $sPath = shift;
+ my $sAddPath = shift;
+ if ($sPath && $sAddPath)
+ {
+ if (! endswith($sPath, "/") &&
+ ! endswith($sPath, "\\"))
+ {
+ # getJavaFileDirSeparator();
+ $sPath .= "/";
+ }
+ $sPath .= $sAddPath;
+ }
+ return $sPath;
+}
+
+sub appendClass($$)
+{
+ my $sPath = shift;
+ my $sAddPath = shift;
+
+ my $sSeparator = getJavaPathSeparator();
+ if ($sPath && $sAddPath)
+ {
+ if (! endswith($sPath, $sSeparator))
+ {
+ # getJavaFileDirSeparator();
+ $sPath .= $sSeparator;
+ }
+ $sPath .= $sAddPath;
+ }
+ return $sPath;
+}
+
+# ------------------------------------------------------------------------------
+
+our $sPrefix;
+sub setPrefix($)
+{
+ $sPrefix = shift;
+}
+
+sub getPrefix()
+{
+ return $sPrefix;
+}
+
+# ------------------------------------------------------------------------------
+our $programprefix;
+
+# sub getProgramPrefix($)
+# {
+# my $sDBDistinct = shift;
+#
+# my $sProgramPrefix;
+# if (! $programprefix)
+# {
+# if ($OSNAME eq "MSWin32")
+# {
+# # $programprefix = "C:/gfxcmp/programs";
+# $programprefix = "C:";
+# if (getPrefix() eq "performance")
+# {
+# $programprefix = "D:";
+# }
+# $programprefix = appendPath($programprefix, "gp");
+# }
+# elsif ($OSNAME eq "linux")
+# {
+# $programprefix = "/space/" . getPrefix() . "/programs";
+# }
+# elsif ($OSNAME eq "solaris")
+# {
+# $programprefix = "/space/" . getPrefix() . "/programs";
+# }
+# else
+# {
+# print "Error: This environment isn't supported yet.\n";
+# exit(1);
+# }
+# }
+# $sProgramPrefix = appendPath($programprefix, substr($sDBDistinct, 0, 19));
+# return $sProgramPrefix;
+# }
+# ------------------------------------------------------------------------------
+our $toolsprefix;
+
+sub getToolsPrefix()
+{
+ my $sToolsPrefix;
+ if (! $toolsprefix)
+ {
+ if ($OSNAME eq "MSWin32")
+ {
+ $toolsprefix = "C:";
+ if (getPrefix() eq "performance")
+ {
+ $toolsprefix = "D:";
+ }
+ }
+ elsif ($OSNAME eq "linux")
+ {
+ $toolsprefix = "/space";
+ }
+ elsif ($OSNAME eq "solaris")
+ {
+ $toolsprefix = "/space";
+ }
+ else
+ {
+ print "Error: This environment isn't supported yet.\n";
+ exit(1);
+ }
+ $toolsprefix = appendPath($toolsprefix, getPrefix());
+ $toolsprefix = appendPath($toolsprefix, "tools");
+ }
+ $sToolsPrefix = $toolsprefix;
+ return $sToolsPrefix;
+}
+
+# also Windows safe
+sub rmkdir($)
+{
+ my($tpath) = shift;
+ my $dir;
+ my $accum = "";
+
+ my @dirs = split(/\//, $tpath);
+ if ( $#dirs eq 0 )
+ {
+ @dirs = split("\\\\", $tpath);
+ }
+
+ foreach $dir (@dirs)
+ {
+ $accum = "$accum$dir/";
+ if($dir ne "")
+ {
+ if(! -d "$accum")
+ {
+ mkdir ($accum);
+ chmod (0777,$accum);
+ }
+ }
+ }
+}
+
+# ------------------------------------------------------------------------------
+sub getJavaPathSeparator()
+{
+ my $ps = ":";
+ if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ $ps = ";";
+ }
+ return $ps;
+}
+# ------------------------------------------------------------------------------
+sub getJavaFileDirSeparator()
+{
+ my $sfs = "/";
+ if ($OSNAME eq "MSWin32")
+ {
+ $sfs = "\\";
+ }
+ return $sfs;
+}
+# ------------------------------------------------------------------------------
+sub getFromPathes($$)
+{
+ my $sPathesIni = shift;
+ my $searchvalue = shift;
+ my $sResult;
+ if ( -e $sPathesIni)
+ {
+ local *PATHES;
+ if (open(PATHES, "$sPathesIni"))
+ {
+ my $line;
+ while ($line = <PATHES>)
+ {
+ chomp($line);
+ if ($line =~ /^$searchvalue=(.*)$/)
+ {
+ $sResult = $1;
+ }
+ }
+ close(PATHES);
+ }
+ }
+ return $sResult;
+}
+
+sub convertCygwinPath($)
+{
+ my $sPath = shift;
+
+ if ($OSNAME eq "cygwin")
+ {
+ # print "Cygwin Path Patch.\n" if ($verbose);
+ if ($sPath =~ /\/cygdrive\/(.)/)
+ {
+ my $Letter = $1;
+ $sPath =~ s/\/cygdrive\/${Letter}/${Letter}\:/;
+ # print "Cygwin Path Patch: '$sPath'\n" if ($verbose);
+ }
+ }
+ return $sPath;
+}
+
+
+
+1;
diff --git a/testgraphical/source/fill_documents_loop.pl b/testgraphical/source/fill_documents_loop.pl
new file mode 100644
index 000000000000..c1b8174fefe5
--- /dev/null
+++ b/testgraphical/source/fill_documents_loop.pl
@@ -0,0 +1,423 @@
+eval 'exec perl -wS $0 ${1+\"$@\"}'
+ if 0;
+
+# This program has to start for the new convwatch,
+# once on Windows environment and once on Linux environment
+# Solaris is handled by the linux also.
+#
+# This program polls the database (documentcompare) every 60s for new jobs
+# it runs over the given directory from documentpoolpath and pool, and create for every file
+# a new database entry in documents.
+#
+
+BEGIN
+{
+ # Adding the path of this script file to the include path in the hope
+ # that all used modules can be found in it.
+ $0 =~ /^(.*)[\/\\]/;
+ push @INC, $1;
+}
+
+use ConvwatchHelper;
+use CallExternals;
+use stringhelper;
+use filehelper;
+use oshelper;
+use timehelper;
+use cwstestresulthelper;
+
+use strict;
+use Cwd;
+use File::Basename;
+use English; # $OSNAME, ...
+use Getopt::Long;
+use File::Path;
+use Cwd 'chdir';
+
+my $cwd = getcwd();
+
+our $help; # Help option flag
+our $version; # Version option flag
+our $test;
+
+our $version_info = 'convwatch.pl $Revision: 1.24 $ ';
+
+our $SOLARENV;
+our $COMMON_ENV_TOOLS;
+
+
+our $documentpoolname;
+our $documentpoolpath;
+our $dbdistinct;
+our $sParentDistinct;
+our $sCurrentDocumentPool;
+
+our $fs;
+our @aEntries;
+
+# Prototypes
+# sub getJavaFileDirSeparator();
+sub readdirectory($$$);
+sub putDocumentInDB($$$);
+
+# flush STDOUT
+my $old_handle = select (STDOUT); # "select" STDOUT and save # previously selected handle
+$| = 1; # perform flush after each write to STDOUT
+select ($old_handle); # restore previously selected handle
+
+setPrefix("gfxcmp");
+
+if (!GetOptions(
+ "test" => \$test,
+ "help" => \$help,
+ "version" => \$version
+ ))
+{
+ print_usage(*STDERR);
+ exit(1);
+}
+if ($help)
+{
+ print_usage(*STDOUT);
+ exit(0);
+}
+# Check for version option
+if ($version)
+{
+ print STDERR "$version_info\n";
+ exit(0);
+}
+
+# ------------------------------------------------------------------------------
+# within mysql it is better to use only '/'
+$fs = "/"; # getJavaFileDirSeparator();
+# ------------------------------------------------------------------------------
+sub readdirectory($$$)
+{
+ my $startdir = shift;
+ my $sValues = shift;
+ my $hook = shift;
+
+ my $myfile;
+
+ local *DIR;
+ chdir $startdir;
+ cwd();
+ if (! endswith($startdir, $fs))
+ {
+ $startdir .= $fs;
+ }
+
+ my $nCountFiles = 0;
+ if (opendir (DIR, $startdir)) # Directory oeffnen
+ {
+ while ($myfile = readdir(DIR))
+ { # ein filename holen
+ #if (! -l $myfile) # not a link
+ #{
+ if (-d $myfile ) # is a directory
+ {
+ if ( -l $myfile)
+ {
+ next;
+ }
+ if ($myfile ne "." && $myfile ne "..")
+ {
+ my $sNewStartDir = $startdir . $myfile ."/"; # neuen Directorystring erstellen
+ if ($sNewStartDir =~ "^\/proc" ||
+ $sNewStartDir =~ "^\/dev" ||
+ $sNewStartDir =~ "^\/udev" ||
+ $sNewStartDir =~ "lost+found" )
+ {
+ next;
+ }
+ # my $sNewDestDir = $destdir . $myfile ."/";
+ # do a recursive call
+ # $nCountFiles++;
+ my $nFileCount = readdirectory($sNewStartDir, $sValues, $hook);
+ # workOnDir($sNewDir, $nFileCount);
+ $nCountFiles += $nFileCount;
+
+ chdir ($startdir); # zurueckwechseln.
+ cwd();
+ }
+ }
+ else
+ {
+ # File must exist, be a regular file and must not be the $onlyOnFile
+ if (-f $myfile)
+ {
+ # print " $startdir" . "$myfile\n";
+ $nCountFiles++;
+ # workOnFile($startdir, $myfile, $destdir);
+ $hook->($startdir, $myfile, $sValues);
+ }
+ }
+ #}
+ #else
+ #{
+ # print "linked file: $dir/$myfile\n";
+ #}
+ }
+ closedir(DIR);
+ }
+ else
+ {
+ print "could not open $startdir\n";
+ }
+ return $nCountFiles;
+}
+# ------------------------------------------------------------------------------
+sub putDocumentInDB($$$)
+{
+ my $currentDir = shift;
+ my $currentFile = shift;
+ my $sValues = shift;
+
+ my $sSourceFilename = $currentDir . $currentFile;
+ # we cut down all the previous names like documentpoolpath and the documentpoolname
+ $sSourceFilename = substr($sSourceFilename, length($sCurrentDocumentPool . $fs));
+
+ my $sSQL = "INSERT INTO documents (dbdistinct2, name, pagecount, priority, parentdistinct) VALUES";
+ $sSQL .= "('" . $dbdistinct . "', '" . $sSourceFilename . "', 0, 1, '". $sParentDistinct . "')";
+ # print $sSQL . "\n";
+
+ push(@aEntries, $sSQL);
+ # ExecSQL($sSQL);
+}
+
+# ------------------------------------------------------------------------------
+sub createDBEntriesForEveryDocument($)
+{
+ my $sStr = shift;
+ if ($sStr =~ /^MySQL-Error/ )
+ {
+ # we don't do anything if an error occured
+ return;
+ }
+
+ # interpret the follows string
+ # documentpoolpath='//so-gfxcmp-documents/doc-pool', documentpool='demo_lla', dbdistinct=62,
+
+ # my $sDocumentPoolDir;
+ if ( $sStr =~ /documentpoolpath='(.*?)',/ )
+ {
+ $documentpoolpath = $1;
+ }
+ if (! $documentpoolpath)
+ {
+ print "Error: no value for documentpoolpath found.\n";
+ return;
+ }
+
+ # my $sDocumentPool;
+ if ( $sStr =~ /documentpool='(.*?)',/ )
+ {
+ $documentpoolname = $1;
+ }
+ if (! $documentpoolname)
+ {
+ print "Error: no value for documentpool found.\n";
+ return;
+ }
+ # my $dbdistinct;
+ if ( $sStr =~ /dbdistinct2='(\S*?)',/ )
+ {
+ $dbdistinct = $1;
+ }
+ if (! $dbdistinct)
+ {
+ print "Error: no dbdistinct given.\n";
+ return;
+ }
+
+ if (! -d $documentpoolpath )
+ {
+ my $sEnv = getEnvironment();
+ if ( isUnixEnvironment() )
+ {
+ $documentpoolpath = "/net/so-gfxcmp-documents" . $documentpoolpath;
+ }
+ if ( -d $documentpoolpath )
+ {
+ print "Warning: given documentpoolpath seems to be local, fix to '$documentpoolpath'\n";
+ my $sSQL = "UPDATE documentcompare SET documentpoolpath='$documentpoolpath' WHERE dbdistinct2='$dbdistinct'";
+ print "$sSQL\n";
+ ExecSQL($sSQL);
+ }
+ else
+ {
+ print "Error: documentpoolpath '$documentpoolpath' not found. Don't insert anything.\n";
+ my $sSQL = "UPDATE documentcompare SET state='failed',info='documentpoolpath not found.' WHERE dbdistinct2='$dbdistinct'";
+ print "$sSQL\n";
+ ExecSQL($sSQL);
+ return;
+ }
+ }
+ # create the documentpool directory, to run through
+ $sCurrentDocumentPool = $documentpoolpath;
+ if (! endswith($sCurrentDocumentPool, $fs))
+ {
+ $sCurrentDocumentPool .= $fs;
+ }
+ $sCurrentDocumentPool .= $documentpoolname;
+
+ if ( -d $sCurrentDocumentPool )
+ {
+ if ( $sStr =~ /parentdistinct='(.*?)',/ )
+ {
+ $sParentDistinct = $1;
+ }
+ else
+ {
+ $sParentDistinct = "";
+ }
+
+ # remove any doubles, if any
+ my $sSQL = "DELETE FROM documents WHERE dbdistinct2='$dbdistinct'";
+ print "$sSQL\n";
+ ExecSQL($sSQL);
+
+ # run over the whole given document pool and store every found document name in the database
+ readdirectory($sCurrentDocumentPool, "", \&putDocumentInDB);
+
+ chdir $cwd;
+ cwd();
+
+ foreach $sSQL (@aEntries)
+ {
+ # print "# $sSQL\n";
+ print "$sSQL\n";
+ ExecSQL($sSQL);
+ }
+
+ my $sSQL = "UPDATE documentcompare SET state='inprogress' WHERE dbdistinct2='$dbdistinct'";
+ print "$sSQL\n";
+ ExecSQL($sSQL);
+ print "----------------------------------------------------------------------\n";
+ $sParentDistinct = "";
+ @aEntries = ();
+ }
+ else
+ {
+ print "Error: Given document pool '$sCurrentDocumentPool' doesn't exists.\n";
+ my $sSQL = "UPDATE documentcompare SET state='cancelled' WHERE dbdistinct2='$dbdistinct'";
+ ExecSQL($sSQL);
+ return;
+ }
+ # Send Mail, due to startconvwatch now
+ sendMail($sStr, $documentpoolname, $dbdistinct);
+}
+
+# ------------------------------------------------------------------------------
+sub sendMail($$$)
+{
+ my $sStr = shift;
+ my $documentpool = shift;
+ my $dbdistinct = shift;
+ my $sourceversion;
+ if ( $sStr =~ /sourceversion='(.*?)',/ )
+ {
+ $sourceversion = $1;
+ }
+ if (! $sourceversion)
+ {
+ print "Warning: no value for sourceversion found.\n";
+ return;
+ }
+ my $destinationversion;
+ if ( $sStr =~ /destinationversion='(.*?)',/ )
+ {
+ $destinationversion = $1;
+ }
+ if (! $destinationversion)
+ {
+ print "Warning: no value for destinationversion found.\n";
+ return;
+ }
+ my $mailaddress;
+ if ( $sStr =~ /mailfeedback='(.*?)',/ )
+ {
+ $mailaddress = $1;
+ }
+ if (! $mailaddress)
+ {
+ print "Warning: no value for mailfeedback found.\n";
+ return;
+ }
+
+ # state is 'inprogress', so send a mail
+ # my $sMailAddress = getMailAddress($sDoneStr);
+ my $sParams = "$sourceversion";
+ $sParams .= " $destinationversion";
+ $sParams .= " $documentpool";
+ $sParams .= " $dbdistinct";
+ $sParams .= " $mailaddress";
+ $sParams .= " starts"; # run through state of convwatch
+
+ my $sMailProgram = appendPath(getQADEVToolsPath(), "mailsend.php");
+
+ my $err;
+ my @lines;
+ my $sLine;
+ ($err, @lines) = callphp(getPHPExecutable(), $sMailProgram, $sParams);
+ foreach $sLine (@lines)
+ {
+ log_print( "Mail: $sLine\n");
+ }
+
+ if ($documentpool eq "EIS-tests")
+ {
+ cwstestresult("running", $dbdistinct, $sourceversion, $destinationversion, $SOLARENV, $COMMON_ENV_TOOLS);
+ }
+}
+# ------------------------------------------------------------------------------
+# ------------------------------------------------------------------------------
+
+my $sEnvironmentCondition;
+if (isWindowsEnvironment())
+{
+ $sEnvironmentCondition = "environment='" . getEnvironment() . "'";
+}
+elsif (isUnixEnvironment())
+{
+ # $sEnvironmentCondition = " ( environment='unxlngi' OR environment='unxsoli' ) ";
+ $sEnvironmentCondition = " environment='" . getEnvironment() . "'";
+}
+else
+{
+ print "Error: wrong environment.\n";
+ exit(1);
+}
+my $sWhereClause = "WHERE ";
+if ($sEnvironmentCondition)
+{
+ $sWhereClause .= $sEnvironmentCondition . " AND ";
+}
+$sWhereClause .= " state='new'";
+
+setToolsPath(getQADEVToolsPath());
+
+# ---------------------------------- main loop ----------------------------------
+while (1)
+{
+ my @aResult;
+ my $sSQL = "SELECT documentpoolpath,documentpool,dbdistinct2,sourceversion,destinationversion,mailfeedback,parentdistinct FROM documentcompare $sWhereClause";
+ @aResult = ExecSQL($sSQL);
+
+ my $aValue;
+ foreach $aValue (@aResult)
+ {
+ # print "# $nValue\n";
+ createDBEntriesForEveryDocument($aValue);
+ }
+ if ($test)
+ {
+ last;
+ }
+
+ # wait 30sec.
+ # wait30seconds();
+ waitAMinute();
+ checkForStop("stop_fill_documents_loop");
+}
diff --git a/testgraphical/source/graphical_compare.pm b/testgraphical/source/graphical_compare.pm
new file mode 100644
index 000000000000..5cde8d64ea01
--- /dev/null
+++ b/testgraphical/source/graphical_compare.pm
@@ -0,0 +1,586 @@
+package graphical_compare;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use CallExternals;
+use stringhelper;
+use timehelper;
+use filehelper;
+use loghelper;
+use oshelper;
+use cwstestresulthelper;
+use solarenvhelper;
+use ConvwatchHelper;
+
+use strict;
+use Cwd;
+# use File::Basename;
+use Getopt::Long;
+use English; # $OSNAME, ...
+use File::Path;
+use Cwd 'chdir';
+use Sys::Hostname;
+use Time::localtime;
+
+# my $cwd = getcwd();
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.2 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&SingleDocumentCompare &setPrefix &setConnectionString);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+
+our $nTimeOut = 300 * 1000;
+our $viewable = 1;
+our $port;
+our $resolution;
+our $overwritereference;
+our $fixreference;
+our $sConncectionString;
+
+sub setConnectionString($)
+{
+ $sConncectionString=shift;
+}
+
+sub getOOoRunnerClasspath()
+{
+ my $sSourceRoot;
+ my $sUPDExtensions = "";
+ if (defined ($ENV{SOL_TMP}) && defined ($ENV{SOLARVERSION}))
+ {
+ $sSourceRoot = $ENV{SOLARVERSION};
+ }
+ elsif (defined $ENV{SOURCE_ROOT})
+ {
+ $sSourceRoot = $ENV{SOURCE_ROOT};
+ $sSourceRoot = appendPath($sSourceRoot, $ENV{WORK_STAMP});
+ }
+ else
+ {
+ $sSourceRoot = $ENV{SOLARVERSION};
+ $sUPDExtensions = ".$ENV{UPDMINOR}";
+ }
+ $sSourceRoot = appendPath($sSourceRoot, $ENV{INPATH});
+ my $sSourceRootBin = appendPath($sSourceRoot, "bin" . $sUPDExtensions);
+ my $sSourceRootLib = appendPath($sSourceRoot, "lib" . $sUPDExtensions);
+
+ if (! -d $sSourceRoot )
+ {
+ log_print( "SourceRoot not found, search it in '$sSourceRoot'\n");
+ return "";
+ }
+
+ my $sOOoRunnerPath = $sSourceRootBin;
+ my $sUnoilPath = $sSourceRootBin;
+ my $sRidlPath = $sSourceRootBin;
+ my $sJurtPath = $sSourceRootBin;
+ my $sJuhPath = $sSourceRootBin;
+ my $sJavaUnoPath = $sSourceRootBin;
+
+ my $sOOoRunnerClasspath =
+ appendPath( $sRidlPath, "ridl.jar") . getJavaPathSeparator() .
+ appendPath( $sUnoilPath, "unoil.jar") . getJavaPathSeparator() .
+ appendPath( $sJurtPath, "jurt.jar") . getJavaPathSeparator() .
+ appendPath( $sJuhPath, "juh.jar") . getJavaPathSeparator() .
+ appendPath( $sJavaUnoPath, "java_uno.jar") . getJavaPathSeparator() .
+ appendPath( $sOOoRunnerPath, "OOoRunnerLight.jar");
+ if (isWindowsEnvironment())
+ {
+ $sOOoRunnerClasspath .= getJavaPathSeparator() . $sSourceRootBin;
+ }
+ else
+ {
+ $sOOoRunnerClasspath .= getJavaPathSeparator() . $sSourceRootLib;
+ }
+ return $sOOoRunnerClasspath;
+}
+
+# ------------------------------------------------------------------------------
+sub getTempPath()
+{
+ my $sTempPath;
+ if (isWindowsEnvironment())
+ {
+ $sTempPath = "C:/temp";
+ }
+ elsif (isUnixEnvironment())
+ {
+ $sTempPath = "/tmp";
+ }
+ else
+ {
+ die "getTempPath() Failed, due to unsupported environment.\n";
+ }
+ return $sTempPath;
+}
+# ------------------------------------------------------------------------------
+
+sub getProjectOutput()
+{
+ my $sOutput = appendPath(getProjectRoot(), $ENV{INPATH});
+ $sOutput = appendPath($sOutput, "misc");
+ return $sOutput;
+}
+
+# ------------------------------------------------------------------------------
+sub getProjectOutputReference()
+{
+ my $sOutput = appendPath(getProjectRoot(), $ENV{INPATH});
+ $sOutput = appendPath($sOutput, "reference");
+ return $sOutput;
+}
+
+
+sub searchForReference($)
+{
+ my $sFile = shift;
+ if ( -e $sFile )
+ {
+ return 0;
+ }
+ if ( -e $sFile . ".ps")
+ {
+ return 0;
+ }
+ if ( -e $sFile . ".pdf")
+ {
+ return 0;
+ }
+ return 1;
+}
+# ------------------------------------------------------------------------------
+
+# my $sOfficeName = $officeprefixname . $officename;
+sub SingleDocumentCompare($$$$$$)
+{
+ # get all about the document to compare
+ my $sDocumentPoolPath = shift;
+ my $sDocumentPool = shift;
+ my $sDocumentName = shift;
+ my $sDebug = "";
+
+ # get all about the destination office
+ my $sCreatorType = shift;
+ if (! $sCreatorType)
+ {
+ # log_print( "parameter -creatortype not given. Use 'OOo'\n");
+ $sCreatorType = "ps";
+ }
+ my $prepareonly = shift;
+ my $show = shift;
+
+ # my $nSimpleCompareTime = getTime();
+
+ my $nConvwatchFailed = 0;
+ set_logfile( appendPath(getProjectOutput(), $sDocumentName . ".txt" ));
+
+ print("$sDocumentName");
+ log_print("\n");
+ log_print("Graphical compare on document: '$sDocumentName'\n");
+ # ------------------------------------------------------------------------------
+ # create postscript or pdf from first installed office
+ # ------------------------------------------------------------------------------
+
+ my $sOOoRunnerClasspath = quoteIfNeed(getOOoRunnerClasspath());
+ if ($OSNAME eq "cygwin")
+ {
+ if (!startswith($sOOoRunnerClasspath, "\""))
+ {
+ $sOOoRunnerClasspath = quote($sOOoRunnerClasspath);
+ }
+ }
+ if (length($sOOoRunnerClasspath) == 0)
+ {
+ $nConvwatchFailed == 1;
+ }
+ # ------------------------------------------------------------------------------
+ # create postscript or pdf from second installed office
+ # ------------------------------------------------------------------------------
+
+ my $sPathesIni = appendPath(getProjectOutput(), "pathes.ini");
+ my $gspath = getFromPathes($sPathesIni, "gs.path");
+ my $gsexe = getFromPathes($sPathesIni, "gs.exe");
+ my $impath = getFromPathes($sPathesIni, "imagemagick.path");
+ my $javaexe = getFromPathes($sPathesIni, "java.exe");
+ setJavaExecutable($javaexe);
+
+ log_print("----- CREATE POSTSCRIPT OR PDF WITH RUNNING OFFICE -----\n");
+ # my $nPrepareSecondPostscriptTime = getTime();
+ if ($nConvwatchFailed == 0)
+ {
+ my $sInputPath = $sDocumentPoolPath;
+ $sInputPath = appendPath($sInputPath, $sDocumentPool);
+ $sInputPath = appendPath($sInputPath, $sDocumentName);
+
+ if (! -f $sInputPath )
+ {
+ $nConvwatchFailed = 1;
+ log_print("ERROR: File '$sInputPath' doesn't exists.\n");
+ }
+ else
+ {
+ my $sOutputPath = getProjectOutput();
+ my $sPropertyFile = appendPath(getProjectOutput() , $sDocumentName . ".build.props");
+
+ local *PROPERTYFILE;
+ if (open(PROPERTYFILE, ">$sPropertyFile"))
+ {
+ print PROPERTYFILE "# This file is automatically created by graphical_compare.pl\n";
+ print PROPERTYFILE "DOC_COMPARATOR_PRINT_MAX_PAGE=9999\n";
+ print PROPERTYFILE "DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION=180\n";
+ print PROPERTYFILE "DOC_COMPARATOR_REFERENCE_CREATOR_TYPE=$sCreatorType\n";
+ print PROPERTYFILE "TEMPPATH=" . getTempPath() . "\n";
+ if ($sConncectionString)
+ {
+ print PROPERTYFILE "ConnectionString=$sConncectionString\n";
+ }
+ else
+ {
+ print PROPERTYFILE "ConnectionString=pipe,name=" . getUsername() . "\n";
+ }
+ print PROPERTYFILE "OFFICE_VIEWABLE=true\n";
+ print PROPERTYFILE "CREATE_DEFAULT_REFERENCE=true\n";
+ print PROPERTYFILE "DOC_COMPARATOR_INPUT_PATH=$sInputPath\n";
+ print PROPERTYFILE "DOC_COMPARATOR_OUTPUT_PATH=$sOutputPath\n";
+ if (isWindowsEnvironment())
+ {
+ print PROPERTYFILE "DOC_COMPARATOR_PRINTER_NAME=CrossOffice Generic Printer\n";
+ }
+ print PROPERTYFILE "NoOffice=true\n";
+
+ close(PROPERTYFILE);
+ }
+ else
+ {
+ print "Can't open '$sPropertyFile' for write.\n";
+ }
+ if ( -e "$sPropertyFile")
+ {
+ # start OOoRunner
+ # sleep 10;
+ # $sOOoRunnerClasspathFromDestinationName = quoteIfNeed(getOOoRunnerClasspath());
+ my $sParams;
+ if ( $ENV{PERL} )
+ {
+ $sParams = "-Dperl.exe=" . convertCygwinPath($ENV{PERL});
+ }
+
+ $sParams .= " -cp " . $sOOoRunnerClasspath .
+ " org.openoffice.Runner" .
+ " -TimeOut $nTimeOut" .
+ " -tb java_complex" .
+ " -ini $sPropertyFile" .
+ " -o graphical.PostscriptCreator";
+ # $sParams .= " -cs pipe,name=$USER";
+
+ # $sDebug = "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9001,suspend=y";
+ my $err = calljava(getJavaExecutable(), $sParams, $sDebug);
+ $sDebug = "";
+ log_print( "\n\n");
+ if ($err != 0)
+ {
+ my $sFailure = "Failed after try to create Postscript/pdf document for " . $sDocumentName;
+ log_print("ERROR: $sFailure\n");
+ $nConvwatchFailed = 1;
+ }
+ }
+ else
+ {
+ my $sFailure = "There is no propertyfile: $sPropertyFile";
+ log_print( "ERROR: $sFailure\n");
+ $nConvwatchFailed=1;
+ }
+ }
+
+ # set prepareonly and it is possible to only create ps or pdf files
+ if ($prepareonly)
+ {
+ print(" [only create ");
+ if ($sCreatorType eq "ps" || $sCreatorType eq "pdf")
+ {
+ print(" $sCreatorType");
+ }
+ else
+ {
+ print(" (${sCreatorType}?)");
+ }
+ if ($nConvwatchFailed == 0)
+ {
+ print(" ok");
+ }
+ else
+ {
+ print(" failed")
+ }
+ print("]\n");
+ return $nConvwatchFailed;
+ }
+
+
+ # ------------------------------------------------------------------------------
+ # create jpeg from postscript or pdf from second installed office
+ # ------------------------------------------------------------------------------
+
+ if ($nConvwatchFailed == 0)
+ {
+ log_print("----- CREATE JPEG FROM POSTSCRIPT OR PDF FROM RUNNING OFFICE -----\n");
+ # start OOoRunner
+ my $sInputPath = getProjectOutput();
+ $sInputPath = appendPath($sInputPath, $sDocumentName);
+
+ my $sOutputPath = getProjectOutput();
+
+ my $sParams = "-cp " . $sOOoRunnerClasspath .
+ " org.openoffice.Runner" .
+ " -TimeOut $nTimeOut" .
+ " -tb java_complex" .
+ " -DOC_COMPARATOR_INPUT_PATH " . quoteIfNeed($sInputPath) .
+ " -DOC_COMPARATOR_OUTPUT_PATH " . quoteIfNeed($sOutputPath) .
+ " -DOC_COMPARATOR_REFERENCE_CREATOR_TYPE $sCreatorType" .
+ " -NoOffice" .
+ " -NoSmallPictures" .
+ " -o graphical.JPEGCreator";
+ if ($gspath)
+ {
+ $sParams .= " -gs.path " . quoteIfNeed($gspath);
+ }
+ if ($gsexe)
+ {
+ $sParams .= " -gs.exe $gsexe";
+ }
+
+ # $sDebug = "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9001,suspend=y";
+ my $err = calljava(getJavaExecutable(), $sParams, $sDebug);
+ $sDebug = "";
+ # log_print( "\n\n");
+ if ($err != 0)
+ {
+ my $sFailure = "Failed after try to create JPEG from Postscript/pdf document for " . $sDocumentName;
+ log_print("ERROR: $sFailure\n");
+ $nConvwatchFailed = 1;
+ }
+ }
+ }
+
+ # ------------------------------------------------------------------------------
+ # create jpeg from postscript or pdf from references
+ # ------------------------------------------------------------------------------
+
+ if ($nConvwatchFailed == 0)
+ {
+ log_print("----- CREATE JPEG FROM POSTSCRIPT OR PDF FROM REFERENCE -----\n");
+
+ # start OOoRunner
+ my $sInputPath = appendPath(getProjectRoot(), "references");
+ $sInputPath = appendPath($sInputPath, getEnvironment());
+ $sInputPath = appendPath($sInputPath, $sDocumentPool);
+ $sInputPath = appendPath($sInputPath, $sDocumentName);
+
+ my $err = searchForReference($sInputPath);
+ if ($err != 0)
+ {
+ log_print("ERROR: Can't find Postscript or PDF reference for '$sInputPath'\n");
+ $nConvwatchFailed = 1;
+ }
+ else
+ {
+ my $sOutputPath = getProjectOutputReference();
+ rmkdir $sOutputPath;
+
+ my $sIndexFile = appendPath($sOutputPath, "index.ini");
+ # we need the index.ini for better run through
+ local *INDEXINI;
+ if ( ! -e $sIndexFile)
+ {
+ if (open(INDEXINI, ">$sIndexFile"))
+ {
+ # print INDEXINI "[$sDocumentName]\n";
+ close(INDEXINI);
+ }
+ }
+ my $sParams = "-cp " . $sOOoRunnerClasspath .
+ " org.openoffice.Runner" .
+ " -TimeOut $nTimeOut" .
+ " -tb java_complex" .
+ " -DOC_COMPARATOR_INPUT_PATH " . quoteIfNeed($sInputPath) .
+ " -DOC_COMPARATOR_OUTPUT_PATH " . quoteIfNeed($sOutputPath) .
+ " -DOC_COMPARATOR_REFERENCE_CREATOR_TYPE $sCreatorType" .
+ " -NoOffice" .
+ " -NoSmallPictures" .
+ " -o graphical.JPEGCreator";
+ if ($gspath)
+ {
+ $sParams .= " -gs.path " . quoteIfNeed($gspath);
+ }
+ if ($gsexe)
+ {
+ $sParams .= " -gs.exe $gsexe";
+ }
+
+ # $sDebug = "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9001,suspend=y";
+ my $err = calljava(getJavaExecutable(), $sParams, $sDebug);
+ $sDebug = "";
+ # log_print( "\n\n");
+ if ($err != 0)
+ {
+ my $sFailure = "Failed after try to create JPEG from Postscript/pdf document for references.";
+ log_print("ERROR: $sFailure\n");
+ $nConvwatchFailed = 1;
+ }
+ }
+ }
+ # ------------------------------------------------------------------------------
+ # compare JPEGs
+ # ------------------------------------------------------------------------------
+
+ if ($nConvwatchFailed == 0)
+ {
+ log_print("----- COMPARE JPEGS -----\n");
+ my $sInputPath = appendPath(getProjectOutputReference(), $sDocumentName);
+
+ my $sOutputPath = getProjectOutput();
+
+ my $sParams = "-Xmx512m" .
+ " -cp " . $sOOoRunnerClasspath .
+ " org.openoffice.Runner" .
+ " -TimeOut $nTimeOut" .
+ " -tb java_complex" .
+ " -DOC_COMPARATOR_INPUT_PATH " . quoteIfNeed($sInputPath) .
+ " -DOC_COMPARATOR_OUTPUT_PATH " . quoteIfNeed($sOutputPath) .
+ " -NoOffice" .
+ " -NoSmallPictures" .
+ " -o graphical.JPEGComparator";
+ if ($impath)
+ {
+ $sParams .= " -imagemagick.path " . quoteIfNeed($impath);
+ }
+
+ # start OOoRunner
+ # $sDebug = "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9001,suspend=y";
+ my $err = calljava(getJavaExecutable(), $sParams, $sDebug);
+ $sDebug = "";
+ log_print( "\n\n");
+ if ($err != 0)
+ {
+ my $sFailure = "Failed after compare JPEGs $sDocumentName\n";
+ log_print("ERROR: $sFailure\n");
+ $nConvwatchFailed = 1;
+
+ if ($show)
+ {
+ # try to execute new java tool to show graphical compare
+ my $sJavaProgram = appendPath(getProjectRoot(), $ENV{INPATH});
+ $sJavaProgram = appendPath($sJavaProgram, "class");
+ $sJavaProgram = appendPath($sJavaProgram, "ConvwatchGUIProject.jar");
+ if ( -e "$sJavaProgram")
+ {
+ my $sInputPath = appendPath(getProjectOutput(), $sDocumentName . ".ps.ini");
+ if (! -e $sInputPath)
+ {
+ $sInputPath = appendPath(getProjectOutput(), $sDocumentName . ".pdf.ini");
+ if (! -e $sInputPath)
+ {
+ $sInputPath = 0;
+ }
+ }
+ if ($sInputPath)
+ {
+ my $sParams = "-Xms128m -Xmx512m -jar $sJavaProgram $sInputPath";
+ # $sParams .= " -cs pipe,name=$USER";
+ # my $sJavaExe = "C:/Program Files/Java/jdk1.6.0_16/bin/java.exe"; # getJavaExecutable()
+ my $sJavaExe = getJavaExecutable();
+ # $sDebug = "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9001,suspend=y";
+ my $err = calljava($sJavaExe, $sParams, $sDebug);
+ # $sDebug = "";
+ # log_print( "\n\n");
+ # if ($err != 0)
+ # {
+ # my $sFailure = "Failed after try to create Postscript/pdf document for " . $sDocumentName;
+ # log_print("ERROR: $sFailure\n");
+ # $nConvwatchFailed = 1;
+ # }
+ }
+ }
+ else
+ {
+ print "WARNING: The show program '$sJavaProgram' doesn't exists.\n";
+ }
+ }
+ }
+ }
+
+ log_print( "\n\n");
+ close_logfile();
+
+ if ($nConvwatchFailed == 0)
+ {
+ print(" [ok]\n");
+ }
+ else
+ {
+ print(" [FAILED]\n");
+ print("\nPrint output of test: $sDocumentName\n");
+ my $sLogFile = appendPath(getProjectOutput(), $sDocumentName . ".txt");
+ showFile($sLogFile);
+ }
+ # printTime(endTime($nSimpleCompareTime));
+
+ return $nConvwatchFailed;
+}
+
+# ------------------------------------------------------------------------------
+# cat $file
+sub showFile($)
+{
+ my $logfile = shift;
+ local *LOGFILE;
+ if (open(LOGFILE, "$logfile"))
+ {
+ my $line;
+ while ($line = <LOGFILE>)
+ {
+ chomp($line);
+ print $line ."\n";
+ }
+ close(LOGFILE);
+ }
+}
+
+
+1;
diff --git a/testgraphical/source/loghelper.pm b/testgraphical/source/loghelper.pm
new file mode 100644
index 000000000000..6dad31c7761a
--- /dev/null
+++ b/testgraphical/source/loghelper.pm
@@ -0,0 +1,94 @@
+package loghelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use strict;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&set_logfile &close_logfile &log_print &setVerbose);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+# ------------------------------- Log into a file -------------------------------
+local *LOGFILE;
+our $nGlobalLog = 0;
+our $nGlobalVerbose = 0;
+
+sub setVerbose()
+{
+ $nGlobalVerbose = 1;
+}
+
+sub set_logfile($)
+{
+ my $sLogFile = shift;
+
+ if (open(LOGFILE, ">$sLogFile"))
+ {
+ $nGlobalLog = 1;
+ }
+}
+sub close_logfile()
+{
+ close(LOGFILE);
+ $nGlobalLog = 0;
+}
+
+sub log_print($)
+{
+ my $sLine = shift;
+ if ($nGlobalLog)
+ {
+ print LOGFILE $sLine;
+ }
+ if ($nGlobalVerbose == 1)
+ {
+ print $sLine;
+ }
+ else
+ {
+ # In this special case for NetBeans, which show if a debugger can access.
+ # The Line should print anyway.
+ if ($sLine =~ /Listening for transport/)
+ {
+ print $sLine;
+ }
+ }
+}
+
+1;
diff --git a/testgraphical/source/makefile.mk b/testgraphical/source/makefile.mk
new file mode 100644
index 000000000000..619fd7786f93
--- /dev/null
+++ b/testgraphical/source/makefile.mk
@@ -0,0 +1,112 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+PRJ=..
+
+PRJNAME=gfxcmp
+TARGET=notargetyet
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : settings.mk
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : target.mk
+
+# call with PDF=1 to use office pdf exporter instead of the XPrinter API
+.IF "$(PDF)"!=""
+ CREATORTYPE="-creatortype" pdf
+.ELSE
+ CREATORTYE="-creatortype" ps
+.ENDIF
+
+.IF "$(SHOW)"!=""
+ P_SHOW=-show
+.ENDIF
+
+
+# call with PREPARE=1 to only create new reference files
+# copy these files by hand into the corresponding directories
+.IF "$(PREPARE)"!=""
+ PREPAREONLY="-prepareonly" 1
+.ELSE
+ PREPAREONLY=
+.ENDIF
+
+.IF "$(DOCUMENTPOOL)"==""
+ DOCUMENTPOOL=$PRJ$/document-pool
+.ENDIF
+
+# PERLDEBUG=-d:ptkdb
+ALLTAR: selftest
+# pwd
+# $(PERL) $(PERLDEBUG) compare.pl -MAJOR $(WORK_STAMP) -MINOR $(UPDMINOR) -cwsname "$(CWS_WORK_STAMP)"
+# $(PERL) $(PERLDEBUG) compare.pl -pool singletest
+
+# $(PRJ)$/util$/makefile.pmk contains ALLTAR stuff
+
+# selftest is the default run through at the moment and use pdf export to create output.
+# dmake
+selftest:
+ $(PERL) $(PERLDEBUG) compare.pl -creatortype pdf $(PREPAREONLY) -pool singletest -document eis-test.odt $(P_SHOW)
+
+# selftest_ps is like the default run through but use always postscript print out
+# dmake selftest_ps
+selftest_ps:
+ $(PERL) $(PERLDEBUG) compare.pl -creatortype ps $(PREPAREONLY) -pool singletest -document eis-test.odt $(P_SHOW)
+
+#
+#
+# The follows are demonstration targets, DO NOT DELETE
+#
+#
+
+# dmake demo SHOW=1
+demo:
+ $(PERL) $(PERLDEBUG) compare.pl $(CREATORTYPE) $(PREPAREONLY) -pool $@ $(P_SHOW)
+
+# failtest is a demonstration of a failure, with SHOW=1 it should open a java windows which shows 3 pictures,
+# the current document, the reference document and the difference between both.
+# dmake failtest SHOW=1
+# dmake failtest PREPARE=1
+# This test will most the time fail, it is just a demonstration.
+failtest:
+ $(PERL) $(PERLDEBUG) compare.pl $(CREATORTYPE) $(PREPAREONLY) -force -pool demo -document CurrentTime.ods $(P_SHOW)
+
+# manual runs through all documents found in document-pool
+# dmake manual
+# dmake manual PDF=1 SHOW=1
+# dmake manual PREPARE=1 PDF=1
+# should help to create a lot of references at one time.
+manual:
+ $(PERL) $(PERLDEBUG) compare.pl $(CREATORTYPE) $(PREPAREONLY) -force $(P_SHOW)
+
+# msoffice:
+# $(PERL) $(PERLDEBUG) compare.pl -creatortype msoffice $(PREPAREONLY) -pool msoffice -document calc_cellformat_import_biff8.xls $(P_SHOW)
+
+clean:
diff --git a/testgraphical/source/oshelper.pm b/testgraphical/source/oshelper.pm
new file mode 100644
index 000000000000..3f2ed1c44e38
--- /dev/null
+++ b/testgraphical/source/oshelper.pm
@@ -0,0 +1,110 @@
+package oshelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use English;
+use warnings;
+use strict;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&getEnvironment &isWindowsEnvironment &isUnixEnvironment &getUsername);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+
+# ------------------------------------------------------------------------------
+sub getEnvironment()
+{
+ my $sEnvironment;
+ if ($OSNAME eq "MSWin32" || $OSNAME eq "cygwin")
+ {
+ $sEnvironment = "wntmsci";
+ }
+ elsif ( $OSNAME eq "linux")
+ {
+ $sEnvironment = "unxlngi";
+ }
+ elsif ( $OSNAME eq "solaris")
+ {
+ $sEnvironment = "unxsoli";
+ }
+ else
+ {
+ print "Unknown Environment please check OSNAME: '$OSNAME'\n";
+ $sEnvironment = "unknown";
+ }
+ return $sEnvironment;
+}
+
+# ------------------------------------------------------------------------------
+
+sub isWindowsEnvironment()
+{
+ if ($OSNAME eq "MSWin32" ||
+ $OSNAME eq "cygwin")
+ {
+ return 1;
+ }
+ return 0;
+}
+
+sub isUnixEnvironment()
+{
+ if ($OSNAME eq "linux" ||
+ $OSNAME eq "solaris")
+ {
+ return 1;
+ }
+ return 0;
+}
+
+sub getUsername()
+{
+ my $sUser = $ENV{USER};
+ if (!$sUser)
+ {
+ $sUser = $ENV{USERNAME};
+ }
+ if (!$sUser)
+ {
+ die "Username not set.\n";
+ }
+ return $sUser;
+}
+
+1;
diff --git a/smoketestoo_native/check_setup.pl b/testgraphical/source/solarenvhelper.pm
index 0d5753d1419d..f8ec17ece12b 100755..100644
--- a/smoketestoo_native/check_setup.pl
+++ b/testgraphical/source/solarenvhelper.pm
@@ -1,6 +1,5 @@
-:
-eval 'exec perl -wS $0 ${1+"$@"}'
- if 0;
+package solarenvhelper;
+
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,42 +27,37 @@ eval 'exec perl -wS $0 ${1+"$@"}'
#
#*************************************************************************
-sub checkLogDat {
- my ($setuplogfile) = shift;
- my ($errorfound) = 0;
-
- open SETUPLOG, "<$setuplogfile" or die "can´t open file $setuplogfile";
- while(<SETUPLOG>) {
- $line = $_;
- chomp $line;
- if ($line =~ /^ERR/ ) {
- print "Error: $line\n";
- $errorfound = 1;
- }
- }
- close SETUPLOG;
- return !$errorfound; #check ok?
-}
-
-$idStr = ' $Revision: 1.3 $ ';
-$idStr =~ /Revision:\s+(\S+)\s+\$/
- ? ($prg_rev = $1) : ($prg_rev = "-");
+use strict;
+use warnings;
-print "checkSetup -- Version: $prg_rev\n";
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
-if ( ($#ARGV >-1) && ($#ARGV < 1) ) {
- $ARGV[0]=~ s/\"//g;
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&setSolenvPath &getSolenvPath);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
}
-if ( ! ( ($#ARGV >-1) && ($#ARGV < 1) && $ARGV[0] && (-e $ARGV[0] ) ) ) {
- print "Usage: checkSetup <setuplogfile>\n" ;
- exit(1);
+our $sSolenvPath;
+sub setSolenvPath($)
+{
+ $sSolenvPath = shift;
}
-
-if (checkLogDat ($ARGV[0])) {
- exit (0);
-}
-else {
- print STDERR "ERROR: setup failed\n";
- exit (2);
+sub getSolenvPath()
+{
+ if ($sSolenvPath)
+ {
+ return $sSolenvPath;
+ }
+ print "INTERNAL ERROR: You must set the solenv path to the performancetest, by call setSolenvPath()\n";
+ exit 1;
}
+
+1;
diff --git a/testgraphical/source/stringhelper.pm b/testgraphical/source/stringhelper.pm
new file mode 100644
index 000000000000..e7d19256bf1b
--- /dev/null
+++ b/testgraphical/source/stringhelper.pm
@@ -0,0 +1,69 @@
+package stringhelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use strict;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.2 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&endswith &startswith);
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+# string helper like java endsWith
+sub endswith($$)
+{
+ my $string = shift;
+ my $search = shift;
+ if ( $string =~ /${search}$/ )
+ {
+ return 1;
+ }
+ return 0;
+}
+sub startswith($$)
+{
+ my $string = shift;
+ my $search = shift;
+ if ( $string =~ /^${search}/ )
+ {
+ return 1;
+ }
+ return 0;
+}
+
+1;
diff --git a/testgraphical/source/timehelper.pm b/testgraphical/source/timehelper.pm
new file mode 100644
index 000000000000..38bd56fc4b20
--- /dev/null
+++ b/testgraphical/source/timehelper.pm
@@ -0,0 +1,99 @@
+package timehelper;
+
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+use POSIX qw(strftime);
+use POSIX qw(time difftime);
+# use POSIX qw(localtime);
+use strict;
+# use Time::localtime;
+use loghelper;
+
+BEGIN {
+ use Exporter ();
+ our ($VERSION, @ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
+
+ $VERSION = 1.00;
+ # if using RCS/CVS, this may be preferred
+ $VERSION = do { my @r = (q$Revision: 1.1 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; # must be all one line, for MakeMaker
+ @ISA = qw(Exporter);
+ @EXPORT = qw(&getTime &endTime &printTime &waitAMinute );
+ %EXPORT_TAGS = ( ); # eg: TAG => [ qw!name1 name2! ],
+ # your exported package globals go here,
+ # as well as any optionally exported functions
+ @EXPORT_OK = ( ); # qw($Var1 %Hashit &func3);
+}
+
+
+# ------------------------------------------------------------------------------
+# our $starttime;
+sub getTime()
+{
+ my $nValue;
+ # $nValue = localtime->sec();
+ # $nValue += 60 * localtime->min();
+ # $nValue += 3600 * localtime->hour();
+ $nValue = time();
+ return $nValue;
+}
+# sub startTime()
+# {
+# $starttime = getTime();
+# }
+sub endTime($)
+{
+ my $starttime = shift;
+
+ my $endtime = getTime();
+ my $nTime = difftime($endtime, $starttime);
+ # my $nTime = $endtime - $starttime;
+ # if ($nTime < 0)
+ # {
+ # $nTime += 24 * 3600; # add 24 hours
+ # }
+ return $nTime;
+}
+sub printTime($)
+{
+ my $nTime = shift;
+ print( "Time: " . $nTime . " seconds.\n\n");
+}
+
+
+# sub waitAMinute()
+# {
+# # _waitInSeconds(20);
+# # _waitInSeconds(20);
+# my $now_string = strftime "%a %b %e %H:%M:%S %Y", localtime;
+# print $now_string . "\n";
+# # print getCurrentDateString() . "\n";
+# sleep(60);
+# }
+#
+
+1;
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/build.xml b/testgraphical/ui/java/ConvwatchGUIProject/build.xml
new file mode 100644
index 000000000000..e4d82212f35d
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/build.xml
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- You may freely edit this file. See commented blocks below for -->
+<!-- some examples of how to customize the build. -->
+<!-- (If you delete it and reopen the project it will be recreated.) -->
+<!-- By default, only the Clean and Build commands use this build script. -->
+<!-- Commands such as Run, Debug, and Test only use this build script if -->
+<!-- the Compile on Save feature is turned off for the project. -->
+<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
+<!-- in the project's Project Properties dialog box.-->
+<project name="ConvwatchGUIProject" default="default" basedir=".">
+ <description>Builds, tests, and runs the project ConvwatchGUIProject.</description>
+ <import file="nbproject/build-impl.xml"/>
+ <!--
+
+ There exist several targets which are by default empty and which can be
+ used for execution of your tasks. These targets are usually executed
+ before and after some main targets. They are:
+
+ -pre-init: called before initialization of project properties
+ -post-init: called after initialization of project properties
+ -pre-compile: called before javac compilation
+ -post-compile: called after javac compilation
+ -pre-compile-single: called before javac compilation of single file
+ -post-compile-single: called after javac compilation of single file
+ -pre-compile-test: called before javac compilation of JUnit tests
+ -post-compile-test: called after javac compilation of JUnit tests
+ -pre-compile-test-single: called before javac compilation of single JUnit test
+ -post-compile-test-single: called after javac compilation of single JUunit test
+ -pre-jar: called before JAR building
+ -post-jar: called after JAR building
+ -post-clean: called after cleaning build products
+
+ (Targets beginning with '-' are not intended to be called on their own.)
+
+ Example of inserting an obfuscator after compilation could look like this:
+
+ <target name="-post-compile">
+ <obfuscate>
+ <fileset dir="${build.classes.dir}"/>
+ </obfuscate>
+ </target>
+
+ For list of available properties check the imported
+ nbproject/build-impl.xml file.
+
+
+ Another way to customize the build is by overriding existing main targets.
+ The targets of interest are:
+
+ -init-macrodef-javac: defines macro for javac compilation
+ -init-macrodef-junit: defines macro for junit execution
+ -init-macrodef-debug: defines macro for class debugging
+ -init-macrodef-java: defines macro for class execution
+ -do-jar-with-manifest: JAR building (if you are using a manifest)
+ -do-jar-without-manifest: JAR building (if you are not using a manifest)
+ run: execution of project
+ -javadoc-build: Javadoc generation
+ test-report: JUnit report generation
+
+ An example of overriding the target for project execution could look like this:
+
+ <target name="run" depends="ConvwatchGUIProject-impl.jar">
+ <exec dir="bin" executable="launcher.exe">
+ <arg file="${dist.jar}"/>
+ </exec>
+ </target>
+
+ Notice that the overridden target depends on the jar target and not only on
+ the compile target as the regular run target does. Again, for a list of available
+ properties which you can use, check the target you are overriding in the
+ nbproject/build-impl.xml file.
+
+ -->
+</project>
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/dist/ConvwatchGUIProject.jar b/testgraphical/ui/java/ConvwatchGUIProject/dist/ConvwatchGUIProject.jar
new file mode 100644
index 000000000000..3b0ac20afa74
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/dist/ConvwatchGUIProject.jar
Binary files differ
diff --git a/testshl2/source/cppunit/win32/makefile.mk b/testgraphical/ui/java/ConvwatchGUIProject/makefile.mk
index a7f7f037b738..5cb16f1d4c31 100644
--- a/testshl2/source/cppunit/win32/makefile.mk
+++ b/testgraphical/ui/java/ConvwatchGUIProject/makefile.mk
@@ -24,37 +24,48 @@
# for a copy of the LGPLv3 License.
#
#*************************************************************************
-PRJ=..$/..$/..
-PRJNAME=testshl2
-TARGET=c5t_winstuff
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE
+PRJ=../../..
+
+PRJNAME=gfxcmp_ui_java_convwatchgui
+TARGET=notargetyet
# --- Settings -----------------------------------------------------
+
.INCLUDE : settings.mk
-# ------------------------------------------------------------------
+# --- ANT build environment ---------------------------------------
+
+.INCLUDE : antsettings.mk
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : target.mk
-SLOFILES = \
- $(SLO)$/winstuff.obj
+.IF "$(SHOW)" == ""
+nothing .PHONY:
-#-------------------------------------------------------------------------------
-# This is a static lib
-LIB1TARGET= $(LB)$/$(TARGET).lib
-LIB1OBJFILES= \
- $(SLOFILES)
+.ELSE
+
+ALLTAR: dist/ConvwatchGUIProject.jar
+
+dist/ConvwatchGUIProject.jar: src/ConvwatchGUI.java src/IniFile.java
+# .if $(JDK_VERSION) < 160
+# echo "You need at least java 6"
+# error
+# .endif
+#
.IF "$(GUI)"=="WNT"
-.IF "$(COM)"=="GCC"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-.ENDIF
+ $(ANT)
+.ELSE
+ ant
+.END
-.IF "$(GUI)" == "UNX"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
+.END
-# --- Targets ------------------------------------------------------
+.INCLUDE : $(PRJ)$/util$/makefile.pmk
+
+clean:
+ $(ANT) clean
-.INCLUDE : target.mk
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/manifest.mf b/testgraphical/ui/java/ConvwatchGUIProject/manifest.mf
new file mode 100644
index 000000000000..328e8e5bc3b7
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/manifest.mf
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+X-COMMENT: Main-Class will be added automatically by build
+
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/build-impl.xml b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/build-impl.xml
new file mode 100644
index 000000000000..e493afec4fc3
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/build-impl.xml
@@ -0,0 +1,805 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+*** GENERATED FROM project.xml - DO NOT EDIT ***
+*** EDIT ../build.xml INSTEAD ***
+
+For the purpose of easier reading the script
+is divided into following sections:
+
+ - initialization
+ - compilation
+ - jar
+ - execution
+ - debugging
+ - javadoc
+ - junit compilation
+ - junit execution
+ - junit debugging
+ - applet
+ - cleanup
+
+ -->
+<project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="ConvwatchGUIProject-impl">
+ <fail message="Please build using Ant 1.7.1 or higher.">
+ <condition>
+ <not>
+ <antversion atleast="1.7.1"/>
+ </not>
+ </condition>
+ </fail>
+ <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>
+ <!--
+ ======================
+ INITIALIZATION SECTION
+ ======================
+ -->
+ <target name="-pre-init">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="-pre-init" name="-init-private">
+ <property file="nbproject/private/config.properties"/>
+ <property file="nbproject/private/configs/${config}.properties"/>
+ <property file="nbproject/private/private.properties"/>
+ </target>
+ <target depends="-pre-init,-init-private" name="-init-user">
+ <property file="${user.properties.file}"/>
+ <!-- The two properties below are usually overridden -->
+ <!-- by the active platform. Just a fallback. -->
+ <property name="default.javac.source" value="1.4"/>
+ <property name="default.javac.target" value="1.4"/>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user" name="-init-project">
+ <property file="nbproject/configs/${config}.properties"/>
+ <property file="nbproject/project.properties"/>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
+ <available file="${manifest.file}" property="manifest.available"/>
+ <condition property="main.class.available">
+ <and>
+ <isset property="main.class"/>
+ <not>
+ <equals arg1="${main.class}" arg2="" trim="true"/>
+ </not>
+ </and>
+ </condition>
+ <condition property="manifest.available+main.class">
+ <and>
+ <isset property="manifest.available"/>
+ <isset property="main.class.available"/>
+ </and>
+ </condition>
+ <condition property="do.mkdist">
+ <and>
+ <isset property="libs.CopyLibs.classpath"/>
+ <not>
+ <istrue value="${mkdist.disabled}"/>
+ </not>
+ </and>
+ </condition>
+ <condition property="manifest.available+main.class+mkdist.available">
+ <and>
+ <istrue value="${manifest.available+main.class}"/>
+ <isset property="do.mkdist"/>
+ </and>
+ </condition>
+ <condition property="manifest.available+mkdist.available">
+ <and>
+ <istrue value="${manifest.available}"/>
+ <isset property="do.mkdist"/>
+ </and>
+ </condition>
+ <condition property="manifest.available-mkdist.available">
+ <or>
+ <istrue value="${manifest.available}"/>
+ <isset property="do.mkdist"/>
+ </or>
+ </condition>
+ <condition property="manifest.available+main.class-mkdist.available">
+ <or>
+ <istrue value="${manifest.available+main.class}"/>
+ <isset property="do.mkdist"/>
+ </or>
+ </condition>
+ <condition property="have.tests">
+ <or>
+ <available file="${test.src.dir}"/>
+ </or>
+ </condition>
+ <condition property="have.sources">
+ <or>
+ <available file="${src.dir}"/>
+ </or>
+ </condition>
+ <condition property="netbeans.home+have.tests">
+ <and>
+ <isset property="netbeans.home"/>
+ <isset property="have.tests"/>
+ </and>
+ </condition>
+ <condition property="no.javadoc.preview">
+ <and>
+ <isset property="javadoc.preview"/>
+ <isfalse value="${javadoc.preview}"/>
+ </and>
+ </condition>
+ <property name="run.jvmargs" value=""/>
+ <property name="javac.compilerargs" value=""/>
+ <property name="work.dir" value="${basedir}"/>
+ <condition property="no.deps">
+ <and>
+ <istrue value="${no.dependencies}"/>
+ </and>
+ </condition>
+ <property name="javac.debug" value="true"/>
+ <property name="javadoc.preview" value="true"/>
+ <property name="application.args" value=""/>
+ <property name="source.encoding" value="${file.encoding}"/>
+ <property name="runtime.encoding" value="${source.encoding}"/>
+ <condition property="javadoc.encoding.used" value="${javadoc.encoding}">
+ <and>
+ <isset property="javadoc.encoding"/>
+ <not>
+ <equals arg1="${javadoc.encoding}" arg2=""/>
+ </not>
+ </and>
+ </condition>
+ <property name="javadoc.encoding.used" value="${source.encoding}"/>
+ <property name="includes" value="**"/>
+ <property name="excludes" value=""/>
+ <property name="do.depend" value="false"/>
+ <condition property="do.depend.true">
+ <istrue value="${do.depend}"/>
+ </condition>
+ <path id="endorsed.classpath.path" path="${endorsed.classpath}"/>
+ <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">
+ <length length="0" string="${endorsed.classpath}" when="greater"/>
+ </condition>
+ <property name="javac.fork" value="false"/>
+ </target>
+ <target name="-post-init">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
+ <fail unless="src.dir">Must set src.dir</fail>
+ <fail unless="test.src.dir">Must set test.src.dir</fail>
+ <fail unless="build.dir">Must set build.dir</fail>
+ <fail unless="dist.dir">Must set dist.dir</fail>
+ <fail unless="build.classes.dir">Must set build.classes.dir</fail>
+ <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
+ <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
+ <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
+ <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
+ <fail unless="dist.jar">Must set dist.jar</fail>
+ </target>
+ <target name="-init-macrodef-property">
+ <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute name="name"/>
+ <attribute name="value"/>
+ <sequential>
+ <property name="@{name}" value="${@{value}}"/>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-javac">
+ <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${src.dir}" name="srcdir"/>
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <attribute default="${javac.classpath}" name="classpath"/>
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="${javac.debug}" name="debug"/>
+ <attribute default="${empty.dir}" name="sourcepath"/>
+ <attribute default="${empty.dir}" name="gensrcdir"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <property location="${build.dir}/empty" name="empty.dir"/>
+ <mkdir dir="${empty.dir}"/>
+ <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+ <src>
+ <dirset dir="@{gensrcdir}" erroronmissingdir="false">
+ <include name="*"/>
+ </dirset>
+ </src>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <compilerarg line="${javac.compilerargs}"/>
+ <customize/>
+ </javac>
+ </sequential>
+ </macrodef>
+ <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${src.dir}" name="srcdir"/>
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <attribute default="${javac.classpath}" name="classpath"/>
+ <sequential>
+ <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ </depend>
+ </sequential>
+ </macrodef>
+ <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${build.classes.dir}" name="destdir"/>
+ <sequential>
+ <fail unless="javac.includes">Must set javac.includes</fail>
+ <pathconvert pathsep="," property="javac.includes.binary">
+ <path>
+ <filelist dir="@{destdir}" files="${javac.includes}"/>
+ </path>
+ <globmapper from="*.java" to="*.class"/>
+ </pathconvert>
+ <delete>
+ <files includes="${javac.includes.binary}"/>
+ </delete>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-junit">
+ <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${includes}" name="includes"/>
+ <attribute default="${excludes}" name="excludes"/>
+ <attribute default="**" name="testincludes"/>
+ <sequential>
+ <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}">
+ <batchtest todir="${build.test.results.dir}">
+ <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
+ <filename name="@{testincludes}"/>
+ </fileset>
+ </batchtest>
+ <classpath>
+ <path path="${run.test.classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <formatter type="brief" usefile="false"/>
+ <formatter type="xml"/>
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ </junit>
+ </sequential>
+ </macrodef>
+ </target>
+ <target depends="-init-debug-args" name="-init-macrodef-nbjpda">
+ <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${main.class}" name="name"/>
+ <attribute default="${debug.classpath}" name="classpath"/>
+ <attribute default="" name="stopclassname"/>
+ <sequential>
+ <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="${debug-transport}">
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ </nbjpdastart>
+ </sequential>
+ </macrodef>
+ <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${build.classes.dir}" name="dir"/>
+ <sequential>
+ <nbjpdareload>
+ <fileset dir="@{dir}" includes="${fix.classes}">
+ <include name="${fix.includes}*.class"/>
+ </fileset>
+ </nbjpdareload>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-debug-args">
+ <property name="version-output" value="java version &quot;${ant.java.version}"/>
+ <condition property="have-jdk-older-than-1.4">
+ <or>
+ <contains string="${version-output}" substring="java version &quot;1.0"/>
+ <contains string="${version-output}" substring="java version &quot;1.1"/>
+ <contains string="${version-output}" substring="java version &quot;1.2"/>
+ <contains string="${version-output}" substring="java version &quot;1.3"/>
+ </or>
+ </condition>
+ <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
+ <istrue value="${have-jdk-older-than-1.4}"/>
+ </condition>
+ <condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem">
+ <os family="windows"/>
+ </condition>
+ <condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}">
+ <isset property="debug.transport"/>
+ </condition>
+ </target>
+ <target depends="-init-debug-args" name="-init-macrodef-debug">
+ <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">
+ <attribute default="${main.class}" name="classname"/>
+ <attribute default="${debug.classpath}" name="classpath"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <java classname="@{classname}" dir="${work.dir}" fork="true">
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg line="${debug-args-line}"/>
+ <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
+ <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
+ <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="run-sys-prop."/>
+ <mapper from="run-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <customize/>
+ </java>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-macrodef-java">
+ <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <attribute default="${main.class}" name="classname"/>
+ <attribute default="${run.classpath}" name="classpath"/>
+ <element name="customize" optional="true"/>
+ <sequential>
+ <java classname="@{classname}" dir="${work.dir}" fork="true">
+ <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
+ <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
+ <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
+ <jvmarg line="${run.jvmargs}"/>
+ <classpath>
+ <path path="@{classpath}"/>
+ </classpath>
+ <syspropertyset>
+ <propertyref prefix="run-sys-prop."/>
+ <mapper from="run-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <customize/>
+ </java>
+ </sequential>
+ </macrodef>
+ </target>
+ <target name="-init-presetdef-jar">
+ <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">
+ <jar compress="${jar.compress}" jarfile="${dist.jar}">
+ <j2seproject1:fileset dir="${build.classes.dir}"/>
+ </jar>
+ </presetdef>
+ </target>
+ <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>
+ <!--
+ ===================
+ COMPILATION SECTION
+ ===================
+ -->
+ <target name="-deps-jar-init" unless="built-jar.properties">
+ <property location="${build.dir}/built-jar.properties" name="built-jar.properties"/>
+ <delete file="${built-jar.properties}" quiet="true"/>
+ </target>
+ <target if="already.built.jar.${basedir}" name="-warn-already-built-jar">
+ <echo level="warn" message="Cycle detected: ConvwatchGUIProject was already built"/>
+ </target>
+ <target depends="init,-deps-jar-init" name="deps-jar" unless="no.deps">
+ <mkdir dir="${build.dir}"/>
+ <touch file="${built-jar.properties}" verbose="false"/>
+ <property file="${built-jar.properties}" prefix="already.built.jar."/>
+ <antcall target="-warn-already-built-jar"/>
+ <propertyfile file="${built-jar.properties}">
+ <entry key="${basedir}" value=""/>
+ </propertyfile>
+ </target>
+ <target depends="init,-check-automatic-build,-clean-after-automatic-build" name="-verify-automatic-build"/>
+ <target depends="init" name="-check-automatic-build">
+ <available file="${build.classes.dir}/.netbeans_automatic_build" property="netbeans.automatic.build"/>
+ </target>
+ <target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build">
+ <antcall target="clean"/>
+ </target>
+ <target depends="init,deps-jar" name="-pre-pre-compile">
+ <mkdir dir="${build.classes.dir}"/>
+ </target>
+ <target name="-pre-compile">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target if="do.depend.true" name="-compile-depend">
+ <pathconvert property="build.generated.subdirs">
+ <dirset dir="${build.generated.sources.dir}" erroronmissingdir="false">
+ <include name="*"/>
+ </dirset>
+ </pathconvert>
+ <j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/>
+ </target>
+ <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
+ <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>
+ <copy todir="${build.classes.dir}">
+ <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+ </copy>
+ </target>
+ <target name="-post-compile">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
+ <target name="-pre-compile-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
+ <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
+ <j2seproject3:force-recompile/>
+ <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/>
+ </target>
+ <target name="-post-compile-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
+ <!--
+ ====================
+ JAR BUILDING SECTION
+ ====================
+ -->
+ <target depends="init" name="-pre-pre-jar">
+ <dirname file="${dist.jar}" property="dist.jar.dir"/>
+ <mkdir dir="${dist.jar.dir}"/>
+ </target>
+ <target name="-pre-jar">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available-mkdist.available">
+ <j2seproject1:jar/>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class-mkdist.available">
+ <j2seproject1:jar manifest="${manifest.file}"/>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available">
+ <j2seproject1:jar manifest="${manifest.file}">
+ <j2seproject1:manifest>
+ <j2seproject1:attribute name="Main-Class" value="${main.class}"/>
+ </j2seproject1:manifest>
+ </j2seproject1:jar>
+ <echo>To run this application from the command line without Ant, try:</echo>
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <property location="${dist.jar}" name="dist.jar.resolved"/>
+ <pathconvert property="run.classpath.with.dist.jar">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
+ </pathconvert>
+ <echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Main-Class" value="${main.class}"/>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ <echo>To run this application from the command line without Ant, try:</echo>
+ <property location="${dist.jar}" name="dist.jar.resolved"/>
+ <echo>java -jar "${dist.jar.resolved}"</echo>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+mkdist.available" name="-do-jar-with-libraries-without-mainclass" unless="main.class.available">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ </target>
+ <target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.mkdist" name="-do-jar-with-libraries-without-manifest" unless="manifest.available">
+ <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
+ <pathconvert property="run.classpath.without.build.classes.dir">
+ <path path="${run.classpath}"/>
+ <map from="${build.classes.dir.resolved}" to=""/>
+ </pathconvert>
+ <pathconvert pathsep=" " property="jar.classpath">
+ <path path="${run.classpath.without.build.classes.dir}"/>
+ <chainedmapper>
+ <flattenmapper/>
+ <globmapper from="*" to="lib/*"/>
+ </chainedmapper>
+ </pathconvert>
+ <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
+ <copylibs compress="${jar.compress}" jarfile="${dist.jar}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
+ <fileset dir="${build.classes.dir}"/>
+ <manifest>
+ <attribute name="Class-Path" value="${jar.classpath}"/>
+ </manifest>
+ </copylibs>
+ </target>
+ <target name="-post-jar">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-jar-with-libraries-without-mainclass,-do-jar-with-libraries-without-manifest,-post-jar" description="Build JAR." name="jar"/>
+ <!--
+ =================
+ EXECUTION SECTION
+ =================
+ -->
+ <target depends="init,compile" description="Run a main class." name="run">
+ <j2seproject1:java>
+ <customize>
+ <arg line="${application.args}"/>
+ </customize>
+ </j2seproject1:java>
+ </target>
+ <target name="-do-not-recompile">
+ <property name="javac.includes.binary" value=""/>
+ </target>
+ <target depends="init,compile-single" name="run-single">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <j2seproject1:java classname="${run.class}"/>
+ </target>
+ <target depends="init,compile-test-single" name="run-test-with-main">
+ <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
+ <j2seproject1:java classname="${run.class}" classpath="${run.test.classpath}"/>
+ </target>
+ <!--
+ =================
+ DEBUGGING SECTION
+ =================
+ -->
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger">
+ <j2seproject1:nbjpdastart name="${debug.class}"/>
+ </target>
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test">
+ <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/>
+ </target>
+ <target depends="init,compile" name="-debug-start-debuggee">
+ <j2seproject3:debug>
+ <customize>
+ <arg line="${application.args}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>
+ <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">
+ <j2seproject1:nbjpdastart stopclassname="${main.class}"/>
+ </target>
+ <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>
+ <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
+ <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
+ <j2seproject3:debug classname="${debug.class}"/>
+ </target>
+ <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>
+ <target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test">
+ <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
+ <j2seproject3:debug classname="${debug.class}" classpath="${debug.test.classpath}"/>
+ </target>
+ <target depends="init,compile-test-single,-debug-start-debugger-main-test,-debug-start-debuggee-main-test" if="netbeans.home" name="debug-test-with-main"/>
+ <target depends="init" name="-pre-debug-fix">
+ <fail unless="fix.includes">Must set fix.includes</fail>
+ <property name="javac.includes" value="${fix.includes}.java"/>
+ </target>
+ <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
+ <j2seproject1:nbjpdareload/>
+ </target>
+ <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
+ <!--
+ ===============
+ JAVADOC SECTION
+ ===============
+ -->
+ <target depends="init" name="-javadoc-build">
+ <mkdir dir="${dist.javadoc.dir}"/>
+ <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
+ <classpath>
+ <path path="${javac.classpath}"/>
+ </classpath>
+ <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
+ <filename name="**/*.java"/>
+ </fileset>
+ <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
+ <include name="**/*.java"/>
+ </fileset>
+ </javadoc>
+ </target>
+ <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">
+ <nbbrowse file="${dist.javadoc.dir}/index.html"/>
+ </target>
+ <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
+ <!--
+ =========================
+ JUNIT COMPILATION SECTION
+ =========================
+ -->
+ <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
+ <mkdir dir="${build.test.classes.dir}"/>
+ </target>
+ <target name="-pre-compile-test">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target if="do.depend.true" name="-compile-test-depend">
+ <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
+ <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
+ <copy todir="${build.test.classes.dir}">
+ <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+ </copy>
+ </target>
+ <target name="-post-compile-test">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
+ <target name="-pre-compile-test-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
+ <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
+ <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>
+ <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="${test.src.dir}" srcdir="${test.src.dir}"/>
+ <copy todir="${build.test.classes.dir}">
+ <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+ </copy>
+ </target>
+ <target name="-post-compile-test-single">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
+ <!--
+ =======================
+ JUNIT EXECUTION SECTION
+ =======================
+ -->
+ <target depends="init" if="have.tests" name="-pre-test-run">
+ <mkdir dir="${build.test.results.dir}"/>
+ </target>
+ <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
+ <j2seproject3:junit testincludes="**/*Test.java"/>
+ </target>
+ <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init" if="have.tests" name="test-report"/>
+ <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
+ <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
+ <target depends="init" if="have.tests" name="-pre-test-run-single">
+ <mkdir dir="${build.test.results.dir}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
+ <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
+ <j2seproject3:junit excludes="" includes="${test.includes}"/>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
+ <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
+ </target>
+ <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
+ <!--
+ =======================
+ JUNIT DEBUGGING SECTION
+ =======================
+ -->
+ <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
+ <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
+ <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
+ <delete file="${test.report.file}"/>
+ <mkdir dir="${build.test.results.dir}"/>
+ <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
+ <customize>
+ <syspropertyset>
+ <propertyref prefix="test-sys-prop."/>
+ <mapper from="test-sys-prop.*" to="*" type="glob"/>
+ </syspropertyset>
+ <arg value="${test.class}"/>
+ <arg value="showoutput=true"/>
+ <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
+ <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
+ <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
+ </target>
+ <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
+ <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
+ <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
+ </target>
+ <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
+ <!--
+ =========================
+ APPLET EXECUTION SECTION
+ =========================
+ -->
+ <target depends="init,compile-single" name="run-applet">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <j2seproject1:java classname="sun.applet.AppletViewer">
+ <customize>
+ <arg value="${applet.url}"/>
+ </customize>
+ </j2seproject1:java>
+ </target>
+ <!--
+ =========================
+ APPLET DEBUGGING SECTION
+ =========================
+ -->
+ <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">
+ <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
+ <j2seproject3:debug classname="sun.applet.AppletViewer">
+ <customize>
+ <arg value="${applet.url}"/>
+ </customize>
+ </j2seproject3:debug>
+ </target>
+ <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>
+ <!--
+ ===============
+ CLEANUP SECTION
+ ===============
+ -->
+ <target name="-deps-clean-init" unless="built-clean.properties">
+ <property location="${build.dir}/built-clean.properties" name="built-clean.properties"/>
+ <delete file="${built-clean.properties}" quiet="true"/>
+ </target>
+ <target if="already.built.clean.${basedir}" name="-warn-already-built-clean">
+ <echo level="warn" message="Cycle detected: ConvwatchGUIProject was already built"/>
+ </target>
+ <target depends="init,-deps-clean-init" name="deps-clean" unless="no.deps">
+ <mkdir dir="${build.dir}"/>
+ <touch file="${built-clean.properties}" verbose="false"/>
+ <property file="${built-clean.properties}" prefix="already.built.clean."/>
+ <antcall target="-warn-already-built-clean"/>
+ <propertyfile file="${built-clean.properties}">
+ <entry key="${basedir}" value=""/>
+ </propertyfile>
+ </target>
+ <target depends="init" name="-do-clean">
+ <delete dir="${build.dir}"/>
+ <delete dir="${dist.dir}" followsymlinks="false" includeemptydirs="true"/>
+ </target>
+ <target name="-post-clean">
+ <!-- Empty placeholder for easier customization. -->
+ <!-- You can override this target in the ../build.xml file. -->
+ </target>
+ <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>
+ <target name="-check-call-dep">
+ <property file="${call.built.properties}" prefix="already.built."/>
+ <condition property="should.call.dep">
+ <not>
+ <isset property="already.built.${call.subproject}"/>
+ </not>
+ </condition>
+ </target>
+ <target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">
+ <ant antfile="${call.script}" inheritall="false" target="${call.target}">
+ <propertyset>
+ <propertyref prefix="transfer."/>
+ <mapper from="transfer.*" to="*" type="glob"/>
+ </propertyset>
+ </ant>
+ </target>
+</project>
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/genfiles.properties b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/genfiles.properties
new file mode 100644
index 000000000000..1b4512b96265
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/genfiles.properties
@@ -0,0 +1,8 @@
+build.xml.data.CRC32=d17eccb2
+build.xml.script.CRC32=a183e208
+build.xml.stylesheet.CRC32=958a1d3e@1.32.1.45
+# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
+# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
+nbproject/build-impl.xml.data.CRC32=d17eccb2
+nbproject/build-impl.xml.script.CRC32=ea0e5dc9
+nbproject/build-impl.xml.stylesheet.CRC32=576378a2@1.32.1.45
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/config.properties b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/config.properties
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/config.properties
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.properties b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.properties
new file mode 100644
index 000000000000..18af3f70309a
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.properties
@@ -0,0 +1,7 @@
+application.args=D:\\sources\\gfxcmp02\\DEV300\\ooo\\testgraphical\\wntmsci12.pro\\misc\\CurrentTime.ods.ps.ini
+compile.on.save=true
+do.depend=false
+do.jar=true
+javac.debug=true
+javadoc.preview=true
+user.properties.file=C:\\Documents and Settings\\ll93751\\.netbeans\\6.8\\build.properties
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.xml b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.xml
new file mode 100644
index 000000000000..c1f155a782bd
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/private/private.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project-private xmlns="http://www.netbeans.org/ns/project-private/1">
+ <editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/1"/>
+</project-private>
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.properties b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.properties
new file mode 100644
index 000000000000..3ec3fae330ae
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.properties
@@ -0,0 +1,71 @@
+application.desc=This Program shows three pictures in one line.
+application.title=ConvwatchGUIProject
+application.vendor=Oracle and/or its affiliates
+build.classes.dir=${build.dir}/classes
+build.classes.excludes=**/*.java,**/*.form
+# This directory is removed when the project is cleaned:
+build.dir=build
+build.generated.dir=${build.dir}/generated
+build.generated.sources.dir=${build.dir}/generated-sources
+# Only compile against the classpath explicitly listed here:
+build.sysclasspath=ignore
+build.test.classes.dir=${build.dir}/test/classes
+build.test.results.dir=${build.dir}/test/results
+# Uncomment to specify the preferred debugger connection transport:
+#debug.transport=dt_socket
+debug.classpath=\
+ ${run.classpath}
+debug.test.classpath=\
+ ${run.test.classpath}
+# This directory is removed when the project is cleaned:
+dist.dir=dist
+dist.jar=${dist.dir}/ConvwatchGUIProject.jar
+dist.javadoc.dir=${dist.dir}/javadoc
+endorsed.classpath=
+excludes=
+includes=**
+jar.compress=false
+javac.classpath=
+# Space-separated list of extra javac options
+javac.compilerargs=
+javac.deprecation=false
+javac.source=1.5
+javac.target=1.5
+javac.test.classpath=\
+ ${javac.classpath}:\
+ ${build.classes.dir}:\
+ ${libs.junit.classpath}:\
+ ${libs.junit_4.classpath}
+javadoc.additionalparam=
+javadoc.author=false
+javadoc.encoding=${source.encoding}
+javadoc.noindex=false
+javadoc.nonavbar=false
+javadoc.notree=false
+javadoc.private=false
+javadoc.splitindex=true
+javadoc.use=true
+javadoc.version=false
+javadoc.windowtitle=
+jnlp.codebase.type=local
+jnlp.descriptor=application
+jnlp.enabled=false
+jnlp.offline-allowed=false
+jnlp.signed=false
+main.class=ConvwatchGUI
+manifest.file=manifest.mf
+meta.inf.dir=${src.dir}/META-INF
+platform.active=default_platform
+run.classpath=\
+ ${javac.classpath}:\
+ ${build.classes.dir}
+# Space-separated list of JVM arguments used when running the project
+# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value
+# or test-sys-prop.name=value to set system properties for unit tests):
+run.jvmargs=
+run.test.classpath=\
+ ${javac.test.classpath}:\
+ ${build.test.classes.dir}
+source.encoding=UTF-8
+src.dir=src
+test.src.dir=test
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.xml b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.xml
new file mode 100644
index 000000000000..0bc513904c86
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/nbproject/project.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+ <type>org.netbeans.modules.java.j2seproject</type>
+ <configuration>
+ <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
+ <name>ConvwatchGUIProject</name>
+ <source-roots>
+ <root id="src.dir"/>
+ </source-roots>
+ <test-roots>
+ <root id="test.src.dir"/>
+ </test-roots>
+ </data>
+ </configuration>
+</project>
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.form b/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.form
new file mode 100644
index 000000000000..ad0552d1efd5
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.form
@@ -0,0 +1,286 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<Form version="1.3" maxVersion="1.7" type="org.netbeans.modules.form.forminfo.JFrameFormInfo">
+ <Properties>
+ <Property name="defaultCloseOperation" type="int" value="3"/>
+ </Properties>
+ <SyntheticProperties>
+ <SyntheticProperty name="formSizePolicy" type="int" value="1"/>
+ </SyntheticProperties>
+ <Events>
+ <EventHandler event="componentResized" listener="java.awt.event.ComponentListener" parameters="java.awt.event.ComponentEvent" handler="formComponentResized"/>
+ <EventHandler event="propertyChange" listener="java.beans.PropertyChangeListener" parameters="java.beans.PropertyChangeEvent" handler="formPropertyChange"/>
+ </Events>
+ <AuxValues>
+ <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="0"/>
+ <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="false"/>
+ <AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
+ <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
+ <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
+ <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
+ <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
+ <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
+ <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
+ </AuxValues>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="1" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Group type="103" groupAlignment="1" attributes="0">
+ <Component id="jPanel5" alignment="0" max="32767" attributes="0"/>
+ <Component id="jPanel4" alignment="0" max="32767" attributes="0"/>
+ <Group type="102" alignment="1" attributes="0">
+ <Component id="jPanelOriginal" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jPanelReference" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jPanelDifference" max="32767" attributes="0"/>
+ </Group>
+ </Group>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="1" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jPanel5" min="-2" max="-2" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ <Group type="103" groupAlignment="1" attributes="0">
+ <Component id="jPanelReference" alignment="1" max="32767" attributes="1"/>
+ <Component id="jPanelOriginal" alignment="1" max="32767" attributes="1"/>
+ <Component id="jPanelDifference" alignment="0" max="32767" attributes="1"/>
+ </Group>
+ <EmptySpace min="-2" max="-2" attributes="0"/>
+ <Component id="jPanel4" min="-2" max="-2" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Container class="javax.swing.JPanel" name="jPanelOriginal">
+ <Properties>
+ <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
+ <Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
+ <TitledBorder title="Picture"/>
+ </Border>
+ </Property>
+ </Properties>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jLabelOriginalImage" pref="299" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <Component id="jLabelOriginalImage" pref="514" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Component class="javax.swing.JLabel" name="jLabelOriginalImage">
+ </Component>
+ </SubComponents>
+ </Container>
+ <Container class="javax.swing.JPanel" name="jPanelReference">
+ <Properties>
+ <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
+ <Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
+ <TitledBorder title="Reference Picture"/>
+ </Border>
+ </Property>
+ </Properties>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jLabelReferenceImage" pref="299" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <Component id="jLabelReferenceImage" pref="514" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Component class="javax.swing.JLabel" name="jLabelReferenceImage">
+ </Component>
+ </SubComponents>
+ </Container>
+ <Container class="javax.swing.JPanel" name="jPanelDifference">
+ <Properties>
+ <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
+ <Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
+ <TitledBorder title="Difference"/>
+ </Border>
+ </Property>
+ </Properties>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jLabelDifferenceImage" pref="298" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <Component id="jLabelDifferenceImage" pref="514" max="32767" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Component class="javax.swing.JLabel" name="jLabelDifferenceImage">
+ <Properties>
+ <Property name="name" type="java.lang.String" value="DifferenceImage" noResource="true"/>
+ </Properties>
+ </Component>
+ </SubComponents>
+ </Container>
+ <Container class="javax.swing.JPanel" name="jPanel4">
+ <Properties>
+ <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
+ <Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
+ <TitledBorder title="Action"/>
+ </Border>
+ </Property>
+ </Properties>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="1" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jButton2" min="-2" max="-2" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ <Component id="jButton3" min="-2" max="-2" attributes="0"/>
+ <EmptySpace type="separate" max="-2" attributes="0"/>
+ <Component id="jLabelCurrentPage" min="-2" pref="107" max="-2" attributes="0"/>
+ <EmptySpace pref="614" max="32767" attributes="0"/>
+ <Component id="jButton1" min="-2" max="-2" attributes="0"/>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="1" attributes="0">
+ <EmptySpace max="32767" attributes="0"/>
+ <Group type="103" groupAlignment="3" attributes="0">
+ <Component id="jButton1" alignment="3" min="-2" max="-2" attributes="0"/>
+ <Component id="jButton2" alignment="3" min="-2" max="-2" attributes="0"/>
+ <Component id="jButton3" alignment="3" min="-2" max="-2" attributes="0"/>
+ <Component id="jLabelCurrentPage" alignment="3" min="-2" max="-2" attributes="0"/>
+ </Group>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Component class="javax.swing.JButton" name="jButton1">
+ <Properties>
+ <Property name="text" type="java.lang.String" value="Close"/>
+ </Properties>
+ <Events>
+ <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jButton1ActionPerformed"/>
+ </Events>
+ </Component>
+ <Component class="javax.swing.JButton" name="jButton2">
+ <Properties>
+ <Property name="label" type="java.lang.String" value="prev page"/>
+ </Properties>
+ <Events>
+ <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jButton2ActionPerformed"/>
+ </Events>
+ </Component>
+ <Component class="javax.swing.JButton" name="jButton3">
+ <Properties>
+ <Property name="label" type="java.lang.String" value="next page"/>
+ </Properties>
+ <Events>
+ <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jButton3ActionPerformed"/>
+ </Events>
+ </Component>
+ <Component class="javax.swing.JLabel" name="jLabelCurrentPage">
+ <Properties>
+ <Property name="text" type="java.lang.String" value="Current page: 1"/>
+ </Properties>
+ </Component>
+ </SubComponents>
+ </Container>
+ <Container class="javax.swing.JPanel" name="jPanel5">
+ <Properties>
+ <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
+ <Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
+ <TitledBorder title="Information"/>
+ </Border>
+ </Property>
+ </Properties>
+
+ <Layout>
+ <DimensionLayout dim="0">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="1" attributes="0">
+ <EmptySpace max="-2" attributes="0"/>
+ <Group type="103" groupAlignment="1" attributes="0">
+ <Component id="jLabel1" alignment="0" pref="972" max="32767" attributes="0"/>
+ <Component id="jLabelDocumentName" alignment="0" pref="972" max="32767" attributes="0"/>
+ </Group>
+ <EmptySpace max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ <DimensionLayout dim="1">
+ <Group type="103" groupAlignment="0" attributes="0">
+ <Group type="102" alignment="0" attributes="0">
+ <Component id="jLabel1" pref="50" max="32767" attributes="0"/>
+ <EmptySpace min="-2" max="-2" attributes="0"/>
+ <Component id="jLabelDocumentName" min="-2" pref="19" max="-2" attributes="0"/>
+ <EmptySpace min="-2" max="-2" attributes="0"/>
+ </Group>
+ </Group>
+ </DimensionLayout>
+ </Layout>
+ <SubComponents>
+ <Component class="javax.swing.JLabel" name="jLabel1">
+ <Properties>
+ <Property name="text" type="java.lang.String" value="&lt;html&gt;Here you see a graphical compare by pictures created with a current running office, a stored reference picture and the difference between those both pictures created by ImageMagicks &apos;composite&apos;.&#xa;&lt;/html&gt;" noResource="true"/>
+ </Properties>
+ </Component>
+ <Component class="javax.swing.JLabel" name="jLabelDocumentName">
+ <Properties>
+ <Property name="text" type="java.lang.String" value="jLabel2"/>
+ </Properties>
+ </Component>
+ </SubComponents>
+ </Container>
+ </SubComponents>
+</Form>
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.java b/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.java
new file mode 100644
index 000000000000..625e7b80c6e0
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/src/ConvwatchGUI.java
@@ -0,0 +1,535 @@
+
+import java.awt.Dimension;
+import java.awt.Image;
+import java.io.File;
+import javax.swing.ImageIcon;
+import javax.swing.JLabel;
+import javax.swing.SwingWorker;
+
+/*
+**************************************************************************
+*
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+*
+* Copyright 2000, 2010 Oracle and/or its affiliates.
+*
+* OpenOffice.org - a multi-platform office productivity suite
+*
+* This file is part of OpenOffice.org.
+*
+* OpenOffice.org is free software: you can redistribute it and/or modify
+* it under the terms of the GNU Lesser General Public License version 3
+* only, as published by the Free Software Foundation.
+*
+* OpenOffice.org is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU Lesser General Public License version 3 for more details
+* (a copy is included in the LICENSE file that accompanied this code).
+*
+* You should have received a copy of the GNU Lesser General Public License
+* version 3 along with OpenOffice.org. If not, see
+* <http://www.openoffice.org/license.html>
+* for a copy of the LGPLv3 License.
+*
+**************************************************************************
+ */
+
+/*
+ * Simple windows, which should show differences if there are some
+ */
+
+public class ConvwatchGUI extends javax.swing.JFrame
+{
+ private ImageIcon[] m_aImageIcon;
+ private String m_sInifile;
+ private int m_nMaxPages;
+ private int m_nCurrentPage;
+
+ /** Creates new form ConvwatchGUI
+ * @param args
+ */
+
+ private ConvwatchGUI(String args[])
+ {
+ if (args.length > 0)
+ {
+ if (args[0].endsWith(".ini"))
+ {
+ m_sInifile = args[0];
+ fillImageIconsFromInifile();
+ }
+ else
+ {
+ fillImageIcons(args);
+ }
+ }
+
+ String sVersion = System.getProperty("java.version");
+ Float f = Float.valueOf(sVersion.substring(0,3));
+ if (f.floatValue() < (float)1.6)
+ {
+ System.out.println("You need at least Java version 1.6");
+ System.exit(1);
+ }
+
+ initComponents();
+ jLabelDocumentName.setText("Document: " + m_sInifile);
+ }
+
+ void fillImageIconsFromInifile()
+ {
+ File aFile = new File(m_sInifile);
+ if (!aFile.exists())
+ {
+ GlobalLogWriter.println("Inifile '" + m_sInifile + "' not found.");
+ printUsage();
+ System.exit(1);
+ }
+
+ IniFile aIniFile = new IniFile(aFile);
+ int nPages = aIniFile.getIntValue("global", "pages", 0);
+ if (nPages < 1)
+ {
+ System.out.println("No pages found.");
+ }
+ m_nMaxPages = nPages;
+ m_nCurrentPage = 1;
+ fillImageIcons();
+ }
+
+ private void fillImageIcons()
+ {
+ File aFile = new File(m_sInifile);
+ IniFile aIniFile = new IniFile(aFile);
+ String sSection = "page" + m_nCurrentPage;
+ String[] files = new String[3];
+ files[0] = aIniFile.getValue(sSection, "newgfx"); // current created picture
+ files[1] = aIniFile.getValue(sSection, "oldgfx"); // reference picture
+ files[2] = aIniFile.getValue(sSection, "diffgfx");
+ fillImageIcons(files);
+ }
+
+ /**
+ * Give 3 file names
+ * @param args
+ */
+ private void fillImageIcons(String args[])
+ {
+ boolean bLoadImages = false;
+ m_aImageIcon = new ImageIcon[3];
+ for (int i=0;i<3;i++)
+ {
+ if (args.length > i && args[i] != null)
+ {
+ File aFile = new File(args[i]);
+ if (aFile.exists())
+ {
+ // TODO: Load images
+ // Image aImage = new BufferedImage(100,100, BufferedImage.TYPE_INT_RGB);
+ // aImage.
+ m_aImageIcon[i] = new ImageIcon(args[i]);
+ if (m_aImageIcon[i] != null)
+ {
+ bLoadImages = true;
+ }
+ }
+ else
+ {
+ System.out.println("Can't read file: " + aFile.getName());
+ bLoadImages = false;
+ }
+ }
+ else
+ {
+ System.out.println("There is no #" + (i + 1) + " image given.");
+ bLoadImages = false;
+ }
+ }
+// if (!bLoadImages)
+// {
+// printUsage();
+// System.exit(1);
+// }
+
+
+
+ // TODO: Set images.
+
+ // formComponentResized(null);
+ }
+
+ private void printUsage()
+ {
+ System.out.println("Usage:");
+ System.out.println(" ConvwatchGUI <pic1> <pic2> <pic3>");
+ System.out.println("or ConvwatchGUI <inifile>");
+ }
+
+// private int m_nOldWidth;
+
+ /** This method is called from within the constructor to
+ * initialize the form.
+ * WARNING: Do NOT modify this code. The content of this method is
+ * always regenerated by the Form Editor.
+ */
+ @SuppressWarnings("unchecked")
+ // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
+ private void initComponents() {
+
+ jPanelOriginal = new javax.swing.JPanel();
+ jLabelOriginalImage = new javax.swing.JLabel();
+ jPanelReference = new javax.swing.JPanel();
+ jLabelReferenceImage = new javax.swing.JLabel();
+ jPanelDifference = new javax.swing.JPanel();
+ jLabelDifferenceImage = new javax.swing.JLabel();
+ jPanel4 = new javax.swing.JPanel();
+ jButton1 = new javax.swing.JButton();
+ jButton2 = new javax.swing.JButton();
+ jButton3 = new javax.swing.JButton();
+ jLabelCurrentPage = new javax.swing.JLabel();
+ jPanel5 = new javax.swing.JPanel();
+ jLabel1 = new javax.swing.JLabel();
+ jLabelDocumentName = new javax.swing.JLabel();
+
+ setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
+ addComponentListener(new java.awt.event.ComponentAdapter() {
+ public void componentResized(java.awt.event.ComponentEvent evt) {
+ formComponentResized(evt);
+ }
+ });
+ addPropertyChangeListener(new java.beans.PropertyChangeListener() {
+ public void propertyChange(java.beans.PropertyChangeEvent evt) {
+ formPropertyChange(evt);
+ }
+ });
+
+ jPanelOriginal.setBorder(javax.swing.BorderFactory.createTitledBorder("Picture"));
+
+ javax.swing.GroupLayout jPanelOriginalLayout = new javax.swing.GroupLayout(jPanelOriginal);
+ jPanelOriginal.setLayout(jPanelOriginalLayout);
+ jPanelOriginalLayout.setHorizontalGroup(
+ jPanelOriginalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelOriginalLayout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jLabelOriginalImage, javax.swing.GroupLayout.DEFAULT_SIZE, 299, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+ jPanelOriginalLayout.setVerticalGroup(
+ jPanelOriginalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelOriginalLayout.createSequentialGroup()
+ .addComponent(jLabelOriginalImage, javax.swing.GroupLayout.DEFAULT_SIZE, 514, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+
+ jPanelReference.setBorder(javax.swing.BorderFactory.createTitledBorder("Reference Picture"));
+
+ javax.swing.GroupLayout jPanelReferenceLayout = new javax.swing.GroupLayout(jPanelReference);
+ jPanelReference.setLayout(jPanelReferenceLayout);
+ jPanelReferenceLayout.setHorizontalGroup(
+ jPanelReferenceLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelReferenceLayout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jLabelReferenceImage, javax.swing.GroupLayout.DEFAULT_SIZE, 299, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+ jPanelReferenceLayout.setVerticalGroup(
+ jPanelReferenceLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelReferenceLayout.createSequentialGroup()
+ .addComponent(jLabelReferenceImage, javax.swing.GroupLayout.DEFAULT_SIZE, 514, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+
+ jPanelDifference.setBorder(javax.swing.BorderFactory.createTitledBorder("Difference"));
+
+ jLabelDifferenceImage.setName("DifferenceImage"); // NOI18N
+
+ javax.swing.GroupLayout jPanelDifferenceLayout = new javax.swing.GroupLayout(jPanelDifference);
+ jPanelDifference.setLayout(jPanelDifferenceLayout);
+ jPanelDifferenceLayout.setHorizontalGroup(
+ jPanelDifferenceLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelDifferenceLayout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jLabelDifferenceImage, javax.swing.GroupLayout.DEFAULT_SIZE, 298, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+ jPanelDifferenceLayout.setVerticalGroup(
+ jPanelDifferenceLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanelDifferenceLayout.createSequentialGroup()
+ .addComponent(jLabelDifferenceImage, javax.swing.GroupLayout.DEFAULT_SIZE, 514, Short.MAX_VALUE)
+ .addContainerGap())
+ );
+
+ jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder("Action"));
+
+ jButton1.setText("Close");
+ jButton1.addActionListener(new java.awt.event.ActionListener() {
+ public void actionPerformed(java.awt.event.ActionEvent evt) {
+ jButton1ActionPerformed(evt);
+ }
+ });
+
+ jButton2.setLabel("prev page");
+ jButton2.addActionListener(new java.awt.event.ActionListener() {
+ public void actionPerformed(java.awt.event.ActionEvent evt) {
+ jButton2ActionPerformed(evt);
+ }
+ });
+
+ jButton3.setLabel("next page");
+ jButton3.addActionListener(new java.awt.event.ActionListener() {
+ public void actionPerformed(java.awt.event.ActionEvent evt) {
+ jButton3ActionPerformed(evt);
+ }
+ });
+
+ jLabelCurrentPage.setText("Current page: 1");
+
+ javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
+ jPanel4.setLayout(jPanel4Layout);
+ jPanel4Layout.setHorizontalGroup(
+ jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel4Layout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jButton2)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addComponent(jButton3)
+ .addGap(18, 18, 18)
+ .addComponent(jLabelCurrentPage, javax.swing.GroupLayout.PREFERRED_SIZE, 107, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 614, Short.MAX_VALUE)
+ .addComponent(jButton1)
+ .addContainerGap())
+ );
+ jPanel4Layout.setVerticalGroup(
+ jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel4Layout.createSequentialGroup()
+ .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
+ .addComponent(jButton1)
+ .addComponent(jButton2)
+ .addComponent(jButton3)
+ .addComponent(jLabelCurrentPage))
+ .addContainerGap())
+ );
+
+ jPanel5.setBorder(javax.swing.BorderFactory.createTitledBorder("Information"));
+
+ jLabel1.setText("<html>Here you see a graphical compare by pictures created with a current running office, a stored reference picture and the difference between those both pictures created by ImageMagicks 'composite'.\n</html>"); // NOI18N
+
+ jLabelDocumentName.setText("jLabel2");
+
+ javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
+ jPanel5.setLayout(jPanel5Layout);
+ jPanel5Layout.setHorizontalGroup(
+ jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel5Layout.createSequentialGroup()
+ .addContainerGap()
+ .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
+ .addComponent(jLabel1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 972, Short.MAX_VALUE)
+ .addComponent(jLabelDocumentName, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 972, Short.MAX_VALUE))
+ .addContainerGap())
+ );
+ jPanel5Layout.setVerticalGroup(
+ jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(jPanel5Layout.createSequentialGroup()
+ .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, 50, Short.MAX_VALUE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addComponent(jLabelDocumentName, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addContainerGap())
+ );
+
+ javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
+ getContentPane().setLayout(layout);
+ layout.setHorizontalGroup(
+ layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
+ .addContainerGap()
+ .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
+ .addComponent(jPanel5, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addComponent(jPanel4, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addGroup(layout.createSequentialGroup()
+ .addComponent(jPanelOriginal, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addComponent(jPanelReference, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addComponent(jPanelDifference, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
+ .addContainerGap())
+ );
+ layout.setVerticalGroup(
+ layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
+ .addComponent(jPanelReference, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addComponent(jPanelOriginal, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
+ .addComponent(jPanelDifference, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addComponent(jPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addContainerGap())
+ );
+
+ pack();
+ }// </editor-fold>//GEN-END:initComponents
+
+ private boolean bAdd = false;
+
+ private void formComponentResized(java.awt.event.ComponentEvent evt)//GEN-FIRST:event_formComponentResized
+ {//GEN-HEADEREND:event_formComponentResized
+ // TODO add your handling code here:
+ // we need to set icons to null
+ // if we don't do this, icons can only grow, but not shrink :-(
+
+ initialiseImages();
+ }
+ private void initialiseImages()
+ {
+ if (jLabelOriginalImage.getIcon() != null)
+ {
+ jLabelOriginalImage.setIcon(null);
+ jLabelReferenceImage.setIcon(null);
+ jLabelDifferenceImage.setIcon(null);
+
+ int w = getWidth();
+ int h = getHeight();
+ if (bAdd)
+ {
+ this.setSize(w, h + 1);
+ bAdd = false;
+ }
+ else
+ {
+ this.setSize(w, h - 1);
+ bAdd = true;
+ }
+ }
+ else
+ {
+ new ResizeImage(jLabelOriginalImage, m_aImageIcon[0]).execute();
+ new ResizeImage(jLabelReferenceImage, m_aImageIcon[1]).execute();
+ new ResizeImage(jLabelDifferenceImage, m_aImageIcon[2]).execute();
+ }
+ int dummy=0;
+ }//GEN-LAST:event_formComponentResized
+
+ private void jButton1ActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_jButton1ActionPerformed
+ {//GEN-HEADEREND:event_jButton1ActionPerformed
+ // TODO add your handling code here:
+ System.exit(1);
+ }//GEN-LAST:event_jButton1ActionPerformed
+
+ private void formPropertyChange(java.beans.PropertyChangeEvent evt)//GEN-FIRST:event_formPropertyChange
+ {//GEN-HEADEREND:event_formPropertyChange
+ // TODO add your handling code here:
+ int dummy = 0;
+ }//GEN-LAST:event_formPropertyChange
+
+ private void jButton2ActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_jButton2ActionPerformed
+ {//GEN-HEADEREND:event_jButton2ActionPerformed
+ // TODO add your handling code here:
+ int nOldPage = m_nCurrentPage;
+ if (m_nCurrentPage > 1)
+ {
+ m_nCurrentPage--;
+ }
+ if (nOldPage != m_nCurrentPage)
+ {
+ jLabelCurrentPage.setText("Current page: " + m_nCurrentPage);
+ fillImageIcons();
+ initialiseImages();
+ }
+ }//GEN-LAST:event_jButton2ActionPerformed
+
+ private void jButton3ActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_jButton3ActionPerformed
+ {//GEN-HEADEREND:event_jButton3ActionPerformed
+ // TODO add your handling code here:
+ int nOldPage = m_nCurrentPage;
+ if (m_nCurrentPage < m_nMaxPages)
+ {
+ m_nCurrentPage++;
+ }
+ if (nOldPage != m_nCurrentPage)
+ {
+ jLabelCurrentPage.setText("Current page: " + m_nCurrentPage);
+ fillImageIcons();
+ initialiseImages();
+ }
+ }//GEN-LAST:event_jButton3ActionPerformed
+
+ class ResizeImage extends SwingWorker <ImageIcon, Object>
+ {
+ private JLabel m_jLabel;
+ private ImageIcon m_aImageIcon;
+ private int w;
+ private int h;
+
+ public ResizeImage(JLabel _aLabel, ImageIcon _aImageIcon)
+ {
+ m_jLabel = _aLabel;
+ m_aImageIcon = _aImageIcon;
+ w = _aLabel.getWidth();
+ h = _aLabel.getHeight();
+ }
+
+ // dont access here anything to "Event Swing Thread"
+ @Override
+ public ImageIcon doInBackground()
+ {
+ Image aImage = m_aImageIcon.getImage().getScaledInstance(w, h, Image.SCALE_AREA_AVERAGING); // SCALE_SMOOTH
+ final ImageIcon aIcon = new ImageIcon(aImage);
+ // m_jLabel.setIcon(aIcon);
+ return aIcon;
+ }
+
+ @Override
+ protected void done()
+ {
+ try
+ {
+ m_jLabel.setIcon(get());
+ }
+ catch (Exception e)
+ {}
+ }
+
+ }
+
+ /**
+ * @param args the command line arguments
+ */
+ public static void main(final String args[])
+ {
+
+ // Start GUI
+
+ java.awt.EventQueue.invokeLater(new Runnable()
+ {
+
+ public void run()
+ {
+ ConvwatchGUI aGUI = new ConvwatchGUI(args);
+ aGUI.setTitle("Graphical Compare");
+ aGUI.setPreferredSize(new Dimension(1024, 768));
+
+ aGUI.setVisible(true);
+ }
+ });
+ }
+ // Variables declaration - do not modify//GEN-BEGIN:variables
+ private javax.swing.JButton jButton1;
+ private javax.swing.JButton jButton2;
+ private javax.swing.JButton jButton3;
+ private javax.swing.JLabel jLabel1;
+ private javax.swing.JLabel jLabelCurrentPage;
+ private javax.swing.JLabel jLabelDifferenceImage;
+ private javax.swing.JLabel jLabelDocumentName;
+ private javax.swing.JLabel jLabelOriginalImage;
+ private javax.swing.JLabel jLabelReferenceImage;
+ private javax.swing.JPanel jPanel4;
+ private javax.swing.JPanel jPanel5;
+ private javax.swing.JPanel jPanelDifference;
+ private javax.swing.JPanel jPanelOriginal;
+ private javax.swing.JPanel jPanelReference;
+ // End of variables declaration//GEN-END:variables
+}
diff --git a/testgraphical/ui/java/ConvwatchGUIProject/src/IniFile.java b/testgraphical/ui/java/ConvwatchGUIProject/src/IniFile.java
new file mode 100644
index 000000000000..20cede5b1c33
--- /dev/null
+++ b/testgraphical/ui/java/ConvwatchGUIProject/src/IniFile.java
@@ -0,0 +1,718 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+import java.io.File;
+import java.io.RandomAccessFile;
+import java.util.ArrayList;
+import java.util.Enumeration;
+
+
+/**
+ * Simple implementation of a inifile manager
+ */
+class GlobalLogWriter
+{
+ public static void println(String _s)
+ {
+ System.out.println(_s);
+ }
+}
+
+/**
+ Helper class to give a simple API to read/write windows like ini files
+*/
+
+/* public */ // is only need, if we need this class outside package convwatch
+public class IniFile implements Enumeration
+{
+
+ /**
+ * internal representation of the ini file content.
+ * Problem, if ini file changed why other write something difference, we don't realise this.
+ */
+ private String m_sFilename;
+ // private File m_aFile;
+ private ArrayList<String> m_aList;
+ boolean m_bListContainUnsavedChanges = false;
+ private int m_aEnumerationPos = 0;
+
+ /**
+ open a ini file by it's name
+ @param _sFilename string a filename, if the file doesn't exist, a new empty ini file will create.
+ write back to disk only if there are really changes.
+ */
+ public IniFile(String _sFilename)
+ {
+ m_sFilename = _sFilename;
+ // m_aFile = new File(_sFilename);
+ m_aList = loadLines();
+ m_aEnumerationPos = findNextSection(0);
+ }
+
+ /**
+ open a ini file by it's name
+ @param _aFile a java.io.File object, if the file doesn't exist, a new empty ini file will create.
+ write back to disk only if there are really changes.
+ */
+ public IniFile(File _aFile)
+ {
+ m_sFilename = _aFile.getAbsolutePath();
+ m_aList = loadLines();
+ m_aEnumerationPos = findNextSection(0);
+ }
+
+ public void insertFirstComment(String[] _aList)
+ {
+ if (m_aList.size() == 0)
+ {
+ // can only insert if there is nothing else already in the ini file
+ for (int i = 0; i < _aList.length; i++)
+ {
+ m_aList.add(_aList[i]);
+ }
+ }
+ }
+
+ private ArrayList<String> loadLines()
+ {
+ ArrayList<String> aLines = new ArrayList<String>();
+ File aFile = new File(m_sFilename);
+ if (!aFile.exists())
+ {
+ // GlobalLogWriter.println("couldn't find file '" + m_sFilename + "', will be created.");
+ // DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
+ // m_bListContainUnsavedChanges = false;
+ return aLines;
+ }
+ RandomAccessFile aReader = null;
+ // BufferedReader aReader;
+ try
+ {
+ aReader = new RandomAccessFile(aFile, "r");
+ String aLine = "";
+ while (aLine != null)
+ {
+ aLine = aReader.readLine();
+ if (aLine != null && aLine.length() > 0)
+ {
+ aLines.add(aLine);
+ }
+ }
+ }
+ catch (java.io.FileNotFoundException fne)
+ {
+ GlobalLogWriter.println("couldn't open file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + fne.getMessage());
+ // DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
+ }
+ catch (java.io.IOException ie)
+ {
+ GlobalLogWriter.println("Exception occurs while reading from file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
+ // DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
+ }
+ try
+ {
+ aReader.close();
+ }
+ catch (java.io.IOException ie)
+ {
+ GlobalLogWriter.println("Couldn't close file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
+ // DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
+ }
+ return aLines;
+ }
+
+ /**
+ * @return true, if the ini file contain some readable data
+ */
+ public boolean is()
+ {
+ return m_aList.size() > 1 ? true : false;
+ }
+
+ /**
+ * Check if a given Section and Key exists in the ini file
+ * @param _sSectionName
+ * @param _sKey
+ * @return true if the given Section, Key exists, now you can get the value
+ */
+ public boolean hasValue(String _sSectionName, String _sKey)
+ {
+ int n = findKey(_sSectionName, _sKey);
+ if (n > 0)
+ {
+ return true;
+ }
+ return false;
+ }
+ // -----------------------------------------------------------------------------
+
+ private boolean isRemark(String _sLine)
+ {
+ if (((_sLine.length() < 2)) ||
+ (_sLine.startsWith("#")) ||
+ (_sLine.startsWith(";")))
+ {
+ return true;
+ }
+ return false;
+ }
+
+ private String getItem(int i)
+ {
+ return m_aList.get(i);
+ }
+
+ private String buildSectionName(String _sSectionName)
+ {
+ String sFindSection = "[" + _sSectionName + "]";
+ return sFindSection;
+ }
+
+ private String sectionToString(String _sSectionName)
+ {
+ String sKeyName = _sSectionName;
+ if (sKeyName.startsWith("[") &&
+ sKeyName.endsWith("]"))
+ {
+ sKeyName = sKeyName.substring(1, sKeyName.length() - 1);
+ }
+ return sKeyName;
+ }
+
+ private String toLowerIfNeed(String _sName)
+ {
+ return _sName.toLowerCase();
+ }
+
+ // return the number where this section starts
+ private int findSection(String _sSection)
+ {
+ String sFindSection = toLowerIfNeed(buildSectionName(_sSection));
+ // ----------- find _sSection ---------------
+ int i;
+ for (i = 0; i < m_aList.size(); i++)
+ {
+ String sLine = toLowerIfNeed(getItem(i).trim());
+ if (isRemark(sLine))
+ {
+ continue;
+ }
+ if (sFindSection.equals("[]"))
+ {
+ // special case, empty Section.
+ return i - 1;
+ }
+ if (sLine.startsWith(sFindSection))
+ {
+ return i;
+ }
+ }
+ return -1;
+ }
+
+ /**
+ * Checks if a given section exists in the ini file
+ * @param _sSection
+ * @return true if the given _sSection was found
+ */
+ public boolean hasSection(String _sSection)
+ {
+ int i = findSection(_sSection);
+ if (i == -1)
+ {
+ return false;
+ }
+ return true;
+ }
+
+ // return the line number, where the key is found.
+ private int findKey(String _sSection, String _sKey)
+ {
+ int i = findSection(_sSection);
+ if (i == -1)
+ {
+ // Section not found, therefore the value can't exist
+ return -1;
+ }
+ return findKeyFromKnownSection(i, _sKey);
+ }
+
+ // i must be the index in the list, where the well known section starts
+ private int findKeyFromKnownSection(int _nSectionIndex, String _sKey)
+ {
+ _sKey = toLowerIfNeed(_sKey);
+ for (int j = _nSectionIndex + 1; j < m_aList.size(); j++)
+ {
+ String sLine = getItem(j).trim();
+
+ if (isRemark(sLine))
+ {
+ continue;
+ }
+ if (sLine.startsWith("[") /* && sLine.endsWith("]") */)
+ {
+ // TODO: due to the fact we would like to insert an empty line before new sections
+ // TODO: we should check if we are in an empty line and if, go back one line.
+
+ // found end.
+ break;
+ }
+
+ int nEqual = sLine.indexOf("=");
+ if (nEqual >= 0)
+ {
+ String sKey = toLowerIfNeed(sLine.substring(0, nEqual).trim());
+ if (sKey.equals(_sKey))
+ {
+ return j;
+ }
+ }
+ }
+ return -1;
+ }
+
+ // i must be the index in the list, where the well known section starts
+ private int findLastKnownKeyIndex(int _nSectionIndex, String _sKey)
+ {
+ _sKey = toLowerIfNeed(_sKey);
+ int i = _nSectionIndex + 1;
+ for (int j = i; j < m_aList.size(); j++)
+ {
+ String sLine = getItem(j).trim();
+
+ if (isRemark(sLine))
+ {
+ continue;
+ }
+
+ if (sLine.startsWith("[") /* && sLine.endsWith("]") */)
+ {
+ // found end.
+ return j;
+ }
+
+ int nEqual = sLine.indexOf("=");
+ if (nEqual >= 0)
+ {
+ String sKey = toLowerIfNeed(sLine.substring(0, nEqual).trim());
+ if (sKey.equals(_sKey))
+ {
+ return j;
+ }
+ }
+ }
+ return i;
+ }
+
+ private String getValue(int _nIndex)
+ {
+ String sLine = getItem(_nIndex).trim();
+ if (isRemark(sLine))
+ {
+ return "";
+ }
+ int nEqual = sLine.indexOf("=");
+ if (nEqual >= 0)
+ {
+ String sKey = sLine.substring(0, nEqual).trim();
+ String sValue = sLine.substring(nEqual + 1).trim();
+ return sValue;
+ }
+ return "";
+ }
+
+ /**
+ @param _sSection string
+ @param _sKey string
+ @return the value found in the inifile which is given by the section and key parameter
+ */
+ // private int m_nCurrentPosition;
+ // private String m_sOldKey;
+ public String getValue(String _sSection, String _sKey)
+ {
+ String sValue = "";
+ int m_nCurrentPosition = findKey(_sSection, _sKey);
+ if (m_nCurrentPosition == -1)
+ {
+ // Section not found, therefore the value can't exist
+ return "";
+ }
+
+ // m_sOldKey = _sKey;
+ sValue = getValue(m_nCurrentPosition);
+
+ return sValue;
+ }
+
+// private String getNextValue()
+// {
+// if (m_nCurrentPosition >= 0)
+// {
+// ++m_nCurrentPosition;
+// String sValue = getValue(m_nCurrentPosition);
+// return sValue;
+// }
+// return "";
+// }
+ /**
+ * Returns the value at Section, Key converted to an integer
+ * Check with hasValue(Section, Key) to check before you get into trouble.
+ * @param _sSection
+ * @param _sKey
+ * @param _nDefault if there is a problem, key not found... this value will return
+ * @return the value as integer if possible to convert, if not return default value.
+ */
+ public int getIntValue(String _sSection, String _sKey, int _nDefault)
+ {
+ String sValue = getValue(_sSection, _sKey);
+ int nValue = _nDefault;
+ if (sValue.length() > 0)
+ {
+ try
+ {
+ nValue = Integer.valueOf(sValue).intValue();
+ }
+ catch (java.lang.NumberFormatException e)
+ {
+ GlobalLogWriter.println("IniFile.getIntValue(): Caught a number format exception, return the default value.");
+ }
+ }
+ return nValue;
+ }
+
+/**
+ * close a open inifile.
+ * If there are changes, all changes will store back to disk.
+ */
+ public void close()
+ {
+ store();
+ }
+
+ /**
+ write back the ini file to the disk, only if there exist changes
+ * @deprecated use close() instead!
+ */
+
+ // TODO: make private
+ private void store()
+ {
+ if (m_bListContainUnsavedChanges == false)
+ {
+ // nothing has changed, so no need to store
+ return;
+ }
+
+ File aFile = new File(m_sFilename);
+ if (aFile.exists())
+ {
+ // System.out.println("couldn't find file " + m_sFilename);
+ // TODO: little bit unsafe here, first rename, after write is complete, delete the old.
+ aFile.delete();
+ if (aFile.exists())
+ {
+ GlobalLogWriter.println("Couldn't delete the file " + m_sFilename);
+ return;
+ // DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, "Couldn't delete the file " + m_sFilename);
+ }
+ }
+ // if (! aFile.canWrite())
+ // {
+ // System.out.println("Couldn't write to file " + m_sFilename);
+ // DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, "");
+ // }
+ try
+ {
+ RandomAccessFile aWriter = new RandomAccessFile(aFile, "rw");
+ for (int i = 0; i < m_aList.size(); i++)
+ {
+ String sLine = getItem(i);
+ if (sLine.startsWith("["))
+ {
+ // write an extra empty line before next section.
+ aWriter.writeByte((int) '\n');
+ }
+ aWriter.writeBytes(sLine);
+ aWriter.writeByte((int) '\n');
+ }
+ aWriter.close();
+ }
+ catch (java.io.FileNotFoundException fne)
+ {
+ GlobalLogWriter.println("couldn't open file for writing " + m_sFilename);
+ GlobalLogWriter.println("Message: " + fne.getMessage());
+ // DebugHelper.exception(BasicErrorCode.SbERR_FILE_NOT_FOUND, "");
+ }
+ catch (java.io.IOException ie)
+ {
+ GlobalLogWriter.println("Exception occurs while writing to file " + m_sFilename);
+ GlobalLogWriter.println("Message: " + ie.getMessage());
+ // DebugHelper.exception(BasicErrorCode.SbERR_INTERNAL_ERROR, ie.getMessage());
+ }
+ }
+
+ public void insertValue(String _sSection, String _sKey, int _nValue)
+ {
+ insertValue(_sSection, _sKey, String.valueOf(_nValue));
+ }
+
+ public void insertValue(String _sSection, String _sKey, long _nValue)
+ {
+ insertValue(_sSection, _sKey, String.valueOf(_nValue));
+ }
+
+ /**
+ insert a value
+ there are 3 cases
+ 1. section doesn't exist, goto end and insert a new section, insert a new key value pair
+ 2. section exist but key not, search section, search key, if key is -1 get last known key position and insert new key value pair there
+ 3. section exist and key exist, remove the old key and insert the key value pair at the same position
+ * @param _sSection
+ * @param _sKey
+ * @param _sValue
+ */
+ public void insertValue(String _sSection, String _sKey, String _sValue)
+ {
+ int i = findSection(_sSection);
+ if (i == -1)
+ {
+ // case 1: section doesn't exist
+ String sFindSection = buildSectionName(_sSection);
+
+ // TODO: before create a new Section, insert a empty line
+ m_aList.add(sFindSection);
+ if (_sKey.length() > 0)
+ {
+ String sKeyValuePair = _sKey + "=" + _sValue;
+ m_aList.add(sKeyValuePair);
+ }
+ m_bListContainUnsavedChanges = true;
+ return;
+ }
+ int j = findKeyFromKnownSection(i, _sKey);
+ if (j == -1)
+ {
+ // case 2: section exist, but not the key
+ j = findLastKnownKeyIndex(i, _sKey);
+ if (_sKey.length() > 0)
+ {
+ String sKeyValuePair = _sKey + "=" + _sValue;
+ m_aList.add(j, sKeyValuePair);
+ m_bListContainUnsavedChanges = true;
+ }
+ return;
+ }
+ else
+ {
+ // case 3: section exist, and also the key
+ String sKeyValuePair = _sKey + "=" + _sValue;
+ m_aList.set(j, sKeyValuePair);
+ m_bListContainUnsavedChanges = true;
+ }
+ }
+ // -----------------------------------------------------------------------------
+ // String replaceEvaluatedValue(String _sSection, String _sValue)
+ // {
+ // String sValue = _sValue;
+ // int nIndex = 0;
+ // while (( nIndex = sValue.indexOf("$(", nIndex)) >= 0)
+ // {
+ // int nNextIndex = sValue.indexOf(")", nIndex);
+ // if (nNextIndex >= 0)
+ // {
+ // String sKey = sValue.substring(nIndex + 2, nNextIndex);
+ // String sNewValue = getValue(_sSection, sKey);
+ // if (sNewValue != null && sNewValue.length() > 0)
+ // {
+ // String sRegexpKey = "\\$\\(" + sKey + "\\)";
+ // sValue = sValue.replaceAll(sRegexpKey, sNewValue);
+ // }
+ // nIndex = nNextIndex;
+ // }
+ // else
+ // {
+ // nIndex += 2;
+ // }
+ // }
+ // return sValue;
+ // }
+ // -----------------------------------------------------------------------------
+
+ // public String getLocalEvaluatedValue(String _sSection, String _sKey)
+ // {
+ // String sValue = getValue(_sSection, _sKey);
+ // sValue = replaceEvaluatedValue(_sSection, sValue);
+ // return sValue;
+ // }
+
+ // -----------------------------------------------------------------------------
+
+ // this is a special behaviour.
+ // public String getGlobalLocalEvaluatedValue(String _sSection, String _sKey)
+ // {
+ // String sGlobalValue = getKey("global", _sKey);
+ // String sLocalValue = getKey(_sSection, _sKey);
+ // if (sLocalValue.length() == 0)
+ // {
+ // sGlobalValue = replaceEvaluatedKey(_sSection, sGlobalValue);
+ // sGlobalValue = replaceEvaluatedKey("global", sGlobalValue);
+ // return sGlobalValue;
+ // }
+ // sLocalValue = replaceEvaluatedKey(_sSection, sLocalValue);
+ // sLocalValue = replaceEvaluatedKey("global", sLocalValue);
+ //
+ // return sLocalValue;
+ // }
+ public void removeSection(String _sSectionToRemove)
+ {
+ // first, search for the name
+ int i = findSection(_sSectionToRemove);
+ if (i == -1)
+ {
+ // Section to remove not found, do nothing.
+ return;
+ }
+ // second, find the next section
+ int j = findNextSection(i + 1);
+ if (j == -1)
+ {
+ // if we are at the end, use size() as second section
+ j = m_aList.size();
+ }
+ // remove all between first and second section
+ for (int k = i; k < j; k++)
+ {
+ m_aList.remove(i);
+ }
+ // mark the list as changed
+ m_bListContainUnsavedChanges = true;
+ }
+
+ /**
+ * some tests for this class
+ */
+// public static void main(String[] args)
+// {
+// String sTempFile = System.getProperty("java.io.tmpdir");
+// sTempFile += "inifile";
+//
+//
+// IniFile aIniFile = new IniFile(sTempFile);
+// String sValue = aIniFile.getValue("Section", "Key");
+// // insert a new value to a already exist section
+// aIniFile.insertValue("Section", "Key2", "a new value in a existing section");
+// // replace a value
+// aIniFile.insertValue("Section", "Key", "replaced value");
+// // create a new value
+// aIniFile.insertValue("New Section", "Key", "a new key value pair");
+// aIniFile.insertValue("New Section", "Key2", "a new second key value pair");
+//
+// String sValue2 = aIniFile.getValue("Section2", "Key");
+//
+// aIniFile.removeSection("Section");
+// aIniFile.removeSection("New Section");
+//
+// aIniFile.close();
+// }
+
+ /**
+ * Enumeration Interface
+ * @return true, if there are more Key values
+ */
+ public boolean hasMoreElements()
+ {
+ if (m_aEnumerationPos >= 0 &&
+ m_aEnumerationPos < m_aList.size())
+ {
+ return true;
+ }
+ return false;
+ }
+
+ /**
+ * Find the next line, which starts with '['
+ * @param i start position
+ * @return the line where '[' found or -1
+ */
+ private int findNextSection(int i)
+ {
+ if (i >= 0)
+ {
+ while (i < m_aList.size())
+ {
+ String sLine = m_aList.get(i);
+ if (sLine.startsWith("["))
+ {
+ return i;
+ }
+ i++;
+ }
+ }
+ return -1;
+ }
+
+ /**
+ * Enumeration Interface
+ * @return a key without the enveloped '[' ']'
+ */
+ public Object nextElement()
+ {
+ int nLineWithSection = findNextSection(m_aEnumerationPos);
+ if (nLineWithSection != -1)
+ {
+ String sSection = m_aList.get(nLineWithSection);
+ m_aEnumerationPos = findNextSection(nLineWithSection + 1);
+ sSection = sectionToString(sSection);
+ return sSection;
+ }
+ else
+ {
+ m_aEnumerationPos = m_aList.size();
+ }
+ return null;
+ }
+
+ /**
+ * Helper to count the occurence of Sections
+ * @return returns the count of '^['.*']$' Elements
+ */
+ public int getElementCount()
+ {
+ int nCount = 0;
+ int nPosition = 0;
+ while ((nPosition = findNextSection(nPosition)) != -1)
+ {
+ nCount++;
+ nPosition++;
+ }
+ return nCount;
+ }
+}
+
diff --git a/testshl2/inc/makefile.mk b/testgraphical/ui/java/makefile.mk
index cbed35c5cbb3..134787a17a08 100644
--- a/testshl2/inc/makefile.mk
+++ b/testgraphical/ui/java/makefile.mk
@@ -24,24 +24,30 @@
# for a copy of the LGPLv3 License.
#
#*************************************************************************
-PRJ=..
-PRJNAME=testshl2
-TARGET=inc
+PRJ=..$/..
+
+PRJNAME=gfxcmp_ui_java
+TARGET=notargetyet
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
-# --- Files --------------------------------------------------------
-# --- Targets -------------------------------------------------------
+# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
-.IF "$(ENABLE_PCH)"!=""
-ALLTAR : \
- $(SLO)$/precompiled.pch \
- $(SLO)$/precompiled_ex.pch
-
-.ENDIF # "$(ENABLE_PCH)"!=""
+.IF "$(SHOW)" == ""
+nothing .PHONY:
+
+.ELSE
+
+# PERLDEBUG=-d:ptkdb
+ALLTAR:
+ $(COPY) ConvwatchGUIProject$/dist/ConvwatchGUIProject.jar $(CLASSDIR)
+
+.END
+
+.INCLUDE : $(PRJ)$/util$/makefile.pmk
diff --git a/testtools/source/bridgetest/component.gcc3.map b/testgraphical/util/makefile.pmk
index 609b64e1e0ca..98b94dca0779 100644
--- a/testtools/source/bridgetest/component.gcc3.map
+++ b/testgraphical/util/makefile.pmk
@@ -1,7 +1,7 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -25,14 +25,10 @@
#
#*************************************************************************
-UDK_3_0_0 {
- global:
- component_getFactory;
- component_getImplementationEnvironment;
- component_writeInfo;
+# this file will include by other makefiles only
- _ZN4_STL7num_put*; # STLport
+demo: ALLTAR
+selftest: ALLTAR
+failtest: ALLTAR
- local:
- *;
-};
+clean: clean_all
diff --git a/testshl2/README b/testshl2/README
deleted file mode 100644
index 03e7475a1d6e..000000000000
--- a/testshl2/README
+++ /dev/null
@@ -1,8 +0,0 @@
-This is the second version of the testshl.
-
-Upper-lower case filenames.
-- I prever lower case filenames. Due to the fact that the cppunit
- code uses mixed upper and lower case I leave the original filenames
- unchanged.
-
-
diff --git a/testshl2/inc/pch/precompiled_testshl2.cxx b/testshl2/inc/pch/precompiled_testshl2.cxx
deleted file mode 100644
index c30f5dd27e3e..000000000000
--- a/testshl2/inc/pch/precompiled_testshl2.cxx
+++ /dev/null
@@ -1,29 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#include "precompiled_testshl2.hxx"
-
diff --git a/testshl2/inc/pch/precompiled_testshl2.hxx b/testshl2/inc/pch/precompiled_testshl2.hxx
deleted file mode 100644
index 4de524c0c650..000000000000
--- a/testshl2/inc/pch/precompiled_testshl2.hxx
+++ /dev/null
@@ -1,32 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): Generated on 2006-09-01 17:50:13.576513
-
-#ifdef PRECOMPILED_HEADERS
-#endif
-
diff --git a/testshl2/inc/testshl/additionalfunc.hxx b/testshl2/inc/testshl/additionalfunc.hxx
deleted file mode 100644
index 463d1ae87280..000000000000
--- a/testshl2/inc/testshl/additionalfunc.hxx
+++ /dev/null
@@ -1,61 +0,0 @@
-#ifndef ADDITIONALFUNC_HXX
-#define ADDITIONALFUNC_HXX
-
-#include "testshl/autoregister/registertestfunction.h"
-#include "sal/types.h"
-
-extern "C" void SAL_CALL RegisterAdditionalFunctions(FktRegFuncPtr _pFunc);
-
-#define NOADDITIONAL \
-void RegisterAdditionalFunctions(FktRegFuncPtr){}
-
-namespace {
-
-enum T2_OSType {
- T2_OS_WNT32 = 1,
- T2_OS_UNIX,
- T2_OS_OS2
-};
-
-inline T2_OSType getOSType()
-{
-#if defined WNT
- return T2_OS_WNT32;
-#elif defined OS2
- return T2_OS_OS2;
-#else
- return T2_OS_UNIX;
-#endif
-}
-
-}
-
-#define TESTSHL2_UNO_BOOTSTRAP(file) \
-void RegisterAdditionalFunctions(FktRegFuncPtr _pFunc) \
-{ \
- com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory> xMS; \
- com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > xComponentContext; \
- try { \
- if (strlen(#file) > 0) { \
- ::rtl::OUString iniFile(rtl::OUString::createFromAscii(#file)); \
- if (getOSType() == T2_OS_WNT32 || getOSType() == T2_OS_OS2) { \
- iniFile += ::rtl::OUString::createFromAscii(".ini"); \
- } else { \
- iniFile += ::rtl::OUString::createFromAscii("rc"); \
- } \
- xComponentContext = cppu::defaultBootstrap_InitialComponentContext(iniFile); \
- } else { \
- xComponentContext = cppu::defaultBootstrap_InitialComponentContext(); \
- } \
- xMS.set(xComponentContext->getServiceManager(), com::sun::star::uno::UNO_QUERY); \
- comphelper::setProcessServiceFactory(xMS); \
- } \
- catch (::com::sun::star::uno::Exception e ) { \
- rtl::OString aError; \
- aError = rtl::OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); \
- printf("Error at UNO bootstrap time caught: %s\nMust quit.\n", aError.getStr()); \
- exit(1); \
- } \
-}
-
-#endif
diff --git a/testshl2/inc/testshl/autoregister/callbackstructure.h b/testshl2/inc/testshl/autoregister/callbackstructure.h
deleted file mode 100644
index 2bddc43eb003..000000000000
--- a/testshl2/inc/testshl/autoregister/callbackstructure.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _callbackstructure_h
-#define _callbackstructure_h
-
-#include <sal/types.h>
-#include <cppunit/callbackfunc_fktptr.h>
-#include <testshl/autoregister/registerfunc.h>
-#include <testshl/autoregister/registertestfunction.h>
-#include <testshl/cmdlinebits.hxx>
-
-// this structure will filled by the testshl tool and hand to the testdll
-
-struct CallbackStructure
-{
- // a version number, if we want to change/expand this struct
- sal_Int32 nVersion;
- sal_Int64 nMagic;
-
- FktRegFuncPtr aRegisterFunction;
-
- FktPtr_CallbackDispatch aCallbackDispatch;
-
- //# FktPtr_TestResult_startTest aStartTest;
- //# FktPtr_TestResult_addFailure aAddFailure;
- //# FktPtr_TestResult_addError aAddError;
- //# FktPtr_TestResult_endTest aEndTest;
- //# FktPtr_TestResult_shouldStop aShouldStop;
- //#
- //# FktPtr_TestResult_addInfo aAddInfo;
- //# FktPtr_TestResult_enterNode aEnterNode;
- //# FktPtr_TestResult_leaveNode aLeaveNode;
-
- const char* psForward;
- CmdLineBits nBits;
-
- // void* pJobList;
-
- sal_Int64 nMagic2;
-
- CallbackStructure()
- :nVersion(1),
- nMagic(SAL_CONST_INT64(0x0123456789abcdef)),
- aRegisterFunction(NULL),
- aCallbackDispatch(NULL),
- /* aStartTest(NULL),
- aAddFailure(NULL),
- aAddError(NULL),
- aEndTest(NULL),
- aShouldStop(NULL),
- aAddInfo(NULL),
- aEnterNode(NULL),
- aLeaveNode(NULL), */
- psForward(NULL),
- nBits(0),
- /* pJobList(NULL), */
- nMagic2(0)
- {}
-};
-
-#endif
diff --git a/testshl2/inc/testshl/autoregister/htestresult.h b/testshl2/inc/testshl/autoregister/htestresult.h
deleted file mode 100644
index 46cfbc8b6808..000000000000
--- a/testshl2/inc/testshl/autoregister/htestresult.h
+++ /dev/null
@@ -1,6 +0,0 @@
-#ifndef _htestresult_h
-#define _htestresult_h
-
-typedef void* hTestResult;
-
-#endif
diff --git a/testshl2/inc/testshl/autoregister/registerfunc.h b/testshl2/inc/testshl/autoregister/registerfunc.h
deleted file mode 100644
index 7e3ee891c2ec..000000000000
--- a/testshl2/inc/testshl/autoregister/registerfunc.h
+++ /dev/null
@@ -1,47 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _registerfunc_h
-#define _registerfunc_h
-
-#include <sal/types.h>
-#include <testshl/autoregister/htestresult.h>
-#include <cppunit/callbackfunc_fktptr.h>
-#include <testshl/autoregister/testfunc.h>
-
-struct CallbackStructure;
-
-// this function is used to register one function into a Container in the testshl tool.
-extern "C" void SAL_CALL registerFunction(FktPtr aFunc, const char* aFuncName);
-
-// this function is the register function for auto registering
-
-extern "C" void SAL_CALL registerAllTestFunction(CallbackStructure* );
-typedef void (* FktRegAllPtr)(CallbackStructure*);
-
-
-#endif
diff --git a/testshl2/inc/testshl/autoregister/registertestfunction.h b/testshl2/inc/testshl/autoregister/registertestfunction.h
deleted file mode 100644
index 0cab2815f85e..000000000000
--- a/testshl2/inc/testshl/autoregister/registertestfunction.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _registertestfunction_h
-#define _registertestfunction_h
-
-#include <sal/types.h>
-#include <testshl/autoregister/testfunc.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-// function ptr, to register a function
-typedef void (* FktRegFuncPtr)(FktPtr aFunc, const char* aFuncName);
-
-// this function is used in the testdll to register the given function
-// into the testshl
-extern "C" void SAL_CALL RegisterTestFunctions(FktRegFuncPtr aFunc);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-
diff --git a/testshl2/inc/testshl/autoregister/testfunc.h b/testshl2/inc/testshl/autoregister/testfunc.h
deleted file mode 100644
index 55b97de05e34..000000000000
--- a/testshl2/inc/testshl/autoregister/testfunc.h
+++ /dev/null
@@ -1,44 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _testfunc_h
-#define _testfunc_h
-
-#include <testshl/autoregister/htestresult.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-// typedef for a testfunction
-typedef void (* FktPtr)(hTestResult);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/testshl2/inc/testshl/autoregisterhelper.hxx b/testshl2/inc/testshl/autoregisterhelper.hxx
deleted file mode 100644
index 538133ade19d..000000000000
--- a/testshl2/inc/testshl/autoregisterhelper.hxx
+++ /dev/null
@@ -1,62 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef AUTOREGISTER_HXX
-#define AUTOREGISTER_HXX
-
-#include <vector>
-#include <rtl/ustring.hxx>
-
-#include <testshl/autoregister/testfunc.h>
-
-#include "testshl/dynamicregister.hxx"
-#include "testshl/getopt.hxx"
-
-typedef std::vector<FktPtr> FunctionList;
-
-// -----------------------------------------------------------------------------
-class JobList;
-class AutomaticRegisterHelper : public DynamicLibraryHelper
-{
- FunctionList m_aFunctionList;
- bool m_bLoadLibraryOK;
- // GetOpt & m_aOptions; // use getOptions() instead!
-
-public:
- AutomaticRegisterHelper(rtl::OUString const& _sDLLName, GetOpt & _aOptions/* , JobList * _pJobList = NULL */ );
-
- // FunctionList getFunctions(){return m_aFunctionList;}
- void CallAll(hTestResult _hResult) const;
-
- /// @return true, if the given DLLName library could load and initialised.
- bool isOkToStartTests() const {return m_bLoadLibraryOK;}
-
- virtual ~AutomaticRegisterHelper();
-};
-
-#endif
-
diff --git a/testshl2/inc/testshl/checkboom.hxx b/testshl2/inc/testshl/checkboom.hxx
deleted file mode 100644
index 668ce603a429..000000000000
--- a/testshl2/inc/testshl/checkboom.hxx
+++ /dev/null
@@ -1,37 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef CHECKBOOM_HXX
-#define CHECKBOOM_HXX
-
-#include <string>
-#include <rtl/ustring.hxx>
-
-void CheckBoom(bool bCondition, std::string const& msg);
-void CheckBoom(bool bCondition, rtl::OUString const& msg);
-
-#endif
diff --git a/testshl2/inc/testshl/cmdlinebits.hxx b/testshl2/inc/testshl/cmdlinebits.hxx
deleted file mode 100644
index 99c166f2fc83..000000000000
--- a/testshl2/inc/testshl/cmdlinebits.hxx
+++ /dev/null
@@ -1,49 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef CMDLINEBITS_HXX
-#define CMDLINEBITS_HXX
-
-#include <sal/types.h>
-
-typedef sal_uInt32 CmdLineBits;
-const char* getForwardString();
-
-#include <stdarg.h>
-
-enum T_Print_Params {
- T_INFO = 1,
- T_VERBOSE,
- T_DEBUG,
- T_ERROR
-};
-
-// void t_print(const char*);
-void t_print(const char*, ...);
-void t_print(T_Print_Params, const char*, ...);
-
-#endif
diff --git a/testshl2/inc/testshl/dynamicregister.hxx b/testshl2/inc/testshl/dynamicregister.hxx
deleted file mode 100644
index f29ad52e963f..000000000000
--- a/testshl2/inc/testshl/dynamicregister.hxx
+++ /dev/null
@@ -1,64 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef DYNAMICREGISTER_HXX
-#define DYNAMICREGISTER_HXX
-
-#include <rtl/ustring.hxx>
-#include <osl/module.hxx>
-
-#include "testshl/getopt.hxx"
-#include "testshl/nocopy.hxx"
-
-// -------------------------------------------------
-
-class DynamicLibraryHelper : NOCOPY
-{
-protected:
- osl::Module* m_pModule;
- rtl::OUString m_suDLLName;
- GetOpt & m_aOptions;
-
- GetOpt& getOptions() {return m_aOptions;}
-
-public:
- DynamicLibraryHelper(rtl::OUString const& _sDLLName, GetOpt & _aOptions);
- virtual ~DynamicLibraryHelper();
-
-private:
- void showFilenameIfVerbose();
- void realLoadLibrary(rtl::OUString const& _sLibToLoad);
- void loadLibraryFromAbsolutePath();
- void loadLibraryFromLocalPath();
-
- rtl::OUString m_suAbsolutePathFile; // file:///D:/foo/bar/library.dll
- rtl::OUString m_suAbsolutePath; // file:///D:/foo/bar
- rtl::OUString m_suFilename; // library.dll
-};
-
-#endif
-
diff --git a/testshl2/inc/testshl/filehelper.hxx b/testshl2/inc/testshl/filehelper.hxx
deleted file mode 100644
index eefef077f4b5..000000000000
--- a/testshl2/inc/testshl/filehelper.hxx
+++ /dev/null
@@ -1,47 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef FILEHELPER_HXX
-#define FILEHELPER_HXX
-
-#include <string>
-#include <rtl/ustring.hxx>
-#include <rtl/string.hxx>
-#include <testshl/cmdlinebits.hxx>
-#include "getopt.hxx"
-
-namespace FileHelper
-{
-
- std::string getTempPath();
- rtl::OUString convertPath( rtl::OUString const& _suSysPath );
- rtl::OUString convertPath( rtl::OString const& sysPth );
- CmdLineBits createFlags( GetOpt & _aOptions );
-
-}
-#endif
-
diff --git a/testshl2/inc/testshl/getopt.hxx b/testshl2/inc/testshl/getopt.hxx
deleted file mode 100644
index b4feaa7c535b..000000000000
--- a/testshl2/inc/testshl/getopt.hxx
+++ /dev/null
@@ -1,332 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-/*************************************************************************
-#* class GetOpt
-#*
-#*
-#* Implementation getopt.cxx
-#*
-#* Description: class to reflect the commandline options. In addition
-#* it provides functinality to get options from an inifile
-#* ( getIniOptions()), evaluate, test and get options
-#* ( hasOpt(), getOpt() ) and display an usage screen
-#* formated in dependance of the given optionset, as well
-#* as display a status about activ options
-#*
-#*
-#* further descriptions:
-#*
-#* the constructor is called with two parameters:
-#* char* argv[] and char* optionSet[],
-#* the commandline and the available set of options.
-#* Valid optionstrings have to start with a minus '-', otherwise it will
-#* be ignored. Optionstrings consist of one or two arguments divided by a
-#* comma separator, where the second (optional) argument is a short
-#* description of the option, called hint. It will be automatically
-#* formated and displayed in the usage screen if available.
-#* The first argument of the optionstring can consist of two sections,
-#* the name and the optional necessity and format.
-#* The name of the option will be the starting minus followed by a string
-#* like "-src".
-#* One section options will be treated as flag (see '-v' option in example).
-#* The second section consist of '=' or ':' which defines the necessity,
-#* in combination with a character 's' for string or 'n' for numeric and
-#* an optional '@' standing for 'vector of'.
-#* '=' means this option needs an argument, ':' means can take an argument
-#* followed by 's' is, as mentioned above, a single string paramenter,
-#* followed by a 's' in combination with '@' means this argument consists
-#* of one string or a vector of strings separated by commas
-#*
-#* an example for an optionset:
-#*
-#* static char* optionSet[] = {
-#* "-src=s, release or version of sources",
-#* "-ini=s, ini file with additional options",
-#* "-db=s, path of type description database",
-#* "-inPth=s, source path of component descriptions",
-#* "-outPth=s, destination path for testcases",
-#* "-logPth=s, destination path for logging",
-#* "-mdl=s@, name(s) of module(s) to generate",
-#* "-v, enable verbose screen messages",
-#* "-dbg, enable debug messages",
-#* "-h:s, display help or help on option",
-#* "-help:s, see -h",
-#* NULL
-#* };
-#*
-#* As seen a GetOpt class object will be created via:
-#* GetOpt myOptions( argv, optionSet );
-#*
-*************************************************************************/
-#ifndef __QADEV_REGSCAN_GETOPT_HXX__
-#define __QADEV_REGSCAN_GETOPT_HXX__
-
-#include <osl/file.hxx>
-#include <sal/types.h>
-#include <rtl/strbuf.hxx>
-
-
-#include <rtl/string.hxx>
-
-// #ifndef __QADEV_REGSCAN_UTIL_HXX__
-// #include "inc/util.hxx"
-// #endif
-
-
-#ifdef SOLARIS
-#include <sys/time.h>
-#endif
-
-#include <iostream>
-#include <hash_map>
-// #include "rsexception.hxx"
-
-// using namespace std;
-
-struct gstr {
- sal_Bool operator()( const rtl::OString& oStr1,
- const rtl::OString& oStr2 ) const {
- return( oStr1 == oStr2 );
- }
-};
-
-struct ghstr
-{
- sal_uInt32 operator()( const rtl::OString& str ) const {
- return str.hashCode();
- }
-};
-
-struct frmt {
- sal_uInt32 fCol;
- sal_uInt32 sCol;
- sal_uInt32 len;
-};
-
-typedef std::hash_map< rtl::OString, std::vector< rtl::OString >, ghstr, gstr >
- optHashMap;
-
-typedef frmt sFormat;
-typedef sal_uInt16 optType;
-
-#define OT_INVALID 0x0000
-#define OT_BOOL 0x0001
-#define OT_STRING 0x0002
-#define OT_NUMBER 0x0004
-#define OT_SINGLE 0x0010
-#define OT_MULTI 0x0020
-#define OT_OPTIONAL 0x0100
-
-//: Option
-class OptDsc {
-
- rtl::OString m_name;
- rtl::OString m_hint;
- rtl::OString m_legend;
- optType m_type;
-
- /**
- * analysis of optionstring and creation of option description class
- * @param const rtl::OString& opt = optionstring to analyse
- * @return void
- */
- void createOptDsc( const rtl::OString& opt );
-
- /**
- * splitting of an optionstring and creation of a tokenvector
- * in dependance of a charset
- *
- * @param const rtl::OString& opt = optionstring to split
- * @param const rtl::OString& cSet = delimiter charset
- * @param vector< rtl::OString >& optLine = tokenvector to fill
- *
- * @return void
- */
- void split( const rtl::OString& opt, const rtl::OString& charSet,
- std::vector< rtl::OString >& optLine );
-
- /**
- * private default c'tor, copy c'tor and assignment operator
- * to get compiler errors on dumb effords
- */
- OptDsc();
- OptDsc( OptDsc& );
- OptDsc& operator = ( OptDsc& );
-
-public:
-
- //> c'tor
- OptDsc( const rtl::OString& opt )
- : m_name(),
- m_hint(),
- m_legend(),
- m_type( 0 ) {
-
- createOptDsc( opt );
- } ///< c'tor
-
- //> d'tor
- ~OptDsc(){}
-
- /**
- * returns the name of this option
- * @return rtl::OString&
- */
- inline rtl::OString& getName() { return m_name; }
- /**
- * returns the hint of this option
- * @return rtl::OString&
- */
- inline rtl::OString& getHint() { return m_hint; }
- /**
- * returns the legend of this option
- * @return rtl::OString&
- */
- inline rtl::OString& getLegend() { return m_legend; }
-
- /**
- * returns the type of this option
- * @return optType
- */
- inline optType getType() { return m_type; }
-
-
- inline sal_Bool isFlag() {
- return( ( m_type &~ 0xfffe ) == OT_BOOL ) ? sal_True : sal_False;
- }
- inline sal_Bool isString() {
- return( ( m_type &~ 0xfffd ) == OT_STRING ) ? sal_True : sal_False;
- }
- inline sal_Bool isNumber() {
- return( ( m_type &~ 0xfffb ) == OT_NUMBER ) ? sal_True : sal_False;
- }
- inline sal_Bool isSingle() {
- return( ( m_type &~ 0xffef ) == OT_SINGLE ) ? sal_True : sal_False;
- }
- inline sal_Bool isMulti() {
- return( ( m_type &~ 0xffdf ) == OT_MULTI ) ? sal_True : sal_False;
- }
- inline sal_Bool isOptional() {
- return( ( m_type &~ 0xfeff ) == OT_OPTIONAL ) ? sal_True : sal_False;
- }
-
-}; ///:~ Option
-
-class Exception
-{
- rtl::OString m_sAsciiMessage;
-public:
- Exception();
- virtual ~Exception(){}
-
- Exception(char const* sAsciiMessage);
- Exception(rtl::OString const& sAsciiMessage);
-
- virtual rtl::OUString message() const;
- virtual char const* what() const;
-};
-
-class ValueNotFoundException : public Exception
-{
-public:
- ValueNotFoundException();
- ValueNotFoundException(char const* sExit);
-};
-
-//: GetOpt
-class GetOpt {
-
- rtl::OString m_prgname;
- rtl::OString m_vardelim;
- std::vector< rtl::OString > m_cmdline;
- std::vector< rtl::OString > m_param;
- std::vector< rtl::OString > m_varvec;
- std::vector< OptDsc* > m_optionset;
- optHashMap m_opthash;
-
- //> private methods
- void initialize( char* cmdLine[], char const * optSet[] );
- void createCmdLineOptions();
- sal_uInt32 getMaxNameLength();
- sal_uInt32 getMaxLegendLength();
- const rtl::OString optDsc2Str( OptDsc* optDsc , sFormat frm );
- void tokenize( const rtl::OString& opt, const rtl::OString& charSet,
- std::vector< rtl::OString >& optLine, sal_Bool strip = sal_True );
- ///< private methods
-
- GetOpt();
- GetOpt( GetOpt& );
- GetOpt& operator = ( GetOpt& );
-
-public:
-
- //> c'tor
- GetOpt( char* cmdLine[], char const * optSet[], rtl::OString varDelim =
- rtl::OString( "$" ) )
- : m_vardelim( varDelim ) {
-
- initialize( cmdLine, optSet );
- createCmdLineOptions();
- } ///< c'tor
-
- //> d'tor
- ~GetOpt();
- ///< d'tor
-
- //> inline methods
- inline std::vector< rtl::OString >* getCmdLine() { return &m_cmdline; }
- inline optHashMap* getOptions() { return ( &m_opthash ); }
- inline rtl::OString& getName() { return m_prgname; }
- inline rtl::OString& getFirstParam() { return *(m_param.begin()); }
- inline std::vector< rtl::OString >& getParams() { return m_param; }
- rtl::OString& getOpt( const rtl::OString& opt );
- void rmvOpt( rtl::OString& opt ) {
- m_opthash.erase( opt );
- }
- inline std::vector< rtl::OString >& getOptVec( const rtl::OString& opt ) {
- return m_opthash[ opt ];
- }
- ///< inline methods
-
-
- sal_Bool exist( rtl::OString& opt );
- sal_Bool hasParam( std::vector< rtl::OString >::iterator iter );
- sal_Bool hasVars( void );
- sal_Bool evaluateOpt( std::vector< rtl::OString >::iterator iter );
- OptDsc* getOptDsc( rtl::OString& opt );
- sal_Bool hasOpt( const rtl::OString& opt ) const;
- ::osl::FileBase::RC getIniOptions( rtl::OString iniPth );
- void createOpt( rtl::OString& optdsc );
- void str2Opt( rtl::OString iOpts );
- void addOpt( rtl::OString& opt, sal_Bool evaluate = sal_True );
- void replVars( void );
- void showUsage( void );
- void printStatus( void );
-
-}; ///:~ GetOpt
-#endif
diff --git a/testshl2/inc/testshl/joblist.hxx b/testshl2/inc/testshl/joblist.hxx
deleted file mode 100644
index 24f45bc5ec26..000000000000
--- a/testshl2/inc/testshl/joblist.hxx
+++ /dev/null
@@ -1,96 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef CPPUNIT_JOBLIST_HXX
-#define CPPUNIT_JOBLIST_HXX
-
-#include <vector>
-#include <string>
-#include <hash_map>
-#include "sal/types.h"
-
-// #include <testshl/nocopy.hxx>
-
-/*
- struct eqstr
- {
- bool operator()( std::string const & s1, std::string const& s2 ) const
- {
- return ( s1 == s2 );
- }
- };
-*/
-
-/*
- struct hashstr
- {
- sal_uInt32 operator()( std::string const & str ) const
- {
- return str.hashCode();
- }
- };
-*/
-typedef std::hash_map< std::string, int > HashMap;
-
-// typedef std::vector<std::string> StringList;
-
-#define JOB_UNKNOWN 0
-#define JOB_NOT_FOUND 1
-#define JOB_PASSED 2
-#define JOB_FAILED 3
-#define JOB_ACCESS 4
-
-#define JOB_EXCLUDE_LIST 0x1000
-#define JOB_ONLY_LIST 0x1001
-
-typedef sal_Int16 JobType;
-
-class JobList /* : NOCOPY */
-{
- HashMap m_aJobList;
- char** ppsJobList;
-
- // returns true if the given List contains unxlngi or unxsols or wntmsci...
- bool isInCurrentEnvironment(std::string const& _sString);
- std::string trim(std::string const& _sStringToTrim);
-
-public:
- JobList();
- ~JobList();
-
- bool readfile(std::string const& _sFilename, JobType _nJobType);
- const char** getList() const {return (const char**)ppsJobList;}
-
- int getJobListEntry(std::string const& _sIndexName);
- void setJobListEntry(std::string const& _sIndexName, int _nValue);
-
- int size() {return m_aJobList.size();}
- HashMap const& getHashMap() {return m_aJobList;}
-};
-
-#endif
-
diff --git a/testshl2/inc/testshl/log.hxx b/testshl2/inc/testshl/log.hxx
deleted file mode 100644
index abe93c55347f..000000000000
--- a/testshl2/inc/testshl/log.hxx
+++ /dev/null
@@ -1,113 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- *************************************************************************
-
- Source Code Control System - Header
-
- $Header$
-
- Source Code Control System - Update
-
-*************************************************************************/
-#ifndef __QADEV_REGSCAN_LOG_HXX__
-#define __QADEV_REGSCAN_LOG_HXX__
-
-#include <time.h>
-#include <rtl/ustring.hxx>
-#include <rtl/strbuf.hxx>
-#include <sal/types.h>
-#include <osl/thread.h>
-#include <osl/file.hxx>
-
-//!io #include <iostream>
-#include <vector>
-
-// using namespace std;
-
-
-/**
- * Log derives the interface of the ::osl::File class ( is-a relation ).
- * Its members (has-a relation) are the (full qualified)name of the log
- * and an OStringBuffer which represents the content of the logfile.
- * It provides the functionality of easy-to-use open and write logs
- */
-//: Log
-class Log {
-
- ::osl::File* m_logfile; // fileobject
- rtl::OUString m_logurl; // url of log
- rtl::OStringBuffer m_buf; // content of log
-
- Log();
-
-public:
-
- //> c'tor
- /**
- * constructors argument is a full qualified UNC path
- * @param OUString logfile ( full qualified UNC path )
- */
- Log( const rtl::OUString& logURL )
- : m_logfile( new ::osl::File( logURL ))
- , m_logurl(logURL)
- {} ///< c'tor
-
- //> d'tor
- virtual ~Log() {
- m_logfile->close();
- delete( m_logfile );
- } ///< d'tor
-
- //> inline methods
- // returns a reference to name instance
- inline rtl::OUString getLogURL() { return m_logurl; }
- inline rtl::OString getName() { return rtl::OUStringToOString(
- m_logurl, RTL_TEXTENCODING_ASCII_US ); }
- ///< inline methods
-
- // open logfile for overwrite (default) or append
- ::osl::FileBase::RC open( sal_Bool append = sal_False );
- ::osl::FileBase::RC close() { return m_logfile->close(); }
-
-
- // write methods without (default) or with echo on display
- ::osl::FileBase::RC write( const sal_Char* buf, sal_Bool v = sal_False );
- ::osl::FileBase::RC write( const rtl::OString& buf,
- sal_Bool v = sal_False );
- // ::osl::FileBase::RC write( rtl::OStringBuffer const& buf,
- // sal_Bool v = sal_False );
- ::osl::FileBase::RC write( const rtl::OUString& buf,
- rtl_TextEncoding enc = RTL_TEXTENCODING_ASCII_US,
- sal_Bool v = sal_False );
-
-}; ///:~ Log
-
-Log &operator <<( Log &_aLog, const sal_Char * _sValue );
-Log &operator <<( Log &_aLog, rtl::OString const& _sValue );
-Log &operator <<( Log &_aLog, rtl::OUString const& _sValue );
-// Log &operator <<( Log &_aLog, rtl::OStringBuffer const& _sValue );
-
-#endif
diff --git a/testshl2/inc/testshl/nocopy.hxx b/testshl2/inc/testshl/nocopy.hxx
deleted file mode 100644
index 660bb1892e46..000000000000
--- a/testshl2/inc/testshl/nocopy.hxx
+++ /dev/null
@@ -1,13 +0,0 @@
-#ifndef NOCOPY_HXX
-#define NOCOPY_HXX
-
-// prevent illegal copies
-class NOCOPY
-{
- NOCOPY(NOCOPY const&);
- NOCOPY& operator=(NOCOPY const&);
-public:
- NOCOPY(){}
-};
-
-#endif
diff --git a/testshl2/inc/testshl/result/SynchronizedObject.h b/testshl2/inc/testshl/result/SynchronizedObject.h
deleted file mode 100644
index 6994fdb1692e..000000000000
--- a/testshl2/inc/testshl/result/SynchronizedObject.h
+++ /dev/null
@@ -1,82 +0,0 @@
-#ifndef CPPUNIT_SYNCHRONIZEDOBJECT_H
-#define CPPUNIT_SYNCHRONIZEDOBJECT_H
-
-#include <cppunit/Portability.h>
-#include <testshl/nocopy.hxx>
-
-namespace CppUnit
-{
-
-/*! \brief Base class for synchronized object.
- *
- * Synchronized object are object which members are used concurrently by mutiple
- * threads.
- *
- * This class define the class SynchronizationObject which must be subclassed
- * to implement an actual lock.
- *
- * Each instance of this class holds a pointer on a lock object.
- *
- * See src/msvc6/MfcSynchronizedObject.h for an example.
- */
-class CPPUNIT_API SynchronizedObject
-{
-public:
- /*! \brief Abstract synchronization object (mutex)
- */
- class SynchronizationObject
- {
- public:
- SynchronizationObject() {}
- virtual ~SynchronizationObject() {}
-
- virtual void lock() {}
- virtual void unlock() {}
- };
-
- /*! Constructs a SynchronizedObject object.
- */
- SynchronizedObject( SynchronizationObject *syncObject =0 );
-
- /// Destructor.
- virtual ~SynchronizedObject();
-
-protected:
- /*! \brief Locks a synchronization object in the current scope.
- */
- class ExclusiveZone : NOCOPY
- {
- SynchronizationObject *m_syncObject;
-
- public:
- ExclusiveZone( SynchronizationObject *syncObject )
- : m_syncObject( syncObject )
- {
- m_syncObject->lock();
- }
-
- ~ExclusiveZone()
- {
- m_syncObject->unlock ();
- }
- };
-
- virtual void setSynchronizationObject( SynchronizationObject *syncObject );
-
-protected:
- SynchronizationObject *m_syncObject;
-
-private:
- /// Prevents the use of the copy constructor.
- SynchronizedObject( const SynchronizedObject &copy );
-
- /// Prevents the use of the copy operator.
- void operator =( const SynchronizedObject &copy );
-};
-
-
-
-} // namespace CppUnit
-
-
-#endif // CPPUNIT_SYNCHRONIZEDOBJECT_H
diff --git a/testshl2/inc/testshl/result/TestListener.h b/testshl2/inc/testshl/result/TestListener.h
deleted file mode 100644
index 0814f21b7e2f..000000000000
--- a/testshl2/inc/testshl/result/TestListener.h
+++ /dev/null
@@ -1,62 +0,0 @@
-#ifndef CPPUNIT_TESTLISTENER_H // -*- C++ -*-
-#define CPPUNIT_TESTLISTENER_H
-
-#include <cppunit/Portability.h>
-
-
-namespace CppUnit {
-
-class Exception;
-class Test;
-class TestFailure;
-
-
-/*! \brief Listener for test progress and result.
- * \ingroup TrackingTestExecution
- *
- * Implementing the Observer pattern a TestListener may be registered
- * to a TestResult to obtain information on the testing progress. Use
- * specialized sub classes of TestListener for text output
- * (TextTestProgressListener). Do not use the Listener for the test
- * result output, use a subclass of Outputter instead.
- *
- * The test framework distinguishes between failures and errors.
- * A failure is anticipated and checked for with assertions. Errors are
- * unanticipated problems signified by exceptions that are not generated
- * by the framework.
- *
- * \see TestResult
- */
-class CPPUNIT_API TestListener
-{
-public:
- virtual ~TestListener() {}
-
- /// Called when just before a TestCase is run.
- virtual void startTest( Test *test ) =0 ;
-
- /*! Called when a failure occurs while running a test.
- * \see TestFailure.
- * \warning \a failure is a temporary object that is destroyed after the
- * method call. Use TestFailure::clone() to create a duplicate.
- */
- virtual void addFailure( const TestFailure &failure ) =0;
-
- /// Called just after a TestCase was run (even if a failure occured).
- virtual void endTest( Test *test ) =0;
-
- // additional info
- virtual void addInfo(Test *test, const char*) =0;
-
- // info in which node we are
- // helper functions to create tree structures
- // old: virtual void enterNode( const char* ) =0;
- // old: virtual void leaveNode( const char* ) =0;
-};
-
-
-} // namespace CppUnit
-
-#endif // CPPUNIT_TESTLISTENER_H
-
-
diff --git a/testshl2/inc/testshl/result/TestResult.h b/testshl2/inc/testshl/result/TestResult.h
deleted file mode 100644
index 22b5d2346664..000000000000
--- a/testshl2/inc/testshl/result/TestResult.h
+++ /dev/null
@@ -1,123 +0,0 @@
-#ifndef CPPUNIT_TESTRESULT_H
-#define CPPUNIT_TESTRESULT_H
-
-#include <cppunit/Portability.h>
-
-#if CPPUNIT_NEED_DLL_DECL
-#ifdef _MSC_VER
-#pragma warning( push )
-#pragma warning( disable: 4251 ) // X needs to have dll-interface to be used by clients of class Z
-#endif
-#endif
-
-#include <testshl/result/SynchronizedObject.h>
-#include <vector>
-#include <string>
-#include <deque>
-//!io #include <iostream>
-
-#include "testshl/result/optionhelper.hxx"
-#include "cppunit/TestFailure.h"
-
-class Outputter;
-namespace CppUnit {
-
-class Exception;
-class Test;
-// class TestFailure;
-class TestListener;
-
-#if CPPUNIT_NEED_DLL_DECL
- template class CPPUNIT_API std::deque<TestListener *>;
-#endif
-
-/*! \brief Manages TestListener.
- * \ingroup TrackingTestExecution
- *
- * A single instance of this class is used when running the test. It is usually
- * created by the test runner (TestRunner).
- *
- * This class shouldn't have to be inherited from. Use a TestListener
- * or one of its subclasses to be informed of the ongoing tests.
- * Use a Outputter to receive a test summary once it has finished
- *
- * TestResult supplies a template method 'setSynchronizationObject()'
- * so that subclasses can provide mutual exclusion in the face of multiple
- * threads. This can be useful when tests execute in one thread and
- * they fill a subclass of TestResult which effects change in another
- * thread. To have mutual exclusion, override setSynchronizationObject()
- * and make sure that you create an instance of ExclusiveZone at the
- * beginning of each method.
- *
- * \see Test, TestListener, TestResultCollector, Outputter.
- */
-class CPPUNIT_API TestResult : protected SynchronizedObject
-{
-protected:
- OptionHelper m_aOptionHelper;
-
-public:
- TestResult( GetOpt & _aOptions, SynchronizationObject *syncObject = 0 );
- virtual ~TestResult();
-
- virtual void addListener( TestListener *listener );
- virtual void removeListener( TestListener *listener );
-
- virtual void reset();
- virtual void stop();
-
- virtual bool shouldStop() const;
-
- virtual void startTest( Test *test );
- virtual void addError( Test *test, Exception *e, ErrorType::num eType=ErrorType::ET_ERROR);
- virtual void addFailure( Test *test, Exception *e );
- virtual void endTest( Test *test );
-
- // LLA: additionals
- virtual void addInfo(Test *test, const char *sInfo);
-
- virtual void enterNode(const char* Node);
- virtual void leaveNode(const char* Node);
- virtual std::string getNodeName();
-
- // if true, execution is allowed.
- virtual bool isAllowedToExecute(std::string const & sName);
- bool isOnlyShowJobs() {return m_aOptionHelper.isOnlyShowJobs();}
- bool isOptionWhereAmI();
-
- virtual void print(Outputter &);
- void setExitValue(int _nValue) {m_nExitValue = _nValue;}
- int getExitValue() {return m_nExitValue;}
-
-protected:
- void addFailure( const TestFailure &failure );
-
-protected:
- typedef std::deque<TestListener *> TestListeners;
- TestListeners m_listeners;
- bool m_stop;
-
- // this vector is used to expand the test name with a current node name
- std::vector<std::string> m_aCurrentNodeNames;
-
- //# std::vector<std::string> m_aNodes;
-
-private:
- TestResult( const TestResult &other );
- TestResult &operator =( const TestResult &other );
- int m_nExitValue;
-};
-
-
-} // namespace CppUnit
-
-
-#if CPPUNIT_NEED_DLL_DECL
-#ifdef _MSC_VER
-#pragma warning( pop )
-#endif
-#endif
-
-#endif // CPPUNIT_TESTRESULT_H
-
-
diff --git a/testshl2/inc/testshl/result/TestResultCollector.h b/testshl2/inc/testshl/result/TestResultCollector.h
deleted file mode 100644
index ddbe517f8935..000000000000
--- a/testshl2/inc/testshl/result/TestResultCollector.h
+++ /dev/null
@@ -1,165 +0,0 @@
-#ifndef CPPUNIT_TESTRESULTCOLLECTOR_H
-#define CPPUNIT_TESTRESULTCOLLECTOR_H
-
-#include <cppunit/Portability.h>
-
-#if CPPUNIT_NEED_DLL_DECL
-#ifdef _MSC_VER
-#pragma warning( push )
-#pragma warning( disable: 4251 ) // X needs to have dll-interface to be used by clients of class Z
-#endif
-#endif
-
-#include <testshl/result/TestResult.h>
-#include <testshl/result/TestSucessListener.h>
-#include <deque>
-#include <vector>
-
-namespace CppUnit
-{
-
-
-#if CPPUNIT_NEED_DLL_DECL
- template class CPPUNIT_API std::deque<TestFailure *>;
- template class CPPUNIT_API std::deque<Test *>;
-#endif
-
-
-/*! \brief Collects test result.
- * \ingroup WritingTestResult
- * \ingroup BrowsingCollectedTestResult
- *
- * A TestResultCollector is a TestListener which collects the results of executing
- * a test case. It is an instance of the Collecting Parameter pattern.
- *
- * The test framework distinguishes between failures and errors.
- * A failure is anticipated and checked for with assertions. Errors are
- * unanticipated problems signified by exceptions that are not generated
- * by the framework.
- * \see TestListener, TestFailure.
- */
-
-class OneStringContainer
-{
- std::string m_sName;
-protected:
- OneStringContainer() {}
-public:
- OneStringContainer(std::string const& _sName)
- :m_sName(_sName){}
- std::string getString() const {return m_sName;}
- virtual ~OneStringContainer(){}
-};
-
-// -----------------------------------------------------------------------------
-class TestEnvelope : public OneStringContainer
-{
- Test* m_pTest;
-public:
- TestEnvelope():m_pTest(NULL){}
-
- TestEnvelope(Test* _pTest, std::string const& _sName)
- : OneStringContainer(_sName),
- m_pTest(_pTest)
- {}
-
- Test* getTest() {return m_pTest;}
- virtual ~TestEnvelope(){}
-
-};
-
-// -----------------------------------------------------------------------------
-class TestInfo : public TestEnvelope
-{
-public:
- TestInfo(Test* _pTest, std::string const& _sName)
- :TestEnvelope(_pTest, _sName)
- {}
-};
-
-// -----------------------------------------------------------------------------
-class TestFailureEnvelope : public OneStringContainer
-{
- TestFailure* m_pTestFailure;
-public:
- TestFailureEnvelope():m_pTestFailure(NULL){}
-
- TestFailureEnvelope(TestFailure* _pTestFailure, std::string const& _sName)
- :OneStringContainer(_sName),
- m_pTestFailure(_pTestFailure)
- {}
-
- TestFailure* getTestFailure() {return m_pTestFailure;}
- virtual ~TestFailureEnvelope(){}
-
-};
-// -----------------------------------------------------------------------------
-
-class CPPUNIT_API TestResultCollector : public TestSucessListener
-{
- TestResult* m_pResult;
-public:
- typedef std::deque<TestFailureEnvelope *> TestFailures;
- typedef std::deque<TestEnvelope *> Tests;
- typedef std::vector<TestInfo *> TestInfos;
-
-
- /*! Constructs a TestResultCollector object.
- */
- TestResultCollector( TestResult *_pResult, SynchronizationObject *syncObject = 0 );
-
- /// Destructor.
- virtual ~TestResultCollector();
-
- void startTest( Test *test );
- void endTest( Test *test );
-
- void addFailure( const TestFailure &failure );
-
- virtual void reset();
-
- virtual int runTests() const;
- virtual int testErrors() const;
- virtual int testFailures() const;
- virtual int testFailuresTotal() const;
-
- virtual const TestFailures& failures() const;
- virtual const Tests &tests() const;
- virtual std::string getInfo(Test*);
-
- virtual void addInfo(Test *test, const char *sInfo);
-
- // virtual void enterNode(const char* Node);
- // virtual void leaveNode(const char* Node);
-
-protected:
- Tests m_tests;
- TestFailures m_failures;
- TestInfos m_aInfos;
-
- int m_testErrors;
-
- // this vector is used to expand the test name with a current node name
- // std::vector<std::string> m_aCurrentNodeNames;
- // std::string getNodeName();
-private:
- /// Prevents the use of the copy constructor.
- TestResultCollector( const TestResultCollector &copy );
-
- /// Prevents the use of the copy operator.
- void operator =( const TestResultCollector &copy );
-};
-
-
-
-} // namespace CppUnit
-
-
-#if CPPUNIT_NEED_DLL_DECL
-#ifdef _MSC_VER
-#pragma warning( pop )
-#endif
-#endif
-
-
-#endif // CPPUNIT_TESTRESULTCOLLECTOR_H
diff --git a/testshl2/inc/testshl/result/TestSucessListener.h b/testshl2/inc/testshl/result/TestSucessListener.h
deleted file mode 100644
index 3eb53b9fc13f..000000000000
--- a/testshl2/inc/testshl/result/TestSucessListener.h
+++ /dev/null
@@ -1,40 +0,0 @@
-#ifndef CPPUNIT_TESTSUCESSLISTENER_H
-#define CPPUNIT_TESTSUCESSLISTENER_H
-
-#include <testshl/result/SynchronizedObject.h>
-#include <testshl/result/TestListener.h>
-
-
-namespace CppUnit
-{
-
-/*! \brief TestListener that checks if any test case failed.
- * \ingroup TrackingTestExecution
- */
-class CPPUNIT_API TestSucessListener : public TestListener,
- public SynchronizedObject
-{
-public:
- /*! Constructs a TestSucessListener object.
- */
- TestSucessListener( SynchronizationObject *syncObject = 0 );
-
- /// Destructor.
- virtual ~TestSucessListener();
-
- virtual void reset();
-
- void addFailure( const TestFailure &failure );
-
- /// Returns whether the entire test was successful or not.
- virtual bool wasSuccessful() const;
-
-private:
- bool m_sucess;
-};
-
-
-} // namespace CppUnit
-
-
-#endif // CPPUNIT_TESTSUCESSLISTENER_H
diff --git a/testshl2/inc/testshl/result/TextTestResult.h b/testshl2/inc/testshl/result/TextTestResult.h
deleted file mode 100644
index e2ba0ffba427..000000000000
--- a/testshl2/inc/testshl/result/TextTestResult.h
+++ /dev/null
@@ -1,62 +0,0 @@
-#ifndef CPPUNIT_TEXTTESTRESULT_H
-#define CPPUNIT_TEXTTESTRESULT_H
-
-#include <testshl/result/TestResult.h>
-#include <testshl/result/TestResultCollector.h>
-#include <ostream>
-
-class GetOpt;
-namespace CppUnit {
-
-class SourceLine;
-class Exception;
-class Test;
-
-/*! \brief Holds printable test result (DEPRECATED).
- * \ingroup TrackingTestExecution
- *
- * deprecated Use class TextTestProgressListener and TextOutputter instead.
- */
-class CPPUNIT_API TextTestResult : public TestResult
-/* public TestResultCollector*/
-{
- TestResultCollector m_aResulter;
-public:
- TextTestResult(GetOpt& _aOptions);
-
- virtual void addFailure( const TestFailure &failure );
- virtual void startTest( Test *test );
- virtual void endTest( Test *test );
-
- virtual void print( std::ostream &stream );
-protected:
-
- virtual void printFailures( std::ostream &stream );
- virtual void printHeader( std::ostream &stream );
-
- virtual void printFailure( TestFailure *failure,
- int failureNumber,
- std::ostream &stream );
- virtual void printFailureListMark( int failureNumber,
- std::ostream &stream );
- virtual void printFailureTestName( TestFailure *failure,
- std::ostream &stream );
- virtual void printFailureType( TestFailure *failure,
- std::ostream &stream );
- virtual void printFailureLocation( SourceLine sourceLine,
- std::ostream &stream );
- virtual void printFailureDetail( Exception *thrownException,
- std::ostream &stream );
- virtual void printFailureWarning( std::ostream &stream );
- virtual void printStatistics( std::ostream &stream );
-};
-
-/** insertion operator for easy output */
-std::ostream &operator <<( std::ostream &stream,
- TextTestResult &result );
-
-} // namespace CppUnit
-
-#endif // CPPUNIT_TEXTTESTRESULT_H
-
-
diff --git a/testshl2/inc/testshl/result/callbackfunc.h b/testshl2/inc/testshl/result/callbackfunc.h
deleted file mode 100644
index 606bf7179163..000000000000
--- a/testshl2/inc/testshl/result/callbackfunc.h
+++ /dev/null
@@ -1,25 +0,0 @@
-#ifndef _callbackfunc_h
-#define _callbackfunc_h
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
- // this is the entry point from the DLL back to the executable.
- long CallbackDispatch(int x, ...);
-
-//# void TestResult_startTest(hTestResult _pResult, hTest _pTest);
-//# void TestResult_addFailure( hTestResult _pResult, hTest _pTest, hException _pException );
-//# void TestResult_addError( hTestResult _pResult, hTest _pTest, hException _pException );
-//# void TestResult_endTest( hTestResult _pResult, hTest _pTest );
-//# bool TestResult_shouldStop(hTestResult _pResult);
-//# void TestResult_addInfo( hTestResult _pResult, hTest _pTest, const char* _sInfo );
-//#
-//# void TestResult_enterNode( hTestResult _pResult, const char* _sInfo );
-//# void TestResult_leaveNode( hTestResult _pResult, const char* _sInfo );
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/testshl2/inc/testshl/result/emacsTestResult.hxx b/testshl2/inc/testshl/result/emacsTestResult.hxx
deleted file mode 100644
index 3f64060d75cb..000000000000
--- a/testshl2/inc/testshl/result/emacsTestResult.hxx
+++ /dev/null
@@ -1,79 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef cppunit_emacstestresult_h
-#define cppunit_emacstestresult_h
-
-#include <testshl/result/TestResult.h>
-#include <testshl/result/TestResultCollector.h>
-#include <ostream>
-#include "testshl/getopt.hxx"
-
-class Outputter;
-namespace CppUnit {
-
-class SourceLine;
-class Exception;
-class Test;
-
-/*! \brief Holds printable test result (DEPRECATED).
- * \ingroup TrackingTestExecution
- *
- * deprecated Use class TextTestProgressListener and TextOutputter instead.
- */
- class CPPUNIT_API emacsTestResult : public TestResult
-
-/* ,public TestResultCollector*/
- {
- GetOpt & m_aOptions;
- // OptionHelper m_aOptionHelper;
- TestResultCollector m_aResulter;
-
- public:
- emacsTestResult(GetOpt & _aOptions);
-
- // virtual void addFailure( const TestFailure &failure );
- // virtual void startTest( Test *test );
- // virtual void endTest( Test *test );
-
- virtual void print( Outputter &stream );
-
- protected:
- virtual void printHeader( Outputter &stream );
- // virtual void printTestLine( Outputter &stream, Test* pTest, std::string const& _sNodeName, std::string const& _sInfo);
- virtual void printFailureLine( Outputter &stream, TestFailure* pFailure, std::string const& _sNodeName );
- };
-
-/** insertion operator for easy output */
-// std::ostream &operator <<( std::ostream &stream,
-// emacsTestResult &result );
-
-} // namespace CppUnit
-
-#endif // CPPUNIT_testshlTESTRESULT_H
-
-
diff --git a/testshl2/inc/testshl/result/log.hxx b/testshl2/inc/testshl/result/log.hxx
deleted file mode 100644
index f57c9af0e119..000000000000
--- a/testshl2/inc/testshl/result/log.hxx
+++ /dev/null
@@ -1,103 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-#ifndef __QADEV_REGSCAN_LOG_HXX__
-#define __QADEV_REGSCAN_LOG_HXX__
-
-#include <time.h>
-#include <rtl/ustring.hxx>
-#include <rtl/strbuf.hxx>
-#include <sal/types.h>
-#include <osl/thread.h>
-#include <osl/file.hxx>
-
-#include <testshl/nocopy.hxx>
-
-//!io #include <iostream>
-#include <vector>
-
-// using namespace std;
-
-
-/**
- * Log derives the interface of the ::osl::File class ( is-a relation ).
- * Its members (has-a relation) are the (full qualified)name of the log
- * and an OStringBuffer which represents the content of the logfile.
- * It provides the functionality of easy-to-use open and write logs
- */
-//: Log
-class Log : NOCOPY {
-
- ::osl::File* m_logfile; // fileobject
- rtl::OUString m_logurl; // url of log
- rtl::OStringBuffer m_buf; // content of log
-
- Log();
-
-public:
-
- //> c'tor
- /**
- * constructors argument is a full qualified UNC path
- * @param OUString logfile ( full qualified UNC path )
- */
- Log( const rtl::OUString& logURL )
- : m_logfile( new ::osl::File( logURL ))
- , m_logurl(logURL)
- {} ///< c'tor
-
- //> d'tor
- virtual ~Log()
- {
- m_logfile->close();
- delete( m_logfile );
- } ///< d'tor
-
- //> inline methods
- // returns a reference to name instance
- inline rtl::OUString getLogURL() { return m_logurl; }
- inline rtl::OString getName() { return rtl::OUStringToOString(
- m_logurl, RTL_TEXTENCODING_ASCII_US ); }
- ///< inline methods
-
- // open logfile for overwrite (default) or append
- ::osl::FileBase::RC open( sal_Bool append = sal_False );
- ::osl::FileBase::RC close() { return m_logfile->close(); }
-
-
- // write methods without (default) or with echo on display
- ::osl::FileBase::RC write( const sal_Char* buf, sal_Bool v = sal_False );
- ::osl::FileBase::RC write( const rtl::OString& buf,
- sal_Bool v = sal_False );
- //! ::osl::FileBase::RC write( rtl::OStringBuffer& buf,
- //! sal_Bool v = sal_False );
- ::osl::FileBase::RC write( const rtl::OUString& buf,
- rtl_TextEncoding enc = RTL_TEXTENCODING_ASCII_US,
- sal_Bool v = sal_False );
-
-}; ///:~ Log
-
-#endif
diff --git a/testshl2/inc/testshl/result/optionhelper.hxx b/testshl2/inc/testshl/result/optionhelper.hxx
deleted file mode 100644
index 6b67bacf0472..000000000000
--- a/testshl2/inc/testshl/result/optionhelper.hxx
+++ /dev/null
@@ -1,95 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef optionhelper_hxx
-#define optionhelper_hxx
-
-#include <string>
-
-#include <sal/types.h>
-
-#include "testshl/nocopy.hxx"
-#include "testshl/getopt.hxx"
-#include "testshl/joblist.hxx"
-
-// -----------------------------------------------------------------------------
-
-typedef std::vector<rtl::OString> OStringList;
-
-//!? Better: OptionHelper
-class OptionHelper : NOCOPY
-{
- GetOpt & m_aOption;
- JobList m_aJobOnlyList;
- JobList m_aJobExcludeList;
- OStringList m_aJobFilter;
-
- std::string m_sProjectId;
- std::string m_sBuildId;
-
- std::string getProjectId() const;
- std::string getBuildId() const;
- std::string createDateTag(std::string const& _sProjectId, std::string const& _sBuildId);
-
- void handleJobs();
-public:
- OptionHelper(GetOpt & _aOption)
- :m_aOption(_aOption)
- {
- if (m_aOption.hasOpt("-projectid"))
- m_sProjectId = m_aOption.getOpt("-projectid");
-
- if (m_aOption.hasOpt("-buildid"))
- m_sBuildId = m_aOption.getOpt("-buildid");
-
- handleJobs();
- }
-
- static std::string integerToAscii(sal_Int32 nValue);
- static std::string twoDigits(std::string const& _sValue);
-
- std::string createDateTag();
- bool showErrors();
- bool showTests();
-
- JobList getJobOnlyList() {return m_aJobOnlyList;}
- JobList getJobExcludeList() {return m_aJobExcludeList;}
-
- bool isAllowedToExecute(std::string const& _sNode, std::string const& _sName);
-
- bool isOnlyShowJobs() {return m_aOption.hasOpt("-onlyshowjobs") == sal_True ? true : false;}
- GetOpt& getOptions() {return m_aOption;}
- bool isVerbose() {return m_aOption.hasOpt("-verbose") == sal_True ? true : false;}
- bool isOptionWhereAmI() {return m_aOption.hasOpt("-whereami") == sal_True ? true : false;}
-};
-
-// -----------------------------------------------------------------------------
-
-
-#endif
-
-
diff --git a/testshl2/inc/testshl/result/outputter.hxx b/testshl2/inc/testshl/result/outputter.hxx
deleted file mode 100644
index 9394a39a1ccd..000000000000
--- a/testshl2/inc/testshl/result/outputter.hxx
+++ /dev/null
@@ -1,82 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-//
-
-#ifndef outputter_hxx
-#define outputter_hxx
-
-#include <string>
-#include <ostream>
-#include <memory>
-#include "testshl/log.hxx"
-#include <sal/types.h>
-#include "testshl/nocopy.hxx"
-
-// #include <fstream>
-
-class Outputter : NOCOPY
-{
- std::auto_ptr<Log> m_pLog;
- std::ostream* m_pStream;
-
- void writeToAll(const sal_Char* _pStr);
-public:
- class endl
- {
- char c;
- public:
- endl():c('\0'){}
- };
-public:
- Outputter(Log * _pLog )
- :m_pLog(_pLog),
- m_pStream(NULL) {}
-
- Outputter(std::ostream& _aStream)
- :m_pLog(NULL),
- m_pStream(&_aStream) {}
-
- ~Outputter();
-
- void write(const sal_Char*);
- void write(std::string const&);
- void write(sal_Int32);
- // void write(double);
-};
-
-Outputter& operator <<( Outputter &stream, const sal_Char* );
-Outputter& operator <<( Outputter &stream, std::string const& );
-Outputter& operator <<( Outputter &stream, sal_Int32 );
-// Outputter& operator <<( Outputter &stream, double );
-
-Outputter& operator <<( Outputter &stream, Outputter::endl const&);
-
-// Outputter& operator <<( Outputter &stream, const char* );
-
-#endif
-
diff --git a/testshl2/inc/testshl/result/testshlTestResult.h b/testshl2/inc/testshl/result/testshlTestResult.h
deleted file mode 100644
index 22a50a9a841e..000000000000
--- a/testshl2/inc/testshl/result/testshlTestResult.h
+++ /dev/null
@@ -1,72 +0,0 @@
-#ifndef cppunit_testshltestresult_h
-#define cppunit_testshltestresult_h
-
-#include <map>
-#include <testshl/result/TestResult.h>
-#include <testshl/result/TestResultCollector.h>
-#include <ostream>
-#include "testshl/getopt.hxx"
-
-class Outputter;
-
-namespace CppUnit {
-
-class SourceLine;
-class Exception;
-class Test;
-
-struct ltstr
-{
- bool operator()(const CppUnit::Test* p1, const CppUnit::Test* p2) const
- {
- return p1 < p2;
- }
-};
-typedef std::map<CppUnit::Test*, bool, ltstr> TestPtrList;
-
-
-/*! \brief Holds printable test result (DEPRECATED).
- * \ingroup TrackingTestExecution
- *
- * deprecated Use class TextTestProgressListener and TextOutputter instead.
- */
- class CPPUNIT_API testshlTestResult : public TestResult
-
-/* ,public TestResultCollector*/
- {
- GetOpt & m_aOptions;
- // OptionHelper m_aOptionHelper;
- TestResultCollector m_aResulter;
-
- public:
- testshlTestResult(GetOpt & _aOptions);
- virtual ~testshlTestResult();
-
- // virtual void addFailure( const TestFailure &failure );
- // virtual void startTest( Test *test );
- // virtual void endTest( Test *test );
-
- virtual void print( Outputter &stream );
-
- protected:
- virtual void printHeader( Outputter &stream );
-
- void printLines(Outputter &stream, HashMap & _aJobList);
- void printFailedTests(Outputter &stream, TestPtrList &aFailedTests);
- void printTestLines(Outputter &stream, TestPtrList &aFailedTests);
- void printUnknownLines(Outputter &stream, HashMap & _aJobList);
-
- virtual void printTestLine( Outputter &stream, Test* pTest, std::string const& _sNodeName, std::string const& _sInfo);
- virtual void printFailureLine( Outputter &stream, TestFailure* pFailure, std::string const& _sNodeName );
- virtual void printUnknownLine( Outputter &stream, std::string const& _sTestName);
- };
-
-/** insertion operator for easy output */
- Outputter &operator <<( Outputter &stream,
- testshlTestResult &result );
-
-} // namespace CppUnit
-
-#endif // CPPUNIT_testshlTESTRESULT_H
-
-
diff --git a/testshl2/inc/testshl/signaltest.h b/testshl2/inc/testshl/signaltest.h
deleted file mode 100644
index 6886d60be906..000000000000
--- a/testshl2/inc/testshl/signaltest.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SIGNALTEST_H
-#define SIGNALTEST_H
-
-#include <string>
-#include "cppunit/Test.h"
-#include <testshl/autoregister/htestresult.h>
-
-namespace CppUnit
-{
-
-class CPPUNIT_API SignalTest : public Test
-{
-public:
-
- SignalTest( std::string const& Name );
-
- ~SignalTest();
-
- virtual void run(hTestResult pResult);
- virtual int countTestCases() const;
- std::string getName() const;
- std::string toString() const;
-
-private:
- SignalTest( const SignalTest &other );
- SignalTest &operator=( const SignalTest &other );
-
-private:
- const std::string m_sName;
-};
-
-} // namespace CppUnit
-
-
-#endif
diff --git a/testshl2/inc/testshl/simpleheader.hxx b/testshl2/inc/testshl/simpleheader.hxx
deleted file mode 100644
index c910a7bdcd0f..000000000000
--- a/testshl2/inc/testshl/simpleheader.hxx
+++ /dev/null
@@ -1,43 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef CPPUNIT_SIMPLEHEADER_HXX
-#define CPPUNIT_SIMPLEHEADER_HXX
-
-// This file contains only the cppunit header files, for simplification.
-
-#include <cppunit/TestFixture.h>
-#include <cppunit/TestCaller.h>
-#include <cppunit/TestSuite.h>
-#include <cppunit/TestAssert.h>
-#include <testshl/autoregister/registertestfunction.h>
-#include <cppunit/extensions/HelperMacros.h>
-#include <testshl/additionalfunc.hxx>
-#include <testshl/cmdlinebits.hxx>
-#include <testshl/checkboom.hxx>
-
-#endif
diff --git a/testshl2/inc/testshl/stringhelper.hxx b/testshl2/inc/testshl/stringhelper.hxx
deleted file mode 100644
index 4e30c2d2d447..000000000000
--- a/testshl2/inc/testshl/stringhelper.hxx
+++ /dev/null
@@ -1,39 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef STRINGHELPER_HXX
-#define STRINGHELPER_HXX
-
-#include <rtl/ustring.hxx>
-#include <rtl/string.hxx>
-
-inline void operator <<= (rtl::OString& _rAsciiString, const rtl::OUString& _rUnicodeString)
-{
- _rAsciiString = rtl::OUStringToOString(_rUnicodeString,RTL_TEXTENCODING_ASCII_US);
-}
-
-#endif
diff --git a/testshl2/inc/testshl/taghelper.hxx b/testshl2/inc/testshl/taghelper.hxx
deleted file mode 100644
index 1100256e6dee..000000000000
--- a/testshl2/inc/testshl/taghelper.hxx
+++ /dev/null
@@ -1,88 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef TAGHELPER_HXX
-#define TAGHELPER_HXX
-
-#include <map>
-#include <sal/types.h>
-#include <testshl/nocopy.hxx>
-#include <cppunit/tagvalues.hxx>
-
-/* Tags are a general mechanism of extensible data arrays for parameter
- * specification and property inquiry. In practice, tags are used in arrays,
- * or chain of arrays.
- *
- */
-
-typedef sal_IntPtr TagData;
-
-//# struct TagItem
-//# {
-//# Tag ti_Tag; /* identifies the type of data */
-//# TagData ti_Data; /* type-specific data */
-//# };
-
-/* constants for Tag.ti_Tag, control tag values */
-#define TAG_DONE (Tag(0L)) /* terminates array of TagItems. ti_Data unused */
-#define TAG_END (Tag(0L)) /* synonym for TAG_DONE */
-#define TAG_IGNORE (Tag(1L)) /* ignore this item, not end of array */
-#define TAG_MORE (Tag(2L)) /* ti_Data is pointer to another array of TagItems
- * note that this tag terminates the current array
- */
-#define TAG_SKIP (Tag(3L)) /* skip this and the next ti_Data items */
-
-/* differentiates user tags from control tags */
-#define TAG_USER (Tag(1L<<31))
-
-// -----------------------------------------------------------------------------
-class TagHelper /* : NOCOPY */
-{
- typedef std::map<Tag, TagData> TagItems;
- TagItems m_aTagItems;
-
-public:
- TagHelper(){}
- void insert(Tag _nTag, TagData _nData)
- {
- m_aTagItems[_nTag] = _nData;
- }
- // const TagItems& get() const { return m_aTagItems; }
-
- TagData GetTagData(Tag _aTagValue, TagData _aDefaultValue = 0 /* NULL */) const
- {
- TagItems::const_iterator it = m_aTagItems.find(_aTagValue);
- if (it != m_aTagItems.end())
- return (*it).second;
- else
- return _aDefaultValue;
- }
-};
-
-#endif
-
-
diff --git a/testshl2/inc/testshl/tresstatewrapper.h b/testshl2/inc/testshl/tresstatewrapper.h
deleted file mode 100644
index 0f6830451caf..000000000000
--- a/testshl2/inc/testshl/tresstatewrapper.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef TESTSTATEWRAPPER_H
-#define TESTSTATEWRAPPER_H
-
-#ifdef _RTL_TRES_H_
-#error "This is old code, please remove the include of rtl/tres.h"
-#endif
-
-#include <sal/types.h>
-#include "testshl/autoregister/registertestfunction.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-// typedef void* hTestResult;
-typedef hTestResult rtlTestResult;
-
-// -----------------------------------------------------------------------------
-void c_rtl_tres_state_start(hTestResult _aResult, const sal_Char* _pName);
-void c_rtl_tres_state_end(hTestResult _aResult, const sal_Char* _pName);
-
-// -----------------------------------------------------------------------------
-// the old test state function, which here convert all values for using with the
-// new testshl tool
-
-sal_Bool SAL_CALL c_rtl_tres_state(
- hTestResult pResult,
- sal_Bool bSuccess,
- char const * pTestMsg,
- char const * pFuncName);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/testshl2/inc/testshl/tresstatewrapper.hxx b/testshl2/inc/testshl/tresstatewrapper.hxx
deleted file mode 100644
index c90a5fe2535b..000000000000
--- a/testshl2/inc/testshl/tresstatewrapper.hxx
+++ /dev/null
@@ -1,57 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef teststatewrapper_hxx
-#define teststatewrapper_hxx
-
-#include <testshl/nocopy.hxx>
-#include <sal/types.h>
-
-#include <testshl/simpleheader.hxx>
-#include <cppunit/callbackfunc_fktptr.h>
-
-// This is a hack, because it's possible that the testshl directory doesn't exist.
-#ifdef LOAD_TRESSTATEWRAPPER_LOCAL
-#include "tresstatewrapper.h"
-#else
-#include <testshl/tresstatewrapper.h>
-#endif
-
-// -----------------------------------------------------------------------------
-// helper class to mark the start off old test code
-// the name is need in the test result generator
-class rtl_tres_state_start : NOCOPY
-{
- const sal_Char* m_pName;
- hTestResult m_aResult;
-public:
- rtl_tres_state_start(hTestResult _aResult, const sal_Char* _pName);
- ~rtl_tres_state_start();
-};
-
-#endif
-
diff --git a/testshl2/inc/testshl/versionhelper.hxx b/testshl2/inc/testshl/versionhelper.hxx
deleted file mode 100644
index efa28bef0bda..000000000000
--- a/testshl2/inc/testshl/versionhelper.hxx
+++ /dev/null
@@ -1,84 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef AUTOREGISTER_HXX
-#define AUTOREGISTER_HXX
-
-#include <stdio.h>
-#include <vector>
-#include <ostream>
-#include <iostream>
-
-#include <rtl/ustring.hxx>
-#include <rtl/string.hxx>
-
-#include "dynamicregister.hxx"
-
-// -----------------------------------------------------------------------------
-// ---------------------------------- Version ----------------------------------
-// -----------------------------------------------------------------------------
-// extern "C" const struct VersionInfo *GetVersionInfo();
-
-// this is a Hack, but at the moment, no change to handle this behaviour better.
-struct VersionInfo
-{
- const char* pTime;
- const char* pDate;
- const char* pUpd;
- const char* pMinor;
- const char* pBuild;
- const char* pInpath;
-};
-typedef const struct VersionInfo* (*FktGetVersionInfoPtr)();
-
-// -----------------------------------------------------------------------------
-class VersionHelper : public DynamicLibraryHelper
-{
- const VersionInfo *m_pInfo;
-
-public:
- VersionHelper(rtl::OUString const& _sDLLName, GetOpt & _aOptions);
-// void print(std::ostream& _aStream);
- void printall(FILE*);
-
- rtl::OString getTime() const;
- rtl::OString getDate() const;
- rtl::OString getUpd() const;
- rtl::OString getMinor() const;
- rtl::OString getBuild() const;
- rtl::OString getInpath() const;
-
- bool isOk() const;
-};
-
-/** insertion operator for easy output */
-// std::ostream &operator <<( std::ostream &stream,
-// VersionHelper &version );
-
-
-#endif
-
diff --git a/testshl2/inc/testshl/winstuff.hxx b/testshl2/inc/testshl/winstuff.hxx
deleted file mode 100644
index 830275883e0a..000000000000
--- a/testshl2/inc/testshl/winstuff.hxx
+++ /dev/null
@@ -1,40 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef WINSTUFF_HXX
-#define WINSTUFF_HXX
-
-#include <sal/types.h>
-
-// Isolated into own compilation unit, to avoid interference with
-// windows headers
-void WinDebugBreak();
-void WinSleep( sal_uInt32 sec );
-sal_uInt32 WinGetCurrentProcessId();
-void WinTerminateApp( sal_uInt32 dwPID, sal_uInt32 dwTimeout );
-
-#endif
diff --git a/testshl2/prj/build.lst b/testshl2/prj/build.lst
deleted file mode 100644
index 7bbdfa8c1646..000000000000
--- a/testshl2/prj/build.lst
+++ /dev/null
@@ -1,9 +0,0 @@
-t2 testshl2 : cppunit sal NULL
-t2 testshl2 usr1 - all t2_mkout NULL
-t2 testshl2\inc nmake - all t2_inc NULL
-t2 testshl2\source\cppunit\win32 nmake - all t2_src_cppunit_win32 t2_inc NULL
-t2 testshl2\source\cppunit nmake - all t2_src_cppunit t2_src_cppunit_win32 t2_inc NULL
-t2 testshl2\source\cppunit\result nmake - all t2_src_cppunit_result t2_inc NULL
-t2 testshl2\source nmake - all t2_src t2_src_cppunit_result t2_src_cppunit t2_inc NULL
-t2 testshl2\util nmake - all t2_util t2_src NULL
-
diff --git a/testshl2/prj/d.lst b/testshl2/prj/d.lst
deleted file mode 100644
index 67cc1ad8e9e7..000000000000
--- a/testshl2/prj/d.lst
+++ /dev/null
@@ -1,29 +0,0 @@
-../%__SRC%/bin/testshl2.exe %_DEST%/bin%_EXT%/testshl2.exe
-../%__SRC%/bin/testshl2_timeout.exe %_DEST%/bin%_EXT%/testshl2_timeout.exe
-../%__SRC%/bin/testshl2 %_DEST%/bin%_EXT%/testshl2
-../%__SRC%/bin/testshl2_timeout %_DEST%/bin%_EXT%/testshl2_timeout
-../%__SRC%/bin/versioninfo.exe %_DEST%/bin%_EXT%/versioninfo.exe
-../%__SRC%/bin/versioninfo %_DEST%/bin%_EXT%/versioninfo
-
-../source/codegen/codegen.pl %_DEST%/bin%_EXT%/codegen_testshl2.pl
-
-mkdir: %_DEST%/inc%_EXT%/testshl
-mkdir: %_DEST%/inc%_EXT%/testshl/autoregister
-mkdir: %_DEST%/inc%_EXT%/testshl/result
-../inc/testshl/*.hxx %_DEST%/inc%_EXT%/testshl/*.hxx
-../inc/testshl/*.h %_DEST%/inc%_EXT%/testshl/*.h
-../inc/testshl/result/*.hxx %_DEST%/inc%_EXT%/testshl/result/*.hxx
-../inc/testshl/result/*.h %_DEST%/inc%_EXT%/testshl/result/*.h
-../inc/testshl/autoregister/*.h %_DEST%/inc%_EXT%/testshl/autoregister/*.h
-
-../%__SRC%/lib/testshl2.lib %_DEST%/lib%_EXT%/testshl2.lib
-../%__SRC%/lib/*.a %_DEST%/lib%_EXT%/*.a
-../%__SRC%/lib/c5t_*.lib %_DEST%/lib%_EXT%/c5t_*.lib
-
-# The follows is a testshl2 selftest library, which must be delivered for tests.
-# But per default this library doesn't exists.
-# For more information see workben/selftest
-../%__SRC%/bin/delivertest.dll %_DEST%/bin%_EXT%/testshl2_deliver_test.dll
-../%__SRC%/lib/libdelivertest.so %_DEST%/lib%_EXT%/libtestshl2_deliver_test.so
-../%__SRC%/lib/libdelivertest.dylib %_DEST%/lib%_EXT%/libtestshl2_deliver_test.dylib
-
diff --git a/testshl2/source/autoregisterhelper.cxx b/testshl2/source/autoregisterhelper.cxx
deleted file mode 100644
index 62e76804262c..000000000000
--- a/testshl2/source/autoregisterhelper.cxx
+++ /dev/null
@@ -1,140 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-
-#include <stdio.h>
-#include <stdlib.h>
-#include "testshl/autoregisterhelper.hxx"
-
-#include <rtl/ustring.hxx>
-
-#include <testshl/autoregister/registerfunc.h>
-#include <testshl/autoregister/callbackstructure.h>
-#include <testshl/result/callbackfunc.h>
-#include <testshl/autoregister/testfunc.h>
-#include "testshl/filehelper.hxx"
-
-FunctionList m_Functions;
-// osl::Mutex m_Mutex;
-
-extern "C" void SAL_CALL registerFunc(FktPtr _pFunc, const char*)
-{
- m_Functions.push_back(_pFunc);
-}
-
-// -----------------------------------------------------------------------------
-AutomaticRegisterHelper::AutomaticRegisterHelper(rtl::OUString const& _sDLLName, GetOpt & _aOptions /*, JobList * _pJobList*/)
- :DynamicLibraryHelper(_sDLLName, _aOptions),
- m_bLoadLibraryOK(false)
-{
- // try to get the entry pointer
- FktRegAllPtr pFunc = (FktRegAllPtr) m_pModule->getFunctionSymbol(
- rtl::OUString::createFromAscii( "registerAllTestFunction" ) );
-
- if (pFunc)
- {
- m_bLoadLibraryOK = true;
- // FktRegFuncPtr pRegisterFunc = &DynamicLibraryHelper::registerFunc;
- // pFunc(pRegisterFunc);
- // osl::Guard aGuard(m_Mutex);
- FktRegFuncPtr pRegisterFunc = &registerFunc;
-
- CallbackStructure aCallback;
- aCallback.aRegisterFunction = pRegisterFunc;
-
- aCallback.aCallbackDispatch = &CallbackDispatch;
-
- // special parameter for API testing
- if (_aOptions.hasOpt("-forward"))
- {
- aCallback.psForward = _aOptions.getOpt("-forward").getStr();
- }
-
- // aCallback.pJobList = _pJobList;
-
- //# aCallback.aStartTest = &TestResult_startTest;
- //# aCallback.aAddFailure = &TestResult_addFailure;
- //# aCallback.aAddError = &TestResult_addError;
- //# aCallback.aEndTest = &TestResult_endTest;
- //# aCallback.aShouldStop = &TestResult_shouldStop;
- //# aCallback.aAddInfo = &TestResult_addInfo;
- //# aCallback.aEnterNode = &TestResult_enterNode;
- //# aCallback.aLeaveNode = &TestResult_leaveNode;
-
- aCallback.nBits = FileHelper::createFlags(_aOptions);
-
- pFunc(&aCallback);
-
- if (aCallback.nMagic == aCallback.nMagic2)
- {
- // ok internal simple test done.
- m_aFunctionList = m_Functions;
- }
- else
- {
- // ERROR, the function seams not to be what we thing it's to be.
- fprintf(stderr, "error: Internal check failed. Structure inconsistent, Value Magic2 != Magic.\nPlease recompile your test libraries.");
- exit(-1);
- }
- }
- else
- {
- fprintf(stderr, "warning: Function 'registerAllTestFunction' not found.\n");
- fprintf(stderr, "If you think, you are right, build testshl2 completly new.\n");
- }
-}
-
-void AutomaticRegisterHelper::CallAll(hTestResult _hResult) const
-{
- // can't load the module, break the tests.
- if (m_bLoadLibraryOK == false)
- {
- return;
- }
-
- for (FunctionList::const_iterator it = m_aFunctionList.begin();
- it != m_aFunctionList.end();
- ++it)
- {
- FktPtr pFunc = *it;
- if (pFunc)
- {
- (pFunc)(_hResult);
- }
- }
-}
-
-AutomaticRegisterHelper::~AutomaticRegisterHelper()
-{
- if (getOptions().hasOpt("-verbose"))
- {
- fprintf(stderr, "Dtor AutomaticRegisterHelper.\n");
- }
-}
diff --git a/testshl2/source/codegen/codegen.pl b/testshl2/source/codegen/codegen.pl
deleted file mode 100644
index ab7a68397aeb..000000000000
--- a/testshl2/source/codegen/codegen.pl
+++ /dev/null
@@ -1,601 +0,0 @@
-eval 'exec perl -wS $0 ${1+"$@"}'
- if 0;
-
-use strict;
-use Cwd;
-
-# #/usr/bin/perl
-
-# @lines
-# push(@lines, $line) append
-# pop(@lines) remove last
-# shift(@lines) remove at first
-# unshift(@lines, $line) insert at first
-# $lines[-1] get last
-# foreach $line (@lines)
-
-# $a eq $b compares strings
-# $a == $b compares digits
-
-# split operator
-# ($vorname, $nachname, $email) = split (/\s+/, $person);
-
-my $sCurrentPackage = "";
-my $sCurrentClass = "";
-my @sMethodNames;
-my @sClassNameStack;
-my @sFilenameStack;
-my $sCurrentFilename;
-my $nNoAdditionalAnyMore = 0;
-my $bShowDemo = 1;
-my $sSrcExt = ".cxx";
-
-my $cwd = getcwd();
-
-sub generateMakefileEntry(*$$);
-
-# ------------------------------------------------------------------------------
-sub createFilename
-{
- my $sPackageName = shift;
- my $sFilenameCounter = "$sPackageName$sSrcExt";
- my $sFilename = "$sPackageName";
- my $nCount = 0;
- while ( -e $sFilenameCounter)
- {
- $nCount ++;
- $sFilename = "$sPackageName" . "_$nCount";
- $sFilenameCounter = "$sFilename$sSrcExt";
- }
- push(@sFilenameStack, $sFilename);
-
- $sCurrentFilename = $sFilenameCounter;
- return $sFilenameCounter;
-}
-# ------------------------------------------------------------------------------
-
-sub generateNewPackage(*$)
-{
- local *CPPFILE = shift;
- my $sPackageName = shift;
-
- my $sFilename = createFilename($sPackageName);
- open(CPPFILE, ">$sFilename") || die "can't create source file";
- print CPPFILE "// autogenerated file with codegen.pl\n";
- print CPPFILE "\n";
- print CPPFILE "#include <testshl/simpleheader.hxx>\n";
- print CPPFILE "\n";
- print CPPFILE "namespace $sPackageName\n";
- print CPPFILE "{\n";
-}
-
-# ------------------------------------------------------------------------------
-sub generateNewClass
-{
- my $sClassName = shift;
- print CPPFILE "\n";
- print CPPFILE "class $sClassName : public CppUnit::TestFixture\n";
- print CPPFILE "{\n";
- print CPPFILE "public:\n";
-}
-# ------------------------------------------------------------------------------
-sub closeMethods
-{
- # due to the fact, that this is a function based code, not object based
- # we have to do some hacks, to prevent us from creating wrong code
- if ($sCurrentClass =~ /^$/ || $sCurrentPackage =~ /^$/ )
- {
- return;
- }
-
- # here we create the methods
- # first the setUp() and tearDown()
- print CPPFILE " // initialise your test code values here.\n";
- print CPPFILE " void setUp()\n";
- print CPPFILE " {\n";
- print CPPFILE " }\n";
- print CPPFILE "\n";
- print CPPFILE " void tearDown()\n";
- print CPPFILE " {\n";
- print CPPFILE " }\n";
- print CPPFILE "\n";
-
- print CPPFILE " // insert your test code here.\n";
-
- my $sMethod;
- if ($#sMethodNames >= 0)
- {
- # all found methods
- foreach $sMethod (@sMethodNames)
- {
- print CPPFILE " void $sMethod()\n";
- print CPPFILE " {\n";
- if ($bShowDemo == 1)
- {
- print CPPFILE " // this is demonstration code\n";
- print CPPFILE " // CPPUNIT_ASSERT_MESSAGE(\"a message\", 1 == 1);\n";
- $bShowDemo = 0;
- }
- print CPPFILE " CPPUNIT_ASSERT_STUB();\n";
- print CPPFILE " }\n";
- print CPPFILE "\n";
- }
- }
- else
- {
- # if no methods found, create at least one
- print CPPFILE " // this is only demonstration code\n";
- print CPPFILE " void EmptyMethod()\n";
- print CPPFILE " {\n";
- print CPPFILE " // CPPUNIT_ASSERT_MESSAGE(\"a message\", 1 == 1);\n";
- print CPPFILE " CPPUNIT_ASSERT_STUB();\n";
- print CPPFILE " }\n";
- print CPPFILE "\n";
- }
-
- # create the autoregister code
- print CPPFILE " // Change the following lines only, if you add, remove or rename \n";
- print CPPFILE " // member functions of the current class, \n";
- print CPPFILE " // because these macros are need by auto register mechanism.\n";
- print CPPFILE "\n";
-
- print CPPFILE " CPPUNIT_TEST_SUITE($sCurrentClass);\n";
- push(@sClassNameStack, $sCurrentClass);
-
- my $nCount = 0;
- if ($#sMethodNames >= 0)
- {
- foreach $sMethod (@sMethodNames)
- {
- print CPPFILE " CPPUNIT_TEST($sMethod);\n";
- $nCount ++;
- }
- # empty the method list
- my $i;
- for ($i = 0;$i < $nCount;$i++)
- {
- pop(@sMethodNames);
- }
- }
- else
- {
- print CPPFILE " CPPUNIT_TEST(EmptyMethod);\n";
- }
- print CPPFILE " CPPUNIT_TEST_SUITE_END();\n";
-}
-
-# ------------------------------------------------------------------------------
-sub closeClass
-{
- # my $sClassName = shift;
- if ($sCurrentClass =~ /^$/)
- {
- return;
- }
- print CPPFILE "}; // class $sCurrentClass\n";
- print CPPFILE "\n";
- $sCurrentClass = "";
-}
-# ------------------------------------------------------------------------------
-
-sub closePackage
-{
- # my $sPackageName = shift;
- if ($sCurrentPackage =~ /^$/)
- {
- return;
- }
- # create the autoregister code
- print CPPFILE "// -----------------------------------------------------------------------------\n";
- my $nCount = 0;
- my $sClassName;
- foreach $sClassName (@sClassNameStack)
- {
- print CPPFILE "CPPUNIT_TEST_SUITE_NAMED_REGISTRATION($sCurrentPackage" . "::" . "$sClassName, \"$sCurrentPackage\");\n";
- $nCount ++;
- }
- # empty the method list
- my $i;
- for ($i = 0;$i < $nCount;$i++)
- {
- pop(@sClassNameStack);
- }
-
- print CPPFILE "} // namespace $sCurrentPackage\n";
- print CPPFILE "\n";
-
- print CPPFILE "
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-";
- # if the variable nNoAdditionalAnyMore is set to one, we insert a remark before
- # the macro NOADDITIONAL; to prevent us from linker problems.
- if ($nNoAdditionalAnyMore == 1)
- {
- print CPPFILE "// ";
- }
- print CPPFILE "NOADDITIONAL;\n";
- print CPPFILE "\n";
-
- close(CPPFILE);
-
- $nNoAdditionalAnyMore = 1;
-
- $sCurrentPackage = "";
-}
-
-# ------------------------------------------------------------------------------
-
-# sub generateCppSource
-# {
-# my $sPackageName = shift;
-# my $sClassName = shift;
-# my $sMethodName = shift;
-#
-#
-# open(CPPFILE, ">$sFilename") || die "can't create cxx source file";
-# print CPPFILE "// autogenerated file\n";
-# close(CPPFILE);
-# }
-# ------------------------------------------------------------------------------
-sub walkThroughJobFile
-{
- my $filename = shift;
-
- open(FILE, $filename) || die "can't open $filename\n";
-
- print "start jobfile interpreter.\n";
- my $line;
- while($line = <FILE>)
- {
- chomp($line);
- # DOS Hack grrrr...
- while ($line =~ /
-$/)
- {
- $line = substr($line, 0, -1);
- }
-
- if ($line =~ /^\#/ || $line =~ /^$/)
- {
- # remark or empty line
- }
- else
- {
- if ($line =~ /^\w+/) # must start with a word character
- {
- # print "$line\n";
- my $sPackageName = "";
- my $sClassName = "";
- my $sMethodName = "";
- my @names;
- @names = split(/\./, $line);
- if (exists $names[0])
- {
- $sPackageName = $names[0];
- }
- if (exists $names[1])
- {
- $sClassName = $names[1];
- }
- if (exists $names[2])
- {
- $sMethodName = $names[2];
- }
-
- if ($sClassName =~ /^$/)
- {
- print "error: in $line, no class name exist. Build no code.\n";
- }
- # test if it also works without methods
- # elsif ($sMethodName =~ /^$/)
- # {
- # print "error: in $line, no method name exist.\n";
- # }
- else
- {
- if ($sMethodName =~ /^$/)
- {
- print "warning: in $line, no method name exist, create only one member function.\n";
- }
-
- print "build code for: ${sPackageName}.${sClassName}.${sMethodName}\n";
-
- if ($sCurrentPackage ne $sPackageName)
- {
- closeMethods();
- closeClass();
- closePackage();
-
- $sCurrentPackage = $sPackageName;
- generateNewPackage(CPPFILE, $sPackageName);
- }
- if ($sCurrentClass ne $sClassName)
- {
- closeMethods();
- closeClass();
- $sCurrentClass = $sClassName;
- generateNewClass($sClassName);
- }
- if ($sMethodName)
- {
- push(@sMethodNames, $sMethodName);
- }
- }
- }
- }
- }
-
- closeMethods();
- closeClass();
- closePackage();
- close(FILE);
-
- print "done.\n\nThe following files have been created in the current directory:\n";
-
- my $sFilename;
- foreach $sFilename (@sFilenameStack)
- {
- print " ${sFilename}${sSrcExt}\n";
- }
- print "\n";
-}
-
-# ------------------------------------------------------------------------------
-sub checkMakefileNumber
-{
- my $sTargetName = shift;
-
- # This function gives back the lowest number for SHL\dTARGET
- open(MAKEFILE, "makefile.mk") || return -1;
-
- my $line;
- my $nNumber;
- my @aNumbers;
- my $i;
- for($i = 1;$i < 10;$i++)
- {
- $aNumbers[$i] = 0;
- }
-
- my $nReplacePos = -1;
- while($line = <MAKEFILE>)
- {
- chomp($line);
-
- if ($line =~ /^SHL(\d)TARGET/)
- {
- $aNumbers[$1] = 1;
- $line =~ /^SHL(\d)TARGET=\s*(\S+)\s*/;
-
- print "Target: $2\n";
- if ($sTargetName eq $2)
- {
- print "info: Targetname already exist.\n";
- $nReplacePos = $1;
- }
- }
- }
- close(MAKEFILE);
-
- my $nFirstFree = 0;
- for($i = 1;$i < 10;$i++)
- {
- if ($aNumbers[$i] == 0)
- {
- $nFirstFree = $i;
- last;
- }
- }
- return $nFirstFree, $nReplacePos;
-}
-# ------------------------------------------------------------------------------
-sub createNewMakefile($$$)
-{
- my $sNewMakefileName = shift;
- my $sTargetName = shift;
- my $nNumber = shift;
- local *MAKEFILE;
-
- # this function split a makefile into two parts,
- open(MAKEFILE, "makefile.mk") || return;
- my @lines = <MAKEFILE>;
- close(MAKEFILE);
-
- # print "info: Makefile has $#lines lines.\n";
-
- # search a point, where to insert the new makefile part.
- my $nTargetMK = -1;
- my $i;
- for ($i = $#lines; $i > 0; $i--)
- {
- if ($lines[$i] =~ /\.INCLUDE.*target.mk\s$/)
- {
- $nTargetMK = $i;
- last;
- }
- }
- if ($nTargetMK > 0)
- {
- # print "info: target.mk found, is in line $nTargetMK\n";
-
- # print "@lines[0]";
- # print "@lines[1]";
- # print "@lines[2]";
- # print "@lines[$nTargetMK - 2]";
- # print "@lines[$nTargetMK - 1]";
- # print "@lines[$nTargetMK]";
-
- local *OUT_MAKEFILE;
- open(OUT_MAKEFILE, ">$sNewMakefileName") || return;
- for ($i = 0;$i < ($nTargetMK - 2); $i++)
- {
- print OUT_MAKEFILE $lines[$i];
- }
-
- generateMakefileEntry(OUT_MAKEFILE, $sTargetName, $nNumber);
-
- for ($i = ($nTargetMK - 2);$i <= $#lines; $i++)
- {
- print OUT_MAKEFILE $lines[$i];
- }
- close(OUT_MAKEFILE);
- }
-}
-# ------------------------------------------------------------------------------
-
-sub generateMakefileEntry(*$$)
-{
- # my MAKEFILE = shift;
- local *_MAKEFILE = shift;
- my $sTargetName = shift;
- my $nNumber = shift;
-
- # open(_MAKEFILE, ">makefile.add") || die "can't open makefile.add";
-
- print _MAKEFILE "# BEGIN ----------------------------------------------------------------\n";
- print _MAKEFILE "# auto generated Target:$sTargetName by codegen.pl \n";
- print _MAKEFILE "SHL${nNumber}OBJS= ";
- my $sFilename;
- foreach $sFilename (@sFilenameStack)
- {
- print _MAKEFILE " \\\n";
- print _MAKEFILE " \$(SLO)\$/$sFilename.obj";
- }
- print _MAKEFILE "\n\n";
-
- # targetname
- print _MAKEFILE "SHL${nNumber}TARGET= $sTargetName\n";
- # additional libraries
- print _MAKEFILE "SHL${nNumber}STDLIBS=\\\n";
- print _MAKEFILE " \$(SALLIB) \\\n";
- # LLA: added by sb 18th jun 2003 (announced)
- print _MAKEFILE " \$(CPPUNITLIB) \n";
- # link static cppunit library
- # print _MAKEFILE ".IF \"\$(GUI)\" == \"WNT\"\n";
- # print _MAKEFILE "SHL${nNumber}STDLIBS+= \$(SOLARLIBDIR)\$/cppunit.lib\n";
- # print _MAKEFILE ".ENDIF\n";
- # print _MAKEFILE ".IF \"\$(GUI)\" == \"UNX\"\n";
- # print _MAKEFILE "SHL${nNumber}STDLIBS+=\$(SOLARLIBDIR)\$/libcppunit\$(DLLPOSTFIX).a\n";
- # print _MAKEFILE ".ENDIF\n";
- print _MAKEFILE "\n";
- print _MAKEFILE "SHL${nNumber}IMPLIB= i\$(SHL${nNumber}TARGET)\n";
- print _MAKEFILE "# SHL${nNumber}DEF= \$(MISC)\$/\$(SHL${nNumber}TARGET).def\n";
- print _MAKEFILE "\n";
- # DEF name
- print _MAKEFILE "DEF${nNumber}NAME =\$(SHL${nNumber}TARGET)\n";
- print _MAKEFILE "# DEF${nNumber}EXPORTFILE= export.exp\n";
- print _MAKEFILE "SHL${nNumber}VERSIONMAP= export.map\n";
- print _MAKEFILE "# auto generated Target:$sTargetName\n";
- print _MAKEFILE "# END ------------------------------------------------------------------\n\n";
-
- # close(_MAKEFILE);
-}
-
-# ------------------------------------------------------------------------------
-sub usage
-{
- print "usage:\ncodegen.pl joblist [targetname]\n";
- print "\n(c) Sun Microsystems Inc. 2003\n";
- print "
-This is a testshl2 codegenerator which creates compilable C++ source files
-with stub functions for all given test routines from the jobfile.
-Also generate a makefile entry which is insert in the makefile.new
-if a makefile.mk already exist or this tool creates a makefile.add. Which
-has to add into a new makefile.mk by hand.
-Also generate a export.map file, if no one exist.
-";
- exit(1);
-}
-# -------------------------------- main function --------------------------------
-
-sub main
-{
- if ($#ARGV < 0)
- {
- usage();
- }
- my $jobfile = $ARGV[0];
- my $sTargetName;
- if ($#ARGV < 2)
- {
- # remove .sce
- $sTargetName = $jobfile;
- $sTargetName =~ s/\.\w*//;
- }
- else
- {
- $sTargetName = $ARGV[1];
- }
- print "Test code generator\n\n";
-
- if (! -e $jobfile)
- {
- print "error: given jobfile '$jobfile' doesn't exist.\n";
- exit(1);
- }
- walkThroughJobFile($jobfile);
-
- # generate makefile
-
- if (-e "makefile.mk")
- {
- my $n;
- my $nReplacePos;
- ($n, $nReplacePos) = checkMakefileNumber($sTargetName);
- # $n == -1 no makefile
- # $n == 0 no free number
- # $n 1..9 ok.
- if ($n > 0)
- {
- my $sNewMakefileName = "makefile.new";
- print "Makefile: Add the 'SHL${n}TARGET' to the file '$sNewMakefileName'\n";
- createNewMakefile($sNewMakefileName, $sTargetName, $n);
- }
- }
- else
- {
- print "warning: No makefile.mk found, please add the content of makefile.add to a makefile.mk file\n";
- local *MAKEFILE;
- open(MAKEFILE, ">makefile.add");
- generateMakefileEntry(MAKEFILE, $sTargetName, 1);
- close(MAKEFILE);
- }
- print "\n";
- # this is the old export.exp method
- # if (! -e "export.exp")
- # {
- # print "info: create export.exp file\n";
- # open(EXPORTEXP, ">export.exp") || die "can't create export.exp";
- # print EXPORTEXP "registerAllTestFunction\n";
- # close(EXPORTEXP);
- # }
- # else
- # {
- # print "The file 'export.exp' file already exist, please make sure that it contains the entry 'registerAllTestFunction'.\n";
- # }
- if (! -e "export.map")
- {
- local *EXPORTMAP;
- print "info: create export.map file\n";
- open(EXPORTMAP, ">export.map") || die "can't create export.map";
- print EXPORTMAP "UDK_3.0 {\n";
- print EXPORTMAP " global:\n";
- print EXPORTMAP " registerAllTestFunction;\n";
- print EXPORTMAP "\n";
- print EXPORTMAP " local:\n";
- print EXPORTMAP " *;\n";
- print EXPORTMAP "};\n";
- close(EXPORTMAP);
- }
- else
- {
- print "The file 'export.map' file already exist, please make sure that it contains the entry 'registerAllTestFunction'.\n";
- }
-}
-
-# ------------------------------------------------------------------------------
-
-main();
diff --git a/testshl2/source/cppunit/cmdlinebits.cxx b/testshl2/source/cppunit/cmdlinebits.cxx
deleted file mode 100644
index 061e82fe2d73..000000000000
--- a/testshl2/source/cppunit/cmdlinebits.cxx
+++ /dev/null
@@ -1,141 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#ifdef WNT
-# define UNDER_WINDOWS_DEBUGGING
-# include "testshl/winstuff.hxx"
-#endif /* WNT */
-
-#include <stdio.h>
-#include <testshl/cmdlinebits.hxx>
-#include "testshl/checkboom.hxx"
-
-#include <testshl/autoregister/callbackstructure.h>
-#include <osl/diagnose.h>
-#include <rtl/tres.h>
-#include <testshl/stringhelper.hxx>
-
-extern CallbackStructure aGlobalStructure;
-
-sal_Bool isBit( CmdLineBits _nBits, CmdLineBits _nFlag );
-
-// sal_Bool isBit( CmdLineBits _nBits, CmdLineBits _nFlag )
-// {
-// return( ( _nBits & _nFlag ) == _nFlag );
-// }
-
-void CheckBoom(bool bCondition, std::string const& msg)
-{
- (void) msg; // avoid warning
- if ( isBit( aGlobalStructure.nBits, rtl_tres_Flag_BOOM ) )
- {
- /* force an assertion on false state */
- if ( !bCondition ) {
-#ifdef UNDER_WINDOWS_DEBUGGING
- WinDebugBreak();
-#else
- OSL_ENSURE( false, msg.c_str() );
-#endif
- }
- }
-}
-
-void CheckBoom(bool bCondition, rtl::OUString const& msg)
-{
- if ( isBit( aGlobalStructure.nBits, rtl_tres_Flag_BOOM ) )
- {
- /* force an assertion on false state */
- rtl::OString sMessage;
- sMessage <<= msg;
- if ( !bCondition ) {
-#ifdef UNDER_WINDOWS_DEBUGGING
- WinDebugBreak();
-#else
- OSL_ENSURE( false, sMessage.getStr() );
-#endif
- }
- }
-}
-
-const char* getForwardString()
-{
- return aGlobalStructure.psForward;
-}
-
-// -----------------------------------------------------------------------------
-// ----------------------------- own printf method -----------------------------
-// -----------------------------------------------------------------------------
-
-// bool isVerbose()
-// {
-// if ( isBit( aGlobalStructure.nBits, rtl_tres_Flag_VERBOSE ) )
-// {
-// return true;
-// }
-// return false;
-// }
-//
-// bool isQuiet()
-// {
-// if ( isBit( aGlobalStructure.nBits, rtl_tres_Flag_QUIET ) )
-// {
-// return true;
-// }
-// return false;
-// }
-//
-// void impl_t_print(const char* _pFormatStr, va_list &args)
-// {
-// if (! isQuiet())
-// {
-// printf("# ");
-// vprintf(_pFormatStr, args);
-// }
-// }
-//
-// void t_print(const char* _pFormatStr, ...)
-// {
-// va_list args;
-// va_start( args, _pFormatStr );
-// impl_t_print(_pFormatStr, args);
-// va_end( args );
-// }
-//
-// void t_print(T_Print_Params _eType, const char* _pFormatStr, ...)
-// {
-// if (_eType == T_VERBOSE && isVerbose())
-// {
-// // if T_VERBOSE and we should be verbose, print info
-// va_list args;
-// va_start( args, _pFormatStr );
-// impl_t_print(_pFormatStr, args);
-// va_end( args );
-// }
-// }
diff --git a/testshl2/source/cppunit/joblist.cxx b/testshl2/source/cppunit/joblist.cxx
deleted file mode 100644
index 18f4c5aff4cd..000000000000
--- a/testshl2/source/cppunit/joblist.cxx
+++ /dev/null
@@ -1,221 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <fstream>
-#include <rtl/string.hxx>
-#include "testshl/joblist.hxx"
-
-#define C_SEPARATOR_LIST " \t,;:#"
-JobList::JobList()
- :ppsJobList(NULL)
-{}
-
-// -----------------------------------------------------------------------------
-bool JobList::isInCurrentEnvironment(std::string const& _sString)
-{
- int nSpace = 0;
- std::string sSearchString = _sString;
- bool bEnd = false;
- // run through the hole given string,
- std::string sEnv;
-
- do {
- nSpace = sSearchString.find_first_of(C_SEPARATOR_LIST);
- if (nSpace < 0)
- {
- sEnv = sSearchString;
- bEnd = true;
- }
- else
- {
- sEnv = sSearchString.substr(0, nSpace);
- sSearchString = sSearchString.substr(nSpace + 1);
- }
- if (sEnv.length() > 0)
- {
- // cout << sEnv << endl;
-#ifdef LINUX
- int nLinux = sEnv.find("unxlng");
- if (nLinux >= 0)
- {
- // found unxlng
- return true;
- }
-#endif
-#ifdef SOLARIS
- int nSolaris = sEnv.find("unxsol");
- if (nSolaris >= 0)
- {
- // found unxsol
- return true;
- }
-#endif
-#ifdef WNT
- int nWindows = sEnv.find("wnt");
- if (nWindows >= 0)
- {
- // found wnt
- return true;
- }
-#endif
- }
- } while ( !bEnd );
- return false;
-}
-
-std::string JobList::trim(std::string const& _sStringToTrim)
-{
- rtl::OString sStr(_sStringToTrim.c_str());
- sStr = sStr.trim();
- return std::string(sStr.getStr());
-}
-
-// -----------------------------------------------------------------------------
-bool JobList::readfile(std::string const& _sFilename, JobType _nJobType)
-{
- // StringList aJobList;
- m_aJobList.clear();
-
- std::ifstream in(_sFilename.c_str(), std::ios::in);
-
- if (!in)
- {
- // fprintf(stderr, "warning: Can't open job file: %s\n", _sFilename.c_str());
- return false;
- }
- else
- {
- if (_nJobType == JOB_EXCLUDE_LIST)
- {
- fprintf(stderr, "warning: There exist a job exclusion list file: %s\n", _sFilename.c_str());
- }
-
- // std::cout << "Check for signal" << std::endl;
- std::string sLine;
- while (std::getline(in, sLine))
- {
- if (sLine.size() > 0)
- {
- char ch = sLine[0];
- if (ch != '#' &&
- isspace(ch) == 0)
- {
- sLine = trim(sLine);
-
- // m_aJobList.push_back( sLine );
- int nSpace = sLine.find_first_of(C_SEPARATOR_LIST);
- if (nSpace < 0)
- {
- m_aJobList[sLine] = JOB_UNKNOWN;
- }
- else
- {
- // found a separator
- std::string sTest = sLine.substr(0, nSpace);
- std::string sRest = sLine.substr(nSpace + 1);
- if (isInCurrentEnvironment(sRest))
- {
- m_aJobList[sTest] = JOB_UNKNOWN;
- }
- }
- }
- }
- }
-
- // inclusion list
-/*
- int nSize = m_aJobList.size();
-
- ppsJobList = (char**) malloc((nSize + 1) * sizeof(char*));
-
- int nIdx = 0;
- StringList::const_iterator aItEnd = m_aJobList.end();
- for(StringList::const_iterator it = m_aJobList.begin();
- it != aItEnd; ++it)
- {
- std::string sValue = *it;
- char* psTestFkt = (char*) malloc(sValue.size() + 1);
- strcpy(psTestFkt, sValue.c_str());
- ppsJobList[nIdx] = psTestFkt;
- ++nIdx;
- }
-
- ppsJobList[nIdx] = NULL;
-*/
- }
- return true;
-}
-
-// -----------------------------------------------------------------------------
-int JobList::getJobListEntry(std::string const& _sIndexName)
-{
- if (m_aJobList.find(_sIndexName) != m_aJobList.end())
- {
- return m_aJobList[_sIndexName];
- }
- return JOB_NOT_FOUND;
-}
-
-// -----------------------------------------------------------------------------
-void JobList::setJobListEntry(std::string const& _sIndexName, int _nValue)
-{
- // if (m_aJobList.find(_sIndexName) == m_aJobList.end())
- // {
- m_aJobList[_sIndexName] = _nValue;
- // }
- // else
- // {
- // fprintf(stderr, "error: test function '%s' already exist.\n", _sIndexName);
- // }
-}
-
-// -----------------------------------------------------------------------------
-JobList::~JobList()
-{
- int nIdx = 0;
- if (ppsJobList)
- {
- while(ppsJobList[nIdx] != NULL)
- {
- free(ppsJobList[nIdx]);
- ++nIdx;
- }
- free(ppsJobList);
- }
-}
-// -----------------------------------------------------------------------------
-/*
- bool JobList::checkFilter(JobList m_aJobFilter, std::string const& _sNodeName, std::string const& _sName)
- {
- std::string sFilter = m_aJobFilter.m_aJobList.begin();
- }
-*/
diff --git a/testshl2/source/cppunit/makefile.mk b/testshl2/source/cppunit/makefile.mk
deleted file mode 100644
index 05e5bfa3fb69..000000000000
--- a/testshl2/source/cppunit/makefile.mk
+++ /dev/null
@@ -1,99 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-
-PRJNAME=testshl2
-TARGET=testshl2
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE
-# ENABLE_RTTI=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-
-# CXXFILES = \
-# querytemplate.cxx \
-# stringhelper.cxx
-
-# ENVCFLAGSCXX+=-DCPPUNIT_BUILD_DLL
-
-CPPUNIT_TESTSHL_SLOFILES = \
- $(SLO)$/joblist.obj \
- $(SLO)$/t_print.obj \
- $(SLO)$/signaltest.obj
-
-CPPUNIT_STATIC_SOLFILES = \
- $(SLO)$/cmdlinebits.obj \
- $(SLO)$/tresregister.obj \
- $(SLO)$/tresstatewrapper.obj \
- $(SLO)$/registertestfunction.obj
-
-
-SLOFILES = \
- $(CPPUNIT_TESTSHL_SLOFILES) \
- $(CPPUNIT_STATIC_SOLFILES)
-#-------------------------------------------------------------------------------
-# This is statically cppunit library
-LIB1TARGET= $(LB)$/$(TARGET).lib
-LIB1OBJFILES= \
- $(SLOFILES)
-
-.IF "$(GUI)"=="WNT"
-.IF "$(COM)"=="GCC"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-LIB1FILES=$(LB)$/c5t_winstuff.lib
-.ENDIF
-
-.IF "$(GUI)" == "UNX"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-
-#-------------------------------------------------------------------------------
-TARGET2=c5t_no_regallfkt
-LIB2TARGET= $(LB)$/$(TARGET2).lib
-LIB2OBJFILES= \
- $(CPPUNIT_TESTSHL_SLOFILES)
-
-.IF "$(GUI)"=="WNT"
-.IF "$(COM)"=="GCC"
-LIB2ARCHIV=$(LB)$/lib$(TARGET2)$(DLLPOSTFIX).a
-.ENDIF
-.ENDIF
-
-.IF "$(GUI)" == "UNX"
-LIB2ARCHIV=$(LB)$/lib$(TARGET2)$(DLLPOSTFIX).a
-.ENDIF
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/testshl2/source/cppunit/registertestfunction.cxx b/testshl2/source/cppunit/registertestfunction.cxx
deleted file mode 100644
index 74c70ee55ab1..000000000000
--- a/testshl2/source/cppunit/registertestfunction.cxx
+++ /dev/null
@@ -1,57 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-#include <testshl/simpleheader.hxx>
-#include <testshl/additionalfunc.hxx>
-
-extern "C" void SAL_CALL testAllRegisteredFunctions(hTestResult _pResult)
-{
- CppUnit::TestFactoryRegistry::testRegistries(_pResult);
- // CppUnit::Test* tp = CppUnit::TestFactoryRegistry::getRegistry("rtl_OUString").makeTest();
- // tp->run(pResult);
-}
-
-// -----------------------------------------------------------------------------
-// ---------------------------- RegisterTestFunctions ----------------------------
-// -----------------------------------------------------------------------------
-
-extern "C" void SAL_CALL RegisterTestFunctions(FktRegFuncPtr _pFunc)
-{
- if (_pFunc)
- {
- (_pFunc)(&testAllRegisteredFunctions, "");
- }
- else
- {
- // error, FktRegFuncPtr not given
- }
- RegisterAdditionalFunctions(_pFunc);
-}
diff --git a/testshl2/source/cppunit/result/SynchronizedObject.cpp b/testshl2/source/cppunit/result/SynchronizedObject.cpp
deleted file mode 100644
index 73de43b8c543..000000000000
--- a/testshl2/source/cppunit/result/SynchronizedObject.cpp
+++ /dev/null
@@ -1,38 +0,0 @@
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <cppunit/SynchronizedObject.h>
-
-
-namespace CppUnit
-{
-
-
-
-
-SynchronizedObject::SynchronizedObject( SynchronizationObject *syncObject )
- : m_syncObject( syncObject == 0 ? new SynchronizationObject() :
- syncObject )
-{
-}
-
-
-SynchronizedObject::~SynchronizedObject()
-{
- delete m_syncObject;
-}
-
-
-/** Accept a new synchronization object for protection of this instance
- * TestResult assumes ownership of the object
- */
-void
-SynchronizedObject::setSynchronizationObject( SynchronizationObject *syncObject )
-{
- delete m_syncObject;
- m_syncObject = syncObject;
-}
-
-
-} // namespace CppUnit
-
diff --git a/testshl2/source/cppunit/result/TestResult.cpp b/testshl2/source/cppunit/result/TestResult.cpp
deleted file mode 100644
index 5fa5e444e540..000000000000
--- a/testshl2/source/cppunit/result/TestResult.cpp
+++ /dev/null
@@ -1,264 +0,0 @@
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <cppunit/TestFailure.h>
-#include <testshl/result/TestListener.h>
-#include "testshl/getopt.hxx"
-#include <testshl/result/TestResult.h>
-#include <algorithm>
-#include "testshl/result/outputter.hxx"
-#include <cppunit/Test.h>
-#include <testshl/cmdlinebits.hxx>
-
-namespace CppUnit {
-
-/// Construct a TestResult
-TestResult::TestResult( GetOpt &_pOptions, SynchronizationObject *syncObject )
- : SynchronizedObject( syncObject ),
- m_aOptionHelper(_pOptions),
- m_nExitValue(0)
-{
- reset();
-}
-
-
-/// Destroys a test result
-TestResult::~TestResult()
-{
-}
-
-
-/** Resets the result for a new run.
- *
- * Clear the previous run result.
- */
-void
-TestResult::reset()
-{
- ExclusiveZone zone( m_syncObject );
- m_stop = false;
-}
-
-
-/** Adds an error to the list of errors.
- * The passed in exception
- * caused the error
- */
-void
-TestResult::addError( Test *test,
- Exception *e, ErrorType::num _eType )
-{
- TestFailure aTestFailure( test, e, _eType );
- addFailure( aTestFailure );
-}
-
-
-/** Adds a failure to the list of failures. The passed in exception
- * caused the failure.
- */
-void
-TestResult::addFailure( Test *test, Exception *e )
-{
- TestFailure aTestFailure( test, e, ErrorType::ET_FAILURE );
- addFailure( aTestFailure );
-}
-
-
-/** Called to add a failure to the list of failures.
- */
-void
-TestResult::addFailure( const TestFailure &failure )
-{
- ExclusiveZone zone( m_syncObject );
-
- // LLA:
- // this set the global returnvalue, due to the fact, there occurs a failure, we have to return a non zero value
- // at the moment this seams to be a good place.
- setExitValue(1);
-
- for ( TestListeners::iterator it = m_listeners.begin();
- it != m_listeners.end();
- ++it )
- {
- TestListener *pListener = *it;
- pListener->addFailure( failure );
- }
-}
-
-
-/// Informs the result that a test will be started.
-void
-TestResult::startTest( Test *test )
-{
- ExclusiveZone zone( m_syncObject );
- if (m_aOptionHelper.isVerbose())
- {
- std::string aStr;
- if (test)
- {
- aStr = getNodeName();
- aStr += ".";
- aStr += test->getName();
- }
- // fprintf(stderr, "Start test: %s\n", aStr.c_str());
- t_print( T_VERBOSE, "Start test: %s\n", aStr.c_str());
- }
-
- for ( TestListeners::iterator it = m_listeners.begin();
- it != m_listeners.end();
- ++it )
- {
- TestListener *pListener = *it;
- pListener->startTest( test );
- }
-}
-
-
-/// Informs the result that a test was completed.
-void
-TestResult::endTest( Test *test )
-{
- ExclusiveZone zone( m_syncObject );
- for ( TestListeners::iterator it = m_listeners.begin();
- it != m_listeners.end();
- ++it )
- {
- TestListener *pListener = *it;
- pListener->endTest( test );
- }
-}
-
-
-/// Returns whether testing should be stopped
-bool
-TestResult::shouldStop() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_stop;
-}
-
-
-/// Stop testing
-void
-TestResult::stop()
-{
- ExclusiveZone zone( m_syncObject );
- m_stop = true;
-}
-
-
-void
-TestResult::addListener( TestListener *listener )
-{
- ExclusiveZone zone( m_syncObject );
- m_listeners.push_back( listener );
-}
-
-
-void
-TestResult::removeListener ( TestListener *listener )
-{
- ExclusiveZone zone( m_syncObject );
-#if defined(_MSC_VER) && (_MSC_VER >=1400)
- m_listeners.erase( remove( m_listeners.begin(),
-#else
- m_listeners.erase( std::remove( m_listeners.begin(),
-#endif
- m_listeners.end(),
- listener ),
- m_listeners.end());
-}
-
-void
-TestResult::addInfo(Test *test, const char* _aStr)
-{
- ExclusiveZone zone( m_syncObject );
- for ( TestListeners::iterator it = m_listeners.begin();
- it != m_listeners.end();
- ++it )
- {
- TestListener *pListener = *it;
- pListener->addInfo( test, _aStr );
- }
-}
-
-// old: void
-// old: TestResult::enterNode(const char* _aStr)
-// old: {
-// old: ExclusiveZone zone( m_syncObject );
-// old: for ( TestListeners::iterator it = m_listeners.begin();
-// old: it != m_listeners.end();
-// old: ++it )
-// old: {
-// old: TestListener *pListener = *it;
-// old: pListener->enterNode( _aStr );
-// old: }
-// old: }
-// old:
-// old: void
-// old: TestResult::leaveNode(const char* _aStr)
-// old: {
-// old: ExclusiveZone zone( m_syncObject );
-// old:
-// old: for ( TestListeners::iterator it = m_listeners.begin();
-// old: it != m_listeners.end();
-// old: ++it )
-// old: {
-// old: TestListener *pListener = *it;
-// old: pListener->leaveNode( _aStr );
-// old: }
-// old: }
-
-void TestResult::enterNode(const char* _sNode)
-{
- ExclusiveZone zone( m_syncObject );
- m_aCurrentNodeNames.push_back(std::string(_sNode));
-}
-
-void TestResult::leaveNode(const char* /*_sNode*/)
-{
- ExclusiveZone zone( m_syncObject );
- std::string sBack = m_aCurrentNodeNames.back();
- m_aCurrentNodeNames.pop_back();
-
- // due to a -Wall warning, comment out.
- // if (sBack != std::string(_sNode))
- // {
- // volatile int dummy = 0;
- // // problem?!
- // }
-}
-
-std::string TestResult::getNodeName()
-{
- std::string sName;
- for (std::vector<std::string>::const_iterator it = m_aCurrentNodeNames.begin();
- it != m_aCurrentNodeNames.end();
- ++it)
- {
- if (sName.size() != 0)
- {
- sName += ".";
- }
- sName += *it;
- }
- return sName;
-}
-
-// -----------------------------------------------------------------------------
-bool TestResult::isAllowedToExecute(std::string const& _sName)
-{
- return m_aOptionHelper.isAllowedToExecute(getNodeName(), _sName);
-}
-// -----------------------------------------------------------------------------
-bool TestResult::isOptionWhereAmI()
-{
- return m_aOptionHelper.isOptionWhereAmI();
-}
-
-// -----------------------------------------------------------------------------
-void TestResult::print(Outputter&)
-{
-}
-
-} // namespace CppUnit
diff --git a/testshl2/source/cppunit/result/TestResultCollector.cpp b/testshl2/source/cppunit/result/TestResultCollector.cpp
deleted file mode 100644
index e3913219b541..000000000000
--- a/testshl2/source/cppunit/result/TestResultCollector.cpp
+++ /dev/null
@@ -1,150 +0,0 @@
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <cppunit/TestFailure.h>
-#include <testshl/result/TestResultCollector.h>
-
-
-namespace CppUnit
-{
-
-
-TestResultCollector::TestResultCollector( TestResult* _pResult, SynchronizationObject *syncObject )
- : TestSucessListener( syncObject ),
- m_pResult(_pResult),
- m_testErrors(0)
-{
- reset();
-}
-
-
-TestResultCollector::~TestResultCollector()
-{
- TestFailures::iterator itFailure = m_failures.begin();
- while ( itFailure != m_failures.end() )
- {
- TestFailureEnvelope *pEnvelope = *itFailure++;
- TestFailure *pFailure = pEnvelope->getTestFailure();
- delete pFailure;
- }
-}
-
-
-void
-TestResultCollector::reset()
-{
- TestSucessListener::reset();
-
- ExclusiveZone zone( m_syncObject );
- m_testErrors = 0;
- m_tests.clear();
- m_failures.clear();
-}
-
-
-void
-TestResultCollector::startTest( Test *test )
-{
- ExclusiveZone zone (m_syncObject);
-
- m_tests.push_back( new TestEnvelope(test, m_pResult->getNodeName()) );
-}
-
-void
-TestResultCollector::endTest( Test * )
-{
- // ExclusiveZone zone (m_syncObject);
- // Nothing!
-}
-
-
-void
-TestResultCollector::addFailure( const TestFailure &failure )
-{
- TestSucessListener::addFailure( failure );
-
- ExclusiveZone zone( m_syncObject );
- if ( failure.isError() )
- ++m_testErrors;
- m_failures.push_back( new TestFailureEnvelope(failure.clone(), m_pResult->getNodeName()) );
-}
-
-
-/// Gets the number of run tests.
-int
-TestResultCollector::runTests() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_tests.size();
-}
-
-
-/// Gets the number of detected errors (uncaught exception).
-int
-TestResultCollector::testErrors() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_testErrors;
-}
-
-
-/// Gets the number of detected failures (failed assertion).
-int
-TestResultCollector::testFailures() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_failures.size() - m_testErrors;
-}
-
-
-/// Gets the total number of detected failures.
-int
-TestResultCollector::testFailuresTotal() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_failures.size();
-}
-
-
-/// Returns a the list failures (random access collection).
-const TestResultCollector::TestFailures &
-TestResultCollector::failures() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_failures;
-}
-
-
-const TestResultCollector::Tests &
-TestResultCollector::tests() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_tests;
-}
-
-void TestResultCollector::addInfo(Test *_pTest, const char* _sInfo)
-{
- ExclusiveZone zone( m_syncObject );
- m_aInfos.push_back(new TestInfo(_pTest, _sInfo));
-}
-
-std::string TestResultCollector::getInfo(Test *_pTest)
-{
- for (TestInfos::const_iterator it = m_aInfos.begin();
- it != m_aInfos.end();
- ++it)
- {
- TestInfo *pInfo = *it;
- Test *pTest = pInfo->getTest();
- if (pTest == _pTest)
- {
- std::string sInfo = pInfo->getString();
- return sInfo;
- }
- }
- return std::string();
-}
-
-
-} // namespace CppUnit
-
diff --git a/testshl2/source/cppunit/result/TestSucessListener.cpp b/testshl2/source/cppunit/result/TestSucessListener.cpp
deleted file mode 100644
index d8f8268f09aa..000000000000
--- a/testshl2/source/cppunit/result/TestSucessListener.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-
-#include <testshl/result/TestSucessListener.h>
-
-
-
-namespace CppUnit
-{
-
-
-TestSucessListener::TestSucessListener( SynchronizationObject *syncObject )
- : SynchronizedObject( syncObject )
- , m_sucess( true )
-{
-}
-
-
-TestSucessListener::~TestSucessListener()
-{
-}
-
-
-void
-TestSucessListener::reset()
-{
- ExclusiveZone zone( m_syncObject );
- m_sucess = true;
-}
-
-
-void
-TestSucessListener::addFailure( const TestFailure & )
-{
- ExclusiveZone zone( m_syncObject );
- m_sucess = false;
-}
-
-
-bool
-TestSucessListener::wasSuccessful() const
-{
- ExclusiveZone zone( m_syncObject );
- return m_sucess;
-}
-
-
-} // namespace CppUnit
-
diff --git a/testshl2/source/cppunit/result/TextTestResult.cpp b/testshl2/source/cppunit/result/TextTestResult.cpp
deleted file mode 100644
index 2ad271ded7de..000000000000
--- a/testshl2/source/cppunit/result/TextTestResult.cpp
+++ /dev/null
@@ -1,194 +0,0 @@
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <cppunit/Exception.h>
-#include <cppunit/NotEqualException.h>
-#include <cppunit/Test.h>
-#include <cppunit/TestFailure.h>
-#include <testshl/result/TextTestResult.h>
-// #include <TextTestResult.h>
-//!io #include <iostream>
-
-namespace CppUnit {
-
-
-TextTestResult::TextTestResult(GetOpt& _aOptions)
- :TestResult(_aOptions),
- m_aResulter(this)
-{
- addListener( &m_aResulter );
-}
-
-
-void
-TextTestResult::addFailure( const TestFailure &failure )
-{
- TestResult::addFailure( failure );
- // std::cerr << ( failure.isError() ? "E" : "F" );
- if (failure.isError())
- fprintf(stderr, "E");
- else
- fprintf(stderr, "F");
-}
-
-
-void
-TextTestResult::startTest( Test *test )
-{
- TestResult::startTest (test);
- // std::cerr << ".";
- fprintf(stderr, ".");
-}
-
-void TextTestResult::endTest( Test *test )
-{
- TestResult::endTest (test);
-}
-
-
-void
-TextTestResult::printFailures( std::ostream &stream )
-{
- TestResultCollector::TestFailures::const_iterator itFailure = m_aResulter.failures().begin();
- int failureNumber = 1;
- while ( itFailure != m_aResulter.failures().end() )
- {
- stream << std::endl;
- TestFailure *pFailure= (*itFailure++)->getTestFailure();
- printFailure( pFailure, failureNumber++, stream );
- }
-}
-
-
-void
-TextTestResult::printFailure( TestFailure *failure,
- int failureNumber,
- std::ostream &stream )
-{
- printFailureListMark( failureNumber, stream );
- stream << ' ';
- printFailureTestName( failure, stream );
- stream << ' ';
- printFailureType( failure, stream );
- stream << ' ';
- printFailureLocation( failure->sourceLine(), stream );
- stream << std::endl;
- printFailureDetail( failure->thrownException(), stream );
- stream << std::endl;
-}
-
-
-void
-TextTestResult::printFailureListMark( int failureNumber,
- std::ostream &stream )
-{
- stream << failureNumber << ")";
-}
-
-
-void
-TextTestResult::printFailureTestName( TestFailure *failure,
- std::ostream &stream )
-{
- Test* pTest = failure->failedTest();
- stream << "test: " << pTest->getName();
-}
-
-
-void
-TextTestResult::printFailureType( TestFailure *failure,
- std::ostream &stream )
-{
- stream << "("
- << (failure->isError() ? "E" : "F")
- << ")";
-}
-
-
-void
-TextTestResult::printFailureLocation( SourceLine sourceLine,
- std::ostream &stream )
-{
- if ( !sourceLine.isValid() )
- return;
-
- stream << "line: " << sourceLine.lineNumber()
- << ' ' << sourceLine.fileName();
-}
-
-
-void
-TextTestResult::printFailureDetail( Exception *thrownException,
- std::ostream &stream )
-{
- if ( thrownException->isInstanceOf( NotEqualException::type() ) )
- {
- NotEqualException *e = (NotEqualException*)thrownException;
- stream << "expected: " << e->expectedValue() << std::endl
- << "but was: " << e->actualValue();
- if ( !e->additionalMessage().empty() )
- {
- stream << std::endl;
- stream << "additional message:" << std::endl
- << e->additionalMessage();
- }
- }
- else
- {
- stream << " \"" << thrownException->what() << "\"";
- }
-}
-
-
-void
-TextTestResult::print( std::ostream& stream )
-{
- printHeader( stream );
- stream << std::endl;
- printFailures( stream );
-}
-
-
-void
-TextTestResult::printHeader( std::ostream &stream )
-{
- if (m_aResulter.wasSuccessful ())
- stream << std::endl << "OK (" << m_aResulter.runTests () << " tests)"
- << std::endl;
- else
- {
- stream << std::endl;
- printFailureWarning( stream );
- printStatistics( stream );
- }
-}
-
-
-void
-TextTestResult::printFailureWarning( std::ostream &stream )
-{
- stream << "!!!FAILURES!!!" << std::endl;
-}
-
-
-void
-TextTestResult::printStatistics( std::ostream &stream )
-{
- stream << "Test Results:" << std::endl;
-
- stream << "Run: " << m_aResulter.runTests()
- << " Failures: " << m_aResulter.testFailures()
- << " Errors: " << m_aResulter.testErrors()
- << std::endl;
-}
-
-
-std::ostream &
-operator <<( std::ostream &stream,
- TextTestResult &result )
-{
- result.print (stream); return stream;
-}
-
-
-} // namespace CppUnit
diff --git a/testshl2/source/cppunit/result/emacsTestResult.cxx b/testshl2/source/cppunit/result/emacsTestResult.cxx
deleted file mode 100644
index 4a4d57b6cee6..000000000000
--- a/testshl2/source/cppunit/result/emacsTestResult.cxx
+++ /dev/null
@@ -1,190 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-
-#include <map>
-#include <cppunit/Exception.h>
-#include <cppunit/NotEqualException.h>
-#include <cppunit/Test.h>
-#include <cppunit/TestFailure.h>
-#include <testshl/result/emacsTestResult.hxx>
-// #include <TextTestResult.h>
-//!io #include <iostream>
-#include <string>
-
-#include <rtl/string.hxx>
-#include "testshl/result/outputter.hxx"
-
-namespace CppUnit {
-
- emacsTestResult::emacsTestResult(GetOpt & _aOptions)
- :TestResult(_aOptions),
- m_aOptions(_aOptions),
- m_aResulter(this)
- {
- addListener( &m_aResulter );
- }
-
- //# struct ltstr
- //# {
- //# bool operator()(const CppUnit::Test* p1, const CppUnit::Test* p2) const
- //# {
- //# return p1 < p2;
- //# }
- //# };
- //# typedef std::map<CppUnit::Test*, bool, ltstr> TestPtrList;
-
- void
- emacsTestResult::print( Outputter& stream )
- {
- printHeader( stream );
- // stream << std::endl;
- // printFailures( stream );
-
- // TestPtrList aFailedTests;
-
- for (TestResultCollector::TestFailures::const_iterator it2 = m_aResulter.failures().begin();
- it2 != m_aResulter.failures().end();
- ++it2)
- {
- TestFailureEnvelope *pEnvelop = *it2;
- TestFailure *pFailure = pEnvelop->getTestFailure();
- std::string sNodeName = pEnvelop->getString();
-
- // aFailedTests[ pFailure->failedTest() ] = true;
-
- printFailureLine(stream, pFailure, sNodeName);
- }
-
- // only errors are from interest here
- //# for (TestResultCollector::Tests::const_iterator it = m_aResulter.tests().begin();
- //# it != m_aResulter.tests().end();
- //# ++it)
- //# {
- //# TestEnvelope *pEnvelop = *it;
- //# Test* pTest = pEnvelop->getTest();
- //# std::string sNodeName = pEnvelop->getString();
- //#
- //# if (aFailedTests.find(pTest) == aFailedTests.end())
- //# {
- //# std::string sInfo = m_aResulter.getInfo(pTest);
- //# printTestLine(stream, pTest, sNodeName, sInfo);
- //# }
- //# }
- stream << "Test #PASSED#" << Outputter::endl();
- }
-
-
- void
- emacsTestResult::printHeader( Outputter &stream )
- {
- std::string sDate(m_aOptionHelper.createDateTag());
- stream << sDate << Outputter::endl();
- }
-
- void
- emacsTestResult::printFailureLine( Outputter &stream, TestFailure *_pFailure, std::string const& _sNodeName)
- {
- std::string aName;
- aName += _sNodeName;
- aName += ".";
- aName += _pFailure->failedTestName();
-
- SourceLine aLine = _pFailure->sourceLine();
- sal_Int32 nLine = -1;
- std::string sFilename;
- if (aLine.isValid())
- {
- nLine = aLine.lineNumber();
- sFilename = aLine.fileName();
- }
-
- Exception *pExp = _pFailure->thrownException();
- std::string sWhat;
- if (pExp)
- {
- sWhat = pExp->what();
- }
-
- stream << sFilename;
- stream << ":";
- stream << nLine;
- stream << ":";
-
- stream << aName;
- stream << ";#FAILED#";
- // ErrorType::num eErr = _pFailure->getErrorType();
- //# if (isErr)
- //# stream << "FAILED#;";
- //# else
- //# stream << "ERROR#;";
-
- stream << sWhat;
- stream << Outputter::endl();
- }
-
- //# void
- //# emacsTestResult::printTestLine( Outputter &stream, Test* _pTest, std::string const& _sNodeName, std::string const& _sInfo)
- //# {
- //# std::string aName;
- //# aName += _sNodeName;
- //# aName += ".";
- //# aName += _pTest->getName();
- //#
- //# stream << aName;
- //# stream << ";";
- //# stream << _sInfo << "#";
- //# stream << "OK#";
- //# stream << std::endl;
- //# }
-
-
-//# void
-//# emacsTestResult::printStatistics( Outputter &stream )
-//# {
-//# stream << "Test Results:" << std::endl;
-//#
-//# stream << "Run: " << runTests()
-//# << " Failures: " << testFailures()
-//# << " Errors: " << testErrors()
-//# << std::endl;
-//# }
-
-
- Outputter &
- operator <<( Outputter &stream,
- emacsTestResult &result )
- {
- result.print (stream); return stream;
- }
-
-
-} // namespace CppUnit
diff --git a/testshl2/source/cppunit/result/log.cxx b/testshl2/source/cppunit/result/log.cxx
deleted file mode 100644
index 3279d1b2091e..000000000000
--- a/testshl2/source/cppunit/result/log.cxx
+++ /dev/null
@@ -1,122 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include "testshl/log.hxx"
-
-// #include <hash_map>
-// #include <list>
-// #include <set>
-
-using namespace std;
-
-::osl::FileBase::RC Log::open( sal_Bool append ) {
-
- ::osl::FileBase::RC ret;
-
- if ( ! append ) {
- ret = ::osl::File::remove( m_logurl );
- }
-
- if( m_logfile->open( OpenFlag_Write ) == ::osl::FileBase::E_NOENT ) {
- ret = m_logfile->open( OpenFlag_Write | OpenFlag_Create );
- }
- else {
- ret = m_logfile->setPos( Pos_End, 0 );
- }
- return ret;
-}
-
-::osl::FileBase::RC Log::write( const sal_Char* buf, sal_Bool v ) {
- sal_uInt64 uBytes=0;
- sal_uInt32 len = 0;
- const sal_Char* ptr = buf;
-
- if( ptr ) {
- while( *ptr++ ) len++;
- }
-
- if ( v ) {
- // cout << buf << flush;
- printf("%s", buf);
- }
- return m_logfile->write( buf, len , uBytes );
-}
-
-::osl::FileBase::RC Log::write( const rtl::OString& buf, sal_Bool v ) {
- sal_uInt64 uBytes=0;
- if ( v ) {
- // cout << buf.getStr() << flush;
- printf("%s", buf.getStr());
- }
- return m_logfile->write( buf.getStr(), buf.getLength(), uBytes );
-}
-/*
-// LLA: due to a problem with sal/OUStingBuffer getLength() which isn't const, this
-// is so not compilable.
-::osl::FileBase::RC Log::write( rtl::OStringBuffer const& buf, sal_Bool v ) {
- sal_uInt64 uBytes=0;
- if ( v ) {
- cout << buf.getStr() << flush;
- }
- return m_logfile->write( buf.getStr(), buf.getLength(), uBytes );
-}
-*/
-::osl::FileBase::RC Log::write( const rtl::OUString& buf,
- rtl_TextEncoding tenc, sal_Bool v ) {
- sal_uInt64 uBytes=0;
- if ( ! tenc ) {
- tenc = RTL_TEXTENCODING_ASCII_US;
- }
- rtl::OStringBuffer osbuf(
- rtl::OUStringToOString( buf, tenc ).getStr() );
-
- if ( v ) {
- // cout << osbuf.getStr() << flush;
- printf("%s", osbuf.getStr());
- }
- return m_logfile->write( osbuf.getStr(), osbuf.getLength(), uBytes );
-}
-
-Log &operator <<( Log &_aLog, const sal_Char * _sValue )
-{
- _aLog.write(_sValue); return _aLog;
-}
-Log &operator <<( Log &_aLog, rtl::OString const& _sValue )
-{
- _aLog.write(_sValue); return _aLog;
-}
-Log &operator <<( Log &_aLog, rtl::OUString const& _sValue )
-{
- _aLog.write(_sValue); return _aLog;
-}
-//! Log &operator <<( Log &_aLog, rtl::OStringBuffer const& _sValue )
-//! {
-//! _aLog.write(_sValue); return _aLog;
-//! }
diff --git a/testshl2/source/cppunit/result/makefile.mk b/testshl2/source/cppunit/result/makefile.mk
deleted file mode 100644
index 59ff333726db..000000000000
--- a/testshl2/source/cppunit/result/makefile.mk
+++ /dev/null
@@ -1,79 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=testshl2
-TARGET=c5t_testresult
-LIBTARGET=NO
-ENABLE_EXCEPTIONS=TRUE
-# ENABLE_RTTI=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-
-# CXXFILES = \
-# querytemplate.cxx \
-# stringhelper.cxx
-
-# ENVCFLAGSCXX+=-DCPPUNIT_BUILD_DLL
-SLOFILES = \
- $(SLO)$/SynchronizedObject.obj \
- $(SLO)$/TestResult.obj \
- $(SLO)$/TestResultCollector.obj \
- $(SLO)$/TestSucessListener.obj \
- $(SLO)$/emacsTestResult.obj \
- $(SLO)$/log.obj \
- $(SLO)$/optionhelper.obj \
- $(SLO)$/outputter.obj \
- $(SLO)$/signal.obj \
- $(SLO)$/testshlTestResult.obj \
- $(SLO)$/treswrapper.obj
-
-# currently unused
-# $(SLO)$/TextTestResult.obj
-
-LIB1TARGET= $(LB)$/$(TARGET).lib
-LIB1OBJFILES= $(SLOFILES)
-
-.IF "$(GUI)"=="WNT"
-.IF "$(COM)"=="GCC"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-.ENDIF
-
-.IF "$(GUI)" == "UNX"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/testshl2/source/cppunit/result/optionhelper.cxx b/testshl2/source/cppunit/result/optionhelper.cxx
deleted file mode 100644
index 90096c8957e7..000000000000
--- a/testshl2/source/cppunit/result/optionhelper.cxx
+++ /dev/null
@@ -1,314 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include "testshl/result/optionhelper.hxx"
-// #include <sstream>
-// #include <string>
-#include <osl/time.h>
-#include "testshl/cmdlinebits.hxx"
-
-// -----------------------------------------------------------------------------
-
-namespace
-{
- void split( const rtl::OString& opt,
- const rtl::OString& _sSeparator,
- OStringList& optLine )
- {
- optLine.clear();
- // const sal_Int32 cSetLen = cSet.getLength();
- sal_Int32 index = 0;
- sal_Int32 oldIndex = 0;
-
- // sal_Int32 i;
- // sal_Int32 j = 0;
- while ( opt.getLength() > 0)
- {
- // for ( i = 0; i < cSetLen; i++ )
- // {
- index = opt.indexOf( _sSeparator, oldIndex);
- if( index != -1 )
- {
- optLine.push_back( opt.copy( oldIndex, index - oldIndex ) );
- oldIndex = index + _sSeparator.getLength();
- }
- // }
- else // if (index == -1)
- {
- optLine.push_back( opt.copy( oldIndex ) );
- break;
- }
- }
- } ///< split
-
- bool match(OStringList const& _aFilter, OStringList const& _aName)
- {
- OStringList::const_iterator aFilterIter = _aFilter.begin();
- OStringList::const_iterator aValueIter = _aName.begin();
-
- bool bMatch = false;
-
- while (aFilterIter != _aFilter.end() && aValueIter != _aName.end())
- {
- rtl::OString sFilter = *aFilterIter;
- rtl::OString sName = *aValueIter;
-
- if (sFilter == sName)
- {
- bMatch = true;
- ++aFilterIter;
- ++aValueIter;
- }
- else if (sFilter == "*")
- {
- bMatch = true;
- break;
- }
- else
- {
- // Filter does not match
- bMatch = false;
- break;
- }
- }
- return bMatch;
- }
-}
-
-/* static */
-std::string OptionHelper::integerToAscii(sal_Int32 nValue)
-{
- sal_Char cBuf[30];
- sal_Char *pBuf = cBuf;
- sprintf(pBuf, "%d", static_cast<int>(nValue));
-//# std::ostringstream sBuf;
-//# sBuf << nValue;
-// rtl::OString sStr;
-// sStr = rtl::OString::valueOf(nValue);
- return std::string(pBuf);
-}
-
-/* static */
-// if a given String is less then 2 char, add a "0" in front.
-std::string OptionHelper::twoDigits(std::string const& _sValue)
-{
- std::string sBack;
- if (_sValue.length() == 0)
- {
- sBack = "00";
- }
- else if (_sValue.length() == 1)
- {
- sBack = "0";
- sBack += _sValue;
- }
- else
- {
- sBack = _sValue;
- }
- return sBack;
-}
-
-
-std::string OptionHelper::createDateTag(std::string const& _sProjectId, std::string const& _sBuildId)
-{
- TimeValue tmv_system;
- TimeValue tmv_local;
- oslDateTime dt;
- osl_getSystemTime( &tmv_system );
- osl_getLocalTimeFromSystemTime(&tmv_system, &tmv_local);
- osl_getDateTimeFromTimeValue( &tmv_local, &dt );
-
- sal_Int32 nYear = dt.Year;
- sal_Int32 nMonth = dt.Month;
- sal_Int32 nDay = dt.Day;
-
- std::string sDate;
- sDate = "# Current Time: ";
- sDate += std::string(twoDigits(integerToAscii(dt.Hours)));
- sDate += ":";
- sDate += std::string(twoDigits(integerToAscii(dt.Minutes)));
- sDate += ":";
- sDate += std::string(twoDigits(integerToAscii(dt.Seconds)));
- sDate += "\n";
-
- sDate += "[";
-
- // sDate += rtl::OString::valueOf(nYear);
- sDate.append(integerToAscii(nYear));
- sDate += ".";
- if (nMonth < 10)
- sDate += "0";
- // sDate += rtl::OString::valueOf(nMonth);
- sDate.append(integerToAscii(nMonth));
- sDate += ".";
- if (nDay < 10)
- sDate += "0";
- // sDate += rtl::OString::valueOf(nDay);
- sDate += std::string(integerToAscii(nDay));
- sDate += "/";
- sDate += _sProjectId;
- sDate += "/";
- sDate += _sBuildId;
- sDate += "]";
-
- return sDate;
-}
-
-//# rtl::OString createDateTag()
-//# {
-//# TimeValue tmv;
-//# oslDateTime dt;
-//# osl_getSystemTime( &tmv );
-//# osl_getDateTimeFromTimeValue( &tmv, &dt );
-//#
-//# sal_Int32 nYear = dt.Year;
-//# sal_Int32 nMonth = dt.Month;
-//# sal_Int32 nDay = dt.Day;
-//#
-//# rtl::OString sDate("[");
-//# sDate += rtl::OString::valueOf(nYear);
-//# sDate += ".";
-//# if (nMonth < 10)
-//# sDate += "0";
-//# sDate += rtl::OString::valueOf(nMonth);
-//# sDate += ".";
-//# if (nDay < 10)
-//# sDate += "0";
-//# sDate += rtl::OString::valueOf(nDay);
-//# sDate += "//]";
-//#
-//# return sDate;
-//# }
-
-std::string OptionHelper::createDateTag()
-{
- return createDateTag(m_sProjectId, m_sBuildId);
-}
-
-bool OptionHelper::showErrors()
-{
- bool bRetValue = true; // default, show all
- if (m_aOption.hasOpt("-noerrors"))
- {
- bRetValue = false;
- }
- return bRetValue;
-}
-
-bool OptionHelper::showTests()
-{
- bool bRetValue = true; // default, show all
- if (m_aOption.hasOpt("-onlyerrors"))
- {
- bRetValue = false;
- }
- return bRetValue;
-}
-
-// Check which parameter is given for handle the jobs.
-// If no parameter is given, all jobs (tests) will run through
-void OptionHelper::handleJobs()
-{
- // load job file, the file contains the functions which we only want to test.
- if (m_aOption.hasOpt("-jobexclude"))
- {
- rtl::OString sJobFile = m_aOption.getOpt("-jobexclude");
- m_aJobExcludeList.readfile(sJobFile.getStr(), JOB_EXCLUDE_LIST);
- }
-
- if (m_aOption.hasOpt("-jobonly"))
- {
- rtl::OString sJobFile = m_aOption.getOpt("-jobonly");
- m_aJobOnlyList.readfile(sJobFile.getStr(), JOB_ONLY_LIST);
- }
-
- //
- if (m_aOption.hasOpt("-jobfilter"))
- {
- rtl::OString sJobFilter = m_aOption.getOpt("-jobfilter");
- split(sJobFilter, ".", m_aJobFilter);
- }
-}
-
-// -----------------------------------------------------------------------------
-// Here will be decide, if a job/test will execute or not.
-// therefore exist some lists, in which stay all jobs (positive list) or a list (negative list) which jobs should not execute
-// or if only specific jobs should execute by a given filter
-
-bool OptionHelper::isAllowedToExecute(std::string const& _sNodeName, std::string const& _sName)
-{
- std::string sJobName = _sNodeName + "." + _sName;
- // t_print(T_VERBOSE, "Jobname %s\n", sJobName.c_str());
- if (isOnlyShowJobs()) // true, if parameter -onlyshowjob
- {
- m_aJobOnlyList.setJobListEntry(sJobName, JOB_ACCESS);
- return false;
- }
-
- if (m_aJobOnlyList.size()) // >0 if parameter -jobonly
- {
- if (m_aJobOnlyList.getJobListEntry(sJobName) != JOB_NOT_FOUND)
- {
- // job entry found, mark as accessed
- m_aJobOnlyList.setJobListEntry(sJobName, JOB_ACCESS);
- return true;
- }
- return false;
- }
- else if (m_aJobFilter.size() > 0) // >0 if parameter -jobfilter
- {
- OStringList aSplitName;
- split(sJobName.c_str(), ".", aSplitName);
- if (! match(m_aJobFilter, aSplitName))
- {
- t_print(T_VERBOSE, "job: '%s' filtered by [-jobfilter]\n", sJobName.c_str());
- return false;
- }
- }
- else if (m_aJobExcludeList.size() > 0) // >0 if parameter -jobexclude
- {
- if (m_aJobExcludeList.getJobListEntry(sJobName) != JOB_NOT_FOUND)
- {
- // job entry found, this job should not executed, so return false
- t_print(T_VERBOSE, "job: '%s' filtered by [-jobexclude]\n", sJobName.c_str());
- return false;
- }
- // m_aJobOnlyList.setJobListEntry(sJobName, JOB_ACCESS);
- return true;
- }
- else
- {
- //! not handled yet
- }
-
- return true;
-}
-
diff --git a/testshl2/source/cppunit/result/outputter.cxx b/testshl2/source/cppunit/result/outputter.cxx
deleted file mode 100644
index 182b9db683e9..000000000000
--- a/testshl2/source/cppunit/result/outputter.cxx
+++ /dev/null
@@ -1,103 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-//
-#include <string>
-#include <sal/types.h>
-#include "testshl/result/outputter.hxx"
-
-// -----------------------------------------------------------------------------
-
-Outputter::~Outputter()
-{
- // delete m_pLog;
-}
-
-void Outputter::writeToAll(const sal_Char* _sCharStr)
-{
- // std::cout << _sCharStr;
- if (m_pStream)
- {
- *m_pStream << _sCharStr;
- }
- if (m_pLog.get())
- {
- m_pLog->write(_sCharStr);
- }
-}
-
-void Outputter::write(const sal_Char* _sCharStr)
-{
- writeToAll(_sCharStr);
-}
-
-void Outputter::write(std::string const& _sStr)
-{
- writeToAll(_sStr.c_str());
-}
-
-void Outputter::write(sal_Int32 _nValue)
-{
- sal_Char cBuf[20];
- sal_Char* pBuf = cBuf;
- sprintf(pBuf, "%d", SAL_STATIC_CAST(int, _nValue));
- writeToAll(pBuf);
-}
-
-// -----------------------------------------------------------------------------
-
-Outputter& operator <<( Outputter &_aStreamWrapper, const sal_Char* _sValue)
-{
- _aStreamWrapper.write(_sValue);
- return _aStreamWrapper;
-}
-
-Outputter& operator <<( Outputter &_aStreamWrapper, std::string const& _sValue)
-{
- _aStreamWrapper.write(_sValue);
- return _aStreamWrapper;
-}
-
-Outputter& operator <<( Outputter &_aStreamWrapper, sal_Int32 _nValue)
-{
- _aStreamWrapper.write(_nValue);
- return _aStreamWrapper;
-}
-
-//# Outputter& operator <<( Outputter &_aStreamWrapper, double )
-//# {
-//# return _aStreamWrapper;
-//# }
-
-Outputter& operator <<( Outputter &_aStreamWrapper, Outputter::endl const&)
-{
- _aStreamWrapper.write("\n");
- return _aStreamWrapper;
-}
diff --git a/testshl2/source/cppunit/result/signal.cxx b/testshl2/source/cppunit/result/signal.cxx
deleted file mode 100644
index 7c96dcfe7589..000000000000
--- a/testshl2/source/cppunit/result/signal.cxx
+++ /dev/null
@@ -1,996 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#if (defined UNX) || (defined OS2)
-#include <signal.h>
-#include <errno.h>
-#endif
-
-#include <fstream>
-#include <vector>
-#include <hash_map>
-
-#include <rtl/tres.h>
-#include <rtl/string.hxx>
-
-#include "testshl/autoregisterhelper.hxx"
-#include "testshl/getopt.hxx"
-#include "signal.hxx"
-#include <cppunit/tagvalues.hxx>
-#include <testshl/taghelper.hxx>
-#include <unistd.h>
-#include "testshl/filehelper.hxx"
-#include <testshl/result/TestResult.h>
-#include "testshl/signaltest.h"
-#include "cppunit/Exception.h"
-
-#ifdef WNT
-#include "testshl/winstuff.hxx"
-#endif
-
-// typedef std::vector<std::string> StringList;
-// StringList sCurrentNodeName;
-CppUnit::TestResult *pTestResult = NULL;
-std::string sSignalFile;
-
-typedef std::hash_map< std::string, int > HashMap;
-HashMap m_aSignalHash;
-bool bSignalsCached = false;
-bool bDoNotTouchSignalFile = false;
-
-// -----------------------------------------------------------------------------
-
-// return 'true' if signalfile doesn't exist.
-// else 'false'
-bool existsSignalFile(std::string const& _sSignalFilename)
-{
- FILE* pFile = fopen(_sSignalFilename.c_str(), "r");
- if (!pFile)
- {
- return false;
- }
- fprintf(stderr, "'%s' exists.\n", _sSignalFilename.c_str());
- fclose(pFile);
- return true;
-}
-
-// -----------------------------------------------------------------------------
-void createEmptySignalFile(std::string const& _sSignalFilename)
-{
- FILE* pFile = fopen(_sSignalFilename.c_str(), "w");
- if (!pFile)
- {
- fprintf(stderr, "error: Could not create signal helper file %s for signal info.\n", _sSignalFilename.c_str());
- }
- else
- {
- fprintf(pFile, "# This is an auto generated helper file for signal handling.\n");
- fprintf(pFile, "# An entry start by '#' is a comment.\n");
- fprintf(pFile, "# All other are test functions which have abort, before this line is removed.\n");
- fprintf(pFile, "# So you have to check this functions by hand.\n");
-
- fclose(pFile);
- }
-}
-
-// -----------------------------------------------------------------------------
-/** get Current PID.
-*/
-inline ::rtl::OUString getCurrentPID( )
-{
- //~ Get current PID and turn it into OUString;
- sal_uInt32 nPID = 0;
-#ifdef WNT
- nPID = WinGetCurrentProcessId();
-#else
- nPID = getpid();
-#endif
- return ( ::rtl::OUString::valueOf( static_cast<long>(nPID ) ) );
-}
-// -----------------------------------------------------------------------------
-static std::string integerToAscii(sal_uInt32 nValue)
-{
- sal_Char cBuf[30];
- sal_Char *pBuf = cBuf;
- sprintf(pBuf, "%d", static_cast<unsigned int>(nValue));
- return std::string(pBuf);
-}
-void my_sleep(int sec);
-
-// -----------------------------------------------------------------------------
-void setSignalFilename(GetOpt & opt)
-{
- if (opt.hasOpt("-dntsf") || opt.hasOpt("-donottouchsignalfile"))
- {
- // special feature, for debugging, so the signal file will not manipulate.
- // but create, if no one exist.
- bDoNotTouchSignalFile = true;
- }
-
- if (opt.hasOpt("-sf") || opt.hasOpt("-signalfile"))
- {
- if (opt.hasOpt("-sf"))
- {
- sSignalFile = opt.getOpt("-sf");
- }
- else if (opt.hasOpt("-signalfile"))
- {
- sSignalFile = opt.getOpt("-signalfile");
- }
- }
- else
- {
- std::string sPath;
- // std::string sPath(FileHelper::getTempPath());
- std::string sFilename("signalfile");
- std::string sFilenameExt(".txt");
- bool bCanQuitLoop = true;
- do
- {
-
-// #ifdef WNT
-// sPath += "\\";
-// #endif
-// #ifdef UNX
-// sPath += "/";
-// #endif
- sPath = sFilename;
- // BUG: i72675
- // add "_12345" where 12345 is the current process ID
-
- TimeValue aTimeValue;
- osl_getSystemTime(&aTimeValue);
-
- sPath += "_";
- sPath += integerToAscii(aTimeValue.Seconds);
- // rtl::OUString suPID = getCurrentPID();
- // rtl::OString sPID = rtl::OUStringToOString(suPID, RTL_TEXTENCODING_ASCII_US);
- // sPath += sPID.getStr();
- sPath += sFilenameExt;
- bCanQuitLoop = true;
- if (existsSignalFile(sPath))
- {
- // there is already a signal file, wait a second, choose an other one.
- my_sleep(1);
- bCanQuitLoop = false;
- }
- }
- while (!(bCanQuitLoop));
-
- sSignalFile = sPath;
- fprintf(stderr, "Use default signal file name '%s'\n", sSignalFile.c_str());
- }
-
- if (opt.hasOpt("-dnrmsf"))
- {
- fprintf(stderr, "'Don't remove signal file' (-dnrmsf) is set.\n");
- }
- else
- {
- if (bDoNotTouchSignalFile == true)
- {
- fprintf(stderr, "warning: 'Don't touch signal file' parameter (-dntsf) is set, will not remove existing signal file.\n");
- }
- else
- {
- // remove signalfile
- createEmptySignalFile(sSignalFile);
- }
- }
-}
-
-// -----------------------------------------------------------------------------
-bool doNotTouchSignalFile() { return bDoNotTouchSignalFile; }
-
-// -----------------------------------------------------------------------------
-std::string buildTestFunctionName(std::string const& _sName)
-{
- std::string sName;
- if (pTestResult)
- {
- sName = pTestResult->getNodeName();
- sName += ".";
- }
-
-/*
- for (StringList::const_iterator it = sCurrentNodeName.begin();
- it != sCurrentNodeName.end();
- ++it)
- {
- sName += *it;
- sName += ".";
- }
-*/
- sName += _sName;
-
- return sName;
-}
-// -----------------------------------------------------------------------------
-// old: void executionPushName(std::string const& _sName)
-// old: {
-// old: sCurrentNodeName.push_back(_sName);
-// old: }
-// old: void executionPopName()
-// old: {
-// old: sCurrentNodeName.pop_back();
-// old: }
-// old:
-
-// -----------------------------------------------------------------------------
-// ------------------------------ Signal Handling ------------------------------
-// -----------------------------------------------------------------------------
-
-// std::string sLastTestFunctionName;
-
-std::string getSignalName(sal_Int32 nSignalNo);
-// -----------------------------------------------------------------------------
-
-std::string getSignalFilename()
-{
- return sSignalFile;
-}
-
-// -----------------------------------------------------------------------------
-// void storeNoSignal(std::string const& _sTestName)
-// {
- // sLastTestFunctionName = buildTestFunctionName(_sTestName);
- // std::ofstream out(getSignalFilename().c_str(), std::ios::out);
- // out << NO_SIGNAL << std::endl; // no signal!
-// }
-
-void markSignalAsAlreadyDone(sal_Int32 _nSignalNo)
-{
- // std::ofstream out(getSignalFilename().c_str(), std::ios::out | std::ios::app);
- FILE *out = fopen(getSignalFilename().c_str(), "a");
- if (out != NULL)
- {
-//# out << "# the previous test function creates signal: "
-//# << getSignalName(_nSignalNo)
-//# << " ("
-//# << _nSignalNo
-//# << ")" << std::endl;
-//# // out << sLastTestFunctionName << std::endl; // SIGNAL!
-
- fprintf(out, "# the previous test function creates signal: %s(%d)\n", getSignalName(_nSignalNo).c_str(), SAL_STATIC_CAST(int, _nSignalNo));
- // fprintf(out, "%s\n", sLastTestFunctionName );
- fclose(out);
- }
- else
- {
- fprintf(stderr, "error: Can't write signal info to file %s \n", getSignalFilename().c_str());
- }
-}
-
-// -----------------------------------------------------------------------------
-
-Signal hasSignaled(std::string const& _sTestName)
-{
- // BACK: true: signal
- // false: nothing
-
- if (bSignalsCached == true)
- {
-
- if (m_aSignalHash.find(buildTestFunctionName(_sTestName)) != m_aSignalHash.end())
- {
- return HAS_SIGNAL;
- }
- return NO_SIGNAL;
- }
-
- std::ifstream in(getSignalFilename().c_str(), std::ios::in);
-
- // std::cout << "Check for signal" << std::endl;
- std::string sLine, sLastLine;
- while (std::getline(in, sLine))
- {
- // std::cout << sTest << std::endl;
- char ch = sLine[0];
- if (isspace(ch) == 0 &&
- sLine.size() > 0)
- {
- if (ch == '#')
- {
- if (sLastLine.size() > 0)
- {
- rtl::OString aStrLine(sLine.c_str());
- sal_Int32 nIdx = aStrLine.indexOf("(") + 1;
- sal_Int32 nIdx2 = aStrLine.indexOf(")");
- sal_Int32 nSignalNo = 0;
- if (nIdx > 0 && nIdx2 > 0)
- {
- rtl::OString sSignalNo = aStrLine.copy(nIdx, nIdx2 - nIdx);
- nSignalNo = sSignalNo.toInt32();
- m_aSignalHash[sLastLine] = nSignalNo;
- }
- sLastLine.clear();
- }
- }
- else
- {
- // if (sTest == buildTestFunctionName(_sTestName))
- m_aSignalHash[sLine] = 1;
- sLastLine = sLine;
- // return HAS_SIGNAL;
- }
- }
- }
-
- bSignalsCached = true;
- return hasSignaled(_sTestName);
- // return NO_SIGNAL;
-}
-
-#ifdef UNX
-
-// -----------------------------------------------------------------------------
-
-void release_signal_Handling();
-
-//# void signalFunction(int value)
-//# {
-//# std::cout << "Signal caught: (" << value << "), please restart." << std::endl;
-//# markSignalAsAlreadyDone();
-//#
-//# release_signal_Handling();
-//# std::cout.flush();
-//# abort();
-//# }
-
-// -----------------------------------------------------------------------------
-extern "C" void SignalHandlerFunction(int _nSignalNo, siginfo_t *, void*)
-{
- // std::cout << "Signal caught: " << getSignalName(_nSignalNo) << " (" << _nSignalNo << "), please restart." << std::endl;
- fprintf(stderr, "Signal caught %s(%d)\n", getSignalName(_nSignalNo).c_str(), _nSignalNo);
- markSignalAsAlreadyDone(_nSignalNo);
-
- release_signal_Handling();
- // std::cout.flush();
- abort();
-}
-
-// -----------------------------------------------------------------------------
-// This is a copy of the osl/signal.c code
-#define ACT_IGNORE 1
-#define ACT_ABORT 2
-#define ACT_EXIT 3
-#define ACT_SYSTEM 4
-#define ACT_HIDE 5
-
-extern "C" {
-static struct SignalAction
-{
- int Signal;
- int Action;
- void (*Handler)(int);
-} Signals[] =
-{
- { SIGHUP, ACT_IGNORE, NULL }, /* hangup */
- { SIGINT, ACT_EXIT, NULL }, /* interrupt (rubout) */
- { SIGQUIT, ACT_ABORT, NULL }, /* quit (ASCII FS) */
- { SIGILL, ACT_SYSTEM, NULL }, /* illegal instruction (not reset when caught) */
-/* changed from ACT_ABOUT to ACT_SYSTEM to try and get collector to run*/
- { SIGTRAP, ACT_ABORT, NULL }, /* trace trap (not reset when caught) */
-#if ( SIGIOT != SIGABRT )
- { SIGIOT, ACT_ABORT, NULL }, /* IOT instruction */
-#endif
-// { SIGABRT, ACT_ABORT, NULL }, /* used by abort, replace SIGIOT in the future */
-#ifdef SIGEMT
- { SIGEMT, ACT_SYSTEM, NULL }, /* EMT instruction */
-/* changed from ACT_ABORT to ACT_SYSTEM to remove handler*/
-/* SIGEMT may also be used by the profiler - so it is probably not a good
- plan to have the new handler use this signal*/
-#endif
- { SIGFPE, ACT_ABORT, NULL }, /* floating point exception */
- { SIGKILL, ACT_SYSTEM, NULL }, /* kill (cannot be caught or ignored) */
- { SIGBUS, ACT_ABORT, NULL }, /* bus error */
- { SIGSEGV, ACT_ABORT, NULL }, /* segmentation violation */
-#ifdef SIGSYS
- { SIGSYS, ACT_ABORT, NULL }, /* bad argument to system call */
-#endif
- { SIGPIPE, ACT_HIDE, NULL }, /* write on a pipe with no one to read it */
- { SIGALRM, ACT_EXIT, NULL }, /* alarm clock */
- { SIGTERM, ACT_EXIT, NULL }, /* software termination signal from kill */
- { SIGUSR1, ACT_SYSTEM, NULL }, /* user defined signal 1 */
- { SIGUSR2, ACT_SYSTEM, NULL }, /* user defined signal 2 */
- { SIGCHLD, ACT_SYSTEM, NULL }, /* child status change */
-#ifdef SIGPWR
- { SIGPWR, ACT_IGNORE, NULL }, /* power-fail restart */
-#endif
- { SIGWINCH, ACT_IGNORE, NULL }, /* window size change */
- { SIGURG, ACT_EXIT, NULL }, /* urgent socket condition */
-#ifdef SIGPOLL
- { SIGPOLL, ACT_EXIT, NULL }, /* pollable event occured */
-#endif
- { SIGSTOP, ACT_SYSTEM, NULL }, /* stop (cannot be caught or ignored) */
- { SIGTSTP, ACT_SYSTEM, NULL }, /* user stop requested from tty */
- { SIGCONT, ACT_SYSTEM, NULL }, /* stopped process has been continued */
- { SIGTTIN, ACT_SYSTEM, NULL }, /* background tty read attempted */
- { SIGTTOU, ACT_SYSTEM, NULL }, /* background tty write attempted */
- { SIGVTALRM, ACT_EXIT, NULL }, /* virtual timer expired */
- { SIGPROF, ACT_SYSTEM, NULL }, /* profiling timer expired */
-/*Change from ACT_EXIT to ACT_SYSTEM for SIGPROF is so that profiling signals do
- not get taken by the new handler - the new handler does not pass on context
- information which causes 'collect' to crash. This is a way of avoiding
- what looks like a bug in the new handler*/
- { SIGXCPU, ACT_ABORT, NULL }, /* exceeded cpu limit */
- { SIGXFSZ, ACT_ABORT, NULL } /* exceeded file size limit */
-};
-}
-
-const int NoSignals = sizeof(Signals) / sizeof(struct SignalAction);
-
-#endif /* UNX */
-
-// -----------------------------------------------------------------------------
-void init_signal_Handling(CppUnit::TestResult *_pResult)
-{
- pTestResult = _pResult;
-#ifdef UNX
-
-// signal(SIGSEGV, signalFunction);
- // signal(SIGSEGV, signalFunction);
- // signal(SIGFPE, signalFunction);
-
-// signal(1, signalFunction);
- // struct sigaction action, oldaction;
- // action.sa_sigaction = signalFunction2;
- // action.sa_flags = SA_ONESHOT /* | SA_SIGINFO */;
-
- struct sigaction act;
- struct sigaction oact;
-
- // act.sa_handler = SignalHandlerFunction;
- act.sa_flags = SA_RESTART;
- // act.sa_flags = SA_ONESHOT /* | SA_SIGINFO */;
- act.sa_sigaction = SignalHandlerFunction;
-
- sigfillset(&(act.sa_mask));
-
- /* Initialize the rest of the signals */
- for (int i = 0; i < NoSignals; i++)
- {
- if (Signals[i].Action != ACT_SYSTEM)
- {
- if (Signals[i].Action == ACT_HIDE)
- {
- struct sigaction ign;
-
- ign.sa_handler = SIG_IGN;
- ign.sa_flags = 0;
- sigemptyset(&ign.sa_mask);
-
- if (sigaction(Signals[i].Signal, &ign, &oact) == 0)
- Signals[i].Handler = oact.sa_handler;
- else
- Signals[i].Handler = SIG_DFL;
- }
- else
- if (sigaction(Signals[i].Signal, &act, &oact) == 0)
- Signals[i].Handler = oact.sa_handler;
- else
- Signals[i].Handler = SIG_DFL;
- }
- }
-#endif
-
- // ------------ signal helper file must exist -----------------
- FILE* pFile = fopen(getSignalFilename().c_str(), "r");
- if (!pFile)
- {
- createEmptySignalFile( getSignalFilename() );
- }
- else
- {
- fclose(pFile);
- }
-}
-
-// -----------------------------------------------------------------------------
-void release_signal_Handling()
-{
- // frees all signals
-#ifdef UNX
- int i;
- struct sigaction act;
-
- act.sa_flags = 0;
- sigemptyset(&(act.sa_mask));
-
- /* Initialize the rest of the signals */
- for (i = NoSignals - 1; i >= 0; i--)
- {
- if (Signals[i].Action != ACT_SYSTEM)
- {
- act.sa_handler = Signals[i].Handler;
-
- sigaction(Signals[i].Signal, &act, NULL);
- }
- }
-#endif
-}
-
-// -----------------------------------------------------------------------------
-Signal signalCheck(CppUnit::TestResult* _pResult, std::string const& _sTestName)
-{
- // BACK: HAS_SIGNAL: the test has already done and signaled
- if (hasSignaled(_sTestName) == HAS_SIGNAL)
- {
- // std::cout << "The Test '" << buildTestFunctionName(_sTestName) << "' is marked as signaled." << std::endl;
- std::string sTestFunctionName = buildTestFunctionName(_sTestName);
- fprintf(stderr, "The Test '%s' is marked as signaled.\n", sTestFunctionName.c_str());
- if (_pResult)
- {
- CppUnit::SignalTest *pTest = new CppUnit::SignalTest(_sTestName);
-
- std::string sErrorText = "Function is marked as signaled: ";
- sal_Int32 nSignalNo = m_aSignalHash[sTestFunctionName];
- sErrorText += getSignalName(nSignalNo);
- sErrorText += " (";
- sErrorText += OptionHelper::integerToAscii(nSignalNo);
- sErrorText += ")";
-
- _pResult->addError(pTest, new CppUnit::SignalException(sErrorText), ErrorType::ET_SIGNAL);
- }
- return HAS_SIGNAL;
- }
-
- // storeNoSignal(_sTestName);
- return NO_SIGNAL;
-}
-
-// -----------------------------------------------------------------------------
-bool copyFile(std::string const& _sFrom, std::string const& _sTo)
-{
- bool bRetValue = false;
- const int MAXBUFSIZE = 1024;
- char buff[MAXBUFSIZE];
- FILE *in = fopen(_sFrom.c_str(), "r");
- if (in == NULL)
- {
- fprintf(stderr, "error: Can't open file %s for read to copy.\n", _sFrom.c_str());
- bRetValue = false;
- }
- else
- {
- FILE *out = fopen(_sTo.c_str(), "w");
- if (out == NULL)
- {
- fclose(in);
- fprintf(stderr, "error: Can't open file %s for write to copy.\n", _sTo.c_str());
- bRetValue = false;
- }
- else
- {
- int nRealGot = 0;
- while(!feof(in))
- {
- nRealGot = fread(buff, sizeof(char), MAXBUFSIZE, in);
- if (nRealGot > 0)
- {
- fwrite(buff, sizeof(char), nRealGot, out);
- }
- }
- bRetValue = true;
- fclose(out);
- fclose(in);
- }
- }
- return bRetValue;
-}
-
-// -----------------------------------------------------------------------------
-void signalStartTest(std::string const& _sName)
-{
- if (doNotTouchSignalFile()) return;
-
- // fprintf(stderr, "### signalStartTest!\n");
- // due to the fact, that functions are vicious, we write the name first.
- // if it isn't vivious, than we removed it.
- std::string sNewName = getSignalFilename();
- sNewName += ".bak";
- if (copyFile(getSignalFilename(), sNewName))
- {
- // std::ofstream out(getSignalFilename().c_str(), std::ios::out | std::ios::app);
- FILE *out = fopen(getSignalFilename().c_str(), "a");
- if (out != NULL)
- {
- // out << buildTestFunctionName(_sName) << std::endl;
- fprintf(out, "%s\n", buildTestFunctionName(_sName).c_str());
- fclose(out);
- }
- else
- {
- fprintf(stderr, "error: Can't open file %s for append.\n", getSignalFilename().c_str());
- }
- }
- else
- {
- fprintf(stderr, "error: Can't copy signal helper from file %s to file %s, %d\n", getSignalFilename().c_str(), sNewName.c_str(), errno);
- }
-}
-
-// -----------------------------------------------------------------------------
-void signalEndTest()
-{
- if (doNotTouchSignalFile()) return;
-
- // fprintf(stderr, "### signalEndTest!\n");
- if (0 != remove(getSignalFilename().c_str()))
- {
- fprintf(stderr, "error: Can't delete file %s\n", getSignalFilename().c_str());
- }
- else
- {
- std::string sNewName = getSignalFilename();
- sNewName += ".bak";
- if (0 != rename(sNewName.c_str(), getSignalFilename().c_str()))
- {
- fprintf(stderr, "error: Can't rename file %s to file %s errno: %d\n", sNewName.c_str(), getSignalFilename().c_str(), errno);
- }
- }
-}
-
-// -----------------------------------------------------------------------------
-void removeSignalFile(GetOpt & opt)
-{
- // fprintf(stderr, "### remove signal file: '%s'\n", sSignalFile.c_str());
- if (opt.hasOpt("-dnrmsf"))
- {
- return;
- }
- if (bDoNotTouchSignalFile == true)
- {
- return;
- }
- remove(getSignalFilename().c_str());
-}
-
-// -----------------------------------------------------------------------------
-
-sal_Int32 SignalHandlerA( TagHelper const& _aTagItems )
-{
- sal_Int32 nRetValue = 0;
- TagData nTagType = _aTagItems.GetTagData(TAG_TYPE, 0);
-// LLA: unused
-// hTestResult hResult = (hTestResult) _aTagItems.GetTagData(TAG_RESULT_PTR, 0 /* NULL */ );
-// CppUnit::TestResult* pResult = (CppUnit::TestResult*)hResult;
-
- try
- {
- switch(nTagType)
- {
- // old: case SIGNAL_PUSH_NAME:
- // old: {
- // old: const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- // old: if (sName != NULL)
- // old: signalPushName(sName);
- // old: break;
- // old: }
- // old:
- // old: case SIGNAL_POP_NAME:
- // old: signalPopName();
- // old: break;
-
- // old: case SIGNAL_CHECK:
- // old: {
- // old: const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- // old: if (sName != NULL)
- // old: {
- // old: nRetValue = signalCheck(sName);
- // old: }
- // old: break;
- // old: }
-
- // old: case INIT_SIGNAL_HANDLING:
- // old: init_signal_Handling();
- // old: break;
- // old:
- // old: case RELEASE_SIGNAL_HANDLING:
- // old: release_signal_Handling();
- // old: break;
-
- case SIGNAL_START_TEST:
- {
- // fprintf(stderr, "### SIGNAL_START_TEST!\n");
- const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- if (sName != NULL)
- {
- signalStartTest(sName);
- }
- break;
- }
-
- case SIGNAL_END_TEST:
- {
- // fprintf(stderr, "### SIGNAL_END_TEST!\n");
- const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- if (sName != NULL)
- {
- signalEndTest();
- }
- break;
- }
-
- default:
- fprintf(stderr, "error: SignalHandlerA: Can't handle the tag type %d\n", SAL_STATIC_CAST(int, nTagType));
- fflush(stderr);
- // throw std::exception(/*std::string("Unknown TYPE_TAG Exception.")*/);
- }
- }
- catch (std::exception &e)
- {
- fprintf(stderr, "error: SignalHandlerA: Exception caught: %s\n", e.what());
- fflush(stderr);
- // throw e;
- }
-
- return nRetValue;
-}
-// -----------------------------------------------------------------------------
-// This a little bit more abstract code, could be easier to modify or expand.
-
-sal_Int32 CheckExecution(CppUnit::TestResult* _pResult, std::string const& _sName)
-{
- // more checks in the corresponding job lists
- if (_pResult)
- {
- if (! _pResult->isAllowedToExecute(_sName))
- {
- return DO_NOT_EXECUTE;
- }
- }
-
- // Check if the given test should be executed.
- if (signalCheck(_pResult, _sName) == HAS_SIGNAL)
- {
- return DO_NOT_EXECUTE;
- }
-
- return GO_EXECUTE;
-}
-
-// -----------------------------------------------------------------------------
-sal_Int32 ExecutionA( TagHelper const& _aTagItems )
-{
- sal_Int32 nRetValue = 0;
- TagData nTagType = _aTagItems.GetTagData(TAG_TYPE, 0);
- hTestResult hResult = (hTestResult) _aTagItems.GetTagData(TAG_RESULT_PTR, 0 /* NULL */ );
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)hResult;
-
- try
- {
- switch(nTagType)
- {
- case EXECUTION_CHECK:
- {
- const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- if (sName)
- {
- nRetValue = CheckExecution(pResult, sName);
- if (nRetValue == GO_EXECUTE)
- {
- if (pResult && pResult->isOptionWhereAmI())
- {
- printf("# This is: %s\n", buildTestFunctionName(sName).c_str());
- }
- }
- }
-
- break;
- }
-
- // old: case EXECUTION_PUSH_NAME:
- // old: {
- // old: const char* sName = (const char*) _aTagItems.GetTagData(TAG_NODENAME);
- // old: if (sName != NULL)
- // old: executionPushName(sName);
- // old: break;
- // old: }
- // old:
- // old: case EXECUTION_POP_NAME:
- // old: executionPopName();
- // old: break;
-
- case INIT_TEST:
- init_signal_Handling(pResult);
- break;
-
- case RELEASE_TEST:
- release_signal_Handling();
- break;
-
- default:
- fprintf(stderr, "ExceptionA: Can't handle the tag type %d\n", SAL_STATIC_CAST(int, nTagType));
- break;
- }
- }
- catch (std::exception &e)
- {
- fprintf(stderr, "ExecutionA: exception caught: %s\n", e.what());
- fflush(stderr);
- // throw e;
- }
- return nRetValue;
-}
-
-// -----------------------------------------------------------------------------
-std::string getSignalName(sal_Int32 nSignalNo)
-{
- std::string sValue;
-#ifdef UNX
- switch(nSignalNo)
- {
- case SIGHUP:
- sValue = "SIGHUP";
- break;
-
- case SIGINT:
- sValue = "SIGINT";
- break;
-
- case SIGQUIT:
- sValue = "SIGQUIT";
- break;
-
- case SIGILL:
- sValue = "SIGILL";
- break;
-
- case SIGTRAP:
- sValue = "SIGTRAP";
- break;
-
-#if ( SIGIOT != SIGABRT )
- case SIGIOT:
- sValue = "SIGIOT";
- break;
-#endif
-// case SIGABRT:
-#ifdef SIGEMT
- case SIGEMT:
- sValue = "SIGEMT";
- break;
-#endif
- case SIGFPE:
- sValue = "SIGFPE";
- break;
-
- case SIGKILL:
- sValue = "SIGKILL";
- break;
-
- case SIGBUS:
- sValue = "SIGBUS";
- break;
-
- case SIGSEGV:
- sValue = "SIGSEGV";
- break;
-
-#ifdef SIGSYS
- case SIGSYS:
- sValue = "SIGSYS";
- break;
-#endif
- case SIGPIPE:
- sValue = "SIGPIPE";
- break;
-
- case SIGALRM:
- sValue = "SIGALRM";
- break;
-
- case SIGTERM:
- sValue = "SIGTERM";
- break;
-
- case SIGUSR1:
- sValue = "SIGUSR1";
- break;
-
- case SIGUSR2:
- sValue = "SIGUSR2";
- break;
-
- case SIGCHLD:
- sValue = "SIGCHLD";
- break;
-
-#ifdef SIGPWR
- case SIGPWR:
- sValue = "SIGPWR";
- break;
-#endif
- case SIGWINCH:
- sValue = "SIGWINCH";
- break;
-
- case SIGURG:
- sValue = "SIGURG";
- break;
-
-#ifdef SIGPOLL
- case SIGPOLL:
- sValue = "SIGPOLL";
- break;
-#endif
- case SIGSTOP:
- sValue = "SIGSTOP";
- break;
-
- case SIGTSTP:
- sValue = "SIGTSTP";
- break;
-
- case SIGCONT:
- sValue = "SIGCONT";
- break;
-
- case SIGTTIN:
- sValue = "SIGTTIN";
- break;
-
- case SIGTTOU:
- sValue = "SIGTTOU";
- break;
-
- case SIGVTALRM:
- sValue = "SIGVTALRM";
- break;
-
- case SIGPROF:
- sValue = "SIGPROF";
- break;
-
- case SIGXCPU:
- sValue = "SIGXCPU";
- break;
-
- case SIGXFSZ:
- sValue = "SIGXFSZ";
- break;
-
- default:
- sValue = "Unhandled Signal.";
- }
-#else
- (void) nSignalNo; // unused
-#endif
- return sValue;
-}
-
-// The following sets variables for GNU EMACS
-// Local Variables:
-// tab-width:4
-// End:
diff --git a/testshl2/source/cppunit/result/signal.hxx b/testshl2/source/cppunit/result/signal.hxx
deleted file mode 100644
index e3f448535014..000000000000
--- a/testshl2/source/cppunit/result/signal.hxx
+++ /dev/null
@@ -1,39 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef SIGNAL_HXX
-#define SIGNAL_HXX
-
-#include <sal/types.h>
-
-#define HAS_SIGNAL 1
-#define NO_SIGNAL 0
-
-typedef sal_Int32 Signal;
-
-#endif
-
diff --git a/testshl2/source/cppunit/result/testshlTestResult.cxx b/testshl2/source/cppunit/result/testshlTestResult.cxx
deleted file mode 100644
index f80b999416ed..000000000000
--- a/testshl2/source/cppunit/result/testshlTestResult.cxx
+++ /dev/null
@@ -1,425 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-
-#include <map>
-#include <cppunit/Exception.h>
-#include <cppunit/NotEqualException.h>
-#include <cppunit/Test.h>
-#include <cppunit/TestFailure.h>
-#include <testshl/result/testshlTestResult.h>
-// #include <TextTestResult.h>
-//!io #include <iostream>
-#include <string>
-
-#include <rtl/string.hxx>
-#include "testshl/result/outputter.hxx"
-
-namespace CppUnit {
-
- testshlTestResult::testshlTestResult(GetOpt & _aOptions)
- :TestResult(_aOptions),
- m_aOptions(_aOptions),
- // m_aOptionHelper(_aOptions),
- m_aResulter(this)
- {
- addListener( &m_aResulter );
- }
-
- testshlTestResult::~testshlTestResult()
- {
- }
-
-//# void
-//# testshlTestResult::addFailure( const TestFailure &failure )
-//# {
-//# // TestResultCollector::addFailure( failure );
-//# // std::cerr << ( failure.isError() ? "E" : "F" );
-//# m_aResulter.addFailure(failure);
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::startTest( Test *test )
-//# {
-//# // TestResultCollector::startTest (test);
-//# m_aResulter.startTest(test);
-//# // std::cerr << ".";
-//# }
-//#
-//# void testshlTestResult::endTest( Test *test )
-//# {
-//# }
-
-// -----------------------------------------------------------------------------
-
-//# void
-//# testshlTestResult::printFailures( Outputter &stream )
-//# {
-//# TestFailures::const_iterator itFailure = failures().begin();
-//# int failureNumber = 1;
-//# while ( itFailure != failures().end() )
-//# {
-//# stream << std::endl;
-//# printFailure( *itFailure++, failureNumber++, stream );
-//# }
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailure( TestFailure *failure,
-//# int failureNumber,
-//# std::ostream &stream )
-//# {
-//# printFailureListMark( failureNumber, stream );
-//# stream << ' ';
-//# printFailureTestName( failure, stream );
-//# stream << ' ';
-//# printFailureType( failure, stream );
-//# stream << ' ';
-//# printFailureLocation( failure->sourceLine(), stream );
-//# stream << std::endl;
-//# printFailureDetail( failure->thrownException(), stream );
-//# stream << std::endl;
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailureListMark( int failureNumber,
-//# std::ostream &stream )
-//# {
-//# stream << failureNumber << ")";
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailureTestName( TestFailure *failure,
-//# std::ostream &stream )
-//# {
-//# Test* pTest = failure->failedTest();
-//# stream << "test: " << pTest->getName();
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailureType( TestFailure *failure,
-//# std::ostream &stream )
-//# {
-//# stream << "("
-//# << (failure->isError() ? "E" : "F")
-//# << ")";
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailureLocation( SourceLine sourceLine,
-//# std::ostream &stream )
-//# {
-//# if ( !sourceLine.isValid() )
-//# return;
-//#
-//# stream << "line: " << sourceLine.lineNumber()
-//# << ' ' << sourceLine.fileName();
-//# }
-//#
-//#
-//# void
-//# testshlTestResult::printFailureDetail( Exception *thrownException,
-//# std::ostream &stream )
-//# {
-//# if ( thrownException->isInstanceOf( NotEqualException::type() ) )
-//# {
-//# NotEqualException *e = (NotEqualException*)thrownException;
-//# stream << "expected: " << e->expectedValue() << std::endl
-//# << "but was: " << e->actualValue();
-//# if ( !e->additionalMessage().empty() )
-//# {
-//# stream << std::endl;
-//# stream << "additional message:" << std::endl
-//# << e->additionalMessage();
-//# }
-//# }
-//# else
-//# {
-//# stream << " \"" << thrownException->what() << "\"";
-//# }
-//# }
-
-
-// LLA: output format:
-// Header
-// # -- BEGIN
-// Error lines
-// No error lines
-// unknown lines
-// # -- END
-// Text 'Test #PASSED#' or 'Errors only'
-
-void
-testshlTestResult::print( Outputter& stream )
-{
- printHeader( stream );
- // stream << std::endl;
- // printFailures( stream );
-
- bool bPassed = false;
- if (isOnlyShowJobs())
- {
- JobList jl(m_aOptionHelper.getJobOnlyList());
- HashMap aJobList = jl.getHashMap();
- printLines(stream, aJobList);
- }
- else
- {
- stream << "# -- BEGIN:" << Outputter::endl();
-
- TestPtrList aFailedTests;
-
- // List of failures
- printFailedTests(stream, aFailedTests);
-
- if (! m_aOptionHelper.getOptions().hasOpt("-onlyerrors"))
- {
- // List of well done tests
- printTestLines(stream, aFailedTests);
-
- // List of unknown Tests
- JobList jl(m_aOptionHelper.getJobOnlyList());
- HashMap aJobList = jl.getHashMap();
- printUnknownLines(stream, aJobList);
-
- bPassed = true;
- }
- stream << "# -- END:" << Outputter::endl();
-
- if (bPassed)
- {
- stream << "Test #PASSED#" << Outputter::endl();
- }
-
- if (m_aOptionHelper.getOptions().hasOpt("-onlyerrors"))
- {
- stream << "Errors only." << Outputter::endl();
- }
- }
-}
-
-// -----------------------------------------------------------------------------
-void
-testshlTestResult::printLines(Outputter &stream, HashMap & _aJobList)
-{
- int nCount = _aJobList.size();
- if (nCount != 0)
- {
- for (HashMap::const_iterator it = _aJobList.begin();
- it != _aJobList.end();
- ++it)
- {
- std::string aKey = (*it).first;
- if (_aJobList[aKey] == JOB_ACCESS)
- {
- stream << aKey;
- stream << Outputter::endl();
- }
- }
- }
-}
-
-void
-testshlTestResult::printFailedTests(Outputter &stream, TestPtrList &aFailedTests)
-{
- for (TestResultCollector::TestFailures::const_iterator it2 = m_aResulter.failures().begin();
- it2 != m_aResulter.failures().end();
- ++it2)
- {
- TestFailureEnvelope *pEnvelop = *it2;
- TestFailure *pFailure = pEnvelop->getTestFailure();
- std::string sNodeName = pEnvelop->getString();
-
- aFailedTests[ pFailure->failedTest() ] = true;
-
- printFailureLine(stream, pFailure, sNodeName);
- }
-}
-
-void
-testshlTestResult::printTestLines(Outputter &stream, TestPtrList &aFailedTests)
-{
- for (TestResultCollector::Tests::const_iterator it = m_aResulter.tests().begin();
- it != m_aResulter.tests().end();
- ++it)
- {
- TestEnvelope *pEnvelop = *it;
- Test* pTest = pEnvelop->getTest();
- std::string sNodeName = pEnvelop->getString();
-
- if (aFailedTests.find(pTest) == aFailedTests.end())
- {
- std::string sInfo = m_aResulter.getInfo(pTest);
- printTestLine(stream, pTest, sNodeName, sInfo);
- }
- }
-}
-
-void
-testshlTestResult::printUnknownLines(Outputter &stream, HashMap & _aJobList)
-{
- int nCount = _aJobList.size();
- if (nCount != 0)
- {
- for (HashMap::const_iterator it = _aJobList.begin();
- it != _aJobList.end();
- ++it)
- {
- std::string aKey = (*it).first;
- if (_aJobList[aKey] == JOB_UNKNOWN)
- {
- printUnknownLine(stream, aKey);
- }
- }
- }
-}
-
-void
-testshlTestResult::printHeader( Outputter &stream )
-{
- std::string sDate(m_aOptionHelper.createDateTag());
- if (isOnlyShowJobs())
- {
- stream << "# This is an automatically generated job file." << Outputter::endl();
- stream << "# ";
- }
- else
- {
- stream << sDate << Outputter::endl();
- }
-}
-
-void
-testshlTestResult::printFailureLine( Outputter &stream, TestFailure *_pFailure, std::string const& _sNodeName)
-{
- std::string aName;
- aName += _sNodeName;
- aName += ".";
- aName += _pFailure->failedTestName();
-
- SourceLine aLine = _pFailure->sourceLine();
- sal_Int32 nLine = -1;
- std::string sFilename;
- if (aLine.isValid())
- {
- nLine = aLine.lineNumber();
- sFilename = aLine.fileName();
- }
-
- Exception *pExp = _pFailure->thrownException();
- std::string sWhat;
- if (pExp)
- {
- sWhat = pExp->what();
- }
-
- ErrorType::num eErr = _pFailure->getErrorType();
-
- stream << aName;
- stream << ";";
-
- if (eErr == ErrorType::ET_FAILURE)
- stream << "FAILED";
-
- else if (eErr == ErrorType::ET_ERROR)
- stream << "ERROR";
-
- else if (eErr == ErrorType::ET_SIGNAL)
- stream << "SIGNAL";
-
- else
- stream << "UNKNOWN";
-
- stream << "#FAILED#";
-
- stream << sWhat;
- stream << Outputter::endl();
-}
-
-void
-testshlTestResult::printTestLine( Outputter &stream, Test* _pTest, std::string const& _sNodeName, std::string const& _sInfo)
-{
- std::string aName;
- aName += _sNodeName;
- aName += ".";
- aName += _pTest->getName();
-
- stream << aName;
- stream << ";";
- stream << _sInfo << "#";
- if (_sInfo == "PASSED")
- {
- stream << "OK#";
- }
- else
- {
- stream << "FAILED#";
- }
- stream << Outputter::endl();
-}
-
-void
-testshlTestResult::printUnknownLine( Outputter &stream, std::string const& _sTestName)
-{
- stream << _sTestName;
- stream << ";";
- stream << "UNKNOWN#";
- stream << "FAILED#";
- stream << Outputter::endl();
-}
-
-//# void
-//# testshlTestResult::printStatistics( Outputter &stream )
-//# {
-//# stream << "Test Results:" << std::endl;
-//#
-//# stream << "Run: " << runTests()
-//# << " Failures: " << testFailures()
-//# << " Errors: " << testErrors()
-//# << std::endl;
-//# }
-
-
-Outputter &
-operator <<( Outputter &stream,
- testshlTestResult &result )
-{
- result.print (stream); return stream;
-}
-
-
-} // namespace CppUnit
diff --git a/testshl2/source/cppunit/result/treswrapper.cxx b/testshl2/source/cppunit/result/treswrapper.cxx
deleted file mode 100644
index 50d0b7f8ebfe..000000000000
--- a/testshl2/source/cppunit/result/treswrapper.cxx
+++ /dev/null
@@ -1,259 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <cstdarg>
-#include <stdlib.h>
-#include <stdio.h>
-
-#include <sal/types.h>
-#include <cppunit/Test.h>
-#include "testshl/autoregister/htestresult.h"
-#include "cppunit/callbackfunc_fktptr.h"
-#include "testshl/result/callbackfunc.h"
-#include "testshl/result/TestResult.h"
-#include <testshl/taghelper.hxx>
-
-#include <cppunit/tagvalues.hxx>
-
-namespace
-{
- void TestResult_startTest(hTestResult _pResult, hTest _pTest)
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
-
- std::string sName = pTest->getName();
- CallbackDispatch(0 /* NULL */, TAG_TYPE, SIGNAL_START_TEST, TAG_RESULT_PTR, _pResult, TAG_NODENAME, sName.c_str(), TAG_DONE);
-
- pResult->startTest(pTest);
- }
-
- void TestResult_endTest( hTestResult _pResult, hTest _pTest )
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- pResult->endTest(pTest);
-
- std::string sName = pTest->getName();
- CallbackDispatch(0 /* NULL */, TAG_TYPE, SIGNAL_END_TEST, TAG_RESULT_PTR, _pResult, TAG_NODENAME, sName.c_str(), TAG_DONE);
- }
-
-// -----------------------------------------------------------------------------
-
- void TestResult_addFailure( hTestResult _pResult, hTest _pTest, hException _pException )
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- CppUnit::Exception* pException = (CppUnit::Exception*)_pException;
- pResult->addFailure(pTest, pException);
- }
-
- void TestResult_addError( hTestResult _pResult, hTest _pTest, hException _pException )
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- CppUnit::Exception* pException = (CppUnit::Exception*)_pException;
- pResult->addError(pTest, pException);
- }
-
- sal_Int32 TestResult_shouldStop(hTestResult _pResult)
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- return pResult->shouldStop() == true ? 1 : 0;
- }
-
-// -----------------------------------------------------------------------------
- void TestResult_addInfo( hTestResult _pResult, hTest _pTest, const char* _sInfo )
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- // CppUnit::Exception* pException = (CppUnit::Exception*)_pException;
- pResult->addInfo(pTest, _sInfo);
- }
-// -----------------------------------------------------------------------------
- void TestResult_enterNode( hTestResult _pResult, const char* _sNode )
- {
- // signalPushName(getName());
- // CallbackDispatch(NULL, TAG_TYPE, EXECUTION_PUSH_NAME, TAG_RESULT_PTR, _pResult, TAG_NODENAME, _sNode, TAG_DONE);
-
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- // CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- // CppUnit::Exception* pException = (CppUnit::Exception*)_pException;
- pResult->enterNode(_sNode);
- }
- void TestResult_leaveNode( hTestResult _pResult, const char* _sNode )
- {
- CppUnit::TestResult* pResult = (CppUnit::TestResult*)_pResult;
- // CppUnit::Test* pTest = (CppUnit::Test*)_pTest;
- // CppUnit::Exception* pException = (CppUnit::Exception*)_pException;
- pResult->leaveNode(_sNode);
-
- // CallbackDispatch(NULL, TAG_TYPE, EXECUTION_POP_NAME, TAG_RESULT_PTR, _pResult, TAG_DONE);
- }
-
-// -----------------------------------------------------------------------------
- sal_Int32 TestResult_StarterA(TagHelper const& _aTagItems)
- {
- sal_Int32 nRetValue = 0;
- TagData nTagType = _aTagItems.GetTagData(TAG_TYPE, 0);
- hTestResult pResult = (hTestResult) _aTagItems.GetTagData(TAG_RESULT_PTR, 0 /* NULL */);
- CppUnit::Test* pTest = (CppUnit::Test*) _aTagItems.GetTagData(TAG_TEST_PTR, 0 /* NULL */);
-
- try
- {
- switch(nTagType)
- {
- case RESULT_START:
- TestResult_startTest(pResult, pTest);
- break;
-
- case RESULT_END:
- TestResult_endTest(pResult, pTest);
- break;
-
- case RESULT_ADD_FAILURE:
- {
- hException pException = (hException) _aTagItems.GetTagData(TAG_EXCEPTION, 0);
- TestResult_addFailure(pResult, pTest, pException);
- break;
- }
-
- case RESULT_ADD_ERROR:
- {
- hException pException = (hException) _aTagItems.GetTagData(TAG_EXCEPTION, 0);
- TestResult_addError(pResult, pTest, pException);
- break;
- }
-
- case RESULT_ADD_INFO:
- {
- const char* pInfo = (const char* ) _aTagItems.GetTagData(TAG_INFO, 0);
- TestResult_addInfo(pResult, pTest, pInfo);
- break;
- }
-
- case RESULT_ENTER_NODE:
- {
- const char* pNode = (const char* )_aTagItems.GetTagData(TAG_NODENAME, 0);
- TestResult_enterNode(pResult, pNode);
- break;
- }
-
- case RESULT_LEAVE_NODE:
- {
- const char* pNode = (const char* ) _aTagItems.GetTagData(TAG_NODENAME, 0);
- TestResult_leaveNode(pResult, pNode);
- break;
- }
-
- case RESULT_SHOULD_STOP:
- nRetValue = TestResult_shouldStop(pResult);
- break;
-
- default:
- fprintf(stderr, "TestResult_StarterA: Can't handle the tag type %8x\n", SAL_STATIC_CAST(int, nTagType));
- fflush(stderr);
- // throw std::exception(/*std::string("Unknown TYPE_TAG Exception.")*/);
- }
- }
- catch (std::exception &e)
- {
- fprintf(stderr, "TestResult_StarterA: Exception caught: %s\n", e.what());
- // throw e;
- }
-
- return nRetValue;
- }
-} // namespace anonymous
-
-// --------------------------------- Prototypes ---------------------------------
-
-sal_Int32 SignalHandlerA( TagHelper const& _aTagItems );
-sal_Int32 ExecutionA( TagHelper const& _aTagItems );
-
-// -----------------------------------------------------------------------------
-long CallbackDispatch(int x, ...)
-{
- (void) x; // avoid warning
-
- // The idea behind TagItems are from the Amiga OS.
- // Due to the fact that the following code does not find my ok
- // I decide to wrote a simple helper
- //
- // struct TagItem *tags = (struct TagItem *)&x + 1;
-
- TagHelper aTagItems;
-
- // the following code could also be in a #define, so other functions could
- // use this, but at the moment this function a the only one.
-
- // FILL_TAGS(aTagItems, x);
- std::va_list args;
- va_start( args, x );
- Tag nTag;
- do
- {
- nTag = va_arg(args, Tag);
- if (nTag != TAG_DONE)
- {
- TagData nValue = va_arg(args, TagData);
- // printf("Tag: %8x Value:%8x\n", nTag, nValue);
- aTagItems.insert(nTag, nValue);
- }
- } while (nTag != TAG_DONE);
-
- va_end ( args );
-
- // FILL_TAGS:END
-
- // printf(".\n");
-
- long nRetValue = 0;
- Tag nPreTag = aTagItems.GetTagData(TAG_TYPE);
- if ( (nPreTag & TAG_RESULT) == TAG_RESULT)
- {
- nRetValue = TestResult_StarterA( aTagItems );
- }
- else if ((nPreTag & TAG_SIGNAL) == TAG_SIGNAL)
- {
- nRetValue = SignalHandlerA(aTagItems);
- }
- else if (( nPreTag & TAG_EXECUTION) == TAG_EXECUTION)
- {
- nRetValue = ExecutionA(aTagItems);
- }
- else
- {
- fprintf(stderr, "CallbackDispatch: First tag is unknown %8x\n", SAL_STATIC_CAST(int, nPreTag));
- // unknown TAG_TYPE
- }
- return nRetValue;
-}
-
diff --git a/testshl2/source/cppunit/signaltest.cxx b/testshl2/source/cppunit/signaltest.cxx
deleted file mode 100644
index 0fbb24965699..000000000000
--- a/testshl2/source/cppunit/signaltest.cxx
+++ /dev/null
@@ -1,89 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <typeinfo>
-
-#include "testshl/signaltest.h"
-
-namespace CppUnit
-{
-
-/** Constructs a test case for a suite.
- * This TestCase is intended for use by the TestCaller and should not
- * be used by a test case for which run() is called.
- **/
-SignalTest::SignalTest(std::string const& _sName)
- : m_sName( _sName )
-{
-}
-
-
-/// Destructs a test case
-SignalTest::~SignalTest()
-{
-}
-
-
-/// Returns a count of all the tests executed
-int
-SignalTest::countTestCases() const
-{
- return 1;
-}
-
-/// We never need to start this
-void SignalTest::run(hTestResult) {}
-
-
-/// Returns the name of the test case
-std::string
-SignalTest::getName() const
-{
- return m_sName;
-}
-
-
-/// Returns the name of the test case instance
-std::string
-SignalTest::toString() const
-{
- std::string className;
-
-#if CPPUNIT_USE_TYPEINFO_NAME
- const std::type_info& thisClass = typeid( *this );
- className = thisClass.name();
-#else
- className = "SignalTest";
-#endif
-
- return className + "." + getName();
-}
-
-} // namespace CppUnit
diff --git a/testshl2/source/cppunit/t_print.cxx b/testshl2/source/cppunit/t_print.cxx
deleted file mode 100644
index 367a97602012..000000000000
--- a/testshl2/source/cppunit/t_print.cxx
+++ /dev/null
@@ -1,95 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <testshl/cmdlinebits.hxx>
-#include <rtl/tres.h>
-#include <osl/mutex.hxx>
-
-extern CmdLineBits st_nBits;
-
-sal_Bool isBit( CmdLineBits _nBits, CmdLineBits _nFlag )
-{
- return( ( _nBits & _nFlag ) == _nFlag );
-}
-
-// -----------------------------------------------------------------------------
-// ----------------------------- own printf method -----------------------------
-// -----------------------------------------------------------------------------
-
-bool isVerbose()
-{
- if ( isBit( st_nBits, rtl_tres_Flag_VERBOSE ) )
- {
- return true;
- }
- return false;
-}
-
-bool isQuiet()
-{
- if ( isBit( st_nBits, rtl_tres_Flag_QUIET ) )
- {
- return true;
- }
- return false;
-}
-
-// ::osl::Mutex m_aTPrintMutex;
-
-void impl_t_print(const char* _pFormatStr, va_list &args)
-{
- if (! isQuiet())
- {
- // ::osl::MutexGuard g(m_aTPrintMutex);
- printf("# ");
- vprintf(_pFormatStr, args);
- }
-}
-
-void t_print(const char* _pFormatStr, ...)
-{
- va_list args;
- va_start( args, _pFormatStr );
- impl_t_print(_pFormatStr, args);
- va_end( args );
-}
-
-void t_print(T_Print_Params _eType, const char* _pFormatStr, ...)
-{
- if (_eType == T_VERBOSE && isVerbose())
- {
- // if T_VERBOSE and we should be verbose, print info
- va_list args;
- va_start( args, _pFormatStr );
- impl_t_print(_pFormatStr, args);
- va_end( args );
- }
-}
diff --git a/testshl2/source/cppunit/tresregister.cxx b/testshl2/source/cppunit/tresregister.cxx
deleted file mode 100644
index b43f2925b2c5..000000000000
--- a/testshl2/source/cppunit/tresregister.cxx
+++ /dev/null
@@ -1,66 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <sal/types.h>
-#include <testshl/autoregister/registerfunc.h>
-#include <testshl/autoregister/callbackstructure.h>
-#include <testshl/cmdlinebits.hxx>
-
-//! is this global CallbackStructure need?
-CallbackStructure aGlobalStructure;
-CmdLineBits st_nBits;
-
-FktPtr_CallbackDispatch pCallbackFunc = NULL;
-
-// This function is called from the TestShl tool.
-extern "C" void SAL_CALL registerAllTestFunction(CallbackStructure* _pCallback)
-{
- aGlobalStructure = *_pCallback;
-
- st_nBits = aGlobalStructure.nBits;
-
- pCallbackFunc = _pCallback->aCallbackDispatch;
- FktRegFuncPtr pFunc = _pCallback->aRegisterFunction;
- if (pFunc)
- {
- RegisterTestFunctions(pFunc);
- }
- else
- {
- // error, should be echoed
- fprintf(stderr, "error: Callback Structure doesn't contain a test function ptr.\n");
- }
-
- // all is done, copy the magic value
- // this is only a simple internal invariant check,
- // if the called registerAllTestFunctions Function do, what we want.
- _pCallback->nMagic2 = _pCallback->nMagic;
-}
diff --git a/testshl2/source/cppunit/tresstatewrapper.cxx b/testshl2/source/cppunit/tresstatewrapper.cxx
deleted file mode 100644
index 580bb4dd1cf6..000000000000
--- a/testshl2/source/cppunit/tresstatewrapper.cxx
+++ /dev/null
@@ -1,166 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-// this functions build the wrapper, to handle old function calls to rtl_tres_state
-// IMPORTANT: Due to the fact that rtl_tres_state is in the sal.lib
-// you have to rename rtl_tres_state to c_rtl_tres_state
-//
-// return c_rtl_tres_state
-// (
-// hRtlTestResult,
-// pData->length == 0 &&
-// ! *pData->buffer,
-// "New OString containing no characters",
-// "ctor_001"
-// )
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include "cppunit/Test.h"
-#include "testshl/autoregister/htestresult.h"
-#include "cppunit/callbackfunc_fktptr.h"
-#include "cppunit/TestAssert.h"
-#include "testshl/checkboom.hxx"
-
-#define LOAD_TRESSTATEWRAPPER_LOCAL
-#include "testshl/tresstatewrapper.hxx"
-#undef LOAD_TRESSTATEWRAPPER_LOCAL
-
-#include "cppunit/tagvalues.hxx"
-#include "cppunit/externcallbackfunc.hxx"
-
-// -----------------------------------------------------------------------------
-// Wrapper class for the CppUnit::Test, because the new TestResult
-// expect a CppUnit::Test interface
-
-class WrappedTest : public CppUnit::Test
-{
- std::string m_sName;
-public:
- WrappedTest(std::string const& _sName)
- :m_sName(_sName){}
-
- virtual ~WrappedTest () {}
- virtual void run (hTestResult /*pResult*/){}
- virtual int countTestCases () const {return 1;}
- virtual std::string getName () const {return m_sName;}
- virtual std::string toString () const {return "WrappedTest";}
-};
-
-// -----------------------------------------------------------------------------
-rtl_tres_state_start::rtl_tres_state_start(hTestResult _aResult, const sal_Char* _pName)
- :m_pName(_pName),
- m_aResult(_aResult)
-{
- // (pTestResult_EnterNode)(m_aResult, m_pName);
- (pCallbackFunc)( 0 /* NULL */, TAG_TYPE, RESULT_ENTER_NODE, TAG_RESULT_PTR, m_aResult, TAG_NODENAME, m_pName, TAG_DONE);
-}
-rtl_tres_state_start::~rtl_tres_state_start()
-{
- // (pTestResult_LeaveNode)(m_aResult, m_pName);
- (pCallbackFunc)(0 /* NULL */, TAG_TYPE, RESULT_LEAVE_NODE, TAG_RESULT_PTR, m_aResult, TAG_NODENAME, m_pName, TAG_DONE);
-}
-
-// --------------------------------- C-Wrapper ---------------------------------
-typedef std::vector<rtl_tres_state_start*> rtl_tres_states;
-rtl_tres_states m_StateStack;
-
-extern "C" void c_rtl_tres_state_start(hTestResult _aResult, const sal_Char* _pName)
-{
- rtl_tres_state_start* pState = new rtl_tres_state_start(_aResult, _pName);
- m_StateStack.push_back(pState);
-}
-
-extern "C" void c_rtl_tres_state_end(hTestResult, const sal_Char*)
-{
- rtl_tres_state_start* pState = m_StateStack.back();
-
- delete pState;
- m_StateStack.pop_back();
-}
-// -----------------------------------------------------------------------------
-// -----------------------------------------------------------------------------
-// -----------------------------------------------------------------------------
-
-// -----------------------------------------------------------------------------
-// ------------------------- Wrapper for rtl_tres_state -------------------------
-// -----------------------------------------------------------------------------
-
-sal_Bool SAL_CALL c_rtl_tres_state(
- hTestResult pResult,
- sal_Bool bSuccess,
- char const * pTestMsg,
- char const * pFuncName)
-{
- CppUnit::Test* pTest = new WrappedTest(pFuncName);
-
- sal_Int32 nValue = (pCallbackFunc)(0 /* NULL */, TAG_TYPE, EXECUTION_CHECK, TAG_RESULT_PTR, pResult, TAG_NODENAME, pTest->getName().c_str(), TAG_DONE);
- if (nValue == DO_NOT_EXECUTE)
- {
- return false;
- }
-
- // This code is copied from CppUnit::TestCase and less adapted, to work with the
- // old test code.
- // (pTestResult_StartTest)(pResult, pTest);
- (pCallbackFunc)(0 /* NULL */, TAG_TYPE, RESULT_START, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_DONE);
-
- try
- {
- CPPUNIT_ASSERT_MESSAGE( pTestMsg, bSuccess ? true : false );
- // (pTestResult_AddInfo)(pResult, pTest, "#PASSED#");
- (pCallbackFunc)(0 /* NULL */, TAG_TYPE, RESULT_ADD_INFO, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_INFO, "PASSED", TAG_DONE);
- }
- catch ( CppUnit::Exception &e )
- {
- CppUnit::Exception *copy = e.clone();
- // (pTestResult_AddFailure)( pResult, pTest, copy );
- (pCallbackFunc)( 0 /* NULL */, TAG_TYPE, RESULT_ADD_FAILURE, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_EXCEPTION, copy, TAG_DONE );
- }
- catch ( std::exception &e )
- {
- //(pTestResult_AddError)( pResult, pTest, new CppUnit::Exception( e.what() ) );
- (pCallbackFunc)( 0 /* NULL */, TAG_TYPE, RESULT_ADD_ERROR, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_EXCEPTION, new CppUnit::Exception( e.what() ), TAG_DONE );
- }
- catch (...)
- {
- CppUnit::Exception *e = new CppUnit::Exception( "caught unknown exception" );
- // (pTestResult_AddError)( pResult, pTest, e );
- (pCallbackFunc)( 0 /* NULL */, TAG_TYPE, RESULT_ADD_ERROR, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_EXCEPTION, e, TAG_DONE );
- }
-
-
- // (pTestResult_EndTest)( pResult, pTest );
- (pCallbackFunc)( 0 /* NULL */, TAG_TYPE, RESULT_END, TAG_RESULT_PTR, pResult, TAG_TEST_PTR, pTest, TAG_DONE );
-
- return bSuccess;
-}
-
diff --git a/testshl2/source/cppunit/win32/winstuff.cxx b/testshl2/source/cppunit/win32/winstuff.cxx
deleted file mode 100644
index f9ffa0c5c972..000000000000
--- a/testshl2/source/cppunit/win32/winstuff.cxx
+++ /dev/null
@@ -1,140 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#ifdef WIN32
-#include "testshl/winstuff.hxx"
-
-#if defined _MSC_VER
-#pragma warning(push, 1)
-#endif
-#include <windows.h>
-#if defined _MSC_VER
-#pragma warning(pop)
-#endif
-#include <MAPIWin.h>
-
-void WinDebugBreak()
-{
- // forward to WinAPI. Note that the whole story is simply to
- // disentangle OOo headers from Windows headers (which are largely
- // incompatible, due to name clashes and macro mess-ups)
- DebugBreak();
-}
-
-void WinSleep( sal_uInt32 sec )
-{
- Sleep(sec * 1000);
-}
-
-sal_uInt32 WinGetCurrentProcessId()
-{
- return GetCurrentProcessId();
-}
-
-#define TA_FAILED 0
-#define TA_SUCCESS_CLEAN 1
-#define TA_SUCCESS_KILL 2
-#define TA_SUCCESS_16 3
-
- // Declare Callback Enum Functions.
-bool CALLBACK TerminateAppEnum( HWND hwnd, LPARAM lParam );
-
-/*----------------------------------------------------------------
- DWORD WINAPI TerminateApp( DWORD dwPID, DWORD dwTimeout )
-
- Purpose:
- Shut down a 32-Bit Process (or 16-bit process under Windows 95)
-
- Parameters:
- dwPID
- Process ID of the process to shut down.
-
- dwTimeout
- Wait time in milliseconds before shutting down the process.
-
- Return Value:
- TA_FAILED - If the shutdown failed.
- TA_SUCCESS_CLEAN - If the process was shutdown using WM_CLOSE.
- TA_SUCCESS_KILL - if the process was shut down with
- TerminateProcess().
- NOTE: See header for these defines.
- ----------------------------------------------------------------*/
-void WinTerminateApp( sal_uInt32 dwPID, sal_uInt32 dwTimeout )
-{
- HANDLE hProc;
- DWORD dwRet;
-
- // If we can't open the process with PROCESS_TERMINATE rights,
- // then we give up immediately.
- hProc = OpenProcess(SYNCHRONIZE|PROCESS_TERMINATE, false,
- dwPID);
-
- if(hProc == NULL)
- return;
-
- // TerminateAppEnum() posts WM_CLOSE to all windows whose PID
- // matches your process's.
- EnumWindows((WNDENUMPROC)TerminateAppEnum, (LPARAM) dwPID);
-
- // Wait on the handle. If it signals, great. If it times out,
- // then you kill it.
- if (WaitForSingleObject(hProc, dwTimeout) != WAIT_OBJECT_0)
- dwRet= (TerminateProcess(hProc,0) ? TA_SUCCESS_KILL : TA_FAILED);
- else
- dwRet = TA_SUCCESS_CLEAN;
-
- CloseHandle(hProc);
-}
-
-bool CALLBACK TerminateAppEnum( HWND hwnd, LPARAM lParam )
-{
- DWORD dwID;
-
- GetWindowThreadProcessId(hwnd, &dwID);
-
- if(dwID == (DWORD)lParam)
- {
- PostMessage(hwnd, WM_CLOSE, 0, 0);
- }
-
- return true;
-}
-#else
-
-// this file is only need within Windows.
-// due to the fact that empty files don't create libraries
-// we store one function in it.
-int WinStuffDummy_this_function_will_never_need()
-{
- return 42; // we need some code
-}
-
-#endif /* WIN32 */
-
diff --git a/testshl2/source/dynamicregister.cxx b/testshl2/source/dynamicregister.cxx
deleted file mode 100644
index 8253fbcb5449..000000000000
--- a/testshl2/source/dynamicregister.cxx
+++ /dev/null
@@ -1,207 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include "testshl/dynamicregister.hxx"
-#include <osl/process.h>
-// #include <osl/mutex.hxx>
-#include <rtl/string.hxx>
-#include <rtl/ustring.hxx>
-#include "testshl/filehelper.hxx"
-
-#include <unistd.h>
-
-#if defined(WIN32)
-#include <direct.h> /* w.g. _chdir() */
-#endif
-
-namespace fixes
-{
- int changedir(const char* _sPath)
- {
-#if defined(WIN32)
- // chdir(_sPath) is marked depricated since Visual C++ 2005
- // use _chdir instead
- return ::_chdir(_sPath);
-#else
- return ::chdir(_sPath);
-#endif
- }
-}
-
-// -----------------------------------------------------------------------------
-
-DynamicLibraryHelper::DynamicLibraryHelper(rtl::OUString const& _suDLLName, GetOpt & _aOptions)
- :m_pModule(new ::osl::Module()),
- m_suDLLName(_suDLLName),
- m_aOptions(_aOptions)
-{
- // create and load the module (shared library)
- m_suAbsolutePathFile = FileHelper::convertPath( _suDLLName );
-
- // due to some problems on mac OS
- // we split the absolute pathname to path and filename
- // change to the path and load the filename direct
- // then change back to the old path.
- rtl::OUString suPathSeparator = rtl::OUString( rtl::OUString::createFromAscii("/"));
- sal_Int32 nPos = m_suAbsolutePathFile.lastIndexOf(suPathSeparator);
- if (nPos != -1)
- {
- m_suAbsolutePath = m_suAbsolutePathFile.copy(0, nPos);
- m_suFilename = m_suAbsolutePathFile.copy(nPos + 1);
- }
- else
- {
- // Should never happen.
- rtl::OString sPath = rtl::OUStringToOString(m_suAbsolutePathFile, RTL_TEXTENCODING_ASCII_US);
- fprintf(stderr, "There is a problem with path '%s'.\n", sPath.getStr());
- exit(1);
- }
-
- if (getOptions().hasOpt("-absolutepath"))
- {
- fprintf(stderr, "Hint: Use absolute path to load test library.\n");
- loadLibraryFromAbsolutePath();
- }
- else if (getOptions().hasOpt("-localpath"))
- {
- fprintf(stderr, "Hint: make a chdir() to the test library, then try to load the test library without given path.\n");
- loadLibraryFromLocalPath();
- }
- else
- {
-
-// PLEASE DON'T CHANGE THIS STUPID STRUCTURE, JUST ADD YOUR ENVIRONMENT
-#if defined(LINUX)
- loadLibraryFromAbsolutePath();
- // will fail if load local
-
-#elif defined(SOLARIS)
- loadLibraryFromAbsolutePath();
- // will also be right if load local
-
-#elif defined(WIN32)
- loadLibraryFromAbsolutePath();
- // will fail if load local
-
-#elif defined(MACOSX)
- loadLibraryFromLocalPath();
- // will fail if local absolute
-#else
- // default is load absolute
- loadLibraryFromAbsolutePath();
-#endif
-}
-}
-
-void DynamicLibraryHelper::showFilenameIfVerbose()
-{
- if (getOptions().hasOpt("-verbose"))
- {
- rtl::OString sFilename = rtl::OUStringToOString(m_suFilename, RTL_TEXTENCODING_ASCII_US);
- rtl::OString sPath = rtl::OUStringToOString(m_suAbsolutePath, RTL_TEXTENCODING_ASCII_US);
- fprintf(stderr, "Try to load '%s' from '%s'.\n", sFilename.getStr(), sPath.getStr());
-
- // check filename
- }
-}
-
-void DynamicLibraryHelper::realLoadLibrary(rtl::OUString const& _suLibToLoad)
-{
- if (! m_pModule->load(_suLibToLoad, SAL_LOADMODULE_LAZY | SAL_LOADMODULE_GLOBAL))
- {
- rtl::OString sDLLName = rtl::OUStringToOString(m_suDLLName, RTL_TEXTENCODING_ASCII_US);
- fprintf(stderr, "warning: Can't load module '%s'.\n", sDLLName.getStr());
- }
-}
-
-void DynamicLibraryHelper::loadLibraryFromAbsolutePath()
-{
- showFilenameIfVerbose();
- realLoadLibrary(m_suAbsolutePathFile);
-}
-
-void DynamicLibraryHelper::loadLibraryFromLocalPath()
-{
- sal_Int32 nPos;
- rtl::OUString suPathSeparator = rtl::OUString( rtl::OUString::createFromAscii("/"));
-#if defined(WIN32)
- suPathSeparator = rtl::OUString( rtl::OUString::createFromAscii("\\"));
-#endif
- rtl::OUString suSystemPathFile;
- osl::FileBase::getSystemPathFromFileURL(m_suAbsolutePathFile, suSystemPathFile);
-
- nPos = suSystemPathFile.lastIndexOf(suPathSeparator);
- rtl::OUString suCurrentDirPath;
- if (nPos != -1)
- {
- // the filename only, no '/' in the path
- rtl::OUString suNewPath = suSystemPathFile.copy(0, nPos );
- if (suNewPath.getLength() > 0)
- {
- rtl::OString sPath = rtl::OUStringToOString(suNewPath, RTL_TEXTENCODING_ASCII_US);
- osl_getProcessWorkingDir( &suCurrentDirPath.pData );
-
- fixes::changedir(sPath.getStr());
-
- // curNewDirPath should be suPath, small self test
- rtl::OUString curNewDirPath;
- osl_getProcessWorkingDir( &curNewDirPath.pData );
- if (! curNewDirPath.equals(m_suAbsolutePath))
- {
- fprintf(stderr, "There is a problem with path '%s'.\n", sPath.getStr());
- }
- }
- }
-
- showFilenameIfVerbose();
- realLoadLibrary(m_suFilename);
-
- // change back to old directory
- if (suCurrentDirPath.getLength() > 0)
- {
- rtl::OString sCurrentDirPath = rtl::OUStringToOString(suCurrentDirPath, RTL_TEXTENCODING_ASCII_US);
- fixes::changedir(sCurrentDirPath.getStr());
- }
-}
-
-DynamicLibraryHelper::~DynamicLibraryHelper()
-{
- if (getOptions().hasOpt("-verbose"))
- {
- fprintf(stderr, "Dtor DynamicLibraryHelper.\n");
- fprintf(stderr, "Delete loaded module.");
- }
- delete m_pModule;
- if (getOptions().hasOpt("-verbose"))
- {
- fprintf(stderr, " [done].\n");
- }
-}
-
diff --git a/testshl2/source/file.cxx b/testshl2/source/file.cxx
deleted file mode 100644
index ca7ec3ad79f4..000000000000
--- a/testshl2/source/file.cxx
+++ /dev/null
@@ -1,74 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <string>
-
-// -----------------------------------------------------------------------------
-// taken from setup2
-std::string getTempPath()
-{
- std::string sTempDir;
-
- char* pTmp = getenv( "TEMP" );
- if (pTmp == NULL) pTmp = getenv("temp");
- if (pTmp == NULL) pTmp = getenv("TMP");
- if (pTmp == NULL) pTmp = getenv("tmp");
-
- if( pTmp && strlen(pTmp) >= 2 )
- {
- sTempDir = std::string( pTmp );
- }
- else
- {
-#if (defined UNX) || (defined OS2)
- int nLen;
- pTmp = P_tmpdir;
- nLen = strlen(pTmp);
- if (pTmp[ nLen - 1] == '/')
- {
- char cBuf[256];
- char* pBuf = cBuf;
- strncpy( pBuf, pTmp, nLen - 1 );
- pBuf[nLen - 1] = '\0';
- sTempDir = std::string( pBuf );
- }
- else
- {
- sTempDir = std::string( pTmp );
- }
-#else
- fprintf(stderr, "error: No temp dir found.\n");
-#endif
- }
- return sTempDir;
-}
diff --git a/testshl2/source/filehelper.cxx b/testshl2/source/filehelper.cxx
deleted file mode 100644
index ef2d78dd99ee..000000000000
--- a/testshl2/source/filehelper.cxx
+++ /dev/null
@@ -1,228 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <string>
-
-#include "testshl/filehelper.hxx"
-#include "testshl/getopt.hxx"
-
-#include <osl/process.h>
-#include <osl/file.hxx>
-
-#ifndef _SAL_TRES_H_
-#include <rtl/tres.h>
-#endif
-
-namespace FileHelper
-{
-// -----------------------------------------------------------------------------
-// taken from setup2
-std::string getTempPath()
-{
- std::string sTempDir;
-
- char const * pTmp = getenv( "TEMP" );
- if (pTmp == NULL) pTmp = getenv("temp");
- if (pTmp == NULL) pTmp = getenv("TMP");
- if (pTmp == NULL) pTmp = getenv("tmp");
-
- if( pTmp && strlen(pTmp) >= 2 )
- {
- sTempDir = std::string( pTmp );
- }
- else
- {
-#if (defined UNX) || (defined OS2)
- int nLen;
- pTmp = P_tmpdir;
- nLen = strlen(pTmp);
- if (pTmp[ nLen - 1] == '/')
- {
- char cBuf[256];
- char* pBuf = cBuf;
- strncpy( pBuf, pTmp, nLen - 1 );
- pBuf[nLen - 1] = '\0';
- sTempDir = std::string( pBuf );
- }
- else
- {
- sTempDir = std::string( pTmp );
- }
-#else
- fprintf(stderr, "error: No temp dir found.\n");
-#endif
- }
- return sTempDir;
-}
-
-// -----------------------------------------------------------------------------
-rtl::OUString convertPath( rtl::OUString const& _suSysPath )
-{
- // PRE: String should contain a filename, relativ or absolut
- rtl::OUString suURL;
- bool bRelativ = false;
-#ifdef WNT
- sal_Char cFileSep[] = "\\";
-#endif
-#if (defined UNX) || (defined OS2)
- sal_Char cFileSep[] = "/";
-#endif
-
- if ( _suSysPath.indexOf(rtl::OUString::createFromAscii("..")) == 0 )
- {
- bRelativ = true;
- }
- else if ( _suSysPath.indexOf(rtl::OUString::createFromAscii(cFileSep)) != 0 )
- {
- // no fileseparator found at first position found, must be relative
- bRelativ = true;
- }
-
- if (bRelativ)
- {
- // filepath contains '..' so it's a relative path make it absolut.
- rtl::OUString curDirPth;
- osl_getProcessWorkingDir( &curDirPth.pData );
-
- // rtl::OString sCurDirPath = rtl::OUStringToOString(curDirPth, RTL_TEXTENCODING_ASCII_US);
- // fprintf(stderr, "Current Dir '%s'.\n", sCurDirPath.getStr());
-
- osl::FileBase::getAbsoluteFileURL( curDirPth, _suSysPath, suURL );
-
- // rtl::OString sURL = rtl::OUStringToOString(suURL, RTL_TEXTENCODING_ASCII_US);
- // fprintf(stderr, " File URL: '%s'.\n", sURL.getStr());
- }
- else
- {
- osl::FileBase::getFileURLFromSystemPath( _suSysPath, suURL );
- }
- return suURL;
-}
-// -----------------------------------------------------------------------------
-rtl::OUString convertPath( rtl::OString const& sysPth )
-{
- rtl::OUString sysPath( rtl::OUString::createFromAscii( sysPth.getStr() ) );
- return convertPath(sysPath);
-}
-
-/**
- * create bitmap of comandline parameters
- */
-
-//# CmdLineBits createFlags( vector< sal_Char* > const& cmdln )
-//# {
-//# CmdLineBits retflags = rtl_tres_Flag_OK;
-//#
-//# vector< sal_Char* >::const_iterator iter = cmdln.begin();
-//# while( iter != cmdln.end() )
-//# {
-//# fprintf( stderr, "%s\n", *iter );
-//# if ( *iter[0] == '-' )
-//# {
-//# rtl::OString item( *iter );
-//# if ( item == "-boom" ) // stop near error position, exception only
-//# retflags |= rtl_tres_Flag_BOOM;
-//#
-//# if ( item == "-verbose" )
-//# retflags |= rtl_tres_Flag_VERBOSE;
-//#
-//# if ( item == "-skip" )
-//# retflags |= rtl_tres_Flag_SKIP;
-//#
-//# if ( item == "-log" )
-//# retflags |= rtl_tres_Flag_LOG;
-//#
-//# if ( item == "-his" )
-//# retflags |= rtl_tres_Flag_HIS;
-//#
-//# if ( item == "-time" )
-//# retflags |= rtl_tres_Flag_TIME;
-//#
-//# if ( item == "-msg" )
-//# retflags |= rtl_tres_Flag_MSG;
-//# }
-//# iter++;
-//# }
-//#
-//# return retflags;
-//# }
-//#
-//# CmdLineBits createFlags(int argc, char* argv[])
-//# {
-//# vector< sal_Char* > cmdln;
-//# sal_Int32 i;
-//#
-//# /* collect comandline */
-//# for ( i = 1; i < argc; i++ )
-//# cmdln.push_back( argv[i] );
-//#
-//# return createFlags(cmdln);
-//# }
-
-CmdLineBits createFlags( GetOpt & _aOptions )
-{
- CmdLineBits retflags = rtl_tres_Flag_OK;
-
- if (_aOptions.hasOpt("-boom")) // stop near error position, exception only
- {
- retflags |= rtl_tres_Flag_BOOM;
- }
-
- if (_aOptions.hasOpt("-verbose"))
- {
- retflags |= rtl_tres_Flag_VERBOSE;
- }
-
- if (_aOptions.hasOpt("-quiet"))
- {
- retflags |= rtl_tres_Flag_QUIET;
- }
- return retflags;
-}
-// -----------------------------------------------------------------------------
-
-/**
- * display usage screen
- */
-
-//# void usage()
-//# {
-//# fprintf( stdout,
-//# "USAGE: testshl shlname [-boom][-verbose][-log][-his][-msg]\n" );
-//# exit(0);
-//# }
-
-
-} // namespace FileHelper
-
-
diff --git a/testshl2/source/getopt.cxx b/testshl2/source/getopt.cxx
deleted file mode 100644
index 844a151276e1..000000000000
--- a/testshl2/source/getopt.cxx
+++ /dev/null
@@ -1,919 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include "testshl/getopt.hxx"
-
-#include "testshl/filehelper.hxx"
-
-using namespace std;
-//----------------------------------------------------------------------------
-// OptDsc
-//----------------------------------------------------------------------------
-//> createOptDsc
-void OptDsc::createOptDsc( const rtl::OString& opt ) {
-
- // analyze type of option
- // in case of flag indicate and set name and hint
- if ( ( opt.indexOf("=") == -1 ) && ( opt.indexOf(":") == -1 ) ) {
- m_type = OT_BOOL;
-
- // extract options dokumentation if any
- sal_Int32 index = opt.indexOf(",");
- if ( index == -1 ) {
- m_name = opt;
- }
- else {
- m_name = opt.copy( 0, index );
- m_hint = ( opt.copy( index + 1 ) ).trim();
- }
- return;
- }
-
- vector < rtl::OString > optLine;
-
- // ':' indicates that option has optional parameter(s)
- if ( opt.indexOf(":") != -1 ) {
- m_type |= OT_OPTIONAL;
- // create optionline tokenvector
- split( opt, ":,", optLine );
- }
- else {
- // create optionline tokenvector
- split( opt, "=,", optLine );
- }
-
- // extract name of option
- m_name = optLine[0];
-
- // parameter(s) of string type
- if ( optLine[1].indexOf("s") != -1 ) {
- m_type |= OT_STRING;
- m_legend += "arg";
- }
- // parameter(s) of numeric type
- if ( optLine[1].indexOf("n") != -1 ) {
- m_type |= OT_NUMBER;
- m_legend += "arg";
- }
- // multiple parameters allowed
- if ( optLine[1].indexOf("@") != -1 ) {
- m_type |= OT_MULTI;
- m_legend += "#1,[arg#n]";
- }
- else {
- m_type |= OT_SINGLE;
- }
-
- // extract options dokumentation if any
- m_hint = optLine[optLine.size()-1].trim();
-
-} ///< createOptDsc
-
-//> split
-void OptDsc::split( const rtl::OString& opt, const rtl::OString& cSet,
- vector< rtl::OString >& optLine ) {
-
- const sal_Int32 cSetLen = cSet.getLength();
- const sal_Char* pcSet = cSet.getStr();
- sal_Int32 index = 0;
- sal_Int32 oldIndex = 0;
-
- sal_Int32 i;
- for ( i = 0; i < cSetLen; i++ ) {
- index = opt.indexOf( pcSet[i] );
- if( index != -1 ) {
- optLine.push_back( opt.copy( oldIndex, index - oldIndex ) );
- oldIndex = index + 1;
- }
- }
- optLine.push_back( opt.copy( oldIndex ) );
-} ///< split
-
-//----------------------------------------------------------------------------
-// GetOpt
-//----------------------------------------------------------------------------
-//> ~GetOpt
-GetOpt::~GetOpt() {
- vector< OptDsc* >::iterator iter = m_optionset.begin();
- while ( iter != m_optionset.end() ) {
- delete (*iter);
- (*iter) = 0;
- iter++;
- }
- m_optionset.clear();
-} ///< ~GetOpt
-
-/**
- * private
- * initialization of GetOpt class means to fill the vector members
- * representing the commandline and optionset
- * @param char* cmdLine[] = comandline
- * @param char* optSet[] = optionset
- *
- * @return void
- */
-//> initialize
-void GetOpt::initialize( char* cmdLine[], char const * optSet[] ) {
-
- while ( *cmdLine ) {
- m_cmdline.push_back( rtl::OString( *cmdLine ) );
- *cmdLine++;
- }
- // insert an empty OString, to mark the end.
- m_cmdline.push_back(rtl::OString());
-
- while ( *optSet && ( rtl::OString( optSet[0] ).indexOf("-") == 0 ) ) {
- m_optionset.push_back( new OptDsc( *optSet ) );
- *optSet++;
- }
-
-} ///< initialize
-
-/**
- * public
- * returns a pointer to an object of type optiondescription (OptDsc)
- *
- * @param rtl::OString& opt = name of option
- *
- * @return OptDsc* = pointer to requested optiondescription
- * or NULL if not found
- */
-//> getOptDsc
-OptDsc* GetOpt::getOptDsc( rtl::OString& opt ) {
-
- vector< OptDsc* >::iterator iter = m_optionset.begin();
- while ( iter != m_optionset.end() ) {
- if ( (*iter)->getName() == opt ) {
- return (*iter);
- }
- iter++;
- }
- return NULL;
-
-} ///< getOptDsc
-
-/**
- * public
- * check if option is already present in optionhash
- * @param const rtl::OString& opt = name of option
- * @return sal_Bool
- */
-//> hasOpt
-sal_Bool GetOpt::hasOpt( const rtl::OString& opt ) const {
-
- if ( m_opthash.find( opt ) != m_opthash.end() ) {
- return sal_True ;
- }
- return sal_False ;
-
-} ///< hasOpt
-
-/**
- * private
- * handles the initialized comandline vector
- * and fill the optionhash with evaluated options
- * @param none
- * @return void
- */
-//> createCmdLineOptions
-void GetOpt::createCmdLineOptions() {
-
- // get iterator of comandline vector
- vector< rtl::OString >::iterator iter = m_cmdline.begin();
-
- // extract first comandlineparameter as program name
- m_prgname = (*iter);
- iter++;
-
- // process the whole vector
- while ( iter != m_cmdline.end() ) {
- // extract following comandline parameter(s) as program parameter(s)
- // int nIdxOfMinus = (*iter).indexOf("-");
- if ( (*iter).indexOf("-") != 0 ) /* start without '-' */
- {
- if ((*iter).getLength() > 0 ) /* is not empty */
- {
- m_param.push_back(*iter);
- }
- iter++;
- continue;
- }
- // option occured
- if ( (*iter).indexOf("-") == 0 )
- {
- // ignore invalid options
- if ( ! evaluateOpt( iter ) )
- {
- iter++;
- // check if wrong option has got a parameter
- // and skip that, too
- if( (iter + 1) != m_cmdline.end() )
- {
- if ( (*(iter + 1)).indexOf("-") != 0 )
- {
- iter++;
- }
- }
- continue;
- }
- rtl::OString opt( (*iter) );
- vector< rtl::OString > optValues;
-
- // option is no flag
- if ( ! getOptDsc( opt )->isFlag() ) {
- // but has optional parameters
- if ( getOptDsc( opt )->isOptional() ) {
- // no parameters present
- if ( ! hasParam( iter ) ) {
- m_opthash[ opt ] = optValues;
- optValues.clear();
- iter++;
- continue;
- }
- }
- iter++;
- // more than one option parameters occured
- if ( (*iter).indexOf( "," ) != -1 ) {
- tokenize( (*iter), "," , optValues );
- }
- else {
- optValues.push_back( (*iter) );
- }
- }
- // create key/value pair in optionhash and clear value vector
- m_opthash[ opt ] = optValues;
- optValues.clear();
- }
- iter++;
- }
-} ///< createCmdLineOptions
-
-/**
- * public
- * check if option has parameter(s)
- * @param vector< rtl::OString >::iterator iter = iterator of
- * comandline vector
- *
- * @return sal_Bool
- */
-//> hasParam
-sal_Bool GetOpt::hasParam( vector< rtl::OString >::iterator iter ) {
- if ( iter+1 == m_cmdline.end() ) {
- return sal_False;
- }
- if ( (*(iter+1)).indexOf("-") == 0 ) {
- return sal_False;
- }
- if ( (*(iter+1)) == "" ) {
- return sal_False;
- }
-
- return sal_True;
-} ///< hasParam
-
-/**
- * public
- * option evaluation in general means to verify if the option occur is
- * a member of optionset say an admitted option, if so does it appear with
- * the right or tolerable usage
- *
- * @param vector< rtl::OString >::iterator iter = iterator of
- * comandline vector
- *
- * @return sal_Bool
- */
-//> evaluateOpt
-sal_Bool GetOpt::evaluateOpt( vector< rtl::OString >::iterator iter ) {
-
- // option is no member of optionset
- if ( ! exist( (*iter) ) ) {
- cout << "Unknown option " << (*iter).getStr()
- << " occurred !" << endl;
- return sal_False;
- }
-
- // option is a flag
- if ( getOptDsc( (*iter) )->isFlag() ) {
- return sal_True;
- }
-
- // parameter not optional
- if ( ! getOptDsc( (*iter) )->isOptional() ) {
-
- // verify that next vectoritem is present and no option
- if ( ( *( iter + 1 ) ).getLength() &&
- ( ( *( iter + 1 ) ).indexOf( "-" ) != 0 ) ) {
-
- // if we are waiting for one single parameter
- if ( getOptDsc( *iter )->isSingle() ) {
- // but find multiple parameters
- if( ( *( iter + 1 ) ).indexOf(",") != -1 ) {
- cout << "Wrong use of option " << (*iter).getStr()
- << " too many parameters !" << endl;
- return sal_False;
- }
- return sal_True;
- }
- return sal_True;
- }
-
- cout << "Wrong use of option " << (*iter).getStr()
- << " parameter missing !" << endl;
- return sal_False;
- }
- // parameter optional
- if ( getOptDsc( *iter )->isSingle() ) {
-
- if ( hasParam( iter ) ) {
- if( ( *( iter + 1 ) ).indexOf(",") != -1 ) {
- cout << "Wrong use of option " << (*iter).getStr()
- << " too many parameters !" << endl;
- return sal_False;
- }
- }
- }
- return sal_True;
-
-} ///< evaluateOpt
-
-
-//> createOpt
-void GetOpt::createOpt( rtl::OString& optDscStr ) {
- m_optionset.push_back( new OptDsc( optDscStr ) );
-} ///< createOpt
-
-/**
- * public
- * conditional addition of an option to optionhash
- * overriding options, already present in optionhash, is not permitted
- *
- * @param rtl::OString& optStr = optionstring which is to break in a
- * key/value pair and to add to optionhash
- *
- * @return void
- */
-//> addOpt
-void GetOpt::addOpt( rtl::OString& optStr, sal_Bool eval ) {
-
- vector< rtl::OString > optTok;
- tokenize( optStr, "=", optTok );
-
- // prevent override of commandline options
- // by options from ini file
- if( hasOpt( optTok[0] ) ) {
- return;
- }
-
- // evaluate rigth usage of option
- if( eval ) {
- if ( ! evaluateOpt( optTok.begin() ) ) {
- return;
- }
- }
- vector< rtl::OString > optValues;
-
- if ( optTok.size() > 1 ) {
- rtl::OString oValStr( optTok[1] );
- // found a variable
- if ( oValStr.indexOf(",") == -1 ) {
- optValues.push_back( oValStr );
- }
- else {
- tokenize( oValStr, ",", optValues );
- }
- }
- m_opthash[ optTok[0] ] = optValues;
- optValues.clear();
- return;
-} ///< addOpt
-
-/**
- * public
- * verify the existance of an option in optionset
- * @param rtl::OString& opt = option name
- * @return sal_Bool
- */
-//> exist
-sal_Bool GetOpt::exist( rtl::OString& opt ) {
- if ( getOptDsc( opt ) ) {
- return sal_True;
- }
- return sal_False;
-} ///< exist
-
-/**
- * public
- * verify the existance of variables inside options
- * @param none
- * @return sal_Bool
- */
-//> hasVars
-sal_Bool GetOpt::hasVars() {
- if ( m_varvec.size() ) {
- return sal_True;
- }
- return sal_False;
-} ///< hasVars
-
-
-/**
- * public
- * proceeds a buffer representing the content of an ini file and adds the
- * options to optionhash. The optionstrings in the file are allowed to contain
- * variables indicated by delimiters described with varDelim
- *
- * @param rtl::OString iOpts = raw filecontent
- * @param const rtl::OString& varDelim = delimiter indicating a variable
- *
- * @return void
- */
-//> str2Opt
-void GetOpt::str2Opt( rtl::OString iOpts ) {
-
- // tokenize filecontent by '\n' to create a vector of lines
- vector< rtl::OString > iniLines;
- tokenize( iOpts, "\n", iniLines );
-
- sal_uInt32 tCnt = iniLines.size();
-
- // process all lines
- sal_uInt32 i;
- for ( i = 1; i < tCnt; i++ ) {
- rtl::OString optLine( iniLines[i] );
- // ignore comments
- if ( ! ( optLine.indexOf("#") == 0 ) ) {
- // filter valid options after trim
- if ( ( optLine.indexOf("-") == 0 ) ) {
- // line contains a variable
- if ( ( optLine.indexOf( m_vardelim ) != -1 ) ) {
- // push to var vector for later process
- m_varvec.push_back( optLine );
- continue;
- }
- addOpt( optLine );
- }
- }
- }
-} ///< str2opt
-
-void GetOpt::replVars() {
-
- // process vector of lines containing variables
- vector< rtl::OString >::iterator iter = m_varvec.begin();
- while ( iter != m_varvec.end() ) {
- sal_Int32 index = 0;
- while ( ( index = (*iter).indexOf( m_vardelim ) ) != -1 ) {
- vector< rtl::OString > varLineTok;
- rtl::OString varKey( "-" );
- tokenize( *iter, m_vardelim, varLineTok );
- varKey += varLineTok[1];
- vector< rtl::OString > keyValues = getOptVec( varKey );
-
- if ( keyValues.size() > 1 ) {
- rtl::OString rplStr;
-
- vector< rtl::OString >::iterator kvi = keyValues.begin();
- while ( kvi != keyValues.end() ) {
- rplStr += (*kvi);
- kvi++;
- if ( kvi != keyValues.end() ) {
- rplStr += ",";
- }
- }
- (*iter ) = (*iter).replaceAt(
- index, varKey.getLength()+1, rplStr );
- }
- else {
- if( *(keyValues[0])) {
- (*iter) = (*iter).replaceAt(
- index, varKey.getLength()+1, keyValues[0] );
- }
- }
- }
- addOpt( (*iter) );
- iter++;
- }
-
-}
-
-/**
- * public
- * displays a formatted usagescreen
- * @param none
- * @return void
- */
-//> showUsage
-void GetOpt::showUsage() {
-
- sFormat frm;
- frm.fCol = getMaxNameLength() + 2;
- frm.sCol = frm.fCol + getMaxLegendLength() + 2 ;
- frm.len = 79;
-
- vector< rtl::OString > nameVec;
- vector< rtl::OString > paramVec;
-
- tokenize( getName(), "/\\", nameVec );
- if ( m_param.empty() ) {
- if ( hasOpt( "-db" ) ) {
- tokenize( getOpt( "-db" ), "/\\", paramVec );
- }
- else {
- paramVec.push_back( rtl::OString( "not available" ) );
- }
- }
- else {
- tokenize( getFirstParam(), "/\\", paramVec );
- }
-
- cout << "\n\n\n\n\nUsage: prgname param [options]\n\nPRGNAME = [path]";
-
- if ( !nameVec.empty() ) {
- cout << (*(nameVec.end()-1)).getStr();
- }
- cout << "\nPARAM = [path]";
- if ( !paramVec.empty() ) {
- cout << (*(paramVec.end()-1)).getStr() << endl;
- }
-
- cout << "\nOPTIONS = [" << flush;
-
- vector< OptDsc* >::iterator iter = m_optionset.begin();
-
- while ( iter != m_optionset.end() ) {
- cout << (*iter)->getName().getStr() << "," << flush;
- iter++;
- }
- cout << "]\n\nOPTIONS:\n" << flush;
-
- iter = m_optionset.begin();
-
- while ( iter != m_optionset.end() ) {
- cout << optDsc2Str( *iter, frm ).getStr() << endl << flush;
-
- iter++;
- }
-
-} ///< showUsage
-
-/**
- * public
- * displays the actual option/parameter status
- * @param none
- * @return void
- */
-//> printStatus
-void GetOpt::printStatus( void ) {
-
- sal_uInt32 maxlen = getMaxNameLength();
- optHashMap::iterator iter = m_opthash.begin();
- cout << endl;
-
- while ( iter != m_opthash.end() ) {
- rtl::OString option( (*iter).first );
-
- cout.setf(ios::left);
- cout.width( maxlen+1 );
- cout << option.getStr() << "= ";
-
- if ( ! getOptDsc( option )->isFlag() ) {
- if ( ! getOptVec( option ).empty() ) {
- sal_uInt32 j;
- for ( j = 0; j < (*iter).second.size(); j++ ) {
- cout << (( (*iter).second )[j]).getStr() << " ";
- }
- cout << endl;
- }
- else {
- cout << "FALSE\n";
- }
- }
- else {
- cout << "TRUE\n";
- }
- iter++;
- }
-}
-
-/**
- * private
- * converts an object of type optiondescription (OptDsc) to a formatted
- * displayable string for usagescreen needs
- * @param OptDsc* optDsc = pointer to option description
- * @param sFormat frm = format structur
- *
- * @return const rtl::OString = formatted string for display purposes
- */
-//> optDsc2Str >>> to be replaced by intelliget algorythm <<<
-const rtl::OString GetOpt::optDsc2Str( OptDsc* optDsc , sFormat frm ) {
-
- sal_Char* buf = new sal_Char[ frm.len + 1 ];
- sal_Char* pBuf = buf;
-
- sal_uInt32 i;
- for ( i = 0; i < frm.len; i++ ) {
- *pBuf++ = ' ';
- }
- *pBuf = '\0';
-
- rtl::OStringBuffer strBuf( buf );
- rtl::OString oStr = strBuf.makeStringAndClear();
-
- oStr = oStr.replaceAt( 0, optDsc->getName().getLength(),
- optDsc->getName() );
- if ( optDsc->isOptional() ) {
- oStr = oStr.replaceAt( frm.fCol-1, 1, "[" );
- }
- oStr = oStr.replaceAt( frm.fCol, optDsc->getLegend().getLength(),
- optDsc->getLegend() );
- if ( optDsc->isOptional() ) {
- oStr = oStr.replaceAt( frm.fCol + optDsc->getLegend().getLength() ,
- 1, "]" );
- }
- if ( ( frm.sCol + optDsc->getHint().getLength() ) >= frm.len ) {
-
- oStr = oStr.replaceAt( frm.sCol, frm.len - frm.sCol,
- optDsc->getHint() );
- }
- else {
- oStr = oStr.replaceAt( frm.sCol,
- optDsc->getHint().getLength(), optDsc->getHint() );
- }
-
- delete [] buf;
-
- return oStr;
-
-} ///< optDsc2Str
-
-/**
- * private
- * returns the maximum length of all optionnames for format purposes
- * @param none
- * @return sal_uInt32 length of longest optionname
- */
-//> getMaxNameLength
-sal_uInt32 GetOpt::getMaxNameLength() {
-
- sal_Int32 len = 0;
- vector< OptDsc* >::iterator iter = m_optionset.begin();
-
- while ( iter != m_optionset.end() ) {
- if( len < (*iter)->getName().getLength() ){
- len = (*iter)->getName().getLength();
- }
- iter++;
- }
- return len;
-} ///< getMaxNameLength
-
-/**
- * private
- * returns the maximum length of all option legends for format purposes
- * @param none
- * @return sal_uInt32 length of longest optionlegend
- */
-//> getMaxLegendLength
-sal_uInt32 GetOpt::getMaxLegendLength() {
-
- sal_Int32 len = 0;
- vector< OptDsc* >::iterator iter = m_optionset.begin();
-
- while ( iter != m_optionset.end() ) {
- if( len < (*iter)->getLegend().getLength() ){
- len = (*iter)->getLegend().getLength();
- }
- iter++;
- }
- return len;
-
-} ///< getMaxLegendLength
-
-/**
- * public
- * reads the filecontent and pass it to str2opt to add valid options
- * to optionhash
- * @param rtl::OString iniPth = full qualified filename
- * @return ::osl::FileBase::RC = to indicate errors
- */
-//> getIniOptions
-::osl::FileBase::RC GetOpt::getIniOptions( rtl::OString iniPth ) {
-
- ::osl::FileStatus fState( FileStatusMask_All );
- ::osl::DirectoryItem dItem;
- rtl::OUString nrmPath( FileHelper::convertPath( iniPth ) );
-
- ::osl::DirectoryItem::get( nrmPath, dItem );
- dItem.getFileStatus( fState );
- rtl::OUString fName( fState.getFileURL() );
- ::osl::File iniFile( fName );
-
- const sal_uInt32 filesize = (sal_uInt32)fState.getFileSize();
-
- ::osl::FileBase::RC ret;
- sal_uInt64 bytesread;
-
- if ( ( ret = iniFile.open( OpenFlag_Read ) ) != ::osl::FileBase::E_None ) {
- return ret;
- }
- char* buf = new char[ filesize + 1 ];
- ret = iniFile.read( buf, filesize, bytesread );
- buf[ filesize ] = '\0';
-
- str2Opt( buf );
- delete [] buf;
- return ret;
-
-} ///< getIniOptions
-
-/**
- * private
- * tokenize a string in dependance of a character set and stores the tokens
- * to a token vector
- * @param const rtl::OString& opt = optionstring to tokenize
- * @param const rtl::OString& cSet = characterset of delimiters
- * @param vector< rtl::OString >& optLine = vector of tokens
- * @param sal_Bool strip = indicates if CR,LF and TAB should be stripped off
- * the token
- * @return void
- */
-//> tokenize
-void GetOpt::tokenize( const rtl::OString& opt, const rtl::OString& cSet,
- vector< rtl::OString >& optLine, sal_Bool strip ) {
-
- const sal_Char* pText; // pointer f. text,
- const sal_Char* pcSet; // charset and
- vector< const sal_Char* > delimVec; // vector of delimiters
-
- // parametercheck for opt ...
- if( ! opt.getLength() ) {
- return;
- }
- // ... and charSet
- if( ! cSet.getLength() ) {
- return;
- }
- // pointer to begin of textinstance
- pText = opt.getStr();
-
- // text
- while( *pText ) {
- // charset-pointer to begin of charset
- pcSet = cSet.getStr();
- // charset
- while( *pcSet ) {
- // delimiter found
- if( ( ( *pText == *pcSet ) ) && ( pText != opt ) ) {
- delimVec.push_back( pText );
- // increment counter
- }
- pcSet++;
- }
- // increment pointer
- pText++;
- }
-
- // save endpointer
- delimVec.push_back( opt + opt.getLength() );
-
- sal_Char* pToken; // ptr to token chars
- const sal_Char* pBegin; // ptr to begin of current,
- const sal_Char* pEnd=opt; // and begin of prev. token
- sal_uInt32 i=0;
-
- while ( pEnd < delimVec[delimVec.size()-1] ) {
-
- pBegin = pEnd;
- if( pBegin > opt.getStr() ) {
- pBegin += 1;
- }
- pEnd = delimVec[i];
- // initialize size
- sal_uInt32 nSize = pEnd - pBegin;
- // allocate memory
-
- // allocate memory for token
- sal_Char* cToken = new sal_Char[ nSize + 1 ];
-
- // get address of allocated memory
- pToken = cToken;
-
- // copy token from text
- sal_uInt32 j;
- for ( j = 0; j < nSize ; ++j ) {
- *pToken++ = *pBegin++;
- }
- // append string end
- *pToken = '\0';
-
- rtl::OString oTok(cToken);
-
- if( strip ) {
- // strip off CR,LF and TAB
- oTok = oTok.replace( 0x0a, 0x20 );
- oTok = oTok.replace( 0x0d, 0x20 );
- oTok = oTok.replace( 0x09, 0x20 );
- oTok = oTok.trim();
- }
- if( oTok != "" ) {
- // push to vector
- optLine.push_back( oTok );
- }
-
- // free memory where cToken points to
- delete [] cToken;
- i++;
- }
- return ;
-} ///< tokenize
-
-// -----------------------------------------------------------------------------
-rtl::OString& GetOpt::getOpt( const rtl::OString& opt )
-{
- if (m_opthash.find( opt ) != m_opthash.end())
- {
- if (!m_opthash[opt].empty())
- {
- return *( m_opthash[opt].begin() );
- }
- rtl::OString aStr;
- aStr = "GetOpt( ";
- aStr += opt;
- aStr += " ): Value not found.";
- throw ValueNotFoundException(aStr.getStr());
- }
- else
- throw ValueNotFoundException(opt);
-}
-
-
-// -----------------------------------------------------------------------------
-
-Exception::Exception()
- : m_sAsciiMessage()
-{
-}
-//---------------------------------------------------------------------
-Exception::Exception(char const* sAsciiMessage)
- : m_sAsciiMessage(sAsciiMessage)
-{
-}
-//---------------------------------------------------------------------
-Exception::Exception(rtl::OString const& sAsciiMessage)
- : m_sAsciiMessage(sAsciiMessage)
-{
-}
-//---------------------------------------------------------------------
-
-rtl::OUString Exception::message() const
-{
- return rtl::OStringToOUString( m_sAsciiMessage, RTL_TEXTENCODING_ASCII_US );
-}
-//---------------------------------------------------------------------
-char const* Exception::what() const
-{
- return m_sAsciiMessage.getLength() ? m_sAsciiMessage.getStr() : "FAILURE in REGSCAN: No description available";
-}
-
-// -----------------------------------------------------------------------------
-static const char c_sValueNotFoundException[] = "GetOpt: Value not Found Exception: ";
-//---------------------------------------------------------------------
-ValueNotFoundException::ValueNotFoundException()
- : Exception( rtl::OString(RTL_CONSTASCII_STRINGPARAM(c_sValueNotFoundException)) )
-{
-}
-//---------------------------------------------------------------------
-
-ValueNotFoundException::ValueNotFoundException(char const* sException)
- : Exception( rtl::OString(RTL_CONSTASCII_STRINGPARAM(c_sValueNotFoundException)) + sException)
-{
-}
-
-
-
diff --git a/testshl2/source/makefile.mk b/testshl2/source/makefile.mk
deleted file mode 100644
index 86a6dc2ca1bc..000000000000
--- a/testshl2/source/makefile.mk
+++ /dev/null
@@ -1,130 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..
-
-PRJNAME=testshl2
-TARGET=testshl2
-TARGETTYPE=CUI
-PRJINC=.
-
-ENABLE_EXCEPTIONS=TRUE
-#USE_LDUMP2=TRUE
-#LDUMP2=LDUMP3
-
-# --- Settings -----------------------------------------------------
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-
-COMMON_OBJFILES=\
- $(OBJ)$/getopt.obj \
- $(OBJ)$/filehelper.obj \
- $(OBJ)$/dynamicregister.obj
-
-TESTSHL_OBJFILES=\
- $(OBJ)$/autoregisterhelper.obj \
- $(OBJ)$/testshl.obj
-
-VERSIONINFO_OBJFILES=\
- $(OBJ)$/versionhelper.obj \
- $(OBJ)$/versioner.obj
-
-BMSMA_OBJFILES=\
- $(OBJ)$/bmsma.obj
-
-# for right dependencies
-# OBJFILES= $(COMMON_OBJFILES) $(TESTSHL_OBJFILES) $(VERSIONINFO_OBJFILES)
-
-# ------------------------------------------------------------------
-APP1TARGET= $(TARGET)
-APP1OBJS= $(COMMON_OBJFILES) $(TESTSHL_OBJFILES)
-APP1RPATH=NONE
-
-APP1STDLIBS=$(SALLIB)
-
-.IF "$(GUI)" == "WNT"
-.IF "$(COM)" == "GCC"
-APP1STDLIBS+= \
- $(SOLARLIBDIR)$/libcppunit$(DLLPOSTFIX).a \
- $(LB)$/libc5t_testresult$(DLLPOSTFIX).a \
- $(LB)$/libc5t_no_regallfkt$(DLLPOSTFIX).a \
- $(LB)$/libc5t_winstuff$(DLLPOSTFIX).a
-.ELSE
-APP1LIBS= \
- $(SOLARLIBDIR)$/cppunit.lib \
- $(LB)$/c5t_testresult.lib \
- $(LB)$/c5t_no_regallfkt.lib \
- $(LB)$/c5t_winstuff.lib
-.ENDIF
-.ENDIF
-
-.IF "$(GUI)" == "OS2"
-APP1LIBS= \
- $(SOLARLIBDIR)$/cppunit.lib \
- $(LB)$/c5t_no_regallfkt.lib \
- $(LB)$/c5t_testresult.lib
-.ENDIF
-
-.IF "$(GUI)" == "UNX"
-APP1STDLIBS+= \
- $(LB)$/libc5t_testresult$(DLLPOSTFIX).a \
- $(LB)$/libc5t_no_regallfkt$(DLLPOSTFIX).a \
- $(SOLARLIBDIR)$/libcppunit$(DLLPOSTFIX).a
-.ENDIF
-
-#
-# ------------------------------------------------------------------
-APP2TARGET= versioninfo
-APP2OBJS= $(COMMON_OBJFILES) $(VERSIONINFO_OBJFILES)
-
-APP2STDLIBS=$(SALLIB)
-
-APP2DEPN=
-APP2LIBS=
-
-# ------------------------------------------------------------------
-APP3TARGET= $(TARGET)_timeout
-APP3OBJS= $(OBJ)$/getopt.obj $(OBJ)$/filehelper.obj $(OBJ)$/terminate.obj
-
-APP3STDLIBS=$(SALLIB)
-
-APP3DEPN=
-APP3LIBS=
-
-.IF "$(GUI)" == "WNT"
-.IF "$(COM)" == "GCC"
-APP3STDLIBS+= \
- $(LB)$/libc5t_winstuff$(DLLPOSTFIX).a
-.ELSE
-APP3LIBS += $(LB)$/c5t_winstuff.lib
-.ENDIF
-.ENDIF
-
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/testshl2/source/terminate.cxx b/testshl2/source/terminate.cxx
deleted file mode 100644
index fcc9f75f83f0..000000000000
--- a/testshl2/source/terminate.cxx
+++ /dev/null
@@ -1,289 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#ifdef SOLARIS
-#include <sys/time.h>
-#include <sys/types.h>
-#endif
-
-#include <signal.h>
-
-#include <iostream>
-#include <string>
-
-#include "testshl/getopt.hxx"
-
-#if (defined UNX) || (defined OS2)
-#include <unistd.h> /* usleep */
-#include <sys/types.h>
-#include <signal.h>
-#endif
-
-#ifdef WNT
-# include "testshl/winstuff.hxx"
-#endif
-
-using namespace std;
-
-// -----------------------------------------------------------------------------
-class ProcessHandler
-{
- std::string m_sProcessIDFilename;
- int m_nPID;
-
- int getPID();
- int readPIDFromFile();
- void sendSignal(int _nPID);
- void write(int);
-public:
- ProcessHandler();
- void setName(std::string const& _sFilename);
-
- ~ProcessHandler();
-
- void waitForPIDFile(int);
- void waitForTimeout(int);
-};
-
-void my_sleep(int sec)
-{
-#ifdef WNT
- WinSleep(sec * 1000);
-#else
- usleep(sec * 1000000); // 10 ms
-#endif
-}
-
-// ------------------------------- ProcessHelper -------------------------------
-ProcessHandler::ProcessHandler():m_nPID(0) {}
-
-void ProcessHandler::setName(std::string const& _sPIDFilename)
-{
- m_sProcessIDFilename = _sPIDFilename;
-}
-
-int ProcessHandler::getPID()
-{
- return m_nPID;
-}
-
-int ProcessHandler::readPIDFromFile()
-{
- // get own PID
- int nPID = 0;
- if (m_sProcessIDFilename.size() > 0)
- {
- FILE* in;
- in = fopen(m_sProcessIDFilename.c_str(), "r");
- if (!in)
- {
- // fprintf(stderr, "warning: (testshl.cxx) can't read own pid.\n");
- return 0;
- // exit(0);
- }
- // if file exist, wait short, maybe the other tool writes it down.
- if (fscanf(in, "%d", &nPID) != 1)
- {
- // fprintf(stderr, "warning: (testshl.cxx) can't read own pid.\n");
- fclose(in);
- return 0;
- // exit(0);
- }
- fclose(in);
- }
- else
- {
- fprintf(stderr, "error: (terminate.cxx) PID Filename empty, must set.\n");
- exit(0);
- }
- return nPID;
-}
-
-ProcessHandler::~ProcessHandler()
-{
-}
-
-void ProcessHandler::sendSignal(int _nPID)
-{
- if (_nPID != 0)
- {
-#ifdef WNT
- WinTerminateApp(_nPID, 100);
-#else
- kill(_nPID, SIGKILL);
-#endif
- }
-}
-
-// -----------------------------------------------------------------------------
-void ProcessHandler::waitForPIDFile(int _nTimeout)
-{
- int nWaitforTimeout = _nTimeout;
- while (getPID() == 0 && nWaitforTimeout > 0)
- {
- int nPID = readPIDFromFile();
- if (nPID != 0)
- {
- m_nPID = nPID;
- break;
- }
-
- my_sleep(1);
- fprintf(stderr, "wait for pid file\n");
- nWaitforTimeout--;
- }
-
- if (nWaitforTimeout <= 0)
- {
- fprintf(stderr, "No PID found, time runs out\n");
- exit(1);
- }
-}
-// -----------------------------------------------------------------------------
-void ProcessHandler::waitForTimeout(int _nTimeout)
-{
- int nTimeout = _nTimeout;
- while (nTimeout > 0)
- {
- my_sleep(1);
- fprintf(stderr, "%d \r", nTimeout);
-
- int nNewPID = readPIDFromFile();
- if ( nNewPID != getPID() )
- {
- fprintf(stderr, "PID has changed.\n");
- if ( nNewPID != 0)
- {
- fprintf(stderr, "new PID is not 0, maybe forgotten to delete old PID file, restart timeout.\n");
- m_nPID = nNewPID;
- nTimeout = _nTimeout;
- }
- else
- {
- break;
- }
- }
- nTimeout --;
- }
- if (nTimeout <= 0)
- {
- fprintf(stderr, "PID: %d\n", getPID());
- sendSignal(getPID());
- write(0);
- }
-}
-
-void ProcessHandler::write(int _nPID)
-{
- // get own PID
-
- if (m_sProcessIDFilename.size() > 0)
- {
- FILE* out;
- out = fopen(m_sProcessIDFilename.c_str(), "w");
- if (!out)
- {
- fprintf(stderr, "warning: (testshl.cxx) can't write own pid.\n");
- return;
- // exit(0);
- }
- fprintf(out, "%d", _nPID);
- fclose(out);
- }
- else
- {
- fprintf(stderr, "warning: (testshl.cxx) PID Filename empty, must set.\n");
- }
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int, char* argv[] )
-#else
-int _cdecl main( int, char* argv[] )
-#endif
-{
- static char const * optionSet[] = {
- "-version, shows current program version and exit.",
- "-pid=s, write current process id to file",
- "-time=s, timeout [default is 10 sec]",
- "-h:s, display help or help on option",
- "-help:s, see -h",
- NULL
- };
-
- ProcessHandler aCurrentProcess;
-
- GetOpt opt( argv, optionSet );
- if ( opt.hasOpt("-pid") )
- {
- aCurrentProcess.setName(opt.getOpt("-pid").getStr());
- }
-
- int nTimeout = 10;
- if ( opt.hasOpt("-time"))
- {
- //
- nTimeout = opt.getOpt("-time").toInt32();
- if (nTimeout == 0)
- {
- nTimeout = 10;
- }
- }
-
- if ( opt.hasOpt("-version") )
- {
- fprintf(stderr, "testshl2_timeout $Revision: 1.9 $\n");
- exit(0);
- }
-
- // someone indicates that he needs help
- if ( opt.hasOpt( "-h" ) || opt.hasOpt( "-help" ) )
- {
- opt.showUsage();
- exit(0);
- }
-
- // wait until pid file exist ==============================
-
- aCurrentProcess.waitForPIDFile(10);
-
- printf("Found PID file, wait for timeout %d sec.\n", nTimeout);
-
- // timeout ==================================================
- aCurrentProcess.waitForTimeout(nTimeout);
-
- return 0;
-}
-
diff --git a/testshl2/source/testshl.cxx b/testshl2/source/testshl.cxx
deleted file mode 100644
index 22b90a0f7002..000000000000
--- a/testshl2/source/testshl.cxx
+++ /dev/null
@@ -1,396 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#ifdef SOLARIS
-#include <sys/time.h>
-#endif
-
-#ifdef WNT
-# include "testshl/winstuff.hxx"
-#endif
-
-#include <iostream>
-#include <vector>
-#include <memory> /* auto_ptr */
-#include "sal/main.h"
-#include <rtl/string.hxx>
-
-// #include <rtl/tres.h>
-#include "testshl/autoregisterhelper.hxx"
-// #include "cmdlinebits.hxx"
-#include "testshl/log.hxx"
-#include "testshl/filehelper.hxx"
-#include "testshl/getopt.hxx"
-#include "testshl/result/outputter.hxx"
-#include "testshl/joblist.hxx"
-
-// #include <osl/time.h>
-
-using namespace std;
-
-#include "testshl/result/testshlTestResult.h"
-#include "testshl/result/emacsTestResult.hxx"
-
-// Prototype for signal handling
-void setSignalFilename(GetOpt & opt);
-void removeSignalFile(GetOpt & opt);
-CmdLineBits st_nBits;
-
-void initTPrint(GetOpt & _aOptions)
-{
- st_nBits = FileHelper::createFlags(_aOptions);
-}
-
-void my_sleep(int nCount)
-{
-#ifdef WNT
- WinSleep(nCount * 2);
-#else
- usleep(nCount * 2000);
-#endif
-}
-
-// -----------------------------------------------------------------------------
-class ProcessHandler
-{
- std::string m_sProcessIDFilename;
- void write(int);
- int getPID();
-public:
- ProcessHandler();
- void setName(std::string const& _sFilename);
- ~ProcessHandler();
-};
-
-// ------------------------------- ProcessHelper -------------------------------
-ProcessHandler::ProcessHandler() {}
-
-void ProcessHandler::setName(std::string const& _sPIDFilename)
-{
- m_sProcessIDFilename = _sPIDFilename;
- write(getPID());
-}
-
-int ProcessHandler::getPID()
-{
- int nPID = 0;
-#ifdef WNT
- nPID = WinGetCurrentProcessId();
-#else
- nPID = getpid();
-#endif
-
- return nPID;
-}
-
-void ProcessHandler::write(int _nPID)
-{
- // get own PID
-
- if (m_sProcessIDFilename.size() > 0)
- {
- FILE* out;
- out = fopen(m_sProcessIDFilename.c_str(), "w");
- if (!out)
- {
- fprintf(stderr, "warning: (testshl.cxx) can't write own pid.\n");
- return;
- // exit(0);
- }
- fprintf(out, "%d", _nPID);
- fclose(out);
- my_sleep(2); // short wait, so testshl2_timeout can find this pid.
- }
- else
- {
- fprintf(stderr, "warning: (testshl.cxx) PID Filename empty, must set.\n");
- }
-}
-
-ProcessHandler::~ProcessHandler()
-{
- if (m_sProcessIDFilename.size() > 0)
- {
- write(0);
- my_sleep(2);
- fprintf(stderr, "hint: it is save to remove PID file.\n");
- }
-}
-
-// -----------------------------------------------------------------------------
-std::auto_ptr<CppUnit::TestResult> initResult(GetOpt & _aOptions)
-{
- std::auto_ptr<CppUnit::TestResult> pResult;
- if (_aOptions.hasOpt("-mode"))
- {
- if (_aOptions.getOpt("-mode").equals("emacs") == sal_True)
- {
- pResult.reset(new CppUnit::emacsTestResult(_aOptions));
- }
- }
- else
- {
- pResult.reset(new CppUnit::testshlTestResult(_aOptions));
- }
- return pResult;
-}
-
-// -----------------------------------------------------------------------------
-
-std::auto_ptr<Outputter> initOutputter(GetOpt & _aOptions)
-{
- std::auto_ptr<Outputter> pOutputter;
-
- if (_aOptions.hasOpt("-log"))
- {
- rtl::OString sLogFile = _aOptions.getOpt("-log");
-
- Log* pLog = new Log( FileHelper::convertPath( sLogFile ) );
- if ( pLog->open() != osl::FileBase::E_None )
- {
- // cerr << "could not open LogFile: " << pLog->getName().getStr() << endl;
- fprintf(stderr, "could not open LogFile: %s\n", pLog->getName().getStr());
- exit(1);
- }
- pOutputter.reset(new Outputter(pLog));
- }
- else
- {
- pOutputter.reset(new Outputter(std::cout));
- }
-
- return pOutputter;
-}
-
-int starttest(GetOpt & opt, AutomaticRegisterHelper const& aHelper);
-
-void makeslow()
-{
- sal_Int32 n = 0;
- for (sal_Int32 i=0;i<1024 * 1024;i++)
- {
- ++n;
- }
-}
-// void endless()
-// {
-// sal_Int64 n = 0;
-// while(1)
-// {
-// n++;
-// makeslow();
-// my_sleep(1);
-// }
-// }
-
-// ----------------------------------- Main -----------------------------------
-
-SAL_IMPLEMENT_MAIN_WITH_ARGS(, argv)
-{
- static char const * optionSet[] = {
- "-boom, stop near error position, exception only",
- "-mode=s, the output mode, emacs, xml, old. Default is -mode old",
- "-log=s, destination file for logging",
- "-noerrors, shows all tests, but not it's errors.",
- "-onlyerrors, shows only the failed test functions",
-/* "-tc=s@, name(s) of testcase(s) to generate", */
- "-sf=s, absolute path and name to the signal file.",
-//! new (helpful if at debug time)
- "-dntsf, if given, do not touch signal file, also if one exist.",
- "-dnrmsf, do not remove signalfile. ",
- "-jobonly=s, job control file, these jobs should only executed.",
- "-jobexclude=s, job control file, but contains only job, they not execute.",
- "-jobfilter=s, use a filter for just some tests.",
- "-onlyshowjobs, show only all jobs, do no tests.",
- "-forward=s, this string will forwarded to the test libraries.",
- "-projectid=s, this text is added to the date output line.",
- "-buildid=s, this text is added to the date output line.",
- "-waitforkey, wait until key pressed.",
- "-verbose, be verbose.",
- "-quiet, be quiet. No t_print(...) will create output.",
- "-pid=s, write current process id to file",
- "-endless, testshl runs endless, for test only!!!",
- "-whereami, shows at runtime, which function is tested next.",
- "-noerroronexit, if this is given the program exits with return code 0 even if runtime errors occurs.",
- "-hardexit, Exit the tests without call any dtor.",
- "-absolutepath, Use the given absolute path to local the test library.",
- "-localpath, Make a chdir() to the test library path, then try to load the library without given path.",
- "-h:s, display help or help on option",
- "-help:s, see -h",
- NULL
- };
-
- ProcessHandler aCurrentProcess;
-
- GetOpt opt( argv, optionSet );
- initTPrint(opt);
-
- if ( opt.hasOpt("-pid") )
- {
- aCurrentProcess.setName(opt.getOpt("-pid").getStr());
- }
-
- if ( opt.hasOpt("-verbose") )
- {
- fprintf(stderr, "testshl2 $Revision: 1.25 $\n");
- }
-
- if ( opt.hasOpt("-endless")) // this exists only for self test issues
- {
-// endless();
-
-// With parameter -endless a test is attachable by debuggers
-// Attach to testshl2.exe set a breakpoint in this while (1) loop
-
-// Then you have to set the process pointer (Set next Statement) to
-// the next line outside the while loop.
-// Now it is possible to debug the whole code.
-// Never source this code to a function, because you will
-// lost the variables like opt.
-
- sal_Int64 n = 0;
- while(1)
- {
- n++;
- makeslow();
- my_sleep(1);
- }
- }
-
- int nExitCode = 0;
- bool bLibrary = true;
-
- // someone indicates that he needs help
- if ( opt.hasOpt( "-h" ) || opt.hasOpt( "-help" ) )
- {
- opt.showUsage();
- nExitCode = 0;
- }
- else
- {
- if (opt.getParams().empty())
- {
- // no library is given, but if a jobonly list is given, we should generate UNKNOWN errors.
- if (! opt.hasOpt("-jobonly"))
- {
- // std::cerr << "error: At least a library or a job file should given." << std::endl;
- fprintf(stderr, "error: At least a library or a job file should given.\n");
- opt.showUsage();
- nExitCode = 2;
- }
- else
- {
- bLibrary = false;
- }
- }
- else
- {
- setSignalFilename(opt);
-
- rtl::OUString suLibraryName;
- if (bLibrary)
- {
- suLibraryName = rtl::OStringToOUString(opt.getFirstParam(), osl_getThreadTextEncoding() /* RTL_TEXTENCODING_ASCII_US */ );
- }
-
- AutomaticRegisterHelper aHelper(suLibraryName, opt /*, &aJobs*/);
-
- if (aHelper.isOkToStartTests())
- {
- // start the tests
- nExitCode = starttest(opt, aHelper);
- }
- else
- {
-
- fprintf(stderr, "error: The library '%s' can't initialised, must quit.\n", opt.getFirstParam().getStr());
- nExitCode = 1;
- }
- }
- }
-
- if (opt.hasOpt("-noerroronexit"))
- {
- nExitCode = 0;
- }
- return nExitCode;
-}
-
-// -----------------------------------------------------------------------------
-// this function is only inserted to give a better startpoint for breakpoints
-
-int starttest(GetOpt & _opt, AutomaticRegisterHelper const& aHelper)
-{
- // create a TestResult
- std::auto_ptr<CppUnit::TestResult> pResult = initResult(_opt);
-
- // call all test functions
- aHelper.CallAll(pResult.get());
-
- // create and open log
- std::auto_ptr<Outputter> pOutput = initOutputter(_opt);
-
- // give the output
- pResult->print(*pOutput.get());
-
- // this is a debug extension, so you can read the output and after a key is pressed the program will end.
- if (_opt.hasOpt("-waitforkey"))
- {
- fprintf(stderr, "Press return key.");
- fflush(stderr);
- getchar();
- }
-
- if (_opt.hasOpt("-verbose"))
- {
- fprintf(stderr, "Remove signal handlers");
- }
-
- removeSignalFile(_opt);
-
- if (_opt.hasOpt("-verbose"))
- {
- fprintf(stderr, " [done]\n");
- }
-
- if (_opt.hasOpt("-hardexit"))
- {
- fprintf(stderr, "Hardexit forced.\n");
- abort();
- }
-
- int nExit = pResult->getExitValue();
- return nExit;
-}
-
diff --git a/testshl2/source/testshlrunner/ProcessHandler.java b/testshl2/source/testshlrunner/ProcessHandler.java
deleted file mode 100644
index 373b482d7825..000000000000
--- a/testshl2/source/testshlrunner/ProcessHandler.java
+++ /dev/null
@@ -1,355 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-import java.io.InputStream;
-import java.io.File;
-import java.io.FileFilter;
-import java.util.ArrayList;
-import java.io.PrintWriter;
-import java.io.PrintStream;
-import java.io.LineNumberReader;
-import java.io.InputStreamReader;
-import java.io.OutputStreamWriter;
-
-/**
- * Class collect information from input stream in
- * background (sparate thread) and outputs it to
- * some log stream. I helps to avoid buffer overflow
- * when output stream has small buffer size (e.g.
- * in case when handling stdout from external
- * <code>Process</code>)
- *
- * This class is currently used by ProcesHandler
- * internally only.
- */
-class Pump extends Thread {
- private LineNumberReader reader;
- private String pref ;
- private Pump thread ;
- private StringBuffer buf = new StringBuffer(256);
- private PrintWriter log ;
-
- /**
- * Creates Pump for specified <code>InputStream</code>.
- * This Pump also synchronously output text read to
- * log by prefixed lines. Constructor immediately
- * starts reading in a separate thread.
- *
- * @param is Stream which requires permanent reading.
- * @param log Writer where prefixed text lines to be output
- * @param outPrefix A prefix which is printed at the
- * beginning of each output line.
- */
- public Pump(InputStream is, PrintWriter log, String outPrefix) {
- this.pref = outPrefix == null ? "" : outPrefix ;
- reader = new LineNumberReader(new InputStreamReader(is));
- this.log = log ;
- start() ;
- }
-
- public void run() {
- try {
- String line = reader.readLine() ;
- while (line != null) {
- log.println(pref + line);
- log.flush();
- buf.append(line).append('\n');
- line = reader.readLine() ;
- }
- } catch (java.io.IOException e) {
- log.println(pref + "Exception occured: " + e) ;
- }
- }
-
- /**
- * Returns the text collected from input stream.
- */
- public String getStringBuffer() {
- return buf.toString();
- }
-}
-
-/**
- * Class provides convenient way for running external program
- * handle its standard streams, control execution and check results.
- * Instance of this class must be created only for a single
- * execution. If you need to execute the same command again you
- * should create a new instance for this.
- */
-public class ProcessHandler {
- private String cmdLine;
- private String[] envVars = null;
- private File workDir = null;
- private PrintWriter log;
-
- private int exitValue = -1;
- private boolean isFinished = false;
- private boolean isStarted = false;
-
- private String stdInBuff = "";
- private Pump stdout = null ;
- private Pump stderr = null ;
- private PrintStream stdIn = null ;
-
- private Process proc = null ;
-
- /**
- * Creates instance with specified external command and
- * log stream where debug info is printed and output
- * of external command.
- */
- public ProcessHandler(String cmdLine, PrintWriter log) {
- this(cmdLine, log, null, null);
- }
- /**
- * Creates instance with specified external command.
- * Debug info and output
- * of external commandis printed to stdout.
- */
- public ProcessHandler(String cmdLine) {
- this(cmdLine, null, null, null);
- }
- /**
- * Creates instance with specified external command which
- * will be executed in the some work directory and
- * log stream where debug info and output
- * of external command is printed .
- * The specified environment variables are set for the new process.
- * If log stream is null, logging is printed to stdout.
- */
- public ProcessHandler(String cmdLine, PrintWriter log,
- File workDir, String[] envVars) {
- this.cmdLine = cmdLine ;
- this.workDir = workDir;
- this.log = log;
- this.cmdLine = cmdLine ;
- this.envVars = envVars;
- if (log == null)
- this.log = new PrintWriter(new OutputStreamWriter(System.out));
- else
- this.log = log;
- }
- /**
- * Creates instance with specified external command which
- * will be executed in the some work directory.
- * Debug info and output
- * of external commandis printed to stdout.
- */
- public ProcessHandler(String cmdLine, File workDir) {
- this(cmdLine, null, workDir, null);
- }
-
- /**
- * Executes the command and returns only when the process
- * exits.
- *
- * @return <code>true</code> if process was successfully
- * started and correcly exits (exit code doesn't affect
- * to this result).
- */
- public boolean executeSynchronously() {
- execute() ;
- return waitFor() ;
- }
-
- /**
- * Executes the command immediately returns. The process
- * remains in running state. Control of its state should
- * be made by <code>waitFor</code> methods.
- *
- * @return <code>true</code> if process was successfully
- * started.
- */
- public boolean executeAsynchronously() {
- execute() ;
- return isStarted() ;
- }
-
- public void kill() {
- if (!isStarted()) return;
- proc.destroy();
- isStarted = false;
- }
-
- protected void execute() {
- if (isStarted()) {
- throw new RuntimeException(
- "The process handler has already been executed.") ;
- }
- Runtime runtime = Runtime.getRuntime() ;
- try {
- log.println("Starting command: " + cmdLine) ;
- if (workDir != null) {
- proc = runtime.exec(cmdLine, envVars, workDir) ;
- } else {
- proc = runtime.exec(cmdLine, envVars) ;
- }
-
- isStarted = true ;
- } catch (java.io.IOException e) {
- log.println("The command "+cmdLine+" can't be started: " + e);
- return;
- }
- stdout = new Pump(proc.getInputStream(), log, "out > ");
- stderr = new Pump(proc.getErrorStream(), log, "err > ");
- stdIn = new PrintStream(proc.getOutputStream()) ;
-
- flushInput() ;
- }
-
- /**
- * This method is useful when the process was executed
- * asynchronously. Waits for process to exit and return
- * its result.
- *
- * @return <code>true</code> if process correctly exited
- * (exit code doesn't affect to this result).
- */
- public boolean waitFor() {
- return waitFor(0) ;
- }
-
- /**
- * This method is useful when the process was executed
- * asynchronously. Waits during specified time for process
- * to exit and return its status.
- *
- * @return <code>true</code> if process correctly exited
- * (exit code doesn't affect to this result).
- */
- public boolean waitFor(long timeout) {
- if (isFinished()) return true ;
- if (!isStarted()) return false ;
-
- if (timeout == 0) {
- try {
- proc.waitFor() ;
- } catch (InterruptedException e) {
- log.println("The process was interrupted: " + e);
- }
- isFinished = true ;
- try {
- exitValue = proc.exitValue() ;
- } catch (IllegalThreadStateException e) {}
- } else {
- try {
- while (!isFinished && timeout > 0) {
- isFinished = true ;
- Thread.sleep(1000);
- timeout -= 1000 ;
- try {
- exitValue = proc.exitValue() ;
- } catch (IllegalThreadStateException e) {
- isFinished = false ;
- }
- }
- } catch (InterruptedException ex) {
- log.println("The process was interrupted: " + ex);
- }
- }
-
- if (!isFinished) {
- proc.destroy();
- }
-
- try {
- stdout.join();
- stderr.join();
- } catch (InterruptedException e) {}
-
- return isFinished() ;
- }
-
- protected void flushInput() {
- if (stdIn == null) return ;
-
- synchronized(stdInBuff) {
- stdIn.print(stdInBuff);
- stdIn.flush();
- stdInBuff = "" ;
- }
- }
-
- /**
- * Returns the text output by external command to stdout.
- */
- public String getOutputText() {
- return stdout.getStringBuffer();
- }
- /**
- * Returns the text output by external command to stderr.
- */
- public String getErrorText() {
- return stderr.getStringBuffer();
- }
-
- /**
- * Prints the string specified to sdtin of external
- * command. '\n' is not added so if you need you
- * should terminate the string with '\n'. <p>
- *
- * The method can also be called before the command
- * starts its execution. Then the text is buffered
- * and transfered to command when it will be started.
- */
- public void printInputText(String str) {
- stdInBuff += str ;
- flushInput();
- }
-
- /**
- * Returns information about was the command started or
- * not.
- *
- * @return <code>true</code> if the external command was
- * found and successfully started.
- */
- public boolean isStarted() {
- return isStarted ;
- }
-
- /**
- * Returns the information about the final state of command
- * execution.
- *
- * @return <code>true</code> if the command correctly starts,
- * exits and was not interrupted due to timeout.
- */
- public boolean isFinished() {
- return isFinished ;
- }
-
- /**
- * Returns exit code of the external command.
- *
- * @return exit code of command if it was finished,
- * -1 if not.
- */
- public int getExitCode() {
- return exitValue ;
- }
-}
diff --git a/testshl2/source/testshlrunner/TestShl2Runner.java b/testshl2/source/testshlrunner/TestShl2Runner.java
deleted file mode 100644
index 295648121042..000000000000
--- a/testshl2/source/testshlrunner/TestShl2Runner.java
+++ /dev/null
@@ -1,937 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// package main;
-
-import java.io.File;
-import java.io.FileWriter;
-import java.io.RandomAccessFile;
-import java.io.PrintWriter;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.ArrayList;
-
-import java.sql.Connection;
-import java.sql.DriverManager;
-import java.sql.Statement;
-import java.sql.ResultSet;
-
-import java.util.HashMap;
-import java.util.Set;
-import java.util.Iterator;
-import java.util.Properties;
-
-import java.io.FileInputStream;
-
-// -----------------------------------------------------------------------------
-/**
- * This class offers helper function, to easily connect to a database
- * delete values and insert values.
- */
-
-class PropertyHelper
-{
- public static Properties getProperties(String name)
- {
- Properties prop = new Properties();
- FileInputStream propFile = null;
- try {
- propFile = new FileInputStream(name);
- prop.load(propFile);
- propFile.close();
- } catch (Exception e) {
- e.printStackTrace();
- }
- return prop;
- }
-
- public static void setProperties(Properties prop, String name) {
- FileOutputStream propFile = null;
- try {
- propFile = new FileOutputStream(name);
- prop.store(propFile,"");
- propFile.close();
- } catch (Exception e) {
- e.printStackTrace();
- }
- }
-}
-
-class DBHelper
-{
- /**
- * This method inserts given values into<br>
- * the table 'states'
- * @param values a set of comma separated values to be inserted
- */
-
- public static void SQLinsertValues(String values)
- {
- Statement oStmt = null;
- Connection oCon = null;
- try
- {
- oCon = getMySQLConnection();
- oStmt = oCon.createStatement();
- ResultSet oResult = oStmt.executeQuery("insert into states values ("
- + values + ")");
- }
- catch(Exception e)
- {
- System.out.println("Couldn't insert values to db");
- e.printStackTrace();
- } finally
- {
- try
- {
- oCon.close();
- oCon = null;
- }
- catch (Exception e) {}
- }
- }
- /**
- * This method establishes a Connection<br>
- * with the database 'module_unit' on jakobus
- */
-
- public static Connection getMySQLConnection() throws Exception
- {
- Class.forName("org.gjt.mm.mysql.Driver");
- Connection mysql = DriverManager.getConnection(
- "jdbc:mysql://jakobus:3306/module_unit","admin","admin");
- return mysql;
- }
- /**
- * This method removes all entries of the given<br>
- * module/platform combination
- * @param mdl the name of the module, e.g. sal
- * @param os the name of the platform, e.g. unxsols
- */
-
- public static void SQLdeleteValues(String _sModulName, String _sEnvironment)
- {
- Statement oStmt = null;
- Connection oCon = null;
- try
- {
- oCon = getMySQLConnection();
- oStmt = oCon.createStatement();
- ResultSet oResult = oStmt.executeQuery("delete from states where mdl='"
- + _sModulName + "' AND pf='" + _sEnvironment + "'");
- }
- catch(Exception e)
- {
- System.out.println("Couldn't delete values from db");
- }
- finally
- {
- try
- {
- oCon.close();
- oCon = null;
- }
- catch (Exception e) {}
- }
- }
-}
-
-// -----------------------------------------------------------------------------
-
-/**
- * This class helps to build only one output line if the classname and the methodname are the same.
- */
-
-class CurrentEntry
-{
- public String m_sDate;
- public String m_sClassName;
- public String m_sMethodName;
-
- ArrayList m_sMethodTestNames = new ArrayList();
- ArrayList m_sComments = new ArrayList();
- ArrayList m_sStates = new ArrayList();
-
- public String m_sCommentContainer = "";
-
- CurrentEntry()
- {}
-
- public String getState()
- {
- // build the right State
- String sAllIsRight = "PASSED#OK#";
- ArrayList sFailedStates = new ArrayList();
- boolean bFailed = false;
- for (int i=0; i<m_sStates.size();i++)
- {
- String sStatus = (String) m_sStates.get(i);
- if (!sStatus.equals(sAllIsRight))
- {
- bFailed = true;
- sFailedStates.add(sStatus);
- }
- }
- if (bFailed == false)
- {
- return "PASSED#OK#";
- }
-
- // interpret the failures
- return "PASSED#FAILED#";
- }
-
- public void add(String _sDate, String _sClassName, String _sMethodName, String _sMethodTestName, String _sState, String _sComment)
- {
- m_sDate = _sDate;
- m_sClassName = _sClassName;
- m_sMethodName = _sMethodName;
- m_sMethodTestNames.add(_sMethodTestName);
- m_sStates.add(_sState);
-
- if (_sComment.length() > 0)
- {
- String sComment = _sComment.replace('\'',' ');
-
- m_sComments.add(sComment);
-
- if (m_sCommentContainer.length() > 0)
- {
- m_sCommentContainer += ";<BR>";
- }
- m_sCommentContainer += _sMethodTestName + "(): " + _sComment;
- }
- }
-
-}
-// -----------------------------------------------------------------------------
-
-/**
- * HashMap Helper. At the moment classname and Methodname build a key value
- * if they already exist, we store additional information into the already existing value
- * if not, build an new entry.
- */
-
-class DatabaseEntry
-{
- HashMap aMap = new HashMap();
-
- public DatabaseEntry()
- {
- }
-
- public String Quote(String _sToQuote)
- {
- String ts = "'";
- return ts + _sToQuote + ts;
- }
-
- /**
- * Write down all collected lines into the database.
- */
- public void writeDown(String _sProjectName, String _sEnvironment)
- {
- System.out.println(" ");
- Set aSet = (Set)aMap.keySet();
- Iterator aIter = aSet.iterator();
- String sComma = ",";
-
- while (aIter.hasNext())
- {
- String sKey = (String)aIter.next();
- CurrentEntry aEntry = (CurrentEntry)aMap.get(sKey);
-
- String db_line= Quote(_sProjectName) + sComma +
- Quote( aEntry.m_sClassName) + sComma +
- Quote( aEntry.m_sMethodName) + sComma +
- Quote( aEntry.getState()) + sComma +
- Quote( _sEnvironment) + sComma +
- Quote( aEntry.m_sDate) + sComma +
- Quote( aEntry.m_sCommentContainer);
- System.out.println(db_line);
- DBHelper.SQLinsertValues(db_line);
- }
- }
-
-
- public void add(String _sDate, String _sClassName,
- String _sMethodName, String _sMethodTestName,
- String _sState, String _sComment)
- {
- String sKey = _sClassName + "." + _sMethodName;
- if (aMap.containsKey(sKey))
- {
- CurrentEntry aEntry = (CurrentEntry)aMap.get(sKey);
- aEntry.add(_sDate, _sClassName, _sMethodName, _sMethodTestName, _sState, _sComment);
- }
- else
- {
- CurrentEntry aEntry = new CurrentEntry();
- aEntry.add(_sDate, _sClassName, _sMethodName, _sMethodTestName, _sState, _sComment);
- aMap.put(sKey, aEntry);
- }
- }
-}
-
-/**
- *
- * This class will run the testshl2 script
- *
- * According to a given baseDir it'll first
- * get all scenario files, clean them up<br>
- * Then all sources will be compiled and
- * the scenarios started.<br>
- * After the a scenarios are finished the result
- * will be stored in the database.
- * @version 0.1
- */
-public class TestShl2Runner
-{
-
- Properties m_aProps;
-
- String m_sVersion = "udk399";
- String m_sExtension = "";
- String m_sProjectDir = "";
- String m_sEnvironment = "";
- String m_sProjectName = "";
- String m_sShellExecutable="";
- String m_sLocalEnv="";
-
- /**
- * The constructor to use this class from any other java-class
- * @param bdir the base directory where the qa-subfolder can be found
- * @param pf the platform e.g. unxsols
- * @param mod the module e.g. sal
- * @param ver the version e.g. udk304
- * @param pre the path to the shell, may be "", but is needed on Windows<br>
- * Systems to ensure that the created scripts run in an 4NT-shell
- */
-
-// public TestShl2Runner(String bdir, String pf, String project, String ver, String pre, String localenv)
- public TestShl2Runner(String filename)
- {
- String fs = System.getProperty("file.separator");
-
- m_aProps = PropertyHelper.getProperties(filename);
-
- m_sEnvironment = m_aProps.getProperty("ENV"); // unxsols3.pro
- m_sProjectName = m_aProps.getProperty("PROJECTNAME"); // sal
- m_sProjectDir = m_aProps.getProperty("BASEDIR") + fs + m_sProjectName; // /usr/qaapi/projects/udk/sal
- m_sVersion = m_aProps.getProperty("BUILD"); // udk305
- m_sShellExecutable = m_aProps.getProperty("SHELL"); // /bin/tcsh
- m_sLocalEnv = m_aProps.getProperty("LOCALENV"); // /usr/qaapi/projects/solartmp
-
- // if (m_sVersion.indexOf("-pro") > 1) m_sExtension=".pro";
-
- startAll();
- }
-
- /**
- * The main Method makes it possible to run this class standalone
- * @param args the command line arguments
- */
- public static void main(String args[])
- {
- if (args.length != 1)
- {
- System.out.println("Usage: TestShl2Runner <config.file>");
- System.out.println("Example: TestShl2Runner /usr/qaapi/projects/udk/sal/qa/configfile");
- System.exit(1);
- }
-
- TestShl2Runner aRunner = new TestShl2Runner(args[0]);
- }
-
- // -----------------------------------------------------------------------------
-
- ArrayList getJobs()
- {
- String fs = System.getProperty("file.separator");
- String sJobFile = m_sProjectDir + fs + m_aProps.getProperty("INPUT") + fs + m_aProps.getProperty("JOBFILE");
- ArrayList aLines = getLines(sJobFile);
- return aLines;
- }
-
- // -----------------------------------------------------------------------------
-
- public void startAll()
- {
- String fs = System.getProperty("file.separator");
-
- //get all scenario-files
- System.out.println("Getting jobs");
- ArrayList aJobList = getJobs();
-
- //cleanup scenorio-files and return a working array
- // Object[] the_array = cleanup(m_sProjectDir + fs + "qa" + fs + "sce" + fs,scene_files);
- // System.out.println("...done");
-
- //create a script to build the sources and run the tests
- System.out.println("creating start script for testprocess");
- String scriptName = createScript(aJobList);
- System.out.println("...done");
-
- //start the script
- System.out.println("starting script for testprocess");
- String sScript = m_sShellExecutable + " " + getOutputDir() + fs + scriptName;
- executeScript(sScript);
- System.out.println("...done");
-
- //remove old values from db-table
- DBHelper.SQLdeleteValues(m_sProjectName,m_sEnvironment);
- DBHelper.SQLdeleteValues(m_sProjectName,m_sEnvironment);
-
- //parse the output and store it
- parseOut (aJobList, m_sProjectName, m_sEnvironment, m_sProjectDir);
- }
-
- /**
- * This method reads the lines of a file and puts<br>
- * them into an ArrayList
- * @param filename the name of the file to be read
- */
-
- public ArrayList getLines(String filename)
- {
- File the_file = new File(filename);
- ArrayList the_lines = new ArrayList();
- if (! the_file.exists())
- {
- System.out.println("couldn't find file " + filename);
- return the_lines;
- }
- RandomAccessFile the_reader = null;
- try
- {
- the_reader = new RandomAccessFile(the_file,"r");
- String aLine = "";
- while (aLine != null)
- {
- aLine = the_reader.readLine();
- if ( (aLine != null) &&
- (! (aLine.length() < 2) ) &&
- (! aLine.startsWith("#")))
- {
- the_lines.add(aLine);
- }
- }
- }
- catch (java.io.FileNotFoundException fne)
- {
- System.out.println("couldn't open file " + filename);
- System.out.println("Message: " + fne.getMessage());
- }
- catch (java.io.IOException ie)
- {
- System.out.println("Exception while reading file " + filename);
- System.out.println("Message: " + ie.getMessage());
- }
- try
- {
- the_reader.close();
- }
- catch (java.io.IOException ie)
- {
- System.out.println("Couldn't close file " + filename);
- System.out.println("Message: " + ie.getMessage());
- }
- return the_lines;
- }
-
-
-
- /**
- * This method calls the createScript-methods<br>
- * for the given platform
- * @param basedir the name of the base-directory, e.g. /usr/qaapi/projects/udk/sal
- * @param qajobs jobs to be done
- */
-
- public String createScript(ArrayList _aJobList)
- {
- String res = "";
- if (m_sEnvironment.startsWith("wnt"))
- {
- try
- {
- res = createwntmsci(_aJobList);
- }
- catch (IOException ioe)
- {
- System.out.println("Couldn't create Script");
- }
- }
- else if (m_sEnvironment.startsWith("unx"))
- {
- try
- {
- res = createunx(_aJobList);
- }
- catch (IOException ioe)
- {
- System.out.println("Couldn't create Script");
- }
- }
- else
- {
- // can't handle unknown environment
- }
- return res;
- }
-
- public String getSignalFileParameter()
- {
- String sParameter;
- sParameter = " -sf /var/tmp/signalfile_" + m_sProjectName + "_" + m_sEnvironment + ".txt ";
- return sParameter;
- }
-
- public String getLogParameter(String job)
- {
- String sParameter = " -log " + getLogName(job) + " ";
- return sParameter;
- }
-
- public String getLogName(String job)
- {
- // create the ' -log file '
- String fs = System.getProperty("file.separator");
- String sLogName = getOutputDir() + fs + job + ".log";
- return sLogName;
- }
-
- public String getInputDir()
- {
- String fs = System.getProperty("file.separator");
- String sInputDir = m_sProjectDir + fs + m_aProps.getProperty("INPUT");
- return sInputDir;
- }
-
-
- public String getOutputDir()
- {
- String fs = System.getProperty("file.separator");
- String sOutputDir = m_sProjectDir + fs + m_sEnvironment + fs + m_aProps.getProperty("OUTPUT");
-
- File aFile = new File(sOutputDir);
- aFile.mkdirs();
- return sOutputDir;
- }
-
- public String getCAXParameter()
- {
- String sCAX = " ";
- // Due to the fu....g java that we havn't access to our well formed ;-)
- // environment variables the simple switch -cax do not longer work :-(
-
- // String sSolTmp = System.getenv("SOL_TMP");
- if (m_sLocalEnv.length() > 0)
- {
- sCAX = " -cax -tmp " + m_sLocalEnv;
- }
- // else
- // {
- // due to the fact that we don't want to get hole lokal env if no one exist, do nothing here.
- // }
- return sCAX;
- }
-
- public String getProParameter()
- {
- String sPro = " ";
- if (m_sEnvironment.endsWith(".pro"))
- {
- sPro = " -pro ";
- }
- return sPro;
- }
-
- public String getCompEnvName()
- {
- String sCompEnv;
- if (m_sEnvironment.endsWith(".pro"))
- {
- sCompEnv = String.copyValueOf(m_sEnvironment.toCharArray(), 0, 8);
- }
- else
- {
- sCompEnv = m_sEnvironment;
- }
- return " " + sCompEnv;
- }
-
- /**
- * This method create the script needed to compile and run the<br>
- * the tests on the Windows platform
- * @param basedir the name of the base-directory, e.g. /usr/qaapi/projects/udk/sal
- * @param qajobs jobs to be done
- */
-
- public void PreNPost(FileWriter out, String _sWhat) throws IOException
- {
- String ls = System.getProperty("line.separator");
-
- out.write(getRemark() + " do " + _sWhat + ls);
- for (int i = 1;i<9;i++)
- {
- String sWhat = m_aProps.getProperty(_sWhat + i);
- if (sWhat != null)
- {
- out.write(sWhat + ls);
- }
- }
- out.write(ls);
- }
-
- public String getChangeDirFkt()
- {
- if (m_sEnvironment.startsWith("wnt"))
- {
- return "cdd";
- }
- return "cd";
- }
- public String getRemark()
- {
- if (m_sEnvironment.startsWith("wnt"))
- {
- return "rem ";
- }
- return "# ";
- }
-
- public void do_setsolar(FileWriter out, String _sPreExec) throws IOException
- {
- String ls = System.getProperty("line.separator");
-
- out.write(getRemark() + " do a setsolar" + ls);
- out.write(_sPreExec + " setsolar -" + m_sVersion + getCAXParameter() + getProParameter() + getCompEnvName() + ls);
- out.write(ls);
- }
-
- public void do_cvs(FileWriter out, String _sPreExec, ArrayList _aJobList) throws IOException
- {
- String fs = System.getProperty("file.separator");
- String ls = System.getProperty("line.separator");
- out.write(getChangeDirFkt() + " " + getInputDir() + ls);
- out.write(getRemark() + " do a cvs and a dmake" + ls);
-
- out.write(_sPreExec + " " + "cvs -d" + m_aProps.getProperty("CVSROOT") + " update -d" + ls);
-
- for (int i=0; i<_aJobList.size();i++)
- {
- String sJob = (String) _aJobList.get(i);
-
- out.write(getChangeDirFkt() + " " + getInputDir() + fs + sJob + ls);
- // setenv VCSID lla
- // set VCSID=lla
- out.write(_sPreExec + " " + "dmake -u" + ls);
- }
- out.write(ls);
- }
-
- public void do_testtool(FileWriter out, String _sPreExec, ArrayList _aJobList) throws IOException
- {
- String ls = System.getProperty("line.separator");
- out.write(getRemark() + " call the test tool" + ls);
- out.write(getChangeDirFkt() + " " + getOutputDir() + ls);
- if (m_sEnvironment.startsWith("wnt"))
- {
- out.write("set DISABLE_SAL_DBGBOX=t" + ls);
- }
-
- for (int i=0; i<_aJobList.size();i++)
- {
- String sLine = (String) _aJobList.get(i);
- // String sJob = getJob(sLine);
- out.write(_sPreExec + " " + m_aProps.getProperty("TESTTOOL") + " " + getLibName(sLine, m_sEnvironment) + getLogParameter(sLine) + getSignalFileParameter() + ls);
- }
- out.write(ls);
- }
-
- public String createwntmsci(ArrayList _aJobList) throws IOException
- {
- String fs = System.getProperty("file.separator");
- String ls = System.getProperty("line.separator");
-
- String sBatchFile = m_aProps.getProperty("BATCHFILE");
- File outputFile = new File(getOutputDir(), sBatchFile);
- FileWriter out = new FileWriter(outputFile.toString());
-
- out.write("rem do not edit, will be created automatically by TestShl2Runner.java" + ls);
-
- // String sBuildEnvironment = "wntmsci9";
- PreNPost(out, "PRE");
-
- String sBatchPreExec = "call";
- do_setsolar(out, sBatchPreExec);
- do_cvs(out, sBatchPreExec, _aJobList);
- do_testtool(out, sBatchPreExec, _aJobList);
-
- PreNPost(out, "POST");
-
- // the exit is alsolute need here, because we do not get back, until
- // shell is stopped with exit.
- out.write("exit" + ls);
- out.close();
- return sBatchFile;
- }
-
- /**
- * This method create the script needed to compile and run the<br>
- * the tests on the Unix platform
- * @param basedir the name of the base-directory, e.g. /usr/qaapi/projects/udk/sal
- * @param qajobs jobs to be done
- */
-
- public String createunx(ArrayList _aJobList) throws IOException
- {
- String fs = System.getProperty("file.separator");
- String ls = System.getProperty("line.separator");
-
- String sBatchFile = m_aProps.getProperty("BATCHFILE");
- File outputFile = new File(getOutputDir(), sBatchFile);
- FileWriter out = new FileWriter(outputFile.toString());
-
- out.write("#!/bin/tcsh" + ls); // shebang
- out.write("# do not edit, will be created automatically by TestShl2Runner.java" + ls);
-
- PreNPost(out, "PRE");
-
- String sBatchPreExec = "";
- do_setsolar(out, sBatchPreExec);
- do_cvs(out, sBatchPreExec, _aJobList);
- do_testtool(out, sBatchPreExec, _aJobList);
-
- PreNPost(out, "POST");
-
- out.write("exit" + ls);
- out.close();
-
- // set excution bits
- String sExec = "chmod u+x " + getOutputDir() + fs + sBatchFile;
- Runtime.getRuntime().exec(sExec);
- return sBatchFile;
- }
-
- // -----------------------------------------------------------------------------
-
- /**
- * This method extracts the libname from a given<br>
- * job and adds a relative path based on the platform
- * @param job the job to be done
- * @param os the platform
- */
-
- public String getLibName(String job, String _sEnvironment)
- {
- String fs = System.getProperty("file.separator");
- // BACK: String like "../wntmsci9.pro/bin/rtl_OString.dll"
-
- String res = "";
- int nIndex = job.indexOf(".");
- // if (nIndex > 0)
- // {
- // }
- String sPureFilename = job;
- String purelibname = "";
- if (_sEnvironment.startsWith("wnt"))
- {
- purelibname = "bin" + fs + sPureFilename + ".dll";
- }
- else if (_sEnvironment.startsWith("unx"))
- {
- purelibname = "lib" + fs + "lib" + sPureFilename + ".so";
- }
- else
- {
- // _sEnvironment unknown
- // throw ...
- }
-
- // we are in the wntmsci9[.pro]/qa directory
- // to go to the bin directory we have to go to
- // ../bin or ../lib
- res = m_sProjectDir + fs + m_sEnvironment + fs + purelibname;
- return res;
- }
-
- // -----------------------------------------------------------------------------
-
-/*
- public Object[] cleanup(String sceneDir, String[] scene_files)
- {
- ArrayList res = new ArrayList();
- for (int j=0;j<scene_files.length;j++)
- {
- if (scene_files[j].endsWith(".sce"))
- {
- try
- {
- removeRemark(sceneDir,scene_files[j]);
- }
- catch (IOException ioe)
- {
- System.out.println("Couldn't cleanup Scene-File " + scene_files[j]);
- }
- String pure = scene_files[j].substring(0,
- scene_files[j].indexOf("."));
- res.add(pure + ".qadev");
- }
- }
- return res.toArray();
- }
-
-
- public void removeRemark(String sceneDir,String scene_file)
- throws IOException
- {
- ArrayList org = getLines(sceneDir + scene_file);
- String pure = scene_file.substring(0,scene_file.indexOf("."));
- String ls = System.getProperty("line.separator");
- File outputFile = new File(sceneDir,pure + ".qadev");
- FileWriter out = new FileWriter(outputFile.toString());
- for (int k=0;k<org.size();k++)
- {
- String toWrite = (String)org.get(k);
- if (toWrite.startsWith("#"))
- {
- toWrite=toWrite.substring(1);
- }
- out.write(toWrite + ls);
- }
- out.close();
- }
-*/
-
- public void parseOut (ArrayList sJobList, String _sProjectName, String _sEnvironment, String basedir)
- {
- //parse the out-files and store the data
- String fs = System.getProperty("file.separator");
- for (int i=0; i<sJobList.size();i++)
- {
- String sJob = (String) sJobList.get(i);
- String outFile = getLogName(sJob);
- ArrayList out_lines = getLines(outFile);
- String date="";
-
- DatabaseEntry aEntry = new DatabaseEntry();
-
- for (int j=0;j<out_lines.size();j++)
- {
- String sLine = (String)out_lines.get(j);
- if (sLine.startsWith("["))
- {
- date = sLine.substring(1, 11);
- date = date.replace('.','-');
- }
- else
- {
- if (sLine.startsWith("Test #PASSED#")) break;
- // if (out_lines.get(j).equals(
- // " ---------- ")) break;
-
- try
- {
- String sName = sLine.substring(0, sLine.indexOf(';'));
-
- // count dot's
- int nFirstDot = sName.indexOf('.');
- int nSecondDot = sName.indexOf('.', nFirstDot + 1);
- String sClassName = "";
- String sMethodName = "";
- String sMethodTestName = "";
-
- if (nFirstDot > 0)
- {
- sClassName = sName.substring(0, nFirstDot);
- if (nSecondDot > 0)
- {
- sMethodName = sName.substring(nFirstDot + 1, nSecondDot);
- sMethodTestName = sName.substring(nSecondDot + 1);
- }
- else
- {
- sMethodName = sName.substring(nFirstDot);
- }
- }
- else
- {
- // no FirstDot, also no secondDot!
- sClassName = sName;
- }
-
- String sComment = sLine.substring(sLine.lastIndexOf('#') + 1);
-
- // get state
- int nSecondNo = sLine.indexOf('#');
- nSecondNo = sLine.indexOf('#', nSecondNo + 1);
- String sState = sLine.substring(sLine.indexOf(";") + 1, nSecondNo + 1);
-
- aEntry.add(date, sClassName, sMethodName, sMethodTestName, sState, sComment);
- }
- catch(IndexOutOfBoundsException e)
- {
- System.out.println("IndexOutOfBoundException: caught in parseOut()");
- }
- }
- }
- aEntry.writeDown(_sProjectName, _sEnvironment);
- }
- }
-
- // -----------------------------------------------------------------------------
-
- private void shortWait(int nMilliSec)
- {
- try
- {
- Thread.sleep(nMilliSec);
- }
- catch (InterruptedException ex)
- {
- }
-
- }
-
- // -----------------------------------------------------------------------------
-
- public boolean executeScript(String scriptFile)
- {
- System.out.println("Running " + scriptFile);
-
- // Process testshl = Runtime.getRuntime().exec(scriptFile);
- ProcessHandler aHandler = new ProcessHandler(scriptFile);
- boolean bBackValue = aHandler.executeSynchronously();
- return bBackValue;
- // return false;
- }
-}
-
diff --git a/testshl2/source/versioner.cxx b/testshl2/source/versioner.cxx
deleted file mode 100644
index 10040ff8cd5f..000000000000
--- a/testshl2/source/versioner.cxx
+++ /dev/null
@@ -1,117 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string>
-
-#include "testshl/versionhelper.hxx"
-
-#include <rtl/ustring.hxx>
-#include <iostream>
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int, char* argv[] )
-#else
-int _cdecl main( int, char* argv[] )
-#endif
-{
- static char const * optionSet[] = {
- "-time, display time only",
- "-date, display date only",
- "-upd, display UPD only",
- "-minor, display minor only",
- "-build, display build only",
- "-inpath, display inpath only",
- "-verbose, be verbose",
- "-h:s, display help or help on option",
- "-help:s, see -h",
- NULL
- };
-
- GetOpt opt( argv, optionSet );
-
- // someone indicates that he needs help
- if ( opt.hasOpt( "-h" ) || opt.hasOpt( "-help" ) )
- {
- opt.showUsage();
- exit(0);
- }
-
- if (opt.getParams().empty())
- {
- // std::cerr << "error: At least a library should given." << std::endl;
- fprintf(stderr, "error: At least a library should given.\n");
- opt.showUsage();
- exit(0);
- }
-
- rtl::OUString suLibraryName = rtl::OStringToOUString(opt.getFirstParam(), RTL_TEXTENCODING_ASCII_US );
- VersionHelper aHelper(suLibraryName, opt);
-
- if (! aHelper.isOk() )
- {
- fprintf(stderr, "error: No version info found.\n");
- exit(1);
- }
-
- if (opt.hasOpt("-time"))
- {
- fprintf(stdout, "%s\n", aHelper.getTime().getStr());
- }
- else if (opt.hasOpt("-date"))
- {
- fprintf(stdout, "%s\n", aHelper.getDate().getStr());
- }
- else if (opt.hasOpt("-upd"))
- {
- fprintf(stdout, "%s\n", aHelper.getUpd().getStr());
- }
- else if (opt.hasOpt("-minor"))
- {
- fprintf(stdout, "%s\n", aHelper.getMinor().getStr());
- }
- else if (opt.hasOpt("-build"))
- {
- fprintf(stdout, "%s\n", aHelper.getBuild().getStr());
- }
- else if (opt.hasOpt("-inpath"))
- {
- fprintf(stdout, "%s\n", aHelper.getInpath().getStr());
- }
- else
- {
- // std::cout << aHelper << std::endl;
- aHelper.printall(stdout);
- }
-
- return 0;
-}
diff --git a/testshl2/source/versionhelper.cxx b/testshl2/source/versionhelper.cxx
deleted file mode 100644
index 2a2f77fbbc6e..000000000000
--- a/testshl2/source/versionhelper.cxx
+++ /dev/null
@@ -1,124 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-#include "testshl/versionhelper.hxx"
-
-#include <rtl/ustring.hxx>
-#include <rtl/string.hxx>
-
-// -----------------------------------------------------------------------------
-VersionHelper::VersionHelper(rtl::OUString const& _sDLLName, GetOpt & _aOptions)
- :DynamicLibraryHelper(_sDLLName, _aOptions),
- m_pInfo(NULL)
-{
- // try to get the entry pointer
- FktGetVersionInfoPtr pFunc = (FktGetVersionInfoPtr)
- m_pModule->getFunctionSymbol(
- rtl::OUString::createFromAscii( "GetVersionInfo" ) );
-
- if (pFunc)
- {
- const VersionInfo *pVersion = (pFunc)();
- m_pInfo = pVersion;
- }
-}
-
-//# void VersionHelper::print(std::ostream &stream)
-//# {
-//# stream << " Time:" << getTime() << std::endl;
-//# stream << " Date:" << getDate() << std::endl;
-//# stream << " Upd:" << getUpd() << std::endl;
-//# stream << " Minor:" << getMinor() << std::endl;
-//# stream << " Build:" << getBuild() << std::endl;
-//# stream << "Inpath:" << getInpath() << std::endl;
-//# }
-//#
-//# std::ostream & operator <<( std::ostream &stream, VersionHelper &_aVersion )
-//# {
-//# _aVersion.print (stream);
-//# return stream;
-//# }
-//#
-// -----------------------------------------------------------------------------
-
-bool VersionHelper::isOk() const
-{
- if (m_pInfo != NULL) return true;
- return false;
-}
-
-rtl::OString VersionHelper::getTime() const
-{
- return m_pInfo->pTime;
-}
-rtl::OString VersionHelper::getDate() const
-{
- return m_pInfo->pDate;
-}
-rtl::OString VersionHelper::getUpd() const
-{
- return m_pInfo->pUpd;
-}
-rtl::OString VersionHelper::getMinor() const
-{
- return m_pInfo->pMinor;
-}
-rtl::OString VersionHelper::getBuild() const
-{
- return m_pInfo->pBuild;
-}
-rtl::OString VersionHelper::getInpath() const
-{
- return m_pInfo->pInpath;
-}
-
-
-
-void VersionHelper::printall(FILE * out)
-{
- if (isOk())
- {
- rtl::OString aStr = getTime();
- fprintf(out, " Time:%s\n", aStr.getStr() );
- fprintf(out, " Date:%s\n", getDate().getStr() );
- fprintf(out, " Upd:%s\n", getUpd().getStr() );
- fprintf(out, " Minor:%s\n", getMinor().getStr() );
- fprintf(out, " Build:%s\n", getBuild().getStr() );
- fprintf(out, "Inpath:%s\n", getInpath().getStr());
-
- fflush(out);
- }
- else
- {
- fprintf(stderr, "error: No version info found.\n");
- }
-}
-
diff --git a/testshl2/workben/codegen/README b/testshl2/workben/codegen/README
deleted file mode 100644
index 0c24b4a05856..000000000000
--- a/testshl2/workben/codegen/README
+++ /dev/null
@@ -1,9 +0,0 @@
-This directory contains a simple code generator self test.
-Within UNIX simply start ./selftest
-
-You will get lot of output.
-The code generator creates some files,
-dmake compiles the generated code,
-testshl2 checks the code.
-
-If something goes wrong, you will hopefully get an informal error message.
diff --git a/testshl2/workben/codegen/checkfile b/testshl2/workben/codegen/checkfile
deleted file mode 100644
index 228642da52af..000000000000
--- a/testshl2/workben/codegen/checkfile
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/csh
-
-if ( -e $1 ) then
- echo "$1 exist."
-else
- echo "$1 doesn't exist."
-endif
diff --git a/testshl2/workben/codegen/cleanup b/testshl2/workben/codegen/cleanup
deleted file mode 100644
index a3fb82312cdf..000000000000
--- a/testshl2/workben/codegen/cleanup
+++ /dev/null
@@ -1,10 +0,0 @@
-#!/bin/csh
-
-# cleanup
-rm -f *.cxx *.new *.exp
-
-if ( -e makefile.mk_orig ) then
- rm -f makefile.mk
- # rename original makefile back
- mv makefile.mk_orig makefile.mk
-endif
diff --git a/testshl2/workben/codegen/selftest b/testshl2/workben/codegen/selftest
deleted file mode 100644
index cf5e80e513ce..000000000000
--- a/testshl2/workben/codegen/selftest
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/csh
-
-echo "========== Generate code =========="
-echo
-
-perl ../../source/codegen/codegen.pl test.job
-
-echo
-echo "========== check files =========="
-echo
-
-./checkfile makefile.new
-./checkfile export.exp
-./checkfile skeleton.cxx
-./checkfile nomethod.cxx
-
-echo
-echo "========== backup makefile =========="
-echo
-
-# backup original makefile
-mv makefile.mk makefile.mk_orig
-mv makefile.new makefile.mk
-
-echo
-echo "========== build new sources =========="
-echo
-
-dmake debug=t
-
-echo
-echo "========== call testshl2 =========="
-echo
-
-
-if ( -e ../../${INPATH}/bin/testshl2 ) then
- ../../${INPATH}/bin/testshl2 -jobonly test.job
-
- echo
- ../../${INPATH}/bin/testshl2 ../../${INPATH}/lib/libtest.so
-else
- echo "testshl2 doesn't exist, test canceled."
-endif
-
-echo
-echo "========== cleanup =========="
-echo
-
-./cleanup
diff --git a/testshl2/workben/codegen/test.job b/testshl2/workben/codegen/test.job
deleted file mode 100644
index 07c47329705b..000000000000
--- a/testshl2/workben/codegen/test.job
+++ /dev/null
@@ -1,17 +0,0 @@
-# Jobfile
-# this is a job file which contain functions, which should exist
-
-skeleton.bones.bone_001
-skeleton.bones.bone_002
-
-skeleton.bones2.bone_001
-skeleton.bones2.bone_002
-
-nomethod.blah
-illegal
-
-# blah.fasel.suelz
-
-
-# rtl_OUStringBuffer.*
-
diff --git a/testshl2/workben/codegen/w32/checkfile.btm b/testshl2/workben/codegen/w32/checkfile.btm
deleted file mode 100644
index 091ecfbf9faf..000000000000
--- a/testshl2/workben/codegen/w32/checkfile.btm
+++ /dev/null
@@ -1,7 +0,0 @@
-rem %1 is the filename
-
-iff exist %1 then
-echo Ok: %1 exist.
-else
-echo ERROR: %1 does not exist.
-endiff
diff --git a/testshl2/workben/codegen/w32/cleanup.btm b/testshl2/workben/codegen/w32/cleanup.btm
deleted file mode 100644
index 5073ef887bac..000000000000
--- a/testshl2/workben/codegen/w32/cleanup.btm
+++ /dev/null
@@ -1,9 +0,0 @@
-rem cleanup
-del *.cxx *.new *.exp
-
-iff exist makefile.mk_orig then
- del makefile.mk
- rem rename original makefile back
- ren makefile.mk_orig makefile.mk
-endiff
-
diff --git a/testshl2/workben/codegen/w32/selftest.btm b/testshl2/workben/codegen/w32/selftest.btm
deleted file mode 100644
index e181ecc3158b..000000000000
--- a/testshl2/workben/codegen/w32/selftest.btm
+++ /dev/null
@@ -1,47 +0,0 @@
-
-rem demo
-
-echo "========== Generate code =========="
-echo
-
-perl ..\..\..\source\codegen\codegen.pl test.job
-
-echo
-echo "========== check files =========="
-echo
-
-call checkfile makefile.new
-call checkfile export.exp
-call checkfile skeleton.cxx
-call checkfile nomethod.cxx
-
-echo
-echo "========== backup makefile =========="
-echo
-
-ren makefile.mk makefile.mk_orig
-ren makefile.new makefile.mk
-
-echo
-echo "========== build new sources =========="
-echo
-
-call dmake debug=t
-
-echo
-echo "========== call testshl2 =========="
-echo
-
-iff exist ..\..\..\%INPATH%\bin\testshl2.exe then
-call ..\..\..\%INPATH%\bin\testshl2 -jobonly test.job
-call ..\..\..\%INPATH%\bin\testshl2 ..\..\..\%INPATH%\bin\test.dll
-else
- echo "testshl2 doesn't exist, test canceled."
-endiff
-
-echo
-echo "========== cleanup =========="
-echo
-
-call cleanup.btm
-
diff --git a/testshl2/workben/codegen/w32/test.job b/testshl2/workben/codegen/w32/test.job
deleted file mode 100644
index 07c47329705b..000000000000
--- a/testshl2/workben/codegen/w32/test.job
+++ /dev/null
@@ -1,17 +0,0 @@
-# Jobfile
-# this is a job file which contain functions, which should exist
-
-skeleton.bones.bone_001
-skeleton.bones.bone_002
-
-skeleton.bones2.bone_001
-skeleton.bones2.bone_002
-
-nomethod.blah
-illegal
-
-# blah.fasel.suelz
-
-
-# rtl_OUStringBuffer.*
-
diff --git a/testshl2/workben/dlltest/export.exp b/testshl2/workben/dlltest/export.exp
deleted file mode 100644
index a13529da5876..000000000000
--- a/testshl2/workben/dlltest/export.exp
+++ /dev/null
@@ -1 +0,0 @@
-registerAllTestFunction
diff --git a/testshl2/workben/dlltest/makefile.mk b/testshl2/workben/dlltest/makefile.mk
deleted file mode 100644
index fdbd8ce4b456..000000000000
--- a/testshl2/workben/dlltest/makefile.mk
+++ /dev/null
@@ -1,126 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-PRJINC=
-
-PRJNAME=testshl2
-TARGET=onefunc
-TARGETTYPE=CUI
-
-ENABLE_EXCEPTIONS=TRUE
-#USE_LDUMP2=TRUE
-#LDUMP2=LDUMP3
-
-# --- Settings -----------------------------------------------------
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-#--------------------------------- Objectfiles ---------------------------------
-OBJFILES=$(OBJ)$/onefuncstarter.obj
-SLOFILES=$(SLO)$/onefunc.obj
-
-# -------------------------------------------------------------------------------
-
-LIB1TARGET= $(LB)$/$(TARGET)_libfile.lib
-LIB1OBJFILES= $(SLOFILES)
-
-.IF "$(GUI)" == "UNX"
-LIB1ARCHIV=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-
-# ------------------------------------------------------------------
-SHL2OBJS = $(SLOFILES)
-
-SHL2TARGET= $(TARGET)_DLL
-SHL2STDLIBS+=\
- $(SALLIB)
-
-SHL2DEPN=
-SHL2IMPLIB= i$(SHL2TARGET)
-SHL2DEF= $(MISC)$/$(SHL2TARGET).def
-
-DEF2NAME =$(SHL2TARGET)
-DEF2EXPORTFILE= export.exp
-
-#----------------------------- prog with *.lib file -----------------------------
-
-APP1TARGET= $(TARGET)starter
-APP1OBJS=$(OBJFILES)
-
-APP1STDLIBS=$(SALLIB)
-
-APP1DEPN= $(APP1OBJS) $(LIB1TARGET)
-APP1LIBS= $(LIB1TARGET)
-
-#-------------------------- executable with LIBARCHIV --------------------------
-
-APP2TARGET= $(TARGET)starter2
-APP2OBJS= $(OBJFILES)
-
-APP2STDLIBS=$(SALLIB)
-.IF "$(GUI)" == "UNX"
-APP2STDLIBS+=$(LB)$/lib$(TARGET)$(DLLPOSTFIX).a
-.ENDIF
-.IF "$(GUI)" == "WNT"
-APP2STDLIBS+=$(LIB1TARGET)
-.ENDIF
-
-APP2DEPN= $(APP1OBJS) $(LIB1TARGET)
-APP2LIBS=
-
-#----------------------- executable with dynamic library -----------------------
-
-APP3TARGET= $(TARGET)starter3
-APP3OBJS= $(OBJFILES)
-
-APP3STDLIBS=$(SALLIB)
-
-.IF "$(GUI)" == "WNT"
-APP3STDLIBS+=i$(SHL2TARGET).lib
-.ENDIF
-.IF "$(GUI)" == "UNX"
-APP3STDLIBS+=-l$(SHL2TARGET)
-.ENDIF
-
-APP3DEPN= $(APP1OBJS) $(LIB1TARGET)
-APP3LIBS=
-# APP3DEF=
-
-#----------------------- executable without any other files -----------------------
-
-APP4TARGET= $(TARGET)starter4
-APP4OBJS= $(OBJFILES)
-
-APP4STDLIBS=$(SALLIB)
-
-APP4DEPN= $(APP1OBJS)
-APP4LIBS=
-# APP3DEF=
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-.INCLUDE : _cppunit.mk
diff --git a/testshl2/workben/dlltest/onefuncstarter.cxx b/testshl2/workben/dlltest/onefuncstarter.cxx
deleted file mode 100644
index b62a1169d15a..000000000000
--- a/testshl2/workben/dlltest/onefuncstarter.cxx
+++ /dev/null
@@ -1,140 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <vector>
-#include <stdio.h>
-#include "registerfunc.h"
-#include <osl/module.hxx>
-#include <osl/process.h>
-#include <osl/file.hxx>
-
-#include <rtl/string.hxx>
-#include <rtl/ustring.hxx>
-
-typedef std::vector<FktPtr> FunctionList;
-FunctionList m_Functions;
-
-extern "C" bool SAL_CALL registerFunc(FktPtr _pFunc, const char* _sFuncName)
-{
- printf("Function register call for func(%s) successful.\n", _sFuncName);
- m_Functions.push_back(_pFunc);
- // FktPtr pFunc = _pFunc;
- // if (_pFunc)
- // {
- // (_pFunc)();
- // }
-
- return true;
-}
-
-void callAll()
-{
- for(FunctionList::const_iterator it = m_Functions.begin();
- it != m_Functions.end();
- ++it)
- {
- FktPtr pFunc = *it;
- if (pFunc)
- {
- (pFunc)();
- }
- }
-}
-
-// void test_link_at_compiletime()
-// {
-// FktRegFuncPtr pRegisterFunc = &registerFunc;
-// registerAll(pRegisterFunc);
-// callAll();
-// }
-
-
-// -----------------------------------------------------------------------------
-rtl::OUString convertPath( rtl::OString const& sysPth )
-{
- // PRE: String should contain a filename, relativ or absolut
- rtl::OUString sysPath( rtl::OUString::createFromAscii( sysPth.getStr() ) );
- rtl::OUString fURL;
- if ( sysPth.indexOf("..") == 0 )
- {
- // filepath contains '..' so it's a relative path make it absolut.
- rtl::OUString curDirPth;
- osl_getProcessWorkingDir( &curDirPth.pData );
- osl::FileBase::getAbsoluteFileURL( curDirPth, sysPath, fURL );
- }
- else
- {
- osl::FileBase::getFileURLFromSystemPath( sysPath, fURL );
- }
- return fURL;
-}
-// -----------------------------------------------------------------------------
-
-void test_link_at_runtime()
-{
- ::osl::Module* pModule;
- pModule = new ::osl::Module();
- // create and load the module (shared library)
- // pModule = new ::osl::Module();
-#if (defined WNT) || (defined OS2)
- pModule->load( convertPath( rtl::OString( "onefunc_DLL.dll" ) ) );
-#endif
-#ifdef UNX
- pModule->load( convertPath( rtl::OString( "libonefunc_DLL.so" ) ) );
-#endif
-
- // get entry pointer
- FktRegAllPtr pFunc = (FktRegAllPtr) pModule->getSymbol( rtl::OUString::createFromAscii( "registerAllTestFunction" ) );
-
- if (pFunc)
- {
- FktRegFuncPtr pRegisterFunc = &registerFunc;
- pFunc(pRegisterFunc);
- callAll();
- }
-
- delete pModule;
-}
-
-
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int argc, char* argv[] )
-#else
-int _cdecl main( int argc, char* argv[] )
-#endif
-{
- (void) argc;
- (void) argv;
-// test_link_at_compiletime();
- test_link_at_runtime();
- return 0;
-}
diff --git a/testshl2/workben/dlltest/registerfunc.h b/testshl2/workben/dlltest/registerfunc.h
deleted file mode 100644
index 805b84bc7ddd..000000000000
--- a/testshl2/workben/dlltest/registerfunc.h
+++ /dev/null
@@ -1,41 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef _register_h
-#define _register_h
-
-#include <sal/types.h>
-
-typedef void (* FktPtr)(void);
-// register the given void* as a function pointer, true, if successful
-extern "C" bool SAL_CALL registerFunc(FktPtr aFunc, const char* aFuncName);
-
-typedef bool (* FktRegFuncPtr)(FktPtr aFunc, const char* aFuncName);
-extern "C" void SAL_CALL registerAllTestFunction(FktRegFuncPtr aFunc);
-
-typedef void (* FktRegAllPtr)(FktRegFuncPtr aFunc);
-#endif
diff --git a/testshl2/workben/examples/makefile.mk b/testshl2/workben/examples/makefile.mk
deleted file mode 100644
index 3ab358d2dc92..000000000000
--- a/testshl2/workben/examples/makefile.mk
+++ /dev/null
@@ -1,64 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-PRJINC=
-
-PRJNAME=testshl2
-TARGET=demotest
-TARGETTYPE=CUI
-
-ENABLE_EXCEPTIONS=TRUE
-#USE_LDUMP2=TRUE
-#LDUMP2=LDUMP3
-
-# --- Settings -----------------------------------------------------
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-
-#--------------------------------- Objectfiles ---------------------------------
-SLOFILES=$(SLO)$/testshl_test.obj
-
-# ------------------------------------------------------------------
-SHL2OBJS = $(SLOFILES)
-
-SHL2TARGET= $(TARGET)
-SHL2STDLIBS=\
- $(SALLIB) \
- $(SOLARLIBDIR)$/cppunit.lib
-
-SHL2DEPN=
-SHL2IMPLIB= i$(SHL2TARGET)
-SHL2DEF= $(MISC)$/$(SHL2TARGET).def
-
-DEF2NAME =$(SHL2TARGET)
-DEF2EXPORTFILE= export.exp
-
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/testshl2/workben/examples/testshl_test.cxx b/testshl2/workben/examples/testshl_test.cxx
deleted file mode 100644
index 2452f8310660..000000000000
--- a/testshl2/workben/examples/testshl_test.cxx
+++ /dev/null
@@ -1,286 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-
-#ifdef WNT
-// #define UNDER_WINDOWS_DEBUGGING
-// Nice feature, to debug under windows, install msdev locally and use DebugBreak() to stop a new process at a point you want.
-#ifdef UNDER_WINDOWS_DEBUGGING
-#include <tools/presys.h>
-#include <windows.h>
-#include <tools/postsys.h>
-
-#define VCL_NEED_BASETSD
-
-#endif /* UNDER_WINDOWS_DEBUGGING */
-#endif /* WNT */
-
-
-#include <vector>
-
-
-#ifndef _SAL_TRES_H_
-#include <rtl/tres.h>
-#endif
-
-#ifndef _TESTSHL_TSTMGR_H_
-#include "tstmgr.h"
-#endif
-
-#ifndef _RTL_STRING_HXX_
- #include <rtl/string.hxx>
-#endif
-
-#include <osl/time.h>
-
-using namespace std;
-
-
-/**
- * create bitmap of comandline parameters
- */
-sal_uInt32 createFlags( vector< sal_Char* > const& cmdln )
-{
- sal_uInt32 retflags = rtl_tres_Flag_OK;
-
- vector< sal_Char* >::const_iterator iter = cmdln.begin();
- while( iter != cmdln.end() )
- {
- fprintf( stderr, "%s\n", *iter );
- if ( *iter[0] == '-' )
- {
- rtl::OString item( *iter );
- if ( item == "-boom" )
- retflags |= rtl_tres_Flag_BOOM;
-
- if ( item == "-verbose" )
- retflags |= rtl_tres_Flag_VERBOSE;
-
- if ( item == "-skip" )
- retflags |= rtl_tres_Flag_SKIP;
-
- if ( item == "-log" )
- retflags |= rtl_tres_Flag_LOG;
-
- if ( item == "-his" )
- retflags |= rtl_tres_Flag_HIS;
-
- if ( item == "-time" )
- retflags |= rtl_tres_Flag_TIME;
-
- if ( item == "-msg" )
- retflags |= rtl_tres_Flag_MSG;
-
- if ( item == "-quiet" )
- retflags |= rtl_tres_Flag_QUIET;
- }
- iter++;
- }
-
- return retflags;
-}
-
-sal_uInt32 createFlags(int argc, char* argv[])
-{
- vector< sal_Char* > cmdln;
- sal_Int32 i;
-
- /* collect comandline */
- for ( i = 1; i < argc; i++ )
- cmdln.push_back( argv[i] );
-
- return createFlags(cmdln);
-}
-
-// -----------------------------------------------------------------------------
-
-/**
- * display usage screen
- */
-
-void usage()
-{
- fprintf( stdout,
- "USAGE: testshl shlname scename [-boom][-verbose][-log][-his][-msg]\n" );
- exit(0);
-}
-
-
-#include <fstream>
-#include <cppunit/TestFixture.h>
-#include <cppunit/TestCaller.h>
-#include <cppunit/TestSuite.h>
-#include <cppunit/TestResult.h>
-#include <cppunit/TestResultCollector.h>
-#include <cppunit/TestAssert.h>
-#include <cppunit/TextTestResult.h>
-
-namespace CppunitTest
-{
- class AStringTest : public CppUnit::TestCase
- {
- rtl::OString *m_pStr;
- public:
- AStringTest()
- :m_pStr(NULL) {}
-
- void setUp()
- {
- m_pStr = new rtl::OString("test1");
- // throw std::exception("initialization failed.");
- }
-
- void tearDown()
- {
- delete m_pStr;
- }
-
- void testEquality()
- {
- CPPUNIT_ASSERT( *m_pStr == "test1" );
- CPPUNIT_ASSERT( (*m_pStr).equalsIgnoreAsciiCase("Test1") );
- CPPUNIT_ASSERT( (*m_pStr).equalsIgnoreAsciiCase("Test2") );
- CPPUNIT_ASSERT( *m_pStr == "test1" );
- CPPUNIT_ASSERT( *m_pStr == "must also fail" );
- }
- void testEquality2()
- {
- rtl::OString aStr("test2");
- CPPUNIT_ASSERT( aStr == "test2" );
- CPPUNIT_ASSERT_MESSAGE("ein vergleichstest", aStr == "test2");
- CPPUNIT_ASSERT( aStr == "must also fail" );
- }
- void testThrow()
- {
- throw std::exception("an own exception!");
- CPPUNIT_ASSERT( *m_pStr == "test2" );
- }
- };
-
- CppUnit::TestSuite *suite1()
- {
- CppUnit::TestSuite *suite = new CppUnit::TestSuite( "AStringTest" );
-
- // CppUnit::TestSuite suite;
- // CppUnit::TextTestResult result;
-
- suite->addTest( new CppUnit::TestCaller<AStringTest>( "throw test", &AStringTest::testThrow ));
-// suite->addTest( new CppUnit::TestCaller<AStringTest>( "test op eq", &AStringTest::testEquality ));
-// suite->addTest( new CppUnit::TestCaller<AStringTest>( "test op eq", &AStringTest::testEquality2 ));
-
- return suite;
- }
-
- // -----------------------------------------------------------------------------
-
- class ASimpleTest : public CppUnit::TestCase
- {
- public:
- void testEqual()
- {
- CPPUNIT_ASSERT( 1 == 1 );
- }
- };
-
- CppUnit::TestSuite *suite2()
- {
- CppUnit::TestSuite *suite = new CppUnit::TestSuite( "A simple test" );
-
- // CppUnit::TestSuite suite;
- // CppUnit::TextTestResult result;
-
- suite->addTest( new CppUnit::TestCaller<ASimpleTest>( "1 == 1", &ASimpleTest::testEqual ));
-
- return suite;
- }
-
- // -----------------------------------------------------------------------------
-
- CppUnit::TestSuite *suite()
- {
- CppUnit::TestSuite *suite = new CppUnit::TestSuite( "A simple test" );
-
- // CppUnit::TestSuite suite;
- // CppUnit::TextTestResult result;
-
- suite->addTest( suite1() );
-// suite->addTest( suite2() );
-
- return suite;
- }
-}
-
-void cppunitbased_test()
-{
- {
- // ofstream out("c:\\temp\\output.txt", ios::out);
- CppUnit::TextTestResult aResult;
-
- CppUnit::TestSuite* pSuite = CppunitTest::suite();
-
- int nTests = pSuite->countTestCases();
- pSuite->run(&aResult);
-
- // aResult.print(out);
- cout << aResult;
-
- delete pSuite;
- }
-
- exit(1);
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int argc, char* argv[] )
-#else
-int _cdecl main( int argc, char* argv[] )
-#endif
-{
- cppunitbased_test();
-
- tslTestManager hMgr = 0;
-
- /* show usage screen if too less parameters */
- if ( argc < 3 )
- usage();
-
-#ifdef UNDER_WINDOWS_DEBUGGING
- DebugBreak();
-#endif
-
- sal_uInt32 nCmdlinebitflags = createFlags( argc, argv );
-
- hMgr = tsl_TestManager_create( argv, argc, nCmdlinebitflags );
- tsl_TestManager_run( hMgr );
- tsl_TestManager_destroy( hMgr );
- return 0;
-}
diff --git a/testshl2/workben/garbage_dump/float.cxx b/testshl2/workben/garbage_dump/float.cxx
deleted file mode 100644
index 30b5b7c2aebd..000000000000
--- a/testshl2/workben/garbage_dump/float.cxx
+++ /dev/null
@@ -1,137 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <stdio.h>
-#include <double>
-#include <math.h> // fabs()
-// #include <sal/types.h>
-
-#define sal_Int16 short
-#define SAL_CALL
-
-// LLA: from kernel.h
-/*
- * min()/max() macros that also do
- * strict type-checking.. See the
- * "unnecessary" pointer comparison.
- */
-#define MIN(x,y) ({ \
- const typeof(x) _x = (x); \
- const typeof(y) _y = (y); \
- (void) (&_x == &_y); \
- _x < _y ? _x : _y; })
-
-#define MAX(x,y) ({ \
- const typeof(x) _x = (x); \
- const typeof(y) _y = (y); \
- (void) (&_x == &_y); \
- _x > _y ? _x : _y; })
-
-//------------------------------------------------------------------------
-// testing the method toDouble()
-//------------------------------------------------------------------------
-template<class T>
-sal_Int16 SAL_CALL test_rtl_OString_checkPrecisionSize()
-{
- sal_Int16 nSize = sizeof(T);
- T nCalcValue = 1.0;
-
- // (i + 1) is the current precision
- sal_Int16 i = 0;
- for (i=0;i<50;i++)
- {
- nCalcValue *= 10;
- T nValue = nCalcValue + 0.1;
- T dSub = nValue - nCalcValue;
- // ----- 0.11 ---- 0.1 ---- 0.09 -----
- if (0.11 > dSub && dSub < 0.09)
- {
- // due to the fact, that the value is break down we sub 1 from the precision value
- // but to suppress this, we start at zero, precision is i+1 till here --i;
- break;
- }
- }
-
- sal_Int16 j= 0;
- nCalcValue = 1.0;
- for (j=0;j<50;j++)
- {
- nCalcValue /= 10;
- T nValue = nCalcValue + 1.0;
- T dSub = nValue - 1.0;
- // ---- 0.02 ----- 0.01 ---- 0 --- -0.99 ---- -0.98 ----
- T dSubAbsolut = fabs(dSub);
- // ---- 0.02 ----- 0.01 ---- 0 (cut)
- if ( dSub == 0)
- break;
- }
- if (i != j)
- {
- // hmmm....
- // imho i +- 1 == j is a good value
- int n = i - j;
- if (n < 0) n = -n;
- if (n <= 1)
- {
- return MIN(i,j);
- }
- else
- {
- printf("warning: presision differs more than 1");
- }
- }
-
- return i;
-}
-
-void SAL_CALL test_precision( )
-{
- sal_Int16 nPrecision;
- nPrecision = test_rtl_OString_checkPrecisionSize<float>();
- nPrecision = test_rtl_OString_checkPrecisionSize<double>();
- nPrecision = test_rtl_OString_checkPrecisionSize<long double>();
- nPrecision = test_rtl_OString_checkPrecisionSize<Double>();
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int argc, char* argv[] )
-#else
-int main( int argc, char* argv[] )
-#endif
-{
- test_precision();
- return 0;
-}
-
-// The following sets variables for GNU EMACS
-// Local Variables:
-// tab-width:4
-// End:
diff --git a/testshl2/workben/garbage_dump/nippondir.cxx b/testshl2/workben/garbage_dump/nippondir.cxx
deleted file mode 100644
index 8cde8c227f22..000000000000
--- a/testshl2/workben/garbage_dump/nippondir.cxx
+++ /dev/null
@@ -1,316 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <iostream>
-#include<osl/file.hxx>
-
-#include<osl/thread.hxx>
-#include <tools/string.hxx>
-
-// -----------------------------------------------------------------------------
-// ---------------------------------- defines ----------------------------------
-// -----------------------------------------------------------------------------
-#ifndef ASCII
-#define ASCII(x) OUString::createFromAscii(x)
-#endif
-
-using namespace osl;
-using namespace rtl;
-using namespace std;
-
-
-ostream& operator << (ostream& out, rtl::OUString const& aStr)
-{
- sal_Unicode const* const pStr = aStr.getStr();
- sal_Unicode const* const pEnd = pStr + aStr.getLength();
- for (sal_Unicode const* p = pStr; p < pEnd; ++p)
- if (0 < *p && *p < 127) // ASCII
- out << char(*p);
- else
- out << "[\\u" << hex << *p << "]";
- return out;
-}
-
-
-inline void operator <<= (::rtl::OUString& _rUnicodeString, const sal_Char* _pAsciiString)
-{
- _rUnicodeString = ::rtl::OUString::createFromAscii(_pAsciiString);
-}
-
-inline void operator <<= (::rtl::OUString& _rUnicodeString, const ::rtl::OString& _rAsciiString)
-{
- _rUnicodeString <<= _rAsciiString.getStr();
-}
-
-/*
-inline void operator <<= (Any& _rUnoValue, const sal_Char* _pAsciiString)
-{
- _rUnoValue <<= ::rtl::OUString::createFromAscii(_pAsciiString);
-}
-
-inline void operator <<= (Any& _rUnoValue, const ::rtl::OString& _rAsciiString)
-{
- _rUnoValue <<= _rAsciiString.getStr();
-}
-*/
-
-inline void operator <<= (::rtl::OString& _rAsciiString, ::rtl::OUString const& _rUnicodeString )
-{
- _rAsciiString = rtl::OUStringToOString(_rUnicodeString, RTL_TEXTENCODING_ASCII_US).getStr();
-}
-// -----------------------------------------------------------------------------
-
-namespace FileHelper
-{
- rtl::OUString createOSLErrorString(FileBase::RC eError)
- {
- rtl::OUString aRet;
- switch(eError)
- {
- case osl_File_E_None:
- break;
-
- case osl_File_E_PERM:
- aRet = ASCII("Operation not permitted");
- break;
-
- case osl_File_E_NOENT:
- aRet = ASCII("No such file or directory");
- break;
-
- case osl_File_E_SRCH:
- aRet = ASCII("unknown error: osl_File_E_SRCH");
- break;
-
- case osl_File_E_INTR:
- aRet = ASCII("function call was interrupted");
- break;
-
- case osl_File_E_IO:
- aRet = ASCII("I/O error");
- break;
-
- case osl_File_E_NXIO:
- aRet = ASCII("No such device or address");
- break;
-
- case osl_File_E_2BIG:
- aRet = ASCII("unknown error: osl_File_E_2BIG");
- break;
-
- case osl_File_E_NOEXEC:
- aRet = ASCII("unknown error: osl_File_E_NOEXEC");
- break;
-
- case osl_File_E_BADF:
- aRet = ASCII("Bad file");
- break;
-
- case osl_File_E_CHILD:
- aRet = ASCII("unknown error: osl_File_E_CHILD");
- break;
-
- case osl_File_E_AGAIN:
- aRet = ASCII("Operation would block");
- break;
-
- case osl_File_E_NOMEM:
- aRet = ASCII("not enough memory for allocating structures");
- break;
-
- case osl_File_E_ACCES:
- aRet = ASCII("Permission denied");
- break;
-
- case osl_File_E_FAULT:
- aRet = ASCII("Bad address");
- break;
-
- case osl_File_E_BUSY:
- aRet = ASCII("Text file busy");
- break;
-
- case osl_File_E_EXIST:
- aRet = ASCII("File exists");
- break;
-
- case osl_File_E_XDEV:
- aRet = ASCII("unknown error: osl_File_E_XDEV");
- break;
-
- case osl_File_E_NODEV:
- aRet = ASCII("No such device");
- break;
-
- case osl_File_E_NOTDIR:
- aRet = ASCII("Not a directory");
- break;
-
- case osl_File_E_ISDIR:
- aRet = ASCII("Is a director");
- break;
-
- case osl_File_E_INVAL:
- aRet = ASCII("the format of the parameters was not valid");
- break;
-
- case osl_File_E_NFILE:
- aRet = ASCII("too many open files in the system");
- break;
-
- case osl_File_E_MFILE:
- aRet = ASCII("too many open files used by the process");
- break;
-
- case osl_File_E_NOTTY:
- aRet = ASCII("unknown error: osl_File_E_NOTTY");
- break;
-
- case osl_File_E_FBIG:
- aRet = ASCII("File too large");
- break;
-
- case osl_File_E_NOSPC:
- aRet = ASCII("No space left on device");
- break;
-
- case osl_File_E_SPIPE:
- aRet = ASCII("unknown error: osl_File_E_SPIPE");
- break;
-
- case osl_File_E_ROFS:
- aRet = ASCII("Read-only file system");
- break;
-
- case osl_File_E_MLINK:
- aRet = ASCII("Too many links");
- break;
-
- case osl_File_E_PIPE:
- aRet = ASCII("unknown error: osl_File_E_PIPE");
- break;
-
- case osl_File_E_DOM:
- aRet = ASCII("unknown error: osl_File_E_DOM");
- break;
-
- case osl_File_E_RANGE:
- aRet = ASCII("unknown error: osl_File_E_RANGE");
- break;
-
- case osl_File_E_DEADLK:
- aRet = ASCII("unknown error: osl_File_E_DEADLK");
- break;
-
- case osl_File_E_NAMETOOLONG:
- aRet = ASCII("File name too long");
- break;
-
- case osl_File_E_NOLCK:
- aRet = ASCII("No record locks available");
- break;
-
- case osl_File_E_NOSYS:
- aRet = ASCII("Function not implemente");
- break;
-
- case osl_File_E_NOTEMPTY:
- aRet = ASCII("Directory not empt");
- break;
-
- case osl_File_E_LOOP:
- aRet = ASCII("Too many symbolic links encountered");
- break;
-
- case osl_File_E_ILSEQ:
- aRet = ASCII("unknown error: osl_File_E_ILSEQ");
- break;
-
- case osl_File_E_NOLINK:
- aRet = ASCII("Link has been severed");
- break;
-
- case osl_File_E_MULTIHOP:
- aRet = ASCII("Multihop attempted");
- break;
-
- case osl_File_E_USERS:
- aRet = ASCII("unknown error: osl_File_E_USERS");
- break;
-
- case osl_File_E_OVERFLOW:
- aRet = ASCII("Value too large for defined data type");
- break;
-
- /* unmapped error: always last entry in enum! */
- case osl_File_E_invalidError:
- aRet = ASCII("unmapped Error");
- break;
- }
- return aRet;
- }
-} // namespace FileHelper
-
-
-#if (defined UNX) || (defined OS2)
-void main( int argc, char * argv[] )
-#else
-void _cdecl main( int argc, char * argv[] )
-#endif
-{
-
- OUString aDirectory(OUString::createFromAscii("file:///C:/%E6%96%B0%E3%81%97%E3%81%84%E3%83%95%E3%82%A9%E3%83%AB%E3%83%80"));
-// OUString aDirex(OUString::createFromAscii("file:///C:/%C2%90V%E2%80%9A%C2%B5%E2%80%9A%C2%A2%C6%92t%C6%92H%C6%92%E2%80%B9%C6%92_"));
-
- osl::FileBase::RC eError = osl::Directory::create(aDirectory);
- if (eError != osl::FileBase::E_None)
- {
- OUString aUStr = FileHelper::createOSLErrorString(eError);
- OString aStr;
- aStr <<= aUStr;
- OSL_ENSURE(false, aStr.getStr());
- }
-
-// OUString suSystemPath, aTmp;
-// FileBase::RC aRC = FileBase::getSystemPathFromFileURL( aDirectory, suSystemPath );
-//
-// String suSystemPathAsString(suSystemPath);
-// ByteString sSystemPath(suSystemPathAsString, osl_getThreadTextEncoding());
-//
-//
-// ByteString sSystemPathNew = sSystemPath;
-// UniString suSystemPathNew(sSystemPathNew, osl_getThreadTextEncoding());
-// FileBase::RC aRC2 = FileBase::getFileURLFromSystemPath( suSystemPathNew, aTmp );
-
-//
-// aRC = FileBase::getSystemPathFromFileURL( aDirex, aTmp );
-// aRC2 = FileBase::getFileURLFromSystemPath( aTmp, aTmp2 );
-}
-
diff --git a/testshl2/workben/garbage_dump/some_tips.cxx b/testshl2/workben/garbage_dump/some_tips.cxx
deleted file mode 100644
index be29a2cdaee1..000000000000
--- a/testshl2/workben/garbage_dump/some_tips.cxx
+++ /dev/null
@@ -1,126 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <cppunit/simpleheader.hxx>
-
-namespace rtl_ByteSequence
-{
-// -----------------------------------------------------------------------
-// call this before any other classes
-// -----------------------------------------------------------------------
-class OSingleton
-{
-public:
- static OSingleton * GetSingleton();
- virtual ~OSingleton() {}
-protected :
- OSingleton()
- {
- printf("Do something before.\n");
- }
-
- static OSingleton * m_pSingleton;
-};
-
-OSingleton * OSingleton::m_pSingleton = NULL;
-OSingleton * OSingleton::GetSingleton()
-{
- if(m_pSingleton == NULL )
- {
- m_pSingleton = new OSingleton;
- }
- return m_pSingleton;
-}
-
-// -----------------------------------------------------------------------------
-
-class before : public CppUnit::TestFixture
-{
-protected:
- before()
- {
- OSingleton::GetSingleton();
- }
-};
-
-// -----------------------------------------------------------------------------
-
-class GlobalObject
-{
-public:
- GlobalObject()
- {
- // do nothing here
- }
- ~GlobalObject()
- {
- printf("shutdown");
- }
-};
-
-GlobalObject theGlobalObject;
-
-// -----------------------------------------------------------------------------
-class assign : public before
-{
-public:
- // initialise your test code values here.
- void setUp()
- {
- }
-
- void tearDown()
- {
- }
-
- // insert your test code here.
- void assign_001()
- {
- }
-
- CPPUNIT_TEST_SUITE(assign);
- CPPUNIT_TEST(assign_001);
- CPPUNIT_TEST_SUITE_END();
-}; // class operator=
-
-// -----------------------------------------------------------------------------
-CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(rtl_ByteSequence::assign, "rtl_ByteSequence");
-} // namespace ByteSequence
-
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-void RegisterAdditionalFunctions(FktRegFuncPtr _pFunc)
-{
- printf("init your work here\n");
-}
-// NOADDITIONAL;
diff --git a/testshl2/workben/getopt/makefile.mk b/testshl2/workben/getopt/makefile.mk
deleted file mode 100644
index 21b563da16a9..000000000000
--- a/testshl2/workben/getopt/makefile.mk
+++ /dev/null
@@ -1,60 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-PRJINC=
-
-PRJNAME=testshl2
-TARGET=test_getopt
-TARGETTYPE=CUI
-
-ENABLE_EXCEPTIONS=TRUE
-#USE_LDUMP2=TRUE
-#LDUMP2=LDUMP3
-
-# --- Settings -----------------------------------------------------
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-#--------------------------------- Objectfiles ---------------------------------
-OBJFILES=\
- $(OBJ)$/getopt.obj \
- $(OBJ)$/filehelper.obj \
- $(OBJ)$/test_getopt.obj
-
-#----------------------------- prog with *.lib file -----------------------------
-
-APP1TARGET= $(TARGET)
-APP1OBJS=$(OBJFILES)
-
-APP1STDLIBS=$(SALLIB)
-
-APP1DEPN= $(APP1OBJS)
-APP1LIBS=
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/testshl2/workben/getopt/test_getopt.cxx b/testshl2/workben/getopt/test_getopt.cxx
deleted file mode 100644
index af2ae1095d8a..000000000000
--- a/testshl2/workben/getopt/test_getopt.cxx
+++ /dev/null
@@ -1,140 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#ifdef SOLARIS
-#include <sys/time.h>
-#endif
-
-#ifdef WNT
-// #define UNDER_WINDOWS_DEBUGGING
-// Nice feature, to debug under windows, install msdev locally and use DebugBreak() to stop a new process at a point you want.
-#ifdef UNDER_WINDOWS_DEBUGGING
-#include <tools/presys.h>
-#include <windows.h>
-#include <tools/postsys.h>
-
-#define VCL_NEED_BASETSD
-
-#endif /* UNDER_WINDOWS_DEBUGGING */
-#endif /* WNT */
-
-#include <iostream>
-#include <vector>
-#include <rtl/string.hxx>
-
-#include "filehelper.hxx"
-#include "getopt.hxx"
-
-// #include <osl/time.h>
-
-using namespace std;
-
-// -----------------------------------------------------------------------------
-
-/**
- * display usage screen
- */
-
-void usage()
-{
- fprintf( stdout,
- "USAGE: testshl shlname [-boom][-verbose][-log][-his][-msg]\n" );
- exit(0);
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int argc, char* argv[] )
-#else
-int _cdecl main( int argc, char* argv[] )
-#endif
-{
- (void) argc;
- static char const* optionSet[] = {
- "-boom, stop near error position, exception only",
- "-mode=s, the output mode, emacs, xml, old. Default is -mode old",
- "-logPath=s, destination path for logging",
- "-tc=s@, name(s) of testcase(s) to generate",
- "-h:s, display help or help on option",
- "-help:s, see -h",
- NULL
- };
-
- GetOpt opt( argv, optionSet );
-
- // someone indicates that he needs help
- if ( opt.hasOpt( "-h" ) || opt.hasOpt( "-help" ) )
- {
- opt.showUsage();
- // exit(0);
- }
-
- // get path for logging stuff..
- rtl::OString logPth;
- // ...if available
- if ( opt.hasOpt( "-logPth" ))
- {
- logPth = opt.getOpt( "-logPth" );
- }
-
- rtl::OString param;
- if ( ! opt.getParams().empty() ) {
- param = opt.getFirstParam();
-
- std::cout << "all non '-' Parameter values" << std::endl;
-
- vector<rtl::OString>& aVec = opt.getParams();
- for(vector<rtl::OString>::const_iterator it = aVec.begin();
- it != aVec.end();
- ++it)
- {
- std::cout << (*it).getStr() << std::endl;
- }
- }
-
- if ( opt.hasOpt("-tc"))
- {
- std::cout << "Parameter -tc" << std::endl;
- vector<rtl::OString>& aVec = opt.getOptVec( "-tc" );
-
- for(vector<rtl::OString>::const_iterator it = aVec.begin();
- it != aVec.end();
- ++it)
- {
- std::cout << (*it).getStr() << std::endl;
- }
- }
-
- return 0;
-}
-
diff --git a/testshl2/workben/makefile.mk b/testshl2/workben/makefile.mk
deleted file mode 100644
index 682793c7724b..000000000000
--- a/testshl2/workben/makefile.mk
+++ /dev/null
@@ -1,126 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..
-PRJINC=
-
-PRJNAME=testshl2
-TARGET=test_autoptr
-TARGETTYPE=CUI
-
-ENABLE_EXCEPTIONS=TRUE
-#USE_LDUMP2=TRUE
-#LDUMP2=LDUMP3
-
-# --- Settings -----------------------------------------------------
-.INCLUDE : settings.mk
-
-# ------------------------------------------------------------------
-#--------------------------------- Objectfiles ---------------------------------
-OBJFILES=\
- $(OBJ)$/test_autoptr.obj \
- $(OBJ)$/test_ostringstream.obj
-
-#----------------------------- prog with *.lib file -----------------------------
-
-APP1TARGET= $(TARGET)
-APP1OBJS=$(OBJ)$/test_autoptr.obj
-
-APP1STDLIBS=$(SALLIB)
-
-APP1DEPN= $(APP1OBJS)
-APP1LIBS=
-
-#-------------------------------------------------------------------------------
-
-APP2TARGET= test_ostringstream
-APP2OBJS=$(OBJ)$/test_ostringstream.obj
-
-APP2STDLIBS=$(SALLIB)
-
-APP2DEPN= $(APP1OBJS)
-APP2LIBS=
-#-------------------------------------------------------------------------------
-
-APP3TARGET= test_filter
-APP3OBJS=$(OBJ)$/test_filter.obj
-
-APP3STDLIBS=$(SALLIB)
-
-APP3DEPN= $(APP1OBJS)
-APP3LIBS=
-#-------------------------------------------------------------------------------
-
-# APP4TARGET= test_member
-# APP4OBJS=$(OBJ)$/test_member.obj
-#
-# APP4STDLIBS=$(SALLIB)
-#
-# APP4DEPN=
- # APP4LIBS=
-
-
-#-------------------------------------------------------------------------------
-
-# APP5TARGET= test_very_long_names
-# APP5OBJS=$(OBJ)$/test_very_long_names.obj
-#
-# APP5STDLIBS=$(SALLIB)
-#
-# APP5DEPN=
-# APP5LIBS=
-
-
-#-------------------------------------------------------------------------------
-
-APP6TARGET= test_string
-APP6OBJS=$(OBJ)$/test_string.obj
-
-APP6STDLIBS=$(SALLIB)
-
-APP6DEPN=
-APP6LIBS=
-#-------------------------------------------------------------------------------
-
-APP7TARGET= test_printf
-APP7OBJS=$(OBJ)$/test_printf.obj
-
-APP7STDLIBS=$(SALLIB)
-
-APP7DEPN=
-APP7LIBS=
-#-------------------------------------------------------------------------------
-
-APP8TARGET= test_preproc
-APP8OBJS=$(OBJ)$/test_preproc.obj
-
-APP8STDLIBS=$(SALLIB)
-
-APP8DEPN=
-APP8LIBS=
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
diff --git a/testshl2/workben/runner/unxlngi4.config.file b/testshl2/workben/runner/unxlngi4.config.file
deleted file mode 100644
index 783b56950e20..000000000000
--- a/testshl2/workben/runner/unxlngi4.config.file
+++ /dev/null
@@ -1,34 +0,0 @@
-# Testshl2Runner
-
-# what is need to start?
-
-PRE1 = setenv SHELL /bin/tcsh
-PRE2 = source ~/staroffice.cshrc
-
-SHELL = /bin/tcsh
-BUILD = udk305
-ENV = unxlngi4
-LOCALENV = /usr/qaapi/projects/solartmp
-BASEDIR = /usr/qaapi/projects
-PROJECTNAME= sal
-INPUT = qa
-OUTPUT = qa
-
-# JOBFILE = $(PROJECTDIR)/$(PROJECTNAME)/$(INPUT)/jobs.txt
-JOBFILE = jobs.txt
-
-TESTTOOL = testshl2
-BATCHFILE = runTestshl.sh
-
-# Hardcoded
-# if ENV == "wnt..."
-# bin
-# if ENV == "unx..."
-# lib
-# PRJLIB = bin
-
-# nothing to do for post
-# POST1 =
-
-
-
diff --git a/testshl2/workben/runner/unxsols3.config.file b/testshl2/workben/runner/unxsols3.config.file
deleted file mode 100644
index 5af1aa49f0c1..000000000000
--- a/testshl2/workben/runner/unxsols3.config.file
+++ /dev/null
@@ -1,34 +0,0 @@
-# Testshl2Runner
-
-# what is need to start?
-
-PRE1 = setenv SHELL /bin/tcsh
-PRE2 =
-
-SHELL = /bin/tcsh
-BUILD = udk305
-ENV = unxsols3
-LOCALENV = /usr/qaapi/projects/solartemp
-BASEDIR = /usr/qaapi/projects/udk
-PROJECTNAME= sal
-INPUT = qa
-OUTPUT = qa
-
-# JOBFILE = $(PROJECTDIR)/$(PROJECTNAME)/$(INPUT)/jobs.txt
-JOBFILE = jobs.txt
-
-TESTTOOL = testshl2
-BATCHFILE = runTestshl.sh
-
-# Hardcoded
-# if ENV == "wnt..."
-# bin
-# if ENV == "unx..."
-# lib
-# PRJLIB = bin
-
-# nothing to do for post
-# POST1 =
-
-
-
diff --git a/testshl2/workben/runner/wntmsci9.config.file b/testshl2/workben/runner/wntmsci9.config.file
deleted file mode 100644
index 12aefabcd29c..000000000000
--- a/testshl2/workben/runner/wntmsci9.config.file
+++ /dev/null
@@ -1,46 +0,0 @@
-# Testshl2Runner
-
-# what is need to start?
-
-# path to find setsolar
-PRE1 = set path=r:\\etw;%PATH%
-
-SHELL = c:\\programme\\4nt\\4nt.exe
-BUILD = udk305
-ENV = wntmsci9
-
-# where to find the output directory
-LOCALENV = d:\\local\\305
-
-# the basedirectory to the sources, before a project
-BASEDIR = d:\\local\\305\\UDK305
-
-# name of the project
-PROJECTNAME= sal
-
-# PROJECTDIR is build within the following: $(BASEDIR)/$(PROJECTNAME)
-
-# INPUT is found in $(PROJECTDIR)
-INPUT = qa_work
-
-# OUTPUT is found in $(PROJECTDIR)/$(ENV)
-OUTPUT = qa_work
-
-# JOBFILE is found in $(PROJECTDIR)/$(INPUT)
-JOBFILE = jobs.txt
-
-TESTTOOL = testshl2
-BATCHFILE = runTestshl.btm
-
-# Hardcoded
-# if ENV == "wnt..."
-# bin
-# if ENV == "unx..."
-# lib
-# PRJLIB = bin
-
-# nothing to do for post
-# POST1 =
-
-
-
diff --git a/testshl2/workben/selftest/README.txt b/testshl2/workben/selftest/README.txt
deleted file mode 100644
index dbf9cce433d7..000000000000
--- a/testshl2/workben/selftest/README.txt
+++ /dev/null
@@ -1,30 +0,0 @@
-There seems to be some problems with load test libraries from the right path,
-if the libraries are stored also in the solver directory.
-
-To test this:
-Call dmake to build the libraries in this selftest directory.
-Call deliver to copy one test library into the solver tree.
-Call dmake test to simply test the behaviour.
-
-Some more words:
-
-Per default the test libraries should not deliver but if:
-
-- Linux and Windows will use an absolute path to load the test libraries
- by dlopen().
-- MacOSX will use local path per default to load the test libraries by
- dlopen();
-
-If there are problems, there exists 2 new parameters like
--absolutepath
--localpath
-
-Just call
-'dmake test TESTOPTADD="-absolutepath"' or
-'dmake test TESTOPTADD="-localpath"' from this directory and see which
-behaviour is the right for your environment.
-
-There exist some environment variables to manipulate the default behaviour
-of load libraries. These are
-LD_LIBRARY_PATH
-DYLD_LIBRARY_PATH (Mac OS X)
diff --git a/testshl2/workben/selftest/delivertest.cxx b/testshl2/workben/selftest/delivertest.cxx
deleted file mode 100644
index b24cda0bccd9..000000000000
--- a/testshl2/workben/selftest/delivertest.cxx
+++ /dev/null
@@ -1,61 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <cppunit/simpleheader.hxx>
-
-namespace delivertest
-{
-//------------------------------------------------------------------------
-// testing constructors
-//------------------------------------------------------------------------
-
- class ctor : public CppUnit::TestFixture
- {
- public:
- void ctor_001()
- {
- CPPUNIT_ASSERT_MESSAGE("Simple testshl2 self test, You have loaded the delivered library, PER DEFAULT THIS IS ABSOLUTLY WRONG. If you have start this test by 'dmake test' please change the behaviour in 'source/dynamicregister.cxx' in the DynamicLibraryHelper::CTor.", sal_False);
- }
-
- CPPUNIT_TEST_SUITE(ctor);
- CPPUNIT_TEST(ctor_001);
- CPPUNIT_TEST_SUITE_END();
- };
-
- // -----------------------------------------------------------------------------
- CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(delivertest::ctor, "delivertest");
-} // delivertest
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-
-NOADDITIONAL;
diff --git a/testshl2/workben/selftest/export.map b/testshl2/workben/selftest/export.map
deleted file mode 100644
index 2718fd9a5cc4..000000000000
--- a/testshl2/workben/selftest/export.map
+++ /dev/null
@@ -1,8 +0,0 @@
-UDK_3.0 {
- global:
- registerAllTestFunction;
-
- local:
- *;
-};
-
diff --git a/testshl2/workben/selftest/makefile.mk b/testshl2/workben/selftest/makefile.mk
deleted file mode 100644
index 974b3beda526..000000000000
--- a/testshl2/workben/selftest/makefile.mk
+++ /dev/null
@@ -1,87 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-
-PRJNAME=sal
-TARGET=selftest_testshl2
-# this is removed at the moment because we need some enhancements
-# TESTDIR=TRUE
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-#------------------------------- All object files -------------------------------
-# do this here, so we get right dependencies
-# SLOFILES= \
-# $(SLO)$/unotest.obj
-
-#----------------------------------- deliver test -----------------------------------
-
-SHL1OBJS= \
- $(SLO)$/notdeliveredtest.obj
-
-SHL1TARGET= testshl2_deliver_test
-SHL1STDLIBS=\
- $(SALLIB) \
- $(CPPUHELPERLIB) \
- $(COMPHELPERLIB) \
- $(CPPULIB) \
- $(CPPUNITLIB)
-
-SHL1IMPLIB= i$(SHL1TARGET)
-
-DEF1NAME =$(SHL1TARGET)
-SHL1VERSIONMAP = export.map
-
-#----------------------------------- deliver test -----------------------------------
-
-SHL2OBJS= \
- $(SLO)$/delivertest.obj
-
-SHL2TARGET= delivertest
-SHL2STDLIBS=\
- $(SALLIB) \
- $(CPPUHELPERLIB) \
- $(COMPHELPERLIB) \
- $(CPPULIB) \
- $(CPPUNITLIB)
-
-SHL2IMPLIB= i$(SHL2TARGET)
-
-DEF2NAME =$(SHL2TARGET)
-SHL2VERSIONMAP = export.map
-
-
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-.INCLUDE : _cppunit.mk
-
diff --git a/testshl2/workben/selftest/notdeliveredtest.cxx b/testshl2/workben/selftest/notdeliveredtest.cxx
deleted file mode 100644
index 93a5532a42ac..000000000000
--- a/testshl2/workben/selftest/notdeliveredtest.cxx
+++ /dev/null
@@ -1,61 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <cppunit/simpleheader.hxx>
-
-namespace delivertest
-{
-//------------------------------------------------------------------------
-// testing constructors
-//------------------------------------------------------------------------
-
- class ctor : public CppUnit::TestFixture
- {
- public:
- void ctor_001()
- {
- CPPUNIT_ASSERT_MESSAGE("Simple testshl2 self test, if you see this error message, the load library test is ok.", sal_False);
- }
-
- CPPUNIT_TEST_SUITE(ctor);
- CPPUNIT_TEST(ctor_001);
- CPPUNIT_TEST_SUITE_END();
- };
-
- // -----------------------------------------------------------------------------
- CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(delivertest::ctor, "delivertest");
-} // delivertest
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-
-NOADDITIONAL;
diff --git a/testshl2/workben/singleton.cxx b/testshl2/workben/singleton.cxx
deleted file mode 100644
index 055e3525410a..000000000000
--- a/testshl2/workben/singleton.cxx
+++ /dev/null
@@ -1,49 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-class OSingleton
-{
-public:
- static OSingleton * GetSingleton();
- virtual ~OSingleton(){}
-protected :
- OSingleton(){}
- static OSingleton * m_pSingleton;
-};
-
-OSingleton * OSingleton::m_pSingleton = NULL;
-OSingleton * OSingleton::GetSingleton()
-{
- if(m_pSingleton == NULL )
- {
- m_pSingleton = new OSingleton;
- }
- return m_pSingleton;
-}
diff --git a/testshl2/workben/skeleton/export.map b/testshl2/workben/skeleton/export.map
deleted file mode 100644
index 4ca70fa85463..000000000000
--- a/testshl2/workben/skeleton/export.map
+++ /dev/null
@@ -1,7 +0,0 @@
-UDK_3.0 {
- global:
- registerAllTestFunction;
-
- local:
- *;
-};
diff --git a/testshl2/workben/skeleton/skeleton.cxx b/testshl2/workben/skeleton/skeleton.cxx
deleted file mode 100644
index 0e7d006ee714..000000000000
--- a/testshl2/workben/skeleton/skeleton.cxx
+++ /dev/null
@@ -1,79 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-/*
- * LLA: 20040527
- */
-#include <cppunit/simpleheader.hxx>
-
-namespace skeleton
-{
-//------------------------------------------------------------------------
-// testing constructors
-//------------------------------------------------------------------------
-
- class ctor : public CppUnit::TestFixture
- {
- public:
- ctor()
- {
- printf("ctor: called\n");
- }
-
- void ctor_test()
- {
- printf("ctor test: called\n");
- }
- void ctor_test2()
- {
- printf("ctor test2: called\n");
- }
- void ctor_test3()
- {
- printf("ctor test3: called\n");
- }
-
- CPPUNIT_TEST_SUITE(ctor);
- CPPUNIT_TEST(ctor_test);
- CPPUNIT_TEST(ctor_test2);
- CPPUNIT_TEST(ctor_test3);
- CPPUNIT_TEST_SUITE_END();
- };
-
- // -----------------------------------------------------------------------------
- CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(skeleton::ctor, "skeleton");
-} // unotest
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-
-NOADDITIONAL;
diff --git a/testshl2/workben/test_autoptr.cxx b/testshl2/workben/test_autoptr.cxx
deleted file mode 100644
index 076924a61fca..000000000000
--- a/testshl2/workben/test_autoptr.cxx
+++ /dev/null
@@ -1,100 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-#include <memory>
-#include <iostream>
-
-#include <stdio.h>
-
-#include <rtl/string.hxx>
-#include <rtl/ustring.hxx>
-
-class AutoPtrTest
-{
- int m_nValue;
-
- // NOCOPY
- AutoPtrTest(AutoPtrTest const& );
- AutoPtrTest& operator =(AutoPtrTest const& );
-
-public:
- AutoPtrTest(int _nValue = 1)
- :m_nValue(_nValue)
- {
- std::cout << "build Value" << std::endl;
- }
- ~AutoPtrTest()
- {
- std::cout << "release Value" << std::endl;
- m_nValue = 0;
- }
-// int operator int() const {return m_nValue;}
- int getValue() const {return m_nValue;}
-};
-
-std::auto_ptr<AutoPtrTest> getPtr()
-{
- return std::auto_ptr<AutoPtrTest>(new AutoPtrTest(2));
-}
-
-// auto_ptr get() gibt den Pointer ohne das ownership
-// auto_ptr release()gibt den Pointer und (!) das ownership
-
-void test_autoptr()
-{
- AutoPtrTest *pValuePtr;
- std::cout << "start test" << std::endl;
- {
- std::auto_ptr<AutoPtrTest> pValue = getPtr();
- std::cout << "Value with getValue() " << pValue->getValue() << std::endl;
- // std::cout << "Value operator int() " << *pValue << std::endl;
- // ownership weiterreichen
- pValuePtr = pValue.release();
- }
- std::cout << "ValuePtr with getValue() " << pValuePtr->getValue() << std::endl;
-
- // ownership an neuen Pointer uebergeben
- std::auto_ptr<AutoPtrTest> pValue2(pValuePtr);
-
- // AutoPtrTest *pStr = getPtr();
- std::cout << "end test" << std::endl;
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */ , char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc*/ , char* /*argv*/ [] )
-#endif
-{
- test_autoptr();
- return 0;
-}
diff --git a/testshl2/workben/test_filter.cxx b/testshl2/workben/test_filter.cxx
deleted file mode 100644
index a22e60182ef2..000000000000
--- a/testshl2/workben/test_filter.cxx
+++ /dev/null
@@ -1,230 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <vector>
-#include <string>
-#include <iostream>
-#include <rtl/string.hxx>
-
-typedef std::vector<std::string> StringList;
-typedef std::vector<rtl::OString> OStringList;
-
-void split( const rtl::OString& opt,
- const rtl::OString& _sSeparator,
- OStringList& optLine )
-{
- optLine.clear();
- // const sal_Int32 cSetLen = cSet.getLength();
- sal_Int32 index = 0;
- sal_Int32 oldIndex = 0;
-
- // sal_Int32 i;
- // sal_Int32 j = 0;
- while ( opt.getLength() > 0)
- {
- // for ( i = 0; i < cSetLen; i++ )
- // {
- index = opt.indexOf( _sSeparator, oldIndex);
- if( index != -1 )
- {
- optLine.push_back( opt.copy( oldIndex, index - oldIndex ) );
- oldIndex = index + _sSeparator.getLength();
- }
- // }
- else // if (index == -1)
- {
- optLine.push_back( opt.copy( oldIndex ) );
- break;
- }
- }
-} ///< split
-
-// -----------------------------------------------------------------------------
-
-StringList splitNameAtDot(rtl::OString const& _sName)
-{
- StringList aList;
- int nIndex = 0;
- // int nLastIndex = 0;
- while ((nIndex = _sName.indexOf(".")) != -1)
- {
- rtl::OString nValue;
- }
-
- return aList;
-}
-
-// -----------------------------------------------------------------------------
-/*
-bool checkFilter(JobList m_aJobFilter, std::string const& _sNodeName, std::string const& _sName)
-{
- std::string sFilter = m_aJobFilter.m_aJobList.begin();
-
- StringList aFilter;
- aFilter.push_back("rtl_OUString");
- aFilter.push_back("ctors");
- aFilter.push_back("*");
-
- StringList aMyName;
- aMyName.push_back("rtl_OUString");
- aMyName.push_back("ctors");
- aMyName.push_back("ctor_001");
-
-}
-*/
-
-void showList(OStringList const& _sList)
-{
- for(OStringList::const_iterator it = _sList.begin();
- it != _sList.end();
- ++it)
- {
- rtl::OString aStr = *it;
- std::cout << aStr.getStr() << std::endl;
- }
-}
-
-bool match(OStringList const& _aFilter, OStringList const& _aName)
-{
- OStringList::const_iterator aFilterIter = _aFilter.begin();
- OStringList::const_iterator aValueIter = _aName.begin();
-
- bool bMatch = false;
-
- while (aFilterIter != _aFilter.end() && aValueIter != _aName.end())
- {
- rtl::OString sFilter = *aFilterIter;
- rtl::OString sName = *aValueIter;
-
- if (sFilter == sName)
- {
- bMatch = true;
- ++aFilterIter;
- ++aValueIter;
- }
- else if (sFilter == "*")
- {
- bMatch = true;
- break;
- }
- else
- {
- // Filter does not match
- bMatch = false;
- break;
- }
- }
- return bMatch;
-}
-
-// -----------------------------------------------------------------------------
-void test_normal_filter()
-{
- OStringList aFilter;
- split("rtl_OUString.ctors.*", ".", aFilter);
- showList(aFilter);
-
- OStringList aName;
- split("rtl_OUString.ctors.ctor_001", ".", aName);
- showList(aName);
-
- if (match(aFilter, aName))
- {
- std::cout << "Name matches filter." << std::endl;
- }
-}
-
-void test_normal_filter_other_sep()
-{
- OStringList aFilter;
- split("rtl_OUString::ctors::*", "::", aFilter);
- showList(aFilter);
-
- OStringList aName;
- split("rtl_OUString::ctors::ctor_001", "::", aName);
- showList(aName);
-
- if (match(aFilter, aName))
- {
- std::cout << "Name matches filter." << std::endl;
- }
-}
-
-void test_no_name()
-{
- OStringList aFilter;
- split("rtl_OUString.*", ".", aFilter);
- showList(aFilter);
-
- OStringList aName;
- split("", ".", aName);
- showList(aName);
-
- if (match(aFilter, aName))
- {
- std::cout << "Name matches filter." << std::endl;
- }
-}
-
-void test_name_longer_filter()
-{
- OStringList aFilter;
- split("rtl_OUString.*", ".", aFilter);
- showList(aFilter);
-
- OStringList aName;
- split("rtl_OUString.ctor.ctor_001", ".", aName);
- showList(aName);
-
- if (match(aFilter, aName))
- {
- std::cout << "Name matches filter." << std::endl;
- }
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */ , char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc */, char* /* argv */ [] )
-#endif
-{
- test_normal_filter();
- test_normal_filter_other_sep();
- test_no_name();
- test_name_longer_filter();
-
- // split("rtl_OUString.*", ".", aFilter);
- // showList(aFilter);
-
-
- // test_autoptr();
- return 0;
-}
diff --git a/testshl2/workben/test_member.cxx b/testshl2/workben/test_member.cxx
deleted file mode 100644
index 11cf2bbc742a..000000000000
--- a/testshl2/workben/test_member.cxx
+++ /dev/null
@@ -1,97 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <iostream>
-#include <string>
-
-using namespace std;
-
-class Aint
-{
- int n;
-
-public:
-
- Aint():n(0)
- {
- cout << "ctor Aint()" << endl;
- }
- Aint(int _n):n(_n)
- {
- cout << "ctor Aint(int(" << _n << "))" << endl;
- }
- int getA() {return n;}
- ~Aint()
- {
- cout << "dtor Aint()" << endl;
- }
-
-};
-
-// -----------------------------------------------------------------------------
-
-class B
-{
- Aint a;
- Aint b;
- std::string aStr;
-
-public:
-
- B()
- :a(2)
- {
- cout << "ctor B()" << endl;
- }
- B(int _a)
- :a(_a)
- {
- cout << "ctor B(int)" << endl;
- }
-
- void foo()
- {
- cout << "a.getA() := " << a.getA() << endl;
- cout << "b.getA() := " << b.getA() << endl;
- }
-
-};
-
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int argc, char* argv[] )
-#else
-int _cdecl main( int argc, char* argv[] )
-#endif
-{
- B b(4);
- b.foo();
-}
diff --git a/testshl2/workben/test_ostringstream.cxx b/testshl2/workben/test_ostringstream.cxx
deleted file mode 100644
index f49b54cd6a9f..000000000000
--- a/testshl2/workben/test_ostringstream.cxx
+++ /dev/null
@@ -1,116 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <stdlib.h>
-#include <memory>
-#include <sstream>
-#include <iostream>
-#include <bitset>
-
-#include <sal/types.h>
-
-
-class TestFactoryRegistry
-{
-public:
- void checkFunc(char* foo);
- void checkFunc2(char* foo);
- void checkFunc3(char* foo);
-};
-
-
-void TestFactoryRegistry::checkFunc(char* /* foo */ )
-{
- static int serialNumber = 1;
-
- std::ostringstream ost;
-//! could this be the problem?
- ost << "@Dummy@" << serialNumber++;
- std::cout << ost.str() << std::endl;
-}
-
-void TestFactoryRegistry::checkFunc2(char* /* foo */)
-{
- static int serialNumber = 1;
-
- std::ostringstream ost;
-//! could this be the problem?
- ost << "@Dummy@" << serialNumber;
- serialNumber++;
- std::cout << ost.str() << std::endl;
-}
-
-void TestFactoryRegistry::checkFunc3(char* /* foo */)
-{
- static int serialNumber = 1;
-
- int nValue = serialNumber;
- std::ostringstream ost;
-//! could this be the problem?
- ost << "@Dummy@" << nValue;
- serialNumber++;
- std::cout << ost.str() << std::endl;
-}
-
-static TestFactoryRegistry a;
-static TestFactoryRegistry b;
-static TestFactoryRegistry c;
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */ , char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc */, char* /* argv */ [] )
-#endif
-{
- std::ostringstream ost;
- // sal_Int32 nValue = 1;
-
- // ost << "@Dummy@" << nValue;
- // ost << "dec: " << 15 << std::hex << " hex: " << 15 << std::endl;
-
- // std::cout << ost.str() << std::endl;
-
- char* cFoo = NULL;
-
- a.checkFunc(cFoo);
- a.checkFunc2(cFoo);
- a.checkFunc3(cFoo);
-
- b.checkFunc(cFoo);
- b.checkFunc2(cFoo);
- b.checkFunc3(cFoo);
-
- c.checkFunc(cFoo);
- c.checkFunc2(cFoo);
- c.checkFunc3(cFoo);
-
- return 0;
-}
diff --git a/testshl2/workben/test_preproc.cxx b/testshl2/workben/test_preproc.cxx
deleted file mode 100644
index 4614a9783ab5..000000000000
--- a/testshl2/workben/test_preproc.cxx
+++ /dev/null
@@ -1,55 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <iostream>
-#include <string>
-#include <rtl/string.hxx>
-
-using namespace std;
-
-#define atest(name) \
- { \
- /*if (strlen(#name))*/ { \
- cout << "String len: " << strlen(#name) << " string: " << #name << endl; \
- }}
-
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */, char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc */, char* /* argv */ [] )
-#endif
-{
- cout << "test preprocessor: " << endl;
- atest(fuck);
- // atest(); compiler error, use "" instead
- atest("");
-}
diff --git a/testshl2/workben/test_printf.cxx b/testshl2/workben/test_printf.cxx
deleted file mode 100644
index a6fd7d86f618..000000000000
--- a/testshl2/workben/test_printf.cxx
+++ /dev/null
@@ -1,60 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-
-#include <string>
-#include <stdarg.h>
-#include <stdio.h>
-
-void t_print(const char* _pFormatStr, va_list &args)
-{
- vprintf(_pFormatStr, args);
-}
-
-void t_print(const char* _pFormatStr, ...)
-{
- va_list args;
- va_start( args, _pFormatStr );
- t_print(_pFormatStr, args);
- va_end( args );
-}
-
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */ , char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc */ , char* /* argv */ [] )
-#endif
-{
- std::string sStr("TestString.");
- printf("Test %s\n", sStr.c_str() );
- t_print("Test %s\n", sStr.c_str() );
- return 0;
-}
diff --git a/testshl2/workben/test_string.cxx b/testshl2/workben/test_string.cxx
deleted file mode 100644
index 0d8d83d83192..000000000000
--- a/testshl2/workben/test_string.cxx
+++ /dev/null
@@ -1,138 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include <iostream>
-#include <string>
-#include <rtl/string.hxx>
-
-using namespace std;
-
-const char* g_cSeparatorList = " \t,;:#";
-
-std::string trim(std::string const& _sStringToTrim)
-{
- rtl::OString sStr(_sStringToTrim.c_str());
- sStr = sStr.trim();
- return std::string(sStr.getStr());
-}
-
-bool isInCurrentEnvironment(std::string const& _sString)
-{
- int nSpace = 0;
- std::string sSearchString = _sString;
- bool bEnd = false;
- // run through the hole given string,
- std::string sEnv;
-
- do {
- nSpace = sSearchString.find_first_of(g_cSeparatorList);
- if (nSpace < 0)
- {
- sEnv = sSearchString;
- bEnd = true;
- }
- else
- {
- sEnv = sSearchString.substr(0, nSpace);
- sSearchString = sSearchString.substr(nSpace + 1);
- }
- if (sEnv.length() > 0)
- {
- cout << sEnv << endl;
-#ifdef LINUX
- int nLinux = sEnv.find("unxlng");
- if (nLinux >= 0)
- {
- // found unxlng
- return true;
- }
-#endif
-#ifdef SOLARIS
- int nSolaris = sEnv.find("unxsol");
- if (nSolaris >= 0)
- {
- // found unxsol
- return true;
- }
-#endif
-#ifdef WNT
- int nWindows = sEnv.find("wnt");
- if (nWindows >= 0)
- {
- // found wnt
- return true;
- }
-#endif
- }
- } while ( !bEnd );
- return false;
-}
-
-// ----------------------------------- Main -----------------------------------
-#if (defined UNX) || (defined OS2)
-int main( int /* argc */, char* /* argv */ [] )
-#else
- int _cdecl main( int /* argc */ , char* /* argv */ [] )
-#endif
-{
- string sLine1 = "osl_Socket.ctor.ctors_001";
- string sLine = "osl_Socket.ctor.ctors_001 unxlngi5.pro unxsols4.pro wntmsci ";
-
- int nSpace = sLine.find_first_of(g_cSeparatorList);
- cout << "Space: " << nSpace << endl;
- std::string sTest;
-
- if (nSpace > 0)
- {
- sLine = trim(sLine);
- // check environment
- sTest = sLine.substr(0, nSpace);
- std::string sRest = sLine.substr(nSpace + 1);
- if (isInCurrentEnvironment(sRest))
- {
- cout << "new string: " << sTest << endl;
- }
- }
- else
- {
- // every environment
- cout << "new string: " << sLine << endl;
- }
-
- // cout << "rest string: " << sRest << endl;
-
- int nCount = 10;
- do {
- cout << nCount << endl;
- nCount --;
- }
- while (nCount >= 0);
- cout << nCount << endl;
-}
diff --git a/testshl2/workben/uno/export.exp b/testshl2/workben/uno/export.exp
deleted file mode 100644
index a13529da5876..000000000000
--- a/testshl2/workben/uno/export.exp
+++ /dev/null
@@ -1 +0,0 @@
-registerAllTestFunction
diff --git a/testshl2/workben/uno/export.map b/testshl2/workben/uno/export.map
deleted file mode 100755
index 2718fd9a5cc4..000000000000
--- a/testshl2/workben/uno/export.map
+++ /dev/null
@@ -1,8 +0,0 @@
-UDK_3.0 {
- global:
- registerAllTestFunction;
-
- local:
- *;
-};
-
diff --git a/testshl2/workben/uno/makefile.mk b/testshl2/workben/uno/makefile.mk
deleted file mode 100644
index ea4cc1c0b758..000000000000
--- a/testshl2/workben/uno/makefile.mk
+++ /dev/null
@@ -1,79 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
-
-PRJNAME=sal
-TARGET=qa_uno
-# this is removed at the moment because we need some enhancements
-# TESTDIR=TRUE
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-#------------------------------- All object files -------------------------------
-# do this here, so we get right dependencies
-# SLOFILES= \
-# $(SLO)$/unotest.obj
-
-#----------------------------------- ByteSequence -----------------------------------
-
-SHL1OBJS= \
- $(SLO)$/unotest.obj
-
-SHL1TARGET= unotest
-SHL1STDLIBS=\
- $(SALLIB) \
- $(CPPUHELPERLIB) \
- $(COMPHELPERLIB) \
- $(CPPULIB) \
- $(CPPUNITLIB)
-
-# link $(CPPUNIT) to SHL1STDLIBS instead
-# .IF "$(GUI)" == "WNT"
-# SHL1STDLIBS+= $(SOLARLIBDIR)$/cppunit.lib
-# .ENDIF
-# .IF "$(GUI)" == "UNX"
-# SHL1STDLIBS+=$(SOLARLIBDIR)$/libcppunit$(DLLPOSTFIX).a
-# .ENDIF
-
-SHL1IMPLIB= i$(SHL1TARGET)
-# SHL1DEF= $(MISC)$/$(SHL1TARGET).def
-
-DEF1NAME =$(SHL1TARGET)
-# DEF1EXPORTFILE= export.exp
-SHL1VERSIONMAP = export.map
-
-
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-.INCLUDE : _cppunit.mk
-
diff --git a/testshl2/workben/uno/unotest.cxx b/testshl2/workben/uno/unotest.cxx
deleted file mode 100644
index d4d3f78f56b6..000000000000
--- a/testshl2/workben/uno/unotest.cxx
+++ /dev/null
@@ -1,114 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_testshl2.hxx"
-#include "rtl/bootstrap.hxx"
-#include <comphelper/processfactory.hxx>
-#include <com/sun/star/uno/XComponentContext.hpp>
-#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#include <cppunit/simpleheader.hxx>
-#include <cppuhelper/bootstrap.hxx>
-#include <com/sun/star/xml/sax/XParser.hpp>
-
-namespace css = com::sun::star;
-namespace lang = css::lang;
-namespace uno = css::uno;
-namespace sax = css::xml::sax;
-
-
-// StringHelper
-inline void operator <<= (rtl::OString& _rAsciiString, const rtl::OUString& _rUnicodeString)
-{
- _rAsciiString = rtl::OUStringToOString(_rUnicodeString,RTL_TEXTENCODING_ASCII_US);
-}
-
-
-namespace unotest
-{
-//------------------------------------------------------------------------
-// testing constructors
-//------------------------------------------------------------------------
-
- class ctor : public CppUnit::TestFixture
- {
- public:
- void ctor_001()
- {
- uno::Reference< lang::XMultiServiceFactory > xFactory( ::comphelper::getProcessServiceFactory() );
- if (xFactory.is())
- {
- // sample, get a xParser instance
- uno::Reference< sax::XParser > xParser;
- xParser = uno::Reference< sax::XParser > (
- xFactory->createInstance(
- ::rtl::OUString::createFromAscii("com.sun.star.xml.sax.Parser")), uno::UNO_QUERY);
-
- CPPUNIT_ASSERT_MESSAGE("can't get sax::Parser", xParser.is());
- }
- }
- void ctor_002()
- {
- CPPUNIT_ASSERT_MESSAGE("Simple testshl2 test, MUST fail.", sal_False);
- }
-
- CPPUNIT_TEST_SUITE(ctor);
- CPPUNIT_TEST(ctor_001);
- CPPUNIT_TEST(ctor_002);
- CPPUNIT_TEST_SUITE_END();
- };
-
- // -----------------------------------------------------------------------------
- CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(unotest::ctor, "unotest");
-} // unotest
-
-// -----------------------------------------------------------------------------
-
-// this macro creates an empty function, which will called by the RegisterAllFunctions()
-// to let the user the possibility to also register some functions by hand.
-
-
-void RegisterAdditionalFunctions(FktRegFuncPtr _pFunc)
-{
- (void) _pFunc;
- uno::Reference<lang::XMultiServiceFactory> xMS;
-
- try
- {
- uno::Reference< uno::XComponentContext > xComponentContext = cppu::defaultBootstrap_InitialComponentContext();
- xMS.set(xComponentContext->getServiceManager(), uno::UNO_QUERY);
- comphelper::setProcessServiceFactory(xMS);
- }
- catch (::com::sun::star::uno::Exception e )
- {
- rtl::OString aError;
- aError <<= e.Message;
- printf("Error: %s\n", aError.getStr());
- }
-}
-// NOADDITIONAL;
diff --git a/testtools/source/bridgetest/makefile.mk b/testtools/source/bridgetest/makefile.mk
index afaacb3e1c4a..9b75a1aed1e3 100644
--- a/testtools/source/bridgetest/makefile.mk
+++ b/testtools/source/bridgetest/makefile.mk
@@ -80,11 +80,7 @@ SHL1STDLIBS= \
SHL1LIBS= $(LIB1TARGET)
SHL1DEF= $(MISC)$/$(SHL1TARGET).def
DEF1NAME= $(SHL1TARGET)
-.IF "$(COMNAME)" == "gcc3"
-SHL1VERSIONMAP = component.gcc3.map
-.ELSE
-SHL1VERSIONMAP = component.map
-.ENDIF
+SHL1VERSIONMAP = $(SOLARENV)/src/component.map
# ---- test object ----
@@ -103,16 +99,12 @@ SHL2STDLIBS= \
SHL2LIBS= $(LIB2TARGET)
SHL2DEF= $(MISC)$/$(SHL2TARGET).def
DEF2NAME= $(SHL2TARGET)
-.IF "$(COMNAME)" == "gcc3"
-SHL2VERSIONMAP = component.gcc3.map
-.ELSE
-SHL2VERSIONMAP = component.map
-.ENDIF
+SHL2VERSIONMAP = $(SOLARENV)/src/component.map
SHL3TARGET = constructors.uno
SHL3OBJS = $(SLO)$/constructors.obj
SHL3STDLIBS = $(CPPULIB) $(CPPUHELPERLIB) $(SALLIB)
-SHL3VERSIONMAP = component.map
+SHL3VERSIONMAP = $(SOLARENV)/src/component.map
SHL3IMPLIB = i$(SHL3TARGET)
DEF3NAME = $(SHL3TARGET)
@@ -154,24 +146,16 @@ $(DLLDEST)$/uno_types.rdb : $(SOLARBINDIR)$/udkapi.rdb
$(REGMERGE) $@ / $(BIN)$/bridgetest.rdb
$(DLLDEST)$/bridgetest_client$(BATCH_SUFFIX) .ERRREMOVE: makefile.mk
-.IF "$(USE_SHELL)" == "bash"
echo '$(AUGMENT_LIBRARY_PATH)' '$(SOLARBINDIR)'/uno -ro uno_services.rdb -ro uno_types.rdb \
-s com.sun.star.test.bridge.BridgeTest -- \
-u \''uno:socket,host=127.0.0.1,port=2002;urp;test'\' > $@
-.ELSE
- echo ERROR: this script can only be created properly for USE_SHELL=bash > $@
-.ENDIF
$(GIVE_EXEC_RIGHTS) $@
$(DLLDEST)$/bridgetest_server$(BATCH_SUFFIX) .ERRREMOVE: makefile.mk
-.IF "$(USE_SHELL)" == "bash"
echo '$(AUGMENT_LIBRARY_PATH)' '$(SOLARBINDIR)'/uno -ro uno_services.rdb -ro uno_types.rdb \
-s com.sun.star.test.bridge.CppTestObject \
-u \''uno:socket,host=127.0.0.1,port=2002;urp;test'\' --singleaccept \
> $@
-.ELSE
- echo ERROR: this script can only be created properly for USE_SHELL=bash > $@
-.ENDIF
$(GIVE_EXEC_RIGHTS) $@
@@ -191,14 +175,10 @@ $(DLLDEST)$/bridgetest_javaserver$(BATCH_SUFFIX) : makefile.mk
$(GIVE_EXEC_RIGHTS) $@
$(DLLDEST)$/bridgetest_inprocess_java$(BATCH_SUFFIX) .ERRREMOVE: makefile.mk
-.IF "$(USE_SHELL)" == "bash"
echo '$(AUGMENT_LIBRARY_PATH)' '$(SOLARBINDIR)'/uno -ro uno_services.rdb -ro uno_types.rdb \
-s com.sun.star.test.bridge.BridgeTest \
-env:URE_INTERNAL_JAVA_DIR=$(MY_URE_INTERNAL_JAVA_DIR) \
-- com.sun.star.test.bridge.JavaTestObject noCurrentContext > $@
-.ELSE
- echo ERROR: this script can only be created properly for USE_SHELL=bash > $@
-.ENDIF
$(GIVE_EXEC_RIGHTS) $@
.ENDIF
diff --git a/testtools/source/bridgetest/pyuno/makefile.mk b/testtools/source/bridgetest/pyuno/makefile.mk
index d7172edae3f0..fb7a78f71f4a 100644
--- a/testtools/source/bridgetest/pyuno/makefile.mk
+++ b/testtools/source/bridgetest/pyuno/makefile.mk
@@ -41,11 +41,6 @@ ENABLE_EXCEPTIONS=TRUE
PYEXC=$(DLLDEST)$/python$(EXECPOST)
REGEXC=$(DLLDEST)$/regcomp$(EXECPOST)
-DOLLAR_SIGN=\$$
-.IF "$(USE_SHELL)" != "tcsh"
-DOLLAR_SIGN=$$
-.ENDIF
-
.IF "$(SYSTEM_PYTHON)"!="YES"
PYTHON=$(AUGMENT_LIBRARY_PATH) $(WRAPCMD) $(SOLARBINDIR)/python
.ELSE # "$(SYSTEM_PYTHON)"!="YES"
@@ -59,25 +54,13 @@ PYTHONPATH:=$(SOLARLIBDIR)$/pyuno:$(PWD):$(SOLARLIBDIR):$(SOLARLIBDIR)$/python:$
.EXPORT: PYTHONPATH
.IF "$(GUI)"!="WNT" && "$(GUI)"!="OS2"
-.IF "$(USE_SHELL)"=="bash"
TEST_ENV=export FOO=file://$(shell @pwd)$/$(DLLDEST) \
UNO_TYPES=pyuno_regcomp.rdb UNO_SERVICES=pyuno_regcomp.rdb
-.ELSE
-TEST_ENV=\
- setenv FOO file://$(shell @pwd)$/$(DLLDEST) && \
- setenv UNO_TYPES pyuno_regcomp.rdb && setenv UNO_SERVICES pyuno_regcomp.rdb
-.ENDIF
.ELSE # "$(GUI)" != "WNT"
# aaaaaa, how to get the current working directory on windows ???
CWD_TMP=$(strip $(shell @echo "import os;print os.getcwd()" | $(PYTHON)))
-.IF "$(USE_SHELL)" == "tcsh"
-TEST_ENV=setenv FOO file:///$(strip $(subst,\,/ $(CWD_TMP)/$(DLLDEST))) && \
- setenv UNO_TYPES pyuno_regcomp.rdb && setenv UNO_SERVICES pyuno_regcomp.rdb
-.ELSE
TEST_ENV=export FOO=file:///$(strip $(subst,\,/ $(CWD_TMP)$/$(DLLDEST))) && \
export UNO_TYPES=pyuno_regcomp.rdb && export UNO_SERVICES=pyuno_regcomp.rdb
-.ENDIF "$(USE_SHELL)" == "tcsh"
-
.ENDIF # "$(GUI)"!="WNT"
PYFILES = \
$(DLLDEST)$/core.py \
@@ -120,6 +103,6 @@ runtest : ALL
cd $(DLLDEST) && $(TEST_ENV) && $(WRAPCMD) $(REGCOMP) -register -br pyuno_regcomp.rdb -r dummy.rdb \
-l com.sun.star.loader.Python $(foreach,i,$(PYCOMPONENTS) -c vnd.openoffice.pymodule:$(i))
cd $(DLLDEST) && $(TEST_ENV) && $(WRAPCMD) $(REGCOMP) -register -br pyuno_regcomp.rdb -r dummy2.rdb \
- -l com.sun.star.loader.Python -c vnd.sun.star.expand:$(DOLLAR_SIGN)FOO/samplecomponent.py
+ -l com.sun.star.loader.Python -c vnd.sun.star.expand:$$FOO/samplecomponent.py
.ENDIF # L10N_framework