summaryrefslogtreecommitdiff
path: root/testautomation/spreadsheet/tools/includes
diff options
context:
space:
mode:
authorAugust Sodora <augsod@gmail.com>2011-12-07 00:55:10 -0500
committerAugust Sodora <augsod@gmail.com>2011-12-07 00:56:22 -0500
commita2eb0cf44bbd15ae24f9423d3bc6e420691c300d (patch)
treeb11ce54011011e96217d9b504e81ec87aaef38a4 /testautomation/spreadsheet/tools/includes
parente2621785569969374cc3bc39fae0341d8b848612 (diff)
Remove testtool
Diffstat (limited to 'testautomation/spreadsheet/tools/includes')
-rw-r--r--testautomation/spreadsheet/tools/includes/c_cell_tools.inc102
-rw-r--r--testautomation/spreadsheet/tools/includes/c_l10n_tools.inc232
-rw-r--r--testautomation/spreadsheet/tools/includes/c_select_tools.inc232
-rw-r--r--testautomation/spreadsheet/tools/includes/c_tool_l10n_mnomics.inc160
-rw-r--r--testautomation/spreadsheet/tools/includes/c_tool_options.inc95
-rw-r--r--testautomation/spreadsheet/tools/includes/c_validity_tools.inc139
6 files changed, 0 insertions, 960 deletions
diff --git a/testautomation/spreadsheet/tools/includes/c_cell_tools.inc b/testautomation/spreadsheet/tools/includes/c_cell_tools.inc
deleted file mode 100644
index 0693f1daf19c..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_cell_tools.inc
+++ /dev/null
@@ -1,102 +0,0 @@
-'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 : oliver.craemer@oracle.com
-'*
-'* short description : tools for working with cells in calc
-'*
-'**************************************************************************************************
-'*
-' #1 fCalcGetCellValue 'Returns the value of a given cell
-' #1 fCalcCompareCellValue 'Compares the value of a given cell with a given result
-' #1 fCalcCompareCellFormular 'Compares the formular of a cell with a given result
-'*
-'\************************************************************************************************
-
-function fCalcGetCellValue ( sCelladdress as string ) as string
-
- '///<b>The function returns the content of a given cell</b>
- '///+The cell is selected by fCalcSelectRange which is located in /spreadsheet/tools/includes/c_select_tools.inc
- '///+The content is copied to the clipboard by slot EditCopy
- '///+ and read out by GetClipboardText which is located in /global/tools/inc/t_tools1.inc
- use "spreadsheet\tools\includes\c_select_tools.inc"
- use "global\tools\includes\required\t_tools1.inc"
-
- call fCalcSelectRange (sCelladdress) 'Select the given cell
- kontext "DocumentCalc" 'Setting kontext to Calcdocument
- EditCopy 'Copy content to clipboard
- fCalcGetCellValue = GetClipboardText 'Returning clipboard to function
-
-end function
-
-'-------------------------------------------------------------------------
-
-function fCalcCompareCellValue ( sCelladdress as string, sresult as string ) as boolean
-
- '///<b>The function compares the value of a cell with a given result</b>
- '///+The cellvalue is read by fCalcGetCellValue which is located in /spreadsheet/tools/includes/c_cell_tools.inc
- '///+The value is compared with a given result (input)
- '///+The function returns true if the comparison is correct and false for incorrect
-
- if fCalcGetCellValue ( sCelladdress ) = sresult then
- printlog " The cellvalue is correct"
- fCalcCompareCellValue = true
- else
- warnlog "The cellvalue is " & fCalcGetCellValue ( sCelladdress ) & " but should be " & sresult
- fCalcCompareCellValue = false
- end if
-
-end function
-
-'-------------------------------------------------------------------------
-
-function fCalcCompareCellFormular ( sCelladdress as string, sresult as string ) as boolean
-
- '///<b>The function compares the formular of a cell with a given result</b>
- '///+The value is compared with a given result (input)
- '///+The function returns true if the comparison is correct and false for incorrect
-
- dim sfunctionwithparameter as string
-
- call fCalcSelectRange (sCelladdress)
- kontext ( "RechenleisteCalc" )
- EingabeZeileCalc.TypeKeys ("<f2><mod1 a>")
- editcopy
- sfunctionwithparameter = GetClipboardText ()
- '/// Press twice <ESCAPE> to leave the cell
- 'printlog "Press twice <ESCAPE> to leave the cell"
- kontext ( "DocumentCalc" )
- DocumentCalc.TypeKeys "<ESCAPE>" , 2
- if sfunctionwithparameter = sresult then
- printlog " The function is correct"
- fCalcCompareCellFormular = true
- else
- warnlog "The function is " & sfunctionwithparameter & " instead of " & sresult
- fCalcCompareCellFormular = false
- end if
-
-end function
diff --git a/testautomation/spreadsheet/tools/includes/c_l10n_tools.inc b/testautomation/spreadsheet/tools/includes/c_l10n_tools.inc
deleted file mode 100644
index 1807ab4bf35a..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_l10n_tools.inc
+++ /dev/null
@@ -1,232 +0,0 @@
-'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 : oliver.craemer@oracle.com
-'*
-'* short description : tools for localisation in calc
-'*
-'\************************************************************************************************
-
-function fFunctionname ( sFunctionname_en as string ) as string
-
- '///<b>The function returns the localized name of a given function in the current UI language</b>
- '///+ -Input is the english name of the function as string
- '///+ -Output is the localized name of the function as string
- '///+ -If there is no translation available the fallback is the english name
-
- dim sloaddocument as string
- dim sfunctionstring as string
- dim scelladress as string
-
- use "global/tools/includes/required/t_doc2.inc"
- const CFN = "spreadsheet:tools:includes:c_l10n_tools.in:fFunctionname "
-
- sloaddocument = gTesttoolPath & "spreadsheet\tools\input\Functionnames.ods"
-
- '///Load document with all functions <i>gTestToolPath</i>/spreadsheet/tools/input/Functionnames.ods
- hFileOpenLocally( sloaddocument )
- sleep (2)
-
- '///Setting selection to A1 to avoid messagebox in Search and Replace dialog.
- call fCalcSelectRange ("A1")
- '///Search for function by Search and Replace dialog
- kontext "DocumentCalc"
- EditSearchAndReplace
-
- kontext "FindAndReplace"
- printlog( "Reset <Find and Replace> dialog to default settings" )
- if ( FindAndReplace.exists( 1 ) ) then
- More.Click
- SimilaritySearch.UnCheck
- CurrentSelectionOnly.UnCheck
- Backwards.UnCheck
- SearchForStyles.UnCheck
- SearchIn.Select 1
- '///Setting search parameter
- WholeWordsOnly.Check
- SearchFor.SetText sFunctionname_en
- SearchNow.click
- kontext
- '///If a MsgBox appears the search must have failed => Fallback to english name
- if active.exists then
- if active.getRT = 304 then
- warnlog CFN & "Function not found, falling back to english name"
- fFunctionname = sFunctionname_en
- active.OK
- else
- '///Throw a warning if a dialog of unexpected resource type appears
- warnlog CFN & "Unknown message box! " & active.GetText
- active.Default
- fFunctionname = sFunctionname_en
- end if
-
- kontext "FindAndReplace"
- printlog( "Reset dialog to default settings" )
- if ( FindAndReplace.exists( 1 ) ) then
- WholeWordsOnly.UnCheck
- hCloseDialog( FindAndReplace, "close" )
- else
- warnlog( CFN & "<FindAndReplace> not open" )
- endif
- call hCloseDocument
- exit function
- end if
-
- kontext "FindAndReplace"
- printlog( "Reset <Find and Replace> dialog to default settings" )
- if ( FindAndReplace.exists( 1 ) ) then
- WholeWordsOnly.UnCheck
- hCloseDialog( FindAndReplace, "close" )
- else
- warnlog( CFN & "<FindAndReplace> not open" )
- endif
-
- Kontext "RechenleisteCalc"
- scelladress = Bereich.GetSelText
- if fCalcGetCellValue (scelladress) = sFunctionname_en then
- '///Get localised string for function by extracting functionname out of next cell
- call fCalcSelectRange ( "B" & mid(scelladress,2) )
- kontext ( "RechenleisteCalc" )
- EingabeZeileCalc.TypeKeys ("<f2><mod1 a>")
- editcopy
- sfunctionstring = GetClipboardText ()
- kontext "DocumentCalc"
- DocumentCalc.TypeKeys ("<ESCAPE>",2)
- ' DEBUG: printlog sfunctionstring
- ' DEBUG: printlog len(sfunctionstring)
- ' DEBUG: printlog instr(sfunctionstring,"(")
- fFunctionname = mid(sfunctionstring,2,(instr(sfunctionstring,"(")-2)
- printlog " The name of the function in this locale (" & iSprache & ") is " & fFunctionname
- else
- warnlog CFN & "Function not found, falling back to english version"
- fFunctionname = sFunctionname_en
- end if
- else
- warnlog( CFN & "Unable to open <FindAndReplace> dialog" )
- endif
-
- call hCloseDocument
- hFileDelete( gLastWorkFile )
-
-end function
-
-'
-'----------------------------------------------------------------------------
-'
-
-function fError_l10n ( sError_en as string ) as string
-
- '///<b>The function returns the localized name of a given error in the current UI language</b>
- '///+ -Input is the english name of the error as string
- '///+ -Output is the localized name of the error as string
- '///+ -If there is no translation available the fallback is the english name
-
- dim sloaddocument as string
- dim sfunctionstring as string
- dim scelladress as string
-
- use "global/tools/includes/required/t_doc2.inc"
- const CFN = "qa:qatesttool:spreadsheet:tools:includes:c_l10n_tools.in:fError_l10n "
-
- sloaddocument = gTesttoolPath & "spreadsheet\tools\input\Errorcodes.ods"
-
- '///Load document with all errorcodes <i>gTestToolPath</i>/spreadsheet/tools/input/Errorcodes.ods
- hFileOpenLocally( sloaddocument )
-
- '///Setting selection to A1 to avoid messagebox in Search and Replace dialog.
- call fCalcSelectRange ("A1")
- '///Search for function by Search and Replace dialog
- kontext "DocumentCalc"
- EditSearchAndReplace
- sleep (1)
- kontext "FindAndReplace"
- '///Setting dialog to defaults
- More.Click
- SimilaritySearch.UnCheck
- CurrentSelectionOnly.UnCheck
- Backwards.UnCheck
- SearchForStyles.UnCheck
- SearchIn.Select 1
- '///Setting search parameter
- WholeWordsOnly.Check
- SearchFor.SetText sError_en
- SearchNow.click
- kontext
- '///If a MsgBox appears the search must have failed => Fallback to english name
- if active.exists then
- if active.getRT = 304 then
- warnlog CFN & "Function not found, falling back to english name"
- fError_l10n = sError_en
- active.OK
- else
- '///Throw a warning if a dialog of unexpected resource type appears
- warnlog CFN & "Unknown message box! " & active.GetText
- active.Default
- fError_l10n = sError_en
- end if
-
- kontext "FindAndReplace"
- '///Reset dialog to defaultsetting
- if ( FindAndReplace.exists( 1 ) ) then
- WholeWordsOnly.UnCheck
- hCloseDialog( FindAndReplace, "close" )
- else
- warnlog( CFN & "Failed to open <FindAndReplace>" )
- endif
-
- call hCloseDocument
- exit function
- end if
-
- kontext "FindAndReplace"
- '///Reset dialog to defaultsetting
- if ( FindAndReplace.exists( 1 ) ) then
- WholeWordsOnly.UnCheck
- hCloseDialog( FindAndReplace, "close" )
- else
- warnlog( CFN & "Failed to open <FindAndReplace>" )
- endif
-
- Kontext "RechenleisteCalc"
- scelladress = Bereich.GetSelText
- if fCalcGetCellValue (scelladress) = sError_en then
- '///Get localised string for ERR by extracting errorcode out of next cell
- call fCalcSelectRange ( "B" & mid(scelladress,2) )
- kontext "DocumentCalc"
- editcopy
- fError_l10n = GetClipboardText ()
- kontext "DocumentCalc"
- printlog " The name for ERR in this locale (" & iSprache & ") is " & fError_l10n
- else
- warnlog CFN & "Errorcode not found, falling back to english version"
- fError_l10n = sError_en
- end if
-
- call hCloseDocument
- hFileDelete( gLastWorkFile )
-
-end function
diff --git a/testautomation/spreadsheet/tools/includes/c_select_tools.inc b/testautomation/spreadsheet/tools/includes/c_select_tools.inc
deleted file mode 100644
index f1087ca3fe8b..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_select_tools.inc
+++ /dev/null
@@ -1,232 +0,0 @@
-'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 : oliver.craemer@oracle.com
-'*
-'* short description : selecting objects in calc
-'*
-'**************************************************************************************************
-'*
-' #1 fCalcSelectRange
-' #1 fCalcNameRange
-' #1 fCalcSelectCell
-' #1 fCalcGetSelectionString
-' #1 fCalcSelectSheet
-' #1 fNavigatorSelectObject
-'*
-'\************************************************************************************************
-
-function fCalcSelectRange ( sSelectThis ) as boolean
- '///<b>Select a range in calc and check success
- '///+Valid cell reference and name should work here
- '///+RETURNS: BOOLEAN</b>
- fCalcSelectRange = FALSE
- '///<ul>
- '///<li>Check if 'formula bar' is visible</li>///
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- '///<li>-> Throw warning and Invoke 'formula bar' if invisible</li>///
- '///<li>-> NOTE: The testcase developer has to take care herself that function is entered correctly</li>///
- warnlog "Formula bar was expected to be visible"
- ViewToolbarsFormulaBar
- end if
- sleep(2)
- '///<li>Select the desired range</li>///
- Kontext "RechenleisteCalc"
- Bereich.TypeKeys "<MOD1 A>"
- Bereich.TypeKeys ( sSelectThis )
- sleep(1)
- Bereich.TypeKeys "<RETURN>"
- sleep(2)
- '///<li>Check if input leads to success</li>///
- kontext
- '///<li>If a MsgBox is in the way the selection must have failed</li>///
- if active.exists then
- if active.getRT = 304 then
- '///<li>-> NOTE: Only throw a PrintLog if selection fails because failture may be the desired result!</li>///
- '///<li>-> FURTHER NOTE: We retrun FALSE to check this in the calling routine</li>///
- printlog "Selecting the range failed due to known reason, e.g. wrong selection or invalid name"
- Active.OK
- else
- '///<li>Only throw a waring if a dialog of unexpected resource type appears</li>///
- warnlog "OOPS, don't know what's disturbing now -> CHECK IT OUT!"
- end if
- else
- '///<li>Everything OK? -> TRUE</li>///
- fCalcSelectRange = TRUE
- end if
-end function
-'///</ul>
-
-'-------------------------------------------------------------------------
-
-function fCalcNameRange ( sNameThis ) as boolean
- '///<b>This is just an alias function to avoid confusion -> see 'fCalcSelectRange'<b>
- '///With the integration of CWS 'rangename' the function 'fCalcSelectRange'
- '///+could also be used to name a previous selected range
- fCalcNameRange = fCalcSelectRange ( sNameThis )
-end function
-
-'
-'--------------------------------------------------------------------
-'
-
-function fCalcSelectCell ( sSelectThisCell ) as boolean
- '///<b>This is just an alias function to avoid confusion -> see 'fCalcSelectRange'<b>
- fCalcSelectCell = fCalcSelectRange ( sSelectThisCell )
-end function
-
-'
-'--------------------------------------------------------------------
-'
-
-function fCalcGetSelectionString() as String
- '///<b>Obtain range (e.g. 'A1:E10') or range name in 'formula bar'
- '///+RETURNS: STRING</b>///
- '///<ul>
- '///<li>Check if 'formula bar' is visible</li>///
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- '///<li>-> Throw warning and Invoke 'formula bar' if invisible</li>///
- '///<li>-> NOTE: The testcase developer has to take care herself that function is entered correctly</li>///
- warnlog "Formula bar was expected to be visible"
- ViewToolbarsFormulaBar
- end if
- sleep(2)
- '///<li>Get and return string in range selection list box</li>///
- Kontext "RechenleisteCalc"
- fCalcGetSelectionString = Bereich.GetSelText
- '///</ul>
-end function
-
-'
-'--------------------------------------------------------------------
-'
-
-function fCalcSelectSheet ( sSelectThisSheet ) as boolean
-
- '///<b>Select a sheet by name (STRING) or number (INTEGER)///
- '///+RETURNS: boolean (success)</u>///
- fCalcSelectSheet = FALSE
- '///<ul>
- try
- Kontext "DocumentCalc"
- '///<li>Invoke Edit::Sheet::Select</li>///
- EditSheetSelect
- Kontext "SelectSheets"
- '///<li>Select sheet no. or sheet name in listbox</li>///
- SheetSelectionBox.Select ( sSelectThisSheet )
- '///<li>OK</li>///
- SelectSheets.OK
- '///<li>Return true</li>///
- fCalcSelectSheet = TRUE
- catch
- warnlog "Something went wrong while selecting a sheet by name"
- '///<li>In case of failture lookup 'Select sheets' dialog andd close it if exists</li>///
- Kontext "SelectSheets"
- if SelectSheets.exists(2) then
- SelectSheets.Cancel
- end if
- endcatch
- '///</ul>
-end function
-'
-'-------------------------------------------------------------------------
-'
-function fNavigatorSelectObject ( sWhatObject as STRING , iObjectPosition as INTEGER )
- '///<b>Select any Object in Navigator</b>
- '///<b>STRING: sWhatObject</b> - A keyword to choose desired obeject category
- '///+Posible values: sheets, range names, database ranges, linked areas, graphics, ole objects, notes, drawing objects
- '///<b>INTEGER: iObjectPosition</b> - Position of object (>=1) within 'sWhatObject'
- '///+<b>NOTE:</b>You're moving within a treelistbox which is quite messy to handle.
- '///+In case 'iObjectPosition' is larger than the real number of objects in category you're end up in another categories.
- '///+<b>WITHOUT ANY WARNING!</b>
- '///<b>RETURNS:</b> BOOLEAN (success)</b>
- '///-----
- '///<ul>
- dim bNavigatorWasVisible as boolean
- bNavigatorWasVisible = FALSE
- dim iIndex
- dim iCategoryPosition as INTEGER
-
- fNavigatorSelectObject = FALSE
- '///<li>Translate 'sWhatObject' to postion number of desired object category</li>///
- select case lcase ( sWhatObject )
- case "sheets" : iCategoryPosition = 1
- case "range names" : iCategoryPosition = 2
- case "database ranges" : iCategoryPosition = 3
- case "linked areas" : iCategoryPosition = 4
- case "graphics" : iCategoryPosition = 5
- case "ole objects" : iCategoryPosition = 6
- case "notes" : iCategoryPosition = 7
- case "drawing objects" : iCategoryPosition = 8
- case else
- warnlog "Invalid keyword -> Aborting fNavigatorSelectObject()"
- exit function
- end select
- '///<li>Check if Navigator is visible</li>///
- Kontext "NavigatorCalc"
- if NavigatorCalc.exists (3) then
- '///<li>Remember state of visibiliy TRUE/FALSE</li>///
- bNavigatorWasVisible = TRUE
- else
- '///<li>Invoke navigator if not visible</li>///
- ViewNavigator
- end if
-
- try
- Kontext "NavigatorCalc"
- '///<li>Go to Top in Navigator</li>///
- liste.TypeKeys "<HOME>"
- '///<li>Travel top to bottom through all categories</li>///
- for iIndex = 1 to 8
- '///<li>Make sure all elements in category are hidden, apply '-' key</li>///
- liste.TypeKeys "-<DOWN>"
- next iIndex
- '///<li>Select desired category</li>///
- liste.select ( iCategoryPosition )
- '///<li>Unfold elements of selected category</li>///
- liste.TypeKeys "+"
- '///<li>Select desired position within category</li>///
- liste.select ( iCategoryPosition + iObjectPosition )
- '///<li>Hit 'RETURN' key to select element in document</li>///
- liste.TypeKeys "<RETURN>"
- '///<li>Return 'TRUE' for 'fNavigatorSelectObject'</li>///
- fNavigatorSelectObject = TRUE
- catch
- warnlog "Selecting the desired object failed. Perhaps your input wasn't valid"
- endcatch
- '///<li>Close navigator if it wasn't visible before entering this function</li>///
- if bNavigatorWasVisible = TRUE then
- printlog "Leaving navigator open as initially found"
- else
- ViewNavigator
- printlog "Closing navigator as initially found"
- end if
- '///</ul>
-end function
-
diff --git a/testautomation/spreadsheet/tools/includes/c_tool_l10n_mnomics.inc b/testautomation/spreadsheet/tools/includes/c_tool_l10n_mnomics.inc
deleted file mode 100644
index 43dd2945c22a..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_tool_l10n_mnomics.inc
+++ /dev/null
@@ -1,160 +0,0 @@
-'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 : oliver.craemer@oracle.com
-'*
-'* short description : Tools for Keyboard Accessibility
-'*
-'************************************************************************
-'*
-' #1 fDataPilotRowSelection
-' #1 fDataPilotColumnSelection
-' #1 fDataPilotDataSelection
-'*
-'\***********************************************************************
-
-function fDataPilotRowSelection()
-
-fDataPilotRowSelection = TRUE
-
- select case iSprache
- case 01 : ' English (USA)
- DataPilotSelection.typekeys "<MOD2 R>"
- case 33 : ' French
- DataPilotSelection.typekeys "<MOD2 g>"
- case 34 : ' Spanish
- DataPilotSelection.typekeys "<MOD2 l>"
- case 39 : ' Italian
- DataPilotSelection.typekeys "<MOD2 R>"
- case 46 : ' Swedish
- DataPilotSelection.typekeys "<MOD2 d>"
- case 49 : ' German
- DataPilotSelection.typekeys "<MOD2 l>"
- case 55 : ' Portuguese
- DataPilotSelection.typekeys "<MOD2 h>"
- case 81 : ' Japanese
- DataPilotSelection.typekeys "<MOD2 B>"
- case 82 : ' Korean
- DataPilotSelection.typekeys "<MOD2 B>"
- case 86 : ' Chinese (simplified)
- DataPilotSelection.typekeys "<MOD2 B>"
- case 88 : ' Chinese (traditional)
- DataPilotSelection.typekeys "<MOD2 B>"
- case else : ' Fallback
- QAErrorLog "Now, the test does not support for the language " +iSprache
- fDataPilotRowSelection = FALSE
- end select
-
-end function
-
-'----------------------------------------------------
-
-function fDataPilotColumnSelection()
-
-fDataPilotColumnSelection = TRUE
-
- select case iSprache
- case 01 : ' English (USA)
- DataPilotSelection.typekeys "<MOD2 C>"
- case 33 : ' French
- DataPilotSelection.typekeys "<MOD2 C>"
- case 34 : ' Spanish
- DataPilotSelection.typekeys "<MOD2 C>"
- case 39 : ' Italian
- DataPilotSelection.typekeys "<MOD2 C>"
- case 46 : ' Swedish
- DataPilotSelection.typekeys "<MOD2 m>"
- case 49 : ' German
- DataPilotSelection.typekeys "<MOD2 S>"
- case 55 : ' Portuguese
- DataPilotSelection.typekeys "<MOD2 C>"
- case 81 : ' Japanese
- DataPilotSelection.typekeys "<MOD2 A>"
- case 82 : ' Korean
- DataPilotSelection.typekeys "<MOD2 A>"
- case 86 : ' Chinese (simplified)
- DataPilotSelection.typekeys "<MOD2 A>"
- case 88 : ' Chinese (traditional)
- DataPilotSelection.typekeys "<MOD2 A>"
- case else : ' Fallback
- QAErrorLog "Now, the test does not support for the language " +iSprache
- fDataPilotColumnSelection = FALSE
- end select
-
-end function
-
-'----------------------------------------------------
-
-function fDataPilotDataSelection()
-
-fDataPilotDataSelection = TRUE
-
- select case iSprache
- case 01 : ' English (USA)
- DataPilotSelection.typekeys "<MOD2 D>"
- case 33 : ' French
- DataPilotSelection.typekeys "<MOD2 D>"
- case 34 : ' Spanish
- DataPilotSelection.typekeys "<MOD2 t>"
- case 39 : ' Italian
- DataPilotSelection.typekeys "<MOD2 D>"
- case 46 : ' Swedish
- DataPilotSelection.typekeys "<MOD2 t>"
- case 49 : ' German
- DataPilotSelection.typekeys "<MOD2 D>"
- case 55 : ' Portuguese
- DataPilotSelection.typekeys "<MOD2 D>"
- case 81 : ' Japanese
- DataPilotSelection.typekeys "<MOD2 C>"
- case 82 : ' Korean
- DataPilotSelection.typekeys "<MOD2 C>"
- case 86 : ' Chinese (simplified)
- DataPilotSelection.typekeys "<MOD2 C>"
- case 88 : ' Chinese (traditional)
- DataPilotSelection.typekeys "<MOD2 C>"
- case else : ' Fallback
- QAErrorLog "Now, the test does not support for the language " +iSprache
- fDataPilotDataSelection = FALSE
- end select
-
-end function
-
-'----------------------------------------------------
-
-function fDataPilotPageSelection()
-
-fDataPilotPageSelection = TRUE
-
- select case iSprache
- case 01 : ' English (USA)
- DataPilotSelection.typekeys "<MOD2 P>"
- case else : ' Fallback
- QAErrorLog "Now, the test does not support for the language " +iSprache
- fDataPilotPageSelection = FALSE
- end select
-
-end function
diff --git a/testautomation/spreadsheet/tools/includes/c_tool_options.inc b/testautomation/spreadsheet/tools/includes/c_tool_options.inc
deleted file mode 100644
index 89bc7a4e0ad3..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_tool_options.inc
+++ /dev/null
@@ -1,95 +0,0 @@
-'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 : oliver.craemer@oracle.com
-'*
-'* short description : Tools for Tools::Options dialog
-'*
-'************************************************************************
-'*
-' #1 subSetConversionMicrosoftOLE
-'*
-'\***********************************************************************
-
-sub subSetConversionMicrosoftOLE ( OPTIONAL sConversionType as STRING )
-'///<u><b>Routine to adjust the behaviour of Tools::Options::Load/Save::Microsoft Office</b></u>///
-'///<b>Possible Keys for 'sConversionType' are:</b>///
-'///<ul>
-'///<li>RESET (or omitted): Uncheck all boxes (default in a freshly installed OOo))</li>///
-'///<li>ALL: Check all boxes</li>///
-'///<li>LOAD: Check all boxes for loading MS OLE objects (left side), uncheck all boxes for saving</li>///
-'///<li>SAVE: Check all boxes for saving MS OLE objects (right side), uncheck all boxes for loading</li>///
-'///<li>For other values the subroutine will exit</li>///
-'///</ul>
-'///<b>Action:</b>///
-'///<ul>
- '///<li>Convert omitted 'sConversionType' to RESET</li>///
- if IsMissing ( sConversionType ) then
- sConversionType = "RESET"
- end if
- dim iPosInAuswahl as INTEGER
- dim iExtraToggle as INTEGER
-
- '///<li>Determine value of 'iExtraToggle' for known keys</li>///
- select case sConversionType
- case "RESET" : iExtraToggle = 1
- case "ALL" : iExtraToggle = 2
- case "LOAD" : iExtraToggle = 3
- case "SAVE" : iExtraToggle = 4
- case else
- warnlog "Unknown keyword for paramter -> Exit the subroutine"
- qaErrorLog "Valid keywords are RESET, ALL, LOAD and SAVE!"
- exit sub
- end select
-
- '///<li>Invoke Tools::Options</li>///
- ToolsOptions
- '///<li>Go to tabpage Load/Save::Microsoft Office</li>///
- call hToolsOptions ( "LOADSAVE" , "MICROSOFTOFFICE" )
- '///<li>Go to top entry in listbox</li>///
- Auswahl.TypeKeys( "<PageUp>" )
-
- '///<li>Toggle (in a tricky way) to a defined state of checkboxes</li>///
- for iPosInAuswahl = 1 to 4
- while NOT Auswahl.IsChecked
- Auswahl.TypeKeys ( "<Space>" )
- wend
- while Auswahl.IsChecked
- Auswahl.TypeKeys ( "<Space>" )
- wend
- '///<li>Toggle to desired state of boxes</li>///
- Auswahl.TypeKeys ( "<Space>" , iExtraToggle )
- '///<li>Go one entry down in list box</li>///
- Auswahl.TypeKeys ( "<Down>" )
- '///<li>Loop for all lines</li>///
- next iPosInAuswahl
-
- '///<li>Quit dialog</li>///
- Kontext "OptionenDLG"
- OptionenDLG.Ok
- '///</ul>
-end sub
diff --git a/testautomation/spreadsheet/tools/includes/c_validity_tools.inc b/testautomation/spreadsheet/tools/includes/c_validity_tools.inc
deleted file mode 100644
index af78bffe2468..000000000000
--- a/testautomation/spreadsheet/tools/includes/c_validity_tools.inc
+++ /dev/null
@@ -1,139 +0,0 @@
-'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 : oliver.craemer@Sun.COM
-'**
-'** short description : Subroutines for the data validity test
-'**
-'************************************************************************
-' **
-' #0 check_message ' Check if the messages in validity test are OK
-' **
-'\***********************************************************************
-
-sub check_message(MType as String, Celladdress as String, cellcontent as String, wrong as String)
-'/// Sub routine for checking message
- if MType <> "Macro" then
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- ViewToolbarsFormulaBar
- end if
- Kontext "RechenleisteCalc"
- Bereich.TypeKeys "<MOD1 A>"
- Bereich.TypeKeys Celladdress
- sleep(1)
- Bereich.TypeKeys "<RETURN>"
-
- Kontext "DocumentCalc"
- DocumentCalc.TypeKeys cellcontent
- DocumentCalc.TypeKeys "<RETURN>"
- kontext "active"
- if active.exists(2) then
- warnlog "Value " & cellcontent & " is correct in cell "& Celladdress & ", so no " & MType & " message must not be appear"
- if MType = "Stop" then
- active.OK
- else
- active.Cancel
- end if
- else
- printlog "OK, no " & MType & " message appears, by inserting the correct value into " & Celladdress
- end if
-
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- ViewToolbarsFormulaBar
- end if
- Kontext "RechenleisteCalc"
- Bereich.TypeKeys "<MOD1 A>"
- Bereich.TypeKeys Celladdress
- sleep(1)
- Bereich.TypeKeys "<RETURN>"
- Kontext "DocumentCalc"
- DocumentCalc.TypeKeys wrong
- DocumentCalc.TypeKeys "<RETURN>"
- kontext "active"
- if active.exists(2) then
- printlog "OK, value " & wrong & " is not correct in cell " & Celladdress & ", so the " & MType & " message has to be appear"
- if MType = "Stop" then
- active.OK
- else
- active.Cancel
- end if
- else
- warnlog "Value " & wrong & " is not correct for cell " & Celladdress & ", so the " & MType & " message has to be appears"
- end if
- else
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- ViewToolbarsFormulaBar
- end if
- Kontext "RechenleisteCalc"
- Bereich.TypeKeys "<MOD1 A>"
- Bereich.TypeKeys Celladdress
- sleep(1)
- Bereich.TypeKeys "<RETURN>"
- Kontext "DocumentCalc"
- DocumentCalc.TypeKeys cellcontent
- DocumentCalc.TypeKeys "<RETURN>"
- DocumentCalc.TypeKeys "<UP><RIGHT>"
- FormatCells
- Kontext
- Active.setPage TabFontEffects
- Kontext "TabFontEffects"
- if FontColor.getSelIndex = 1 then
- printlog "OK, the macro detect the correct word in " & Celladdress
- else
- warnlog "The Fontcolor is " & FontColor.getSelText & " instead of automatic in cell " & Celladdress
- end if
- TabFontEffects.Cancel
-
- Kontext "RechenleisteCalc"
- if not RechenleisteCalc.isvisible then
- ViewToolbarsFormulaBar
- end if
- Kontext "RechenleisteCalc"
- Bereich.TypeKeys "<MOD1 A>"
- Bereich.TypeKeys Celladdress
- sleep(1)
- Bereich.TypeKeys "<RETURN>"
- Kontext "DocumentCalc"
- DocumentCalc.TypeKeys wrong
- DocumentCalc.TypeKeys "<RETURN>"
- DocumentCalc.TypeKeys "<UP><RIGHT>"
- FormatCells
- Kontext
- Active.setPage TabFontEffects
- Kontext "TabFontEffects"
- if FontColor.getSelIndex = 12 then
- printlog "OK, the macro detect the wrong word in " & Celladdress
- else
- warnlog "The Fontcolor is " & FontColor.getSelText & " instead of light green in cell " & Celladdress
- end if
- TabFontEffects.Cancel
- end if
-end sub
-