summaryrefslogtreecommitdiff
path: root/testautomation/framework
diff options
context:
space:
mode:
authorJoerg Skottke [jsk] <jsk@openoffice.org>2010-06-02 10:05:17 +0200
committerJoerg Skottke [jsk] <jsk@openoffice.org>2010-06-02 10:05:17 +0200
commit5b17ec8ba275c12bcdb1e58aa88b6a979e4db140 (patch)
tree4e8125a71be8f2d1d1b850bc9176469d9f550783 /testautomation/framework
parent6f38ce3900f0779ddb55f538f0da98c3f933b838 (diff)
vitomation01: #i109696
- Removed f_first.bas: it does no longer have a special status as we are working with categories now. Tests have been moved to other files. - Removed f_script_organizers.bas, f_basic_dialogs.bas: Their scripts are now combined in f_programmability_dialogs.bas - tInsertAllGraphics() has been removed from (now deleted f_first.bas) and replaces an identical but less strict test in w_updt.bas. This gives a speed gain of about five minutes to w_updt.bas. - graphics_import.inc: Deleted, tests moved to f_topten.bas and w_updt.bas
Diffstat (limited to 'testautomation/framework')
-rwxr-xr-xtestautomation/framework/required/f_first.bas70
-rwxr-xr-xtestautomation/framework/required/f_help_browser.bas2
-rwxr-xr-xtestautomation/framework/required/f_programmability_dialogs.bas (renamed from testautomation/framework/required/f_basic_dialogs.bas)6
-rwxr-xr-xtestautomation/framework/required/f_script_organizers.bas60
-rwxr-xr-xtestautomation/framework/required/f_tools_options.bas2
-rwxr-xr-xtestautomation/framework/required/f_topten.bas26
-rwxr-xr-x[-rw-r--r--]testautomation/framework/required/includes/first.inc149
-rwxr-xr-xtestautomation/framework/required/includes/graphics_import.inc312
-rwxr-xr-x[-rw-r--r--]testautomation/framework/required/includes/help_browser.inc39
-rwxr-xr-x[-rw-r--r--]testautomation/framework/required/includes/tools_options.inc37
10 files changed, 192 insertions, 511 deletions
diff --git a/testautomation/framework/required/f_first.bas b/testautomation/framework/required/f_first.bas
deleted file mode 100755
index a4733f612375..000000000000
--- a/testautomation/framework/required/f_first.bas
+++ /dev/null
@@ -1,70 +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 : joerg.skottke@sun.com
-'*
-'* short description : first test, to check global functionality
-'*
-'\******************************************************************************
-
-
-sub main
- ' Disable sleep() calls. If you encounter unexpected test interruptions
- ' you should try to outcomment this or set the value to FALSE.
- GLOBAL_USE_NEW_SLEEP = TRUE
-
- use "framework\required\includes\first.inc"
- use "framework\required\includes\graphics_import.inc"
- use "global\required\includes\g_option_application.inc"
-
- call hStatusIn ("framework", "f_first.bas")
- call tAllNew
-
- gApplication = "DRAW"
- call tInFilterCountCompare
- call tQuickInsertGraphNotAsLink
- call tJava
-
- gApplication = "WRITER"
- call tToolsOptionsTestFirst
- call tDatabaseCheck
- call tHelpRegistration
- call hStatusOut
-end sub
-
-sub LoadIncludeFiles
- use "global\system\includes\master.inc"
- use "global\system\includes\gvariabl.inc"
- use "global\tools\includes\optional\t_ui_filters.inc"
- use "global\tools\includes\optional\t_filetools.inc"
- use "global\tools\includes\optional\t_docfuncs.inc"
- use "global\tools\includes\optional\t_listfuncs.inc"
-
- gApplication = "WRITER"
- call GetUseFiles()
-end sub
-
diff --git a/testautomation/framework/required/f_help_browser.bas b/testautomation/framework/required/f_help_browser.bas
index 330e0a31e78a..edc70c63f9ca 100755
--- a/testautomation/framework/required/f_help_browser.bas
+++ b/testautomation/framework/required/f_help_browser.bas
@@ -38,6 +38,8 @@ sub main
call hStatusIn( "framework", "f_help_browser.bas" )
call tHelp_DialogTest()
call tHelp_ToolBar()
+ call tHelp_Registration()
+
call hStatusOut()
end sub
diff --git a/testautomation/framework/required/f_basic_dialogs.bas b/testautomation/framework/required/f_programmability_dialogs.bas
index 9820062e8139..537a4693770f 100755
--- a/testautomation/framework/required/f_basic_dialogs.bas
+++ b/testautomation/framework/required/f_programmability_dialogs.bas
@@ -38,13 +38,17 @@ sub main
use "framework\required\includes\basic_organizer.inc"
use "framework\required\includes\basic_dialog_export.inc"
use "framework\required\includes\basic_dialog_i18n_import.inc"
+ use "framework\required\includes\scripting_basics.inc"
+ use "framework\required\includes\script_organizers.inc"
- call hStatusIn( "framework" , "f_basic_dialogs.bas" )
+ call hStatusIn( "framework" , "f_programmability_dialogs.bas" )
call tUpdtMacroAssignment()
call tUpdtBasicDialogI18n()
call tUpdtBasicOrganizer()
call tUpdtDialogExport()
call tBasicDialogI18nImport()
+ call tScripting() ' script organizer nodes if no documents are open
+ call tUpdtScriptCount() ' script organizer nodes with one open document
call hStatusOut()
end sub
diff --git a/testautomation/framework/required/f_script_organizers.bas b/testautomation/framework/required/f_script_organizers.bas
deleted file mode 100755
index cdf5018d3374..000000000000
--- a/testautomation/framework/required/f_script_organizers.bas
+++ /dev/null
@@ -1,60 +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 : Joerg.Skottke@Sun.Com
-'*
-'* short description : Verify names of macros and scripts
-'*
-'\******************************************************************************
-
-sub main
-
- use "framework\required\includes\scripting_basics.inc"
- use "framework\required\includes\script_organizers.inc"
-
- call hStatusIn( "framework" , "f_script_organizers.bas" )
- call tScripting() ' script organizer nodes if no documents are open
- call tUpdtScriptCount() ' script organizer nodes with one open document
- call hStatusOut()
-
-end sub
-
-'*******************************************************************************
-
-sub LoadIncludeFiles
-
- use "global\system\includes\master.inc"
- use "global\system\includes\gvariabl.inc"
-
- use "global\tools\includes\optional\t_docfuncs.inc"
- use "global\tools\includes\optional\t_treelist_tools.inc"
-
- gApplication = "WRITER"
- call GetUseFiles()
-
-end sub
-
diff --git a/testautomation/framework/required/f_tools_options.bas b/testautomation/framework/required/f_tools_options.bas
index d9945c5333ff..9b64e7e1cd26 100755
--- a/testautomation/framework/required/f_tools_options.bas
+++ b/testautomation/framework/required/f_tools_options.bas
@@ -34,9 +34,11 @@
sub main
use "framework\required\includes\tools_options.inc"
+ use "global\required\includes\g_option_application.inc"
call hStatusIn( "framework" , "f_tools_options.bas" )
call tUpdtOptionItems()
+ call tToolsOptionsTestFirst() ' Global test that should be called from within the application modules really.
call hStatusOut()
end sub
diff --git a/testautomation/framework/required/f_topten.bas b/testautomation/framework/required/f_topten.bas
index 49a13aeb3f1b..3b7068ece70b 100755
--- a/testautomation/framework/required/f_topten.bas
+++ b/testautomation/framework/required/f_topten.bas
@@ -35,21 +35,21 @@ sub main
use "framework\required\includes\topten.inc"
use "framework\required\includes\smoketest.inc"
-
+ use "framework\required\includes\first.inc"
+
+ hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
+
call hStatusIn ("framework", "f_topten.bas")
-
- printlog Chr(13) + "* ------ Top-Ten-Test ------ *"
+ call tAllNew
+ call tInFilterCountCompare
+ call tJava
+ call tDatabaseCheck
call topten
-
-
- hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_LOW )
call tSmokeTest
-
- ' Do not use hSetMacroSecurityAPI here as this is the ONLY place within
- ' the framework module where the setting is done via UI.
- hSetMacroSecurity( GC_MACRO_SECURITY_LEVEL_DEFAULT )
-
call hStatusOut
+
+ hSetMacroSecurity( GC_MACRO_SECURITY_LEVEL_DEFAULT )
+
end sub
'*******************************************************************************
@@ -60,6 +60,10 @@ sub LoadIncludeFiles
use "global\system\includes\gvariabl.inc"
use "global\tools\includes\optional\t_docfuncs.inc"
+ use "global\tools\includes\optional\t_ui_filters.inc"
+ use "global\tools\includes\optional\t_filetools.inc"
+ use "global\tools\includes\optional\t_docfuncs.inc"
+ use "global\tools\includes\optional\t_listfuncs.inc"
gApplication = "BACKGROUND"
Call GetUseFiles
diff --git a/testautomation/framework/required/includes/first.inc b/testautomation/framework/required/includes/first.inc
index 0c0b737ffe5d..700cee374104 100644..100755
--- a/testautomation/framework/required/includes/first.inc
+++ b/testautomation/framework/required/includes/first.inc
@@ -271,62 +271,129 @@ endcase
'*******************************************************************************
-function fDocumentCheck (SollFilter as String) as boolean
+function fDocumentCheck( SollFilter as String ) as boolean
' Check the name of the file type in the Save dialog and validate
' it against a given string.
Dim sFiltername as String
FileSaveAs
+
Kontext "SpeichernDlg"
- sFiltername = DateiTyp.GetItemText (1)
- if (Instr(lcase(sFiltername), lcase (SollFilter)) <> 0) then
- fDocumentCheck() = TRUE
+ if ( SpeichernDlg.exists( 1 ) ) then
+ sFiltername = DateiTyp.GetItemText (1)
+ if (Instr(lcase(sFiltername), lcase (SollFilter)) <> 0) then
+ fDocumentCheck() = TRUE
+ else
+ printlog("Filter names do not match:")
+ printlog("Found: [" & sFilterName & "]")
+ printlog("Expected: [" & SollFilter & "]")
+ SollFilter = sFiltername
+ fDocumentCheck() = FALSE
+ end if
+ SpeichernDlg.Cancel()
else
- printlog("Filter names do not match:")
- printlog("Found: [" & sFilterName & "]")
- printlog("Expected: [" & SollFilter & "]")
- SollFilter = sFiltername
+ warnlog( "Dialog <File Save As> did not open" )
fDocumentCheck() = FALSE
- end if
- SpeichernDlg.Cancel()
+ endif
end function
'*******************************************************************************
-testcase tHelpRegistration
+testcase tInFilterCountCompare()
- ' Check i69670 which was a showstopper in OOo 2.0.4
- ' Menu-entry "Help / Registration" is disabled
+ printlog( "Check filterlist (filterstring) for graphics files" )
- dim iCurrentMenuEntry as integer
- dim iMenuEntryCount as integer
-
- printlog "Check if all entries in Help Menu are enabled"
- call hNewDocument
-
- printlog "Open menu"
- hUseMenu()
- iMenuEntryCount = hMenuItemGetCount
-
- printlog "Select the last entry 'Help'"
- hMenuSelectNr( iMenuEntryCount )
- iMenuEntryCount = hMenuItemGetCount
- for iCurrentMenuEntry = 1 to iMenuEntryCount
- if ( hMenuItemIsEnabled( iCurrentMenuEntry ) ) then
- printlog "(" & iCurrentMenuEntry & "/" & iMenuEntryCount & _
- "): Menu entry is enabled: Help-> " & hMenuItemGetText( iCurrentMenuEntry )
- else
- if (lcase(gPlatform) = "osx") then
- warnlog "#i86247# Help->Registration is disabled on MacOS X"
- else
- warnlog "(" & iCurrentMenuEntry & "/" & iMenuEntryCount & _
- "): Menu entry is not enabled: Help-> " & hMenuItemGetText( iCurrentMenuEntry )
- endif
+ const FILE_NAME = "graphic_filters.txt"
+ const SUFFIX_STRING_LENGTH = 178
+
+' List of filter suffixes for verification in case of error
+' *.bmp;*.dxf;*.emf;*.eps;*.gif;*.jpg;*.jpeg;*.jfif;*.jif;*.met;*.pbm;*.pcd;
+' *.pct;*.pcx;*.pgm;*.png;*.ppm;*.psd;*.ras;*.sgf;*.sgv;*.svm;*.tga;*.tif;
+' *.tiff;*.wmf;*.xbm;*.xpm;*.pict
+
+ dim caUIFilters( 30 ) as string
+
+ dim cReferencePath as string
+ cReferencePath = gTesttoolPath & "global/input/filters/"
+ cReferencePath = convertpath ( cReferencePath & FILE_NAME )
+
+ dim cUIFiltersPath as string
+ cUIFiltersPath = hGetWorkPath() & FILE_NAME
+
+ dim iCurrentFilter as integer
+ dim iFilterCount as integer
+
+ dim cAllFormats as string
+
+ dim irc as integer
+ dim iBegin as integer
+ dim iEnd as integer
+
+ printlog( "" )
+ printlog( "Verify filternames listed on the Insert Graphics dialog" )
+
+ hCreateDocument()
+ hChangeDoc()
+
+ InsertGraphicsFromFile
+
+ kontext "GrafikEinfuegenDlg"
+ if ( GrafikEinfuegenDlg.exists( 1 ) ) then
+ iFilterCount = DateiTyp.getItemCount()
+
+ 'Make list compatible with listfunctions
+ caUIFilters( 0 ) = iFilterCount - 1
+
+ for iCurrentFilter = 2 to iFilterCount
+
+ caUIFilters( iCurrentFilter - 1 ) = DateiTyp.getItemText( iCurrentFilter )
+
+ next iCurrentFilter
+
+ irc = hManageComparisionList( cReferencePath, cUIFiltersPath, caUIFilters() )
+ hListResultEvaluation( irc , 0 )
+
+ printlog( "" )
+ printlog( "Verify <All formats>-string" )
+ cAllFormats = DateiTyp.getItemText( 1 )
+
+ iBegin = instr( cAllFormats, "<" )
+ if ( iBegin <> 1 ) then
+ warnlog( "The opening bracket < is missing in <All formats> string" )
+ endif
+
+ iEnd = instr( cAllFormats, ">" )
+ if ( iEnd = 0 ) then
+ warnlog( "The closing bracket > is missing in <All formats> string" )
+ endif
+
+ if ( ( iEnd - iBegin ) < 2 ) then
+ warnlog( "<All formats> string is shorter than expected, please check" )
+ printlog( "String is: " & cAllFormats & ", length (" & len( cAllFormats ) & ")" )
endif
- next iCurrentMenuEntry
- hMenuClose()
- call hCloseDocument
-endcase
+ iBegin = instr( cAllFormats, "(" )
+ if ( iBegin <> iEnd + 2 ) then
+ warnlog( "The opening bracket ( is missing in <All formats> string" )
+ endif
+ iEnd = instr( cAllFormats, ")" )
+ if ( iEnd < 10 ) then
+ warnlog( "The closing bracket ) is missing in <All formats> string" )
+ endif
+
+ irc = iEnd - iBegin
+ if ( irc <> SUFFIX_STRING_LENGTH ) then
+ warnlog( "The list of file suffixes has changed, please verify" )
+ printlog( "Found: " & irc & " chars, expected " & SUFFIX_STRING_LENGTH )
+ endif
+ kontext "GrafikEinfuegenDlg"
+ GrafikEinfuegenDlg.cancel()
+ else
+ warnlog( "<Insert Graphics> dialog did not open" )
+ endif
+
+ hDestroyDocument()
+
+endcase
diff --git a/testautomation/framework/required/includes/graphics_import.inc b/testautomation/framework/required/includes/graphics_import.inc
deleted file mode 100755
index f9567037ddde..000000000000
--- a/testautomation/framework/required/includes/graphics_import.inc
+++ /dev/null
@@ -1,312 +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 : joerg.skottke@sun.com
-'*
-'* short description : Graphic import (2nd file for the first.bas)
-'*
-'\******************************************************************************
-
-
-testcase tQuickInsertGraphNotAsLink
-
- printlog( "Load files of all known graphics formats" )
-
- dim iCurrentFile as integer
- dim GraphicFile as String
- dim Filtername as String
-
- printlog( "Insert a sample of commonly used file formats into a writer document (not linked)" )
-
- if ( gUseSysDlg ) then
- warnlog( "This test needs the OpenOffice.org filepicker to be set as default" )
- goto endsub
- endif
-
- gApplication = "WRITER"
- Call hNewDocument
-
- for iCurrentFile = 1 to 25
-
- ' MODIFY and ENABLE this SAMPLE snippet to exclude one fileformat from testing
- ' if ( iCurrentFile = 7 ) AND (gtPlatform="x86") then
- ' qaErrorLog("#<issue-id># crash on <platform> on loading <image-file>")
- ' goto skipformat
- ' endif
- ' Note: Can be locale dependent!
- if (iCurrentFile = 4) AND (gPlatform="osx") then
- qaerrorlog("#i100253# crash on MacOS X on loading ball.eps")
- goto skipformat
- endif
-
- Kontext "GrafikEinfuegenDlg"
- if ( not GrafikEinfuegenDlg.exists() ) then
- InsertGraphicsFromFile
- Kontext "GrafikEinfuegenDlg"
- endif
-
- if ( GrafikEinfuegenDlg.Exists( 2 ) ) then
- ' the list of files expected to be found in the samples directory
- select case iCurrentFile
- case 1 : GraphicFile = "desp.bmp"
- case 2 : GraphicFile = "columbia.dxf"
- case 3 : GraphicFile = "extrud.emf"
- case 4 : GraphicFile = "ball.eps"
- case 5 : GraphicFile = "airshw.met"
- case 6 : GraphicFile = "eface.gif"
- case 7 : GraphicFile = "purzel.gif" ' Animated Gif
- case 8 : GraphicFile = "borabora.jpg"
- case 9 : GraphicFile = "grafix1.pbm"
- case 10 : GraphicFile = "circle.pcx"
- case 11 : GraphicFile = "papagei1.pcd"
- case 12 : GraphicFile = "newtonme.pct"
- case 13 : GraphicFile = "grafix2.pgm"
- case 14 : GraphicFile = "obst.png"
- case 15 : GraphicFile = "london.ppm"
- case 16 : GraphicFile = "tiger.psd"
- case 17 : GraphicFile = "grafix3.ras"
- case 18 : GraphicFile = "mickym.sgf"
- case 19 : GraphicFile = "faxpfeil.sgv"
- case 20 : GraphicFile = "picture.svm"
- case 21 : GraphicFile = "pilz.tga"
- case 22 : GraphicFile = "stabler.tif"
- case 23 : GraphicFile = "krokodil.wmf"
- case 24 : GraphicFile = "grafix4.xbm"
- case 25 : GraphicFile = "papagei2.xpm"
- end select
-
- GraphicFile = ConvertPath (gTesttoolPath & "global\input\graf_inp\" & GraphicFile)
- printlog( "Current file " + iCurrentFile + ": " & GraphicFile )
- printlog( " * Set filter to <All formats>" )
- DateiName.SetText( GraphicFile )
- DateiTyp.Select( 1 )
- WaitSlot()
-
- printlog( " * Uncheck Preview- and Link-checkbox, load the file" )
- Vorschau.unCheck
- Verknuepfen.unCheck()
- Oeffnen.click()
- WaitSlot( 2000 )
-
- Kontext "Active"
- if ( Active.Exists() ) then
- Warnlog( "Unexpected messagebox: " & Active.GetText() )
- Warnlog( "Affected file: " & GraphicFile )
- Active.OK
- else
- try
- EditCopy
- WaitSlot( 2000 )
- EditDeleteContents
- WaitSlot( 2000 )
- catch
- Warnlog( "Graphic file not selected/Copy or Delete is disabled: " & GraphicFile )
- gMouseClick (90, 90)
- endcatch
- endif
- else
- warnlog( "Insert Graphics Dialog is not open, aborting" )
- goto endsub
- endif
-
- skipformat:
- next iCurrentFile
-
- printlog( "" )
- printlog( "Test the PCD-Filters directly (3 samples)" )
-
- for iCurrentFile = 1 to 3
-
- printlog( "" )
-
- Kontext "GrafikEinfuegenDlg"
- if ( not GrafikEinfuegenDlg.exists() ) then
- InsertGraphicsFromFile
- Kontext "GrafikEinfuegenDlg"
- endif
-
- if ( GrafikEinfuegenDlg.exists( 2 ) ) then
-
- select case iCurrentFile
- case 1 : Filtername = "PCD - Kodak Photo CD (768x512) (*.pcd)"
- case 2 : Filtername = "PCD - Kodak Photo CD (384x256) (*.pcd)"
- case 3 : Filtername = "PCD - Kodak Photo CD (192x128) (*.pcd)"
- end select
-
- GraphicFile = ConvertPath( gTesttoolPath & "global\input\graf_inp\papagei1.pcd" )
-
- printlog( "Current filter: " & Filtername )
- printlog( "Current file..: " & GraphicFile )
- DateiName.SetText ( GraphicFile )
- DateiTyp.Select( Filtername )
-
- printlog( " * Uncheck Preview- and Link-checkbox, load the file" )
- Vorschau.Uncheck()
- Verknuepfen.unCheck()
- Oeffnen.click()
- WaitSlot( 2000 )
-
- Kontext "Active"
- if ( Active.Exists() )then
- Warnlog( "Unexpected messagebox: " & Active.GetText() )
- Warnlog( "Affected file..: " & GraphicFile )
- Warnlog( "Affected filter: " & Filtername )
- Active.OK()
- else
- try
- EditCopy
- WaitSlot( 2000 )
- EditDeleteContents
- WaitSlot( 2000 )
- catch
- Warnlog( "Problems with filtertype : " & Filtername )
- gMouseClick (90, 90)
- endcatch
- endif
- else
- warnlog( "Insert Graphics Dialog is not open. Aborting" )
- goto endsub
- endif
-
- next iCurrentFile
-
- Kontext "GrafikEinfuegenDlg"
- if GrafikEinfuegenDlg.Exists then
- GrafikEinfuegenDlg.Cancel
- endif
-
- Call hCloseDocument
-
-endcase
-
-'*******************************************************************************
-
-testcase tInFilterCountCompare()
-
- printlog( "Check filterlist (filterstring) for graphics files" )
-
- if ( gUseSysDlg ) then
- warnlog( "This test needs the OpenOffice.org filepicker to be set as default" )
- goto endsub
- endif
-
- const FILE_NAME = "graphic_filters.txt"
- const SUFFIX_STRING_LENGTH = 178
-
-' List of filter suffixes for verification in case of error
-' *.bmp;*.dxf;*.emf;*.eps;*.gif;*.jpg;*.jpeg;*.jfif;*.jif;*.met;*.pbm;*.pcd;
-' *.pct;*.pcx;*.pgm;*.png;*.ppm;*.psd;*.ras;*.sgf;*.sgv;*.svm;*.tga;*.tif;
-' *.tiff;*.wmf;*.xbm;*.xpm;*.pict
-
- dim caUIFilters( 30 ) as string
-
- dim cReferencePath as string
- cReferencePath = gTesttoolPath & "global/input/filters/"
- cReferencePath = convertpath ( cReferencePath & FILE_NAME )
-
- dim cUIFiltersPath as string
- cUIFiltersPath = hGetWorkPath() & FILE_NAME
-
- dim iCurrentFilter as integer
- dim iFilterCount as integer
-
- dim cAllFormats as string
-
- dim irc as integer
- dim iBegin as integer
- dim iEnd as integer
-
- printlog( "" )
- printlog( "Verify filternames listed on the Insert Graphics dialog" )
-
- hCreateDocument()
- hChangeDoc()
-
- InsertGraphicsFromFile
-
- kontext "GrafikEinfuegenDlg"
- if ( GrafikEinfuegenDlg.exists( 1 ) ) then
- iFilterCount = DateiTyp.getItemCount()
-
- 'Make list compatible with listfunctions
- caUIFilters( 0 ) = iFilterCount - 1
-
- for iCurrentFilter = 2 to iFilterCount
-
- caUIFilters( iCurrentFilter - 1 ) = DateiTyp.getItemText( iCurrentFilter )
-
- next iCurrentFilter
-
- irc = hManageComparisionList( cReferencePath, cUIFiltersPath, caUIFilters() )
- hListResultEvaluation( irc , 0 )
-
- printlog( "" )
- printlog( "Verify <All formats>-string" )
- cAllFormats = DateiTyp.getItemText( 1 )
-
- iBegin = instr( cAllFormats, "<" )
- if ( iBegin <> 1 ) then
- warnlog( "The opening bracket < is missing in <All formats> string" )
- endif
-
- iEnd = instr( cAllFormats, ">" )
- if ( iEnd = 0 ) then
- warnlog( "The closing bracket > is missing in <All formats> string" )
- endif
-
- if ( ( iEnd - iBegin ) < 2 ) then
- warnlog( "<All formats> string is shorter than expected, please check" )
- printlog( "String is: " & cAllFormats & ", length (" & len( cAllFormats ) & ")" )
- endif
-
- iBegin = instr( cAllFormats, "(" )
- if ( iBegin <> iEnd + 2 ) then
- warnlog( "The opening bracket ( is missing in <All formats> string" )
- endif
-
- iEnd = instr( cAllFormats, ")" )
- if ( iEnd < 10 ) then
- warnlog( "The closing bracket ) is missing in <All formats> string" )
- endif
-
- irc = iEnd - iBegin
- if ( irc <> SUFFIX_STRING_LENGTH ) then
- warnlog( "The list of file suffixes has changed, please verify" )
- printlog( "Found: " & irc & " chars, expected " & SUFFIX_STRING_LENGTH )
- endif
-
- kontext "GrafikEinfuegenDlg"
- GrafikEinfuegenDlg.cancel()
- else
- warnlog( "<Insert Graphics> dialog did not open" )
- endif
-
- hDestroyDocument()
-
-
-
-endcase
diff --git a/testautomation/framework/required/includes/help_browser.inc b/testautomation/framework/required/includes/help_browser.inc
index 0b8b80bcbdaf..62438373dc37 100644..100755
--- a/testautomation/framework/required/includes/help_browser.inc
+++ b/testautomation/framework/required/includes/help_browser.inc
@@ -154,3 +154,42 @@ testcase tHelp_ToolBar
brc = hCloseHelp()
endcase
+
+'*******************************************************************************
+
+testcase tHelp_Registration
+
+ ' Check i69670 which was a showstopper in OOo 2.0.4
+ ' Menu-entry "Help / Registration" is disabled
+
+ dim iCurrentMenuEntry as integer
+ dim iMenuEntryCount as integer
+
+ printlog "Check if all entries in Help Menu are enabled"
+ call hNewDocument
+
+ printlog "Open menu"
+ hUseMenu()
+ iMenuEntryCount = hMenuItemGetCount
+
+ printlog "Select the last entry 'Help'"
+ hMenuSelectNr( iMenuEntryCount )
+ iMenuEntryCount = hMenuItemGetCount
+ for iCurrentMenuEntry = 1 to iMenuEntryCount
+ if ( hMenuItemIsEnabled( iCurrentMenuEntry ) ) then
+ printlog "(" & iCurrentMenuEntry & "/" & iMenuEntryCount & _
+ "): Menu entry is enabled: Help-> " & hMenuItemGetText( iCurrentMenuEntry )
+ else
+ if (lcase(gPlatform) = "osx") then
+ warnlog "#i86247# Help->Registration is disabled on MacOS X"
+ else
+ warnlog "(" & iCurrentMenuEntry & "/" & iMenuEntryCount & _
+ "): Menu entry is not enabled: Help-> " & hMenuItemGetText( iCurrentMenuEntry )
+ endif
+ endif
+ next iCurrentMenuEntry
+ hMenuClose()
+ call hCloseDocument
+
+endcase
+
diff --git a/testautomation/framework/required/includes/tools_options.inc b/testautomation/framework/required/includes/tools_options.inc
index 0b226db7e7b0..82d5ef6ae861 100644..100755
--- a/testautomation/framework/required/includes/tools_options.inc
+++ b/testautomation/framework/required/includes/tools_options.inc
@@ -59,24 +59,29 @@ testcase tUpdtOptionItems
ToolsOptions
kontext "ExtrasOptionenDlg"
-
- iAppItems = Optionsliste.getItemCount()
- Optionsliste.typeKeys( "<HOME>" )
- for iNodes = 1 to iAppItems
- Optionsliste.typeKeys( "-" )
- Optionsliste.typeKeys( "<DOWN>" )
- next iNodes
-
- iAppItems = Optionsliste.getItemCount()
- if ( iAppItems <> iAppCount( iDocType ) ) then
- warnlog( "#i68068# The number of top nodes in Tools/Options is incorrect." )
- printlog( "Found...: " & iAppItems )
- printlog( "Expected: " & iAppCount( iDocType ) )
+ if ( ExtrasOptionenDlg.exists( 2 ) ) then
+
+ iAppItems = Optionsliste.getItemCount()
+ Optionsliste.typeKeys( "<HOME>" )
+ for iNodes = 1 to iAppItems
+ Optionsliste.typeKeys( "-" )
+ Optionsliste.typeKeys( "<DOWN>" )
+ next iNodes
+
+ iAppItems = Optionsliste.getItemCount()
+ if ( iAppItems <> iAppCount( iDocType ) ) then
+ warnlog( "#i68068# The number of top nodes in Tools/Options is incorrect." )
+ printlog( "Found...: " & iAppItems )
+ printlog( "Expected: " & iAppCount( iDocType ) )
+ else
+ printlog( "The number of top nodes is correct." )
+ endif
+
+ hCloseDialog( ExtrasOptionenDlg, "Cancel" )
else
- printlog( "The number of top nodes is correct." )
+ warnlog( "Dialog <Tools/Options> did not open " )
endif
-
- ExtrasOptionenDlg.cancel()
+
hDestroyDocument()
next iDocType