diff options
author | Michael Meeks <michael.meeks@novell.com> | 2011-03-11 11:35:29 +0000 |
---|---|---|
committer | Michael Meeks <michael.meeks@novell.com> | 2011-03-11 11:35:29 +0000 |
commit | 8c59580b88a33d7f0c892c9c53776716ad661fcf (patch) | |
tree | da43a9c8f3ba7cba7afca05894acc8712f6e36ce /testautomation/graphics | |
parent | e62f74cabe9558e003d3105df7a69e3841dfc9ce (diff) | |
parent | 36979f1c9e43c42e62b0ad5a32b7abb2fc425b5b (diff) |
Merge commit 'ooo/DEV300_m101' into integration/dev300_m101
Conflicts:
smoketestoo_native/data/Global.xml
smoketestoo_native/data/OptionsDlg.xml
smoketestoo_native/data/Test_10er.xml
smoketestoo_native/data/content.xml
smoketestoo_native/smoketest.cxx
test/source/cpp/getargument.cxx
test/source/cpp/officeconnection.cxx
testautomation/framework/optional/includes/basic_vba-compat_security_check.inc
testautomation/framework/optional/includes/filedlg_cjk_folders.inc
testautomation/global/sid/all.sid
testautomation/global/sid/bars.sid
testautomation/global/sid/e_all.sid
testautomation/global/win/bars.win
testautomation/graphics/optional/includes/impress/i_slideshow2.inc
testautomation/graphics/optional/includes/impress/i_slideshow3.inc
testtools/source/bridgetest/bridgetest.cxx
testtools/source/bridgetest/constructors.cxx
testtools/source/bridgetest/makefile.mk
testtools/source/bridgetest/testComponent.component
Diffstat (limited to 'testautomation/graphics')
167 files changed, 9565 insertions, 17466 deletions
diff --git a/testautomation/graphics/optional/d_export_graphic_a.bas b/testautomation/graphics/optional/d_export_graphic_a.bas index b5968240e024..45b5ef107409 100644..100755 --- a/testautomation/graphics/optional/d_export_graphic_a.bas +++ b/testautomation/graphics/optional/d_export_graphic_a.bas @@ -51,16 +51,16 @@ sub main endif Call sFileExport 'OBSERVE - This line must run before the following testcases! - Call tEPS '///+- Encapsulated PostScript ///' - Call tPCT '///+- Mac Pict ///' - Call tPBM '///+- Portable Bitmap ///' - Call tPGM '///+- Portable Graymap ///' - Call tPPM '///+- Portable Pixelmap ///' - Call tRAS '///+- Sun Raster Image ///' - Call tTIFF '///+- Tagged Image File Format ///' - Call tXPM '///+- X PixMap ///' - Call tGIF '///+- Graphics Interchange Format ///' - Call tJPEG '///+- Joint Photographic Experts Group ///' + Call tEPS 'Encapsulated PostScript + Call tPCT 'Mac Pict + Call tPBM 'Portable Bitmap + Call tPGM 'Portable Graymap + Call tPPM 'Portable Pixelmap + Call tRAS 'Sun Raster Image + Call tTIFF 'Tagged Image File Format + Call tXPM 'X PixMap + Call tGIF 'Graphics Interchange Format + Call tJPEG 'Joint Photographic Experts Group Call hStatusOut end sub diff --git a/testautomation/graphics/optional/d_export_graphic_b.bas b/testautomation/graphics/optional/d_export_graphic_b.bas index 97560705afc4..f1a4d783ef62 100644..100755 --- a/testautomation/graphics/optional/d_export_graphic_b.bas +++ b/testautomation/graphics/optional/d_export_graphic_b.bas @@ -50,16 +50,16 @@ sub main endif Call sFileExport 'OBSERVE - This line must run before the following testcases! - Call tPNG '///+- Portable Network Graphic ///' - Call tSVM '///+- StarView Metafile ///' - Call tPDF '///+- Portable Document Format ///' - Call tPDF_Creator '///+- test if the right creator is set in the PDF document - Call tSVG '///+- Scalable Vector Graphics ///' - Call tBMP '///+- Windows Bitmap ///' - Call tEMF '///+- Enhanced Metafile ///' - Call tMET '///+- OS/2 Metafile ///' - Call tSWF '///+- Macromedia Flash (SWF) (.swf) ///' - Call tWMF '///+- Windows Metafile ///' + Call tPNG 'Portable Network Graphic + Call tSVM 'StarView Metafile + Call tPDF 'Portable Document Format + Call tPDF_Creator 'test if the right creator is set in the PDF document + Call tSVG 'Scalable Vector Graphics + Call tBMP 'Windows Bitmap + Call tEMF 'Enhanced Metafile + Call tMET 'OS/2 Metafile + Call tSWF 'Macromedia Flash (SWF) (.swf) + Call tWMF 'Windows Metafile Call hStatusOut end sub diff --git a/testautomation/graphics/optional/export_graphic_a.bas b/testautomation/graphics/optional/export_graphic_a.bas index 9dee4114b37f..1bd3149cf650 100644..100755 --- a/testautomation/graphics/optional/export_graphic_a.bas +++ b/testautomation/graphics/optional/export_graphic_a.bas @@ -50,16 +50,16 @@ sub main endif Call sFileExport 'OBSERVE - This line must run before the following testcases! - Call tEPS '///+- Encapsulated PostScript ///' - Call tPCT '///+- Mac Pict ///' - Call tPBM '///+- Portable Bitmap ///' - Call tPGM '///+- Portable Graymap ///' - Call tPPM '///+- Portable Pixelmap ///' - Call tRAS '///+- Sun Raster Image ///' - Call tTIFF '///+- Tagged Image File Format ///' - Call tXPM '///+- X PixMap ///' - Call tGIF '///+- Graphics Interchange Format ///' - Call tJPEG '///+- Joint Photographic Experts Group ///' + Call tEPS 'Encapsulated PostScript + Call tPCT 'Mac Pict + Call tPBM 'Portable Bitmap + Call tPGM 'Portable Graymap + Call tPPM 'Portable Pixelmap + Call tRAS 'Sun Raster Image + Call tTIFF 'Tagged Image File Format + Call tXPM 'X PixMap + Call tGIF 'Graphics Interchange Format + Call tJPEG 'Joint Photographic Experts Group Call hStatusOut end sub diff --git a/testautomation/graphics/optional/export_graphic_b.bas b/testautomation/graphics/optional/export_graphic_b.bas index 9502b5005625..0abe27eb7579 100644..100755 --- a/testautomation/graphics/optional/export_graphic_b.bas +++ b/testautomation/graphics/optional/export_graphic_b.bas @@ -50,16 +50,16 @@ sub main endif Call sFileExport 'OBSERVE - This line must run before the following testcases! - Call tPDF '///+- Portable Document Format ///' - Call tPDF_Creator '///+- test if the right creator is set in the PDF document - Call tSVG '///+- Scalable Vector Graphics ///' - Call tSVM '///+- StarView Metafile ///' - Call tBMP '///+- Windows Bitmap ///' - Call tEMF '///+- Enhanced Metafile ///' - Call tPNG '///+- Portable Network Graphic ///' - Call tMET '///+- OS/2 Metafile ///' - Call tWMF '///+- Windows Metafile ///' - Call tSWF '///+- Macromedia Flash (SWF) (.swf) ///' + Call tPDF ' Portable Document Format + Call tPDF_Creator 'test if the right creator is set in the PDF document + Call tSVG 'Scalable Vector Graphics + Call tSVM 'StarView Metafile + Call tBMP 'Windows Bitmap + Call tEMF 'Enhanced Metafile + Call tPNG 'Portable Network Graphic + Call tMET 'OS/2 Metafile + Call tWMF 'Windows Metafile + Call tSWF 'Macromedia Flash (SWF) (.swf) Call hStatusOut end sub diff --git a/testautomation/graphics/optional/g_accessability.bas b/testautomation/graphics/optional/g_accessability.bas index 1113dcb4324f..1113dcb4324f 100644..100755 --- a/testautomation/graphics/optional/g_accessability.bas +++ b/testautomation/graphics/optional/g_accessability.bas diff --git a/testautomation/graphics/optional/g_area.bas b/testautomation/graphics/optional/g_area.bas index 3ad024ced1f6..3ad024ced1f6 100644..100755 --- a/testautomation/graphics/optional/g_area.bas +++ b/testautomation/graphics/optional/g_area.bas diff --git a/testautomation/graphics/optional/g_arrangealign.bas b/testautomation/graphics/optional/g_arrangealign.bas index 3d9f2e2ab4ab..3d9f2e2ab4ab 100644..100755 --- a/testautomation/graphics/optional/g_arrangealign.bas +++ b/testautomation/graphics/optional/g_arrangealign.bas diff --git a/testautomation/graphics/optional/g_autocorrection.bas b/testautomation/graphics/optional/g_autocorrection.bas index b4fb2af0b472..b4fb2af0b472 100644..100755 --- a/testautomation/graphics/optional/g_autocorrection.bas +++ b/testautomation/graphics/optional/g_autocorrection.bas diff --git a/testautomation/graphics/optional/g_character.bas b/testautomation/graphics/optional/g_character.bas index e13eccb813c3..e13eccb813c3 100644..100755 --- a/testautomation/graphics/optional/g_character.bas +++ b/testautomation/graphics/optional/g_character.bas diff --git a/testautomation/graphics/optional/g_clipboard.bas b/testautomation/graphics/optional/g_clipboard.bas index 47b48949a162..47b48949a162 100644..100755 --- a/testautomation/graphics/optional/g_clipboard.bas +++ b/testautomation/graphics/optional/g_clipboard.bas diff --git a/testautomation/graphics/optional/g_clipexport.bas b/testautomation/graphics/optional/g_clipexport.bas index d75eef694394..d75eef694394 100644..100755 --- a/testautomation/graphics/optional/g_clipexport.bas +++ b/testautomation/graphics/optional/g_clipexport.bas diff --git a/testautomation/graphics/optional/g_convertto.bas b/testautomation/graphics/optional/g_convertto.bas index 8283981462ee..8283981462ee 100644..100755 --- a/testautomation/graphics/optional/g_convertto.bas +++ b/testautomation/graphics/optional/g_convertto.bas diff --git a/testautomation/graphics/optional/g_crossfading.bas b/testautomation/graphics/optional/g_crossfading.bas index 0c8102e70bde..0c8102e70bde 100644..100755 --- a/testautomation/graphics/optional/g_crossfading.bas +++ b/testautomation/graphics/optional/g_crossfading.bas diff --git a/testautomation/graphics/optional/g_customshapes.bas b/testautomation/graphics/optional/g_customshapes.bas index 960fb7a2e19b..960fb7a2e19b 100644..100755 --- a/testautomation/graphics/optional/g_customshapes.bas +++ b/testautomation/graphics/optional/g_customshapes.bas diff --git a/testautomation/graphics/optional/g_demoguide.bas b/testautomation/graphics/optional/g_demoguide.bas index c3a8fe861724..c3a8fe861724 100644..100755 --- a/testautomation/graphics/optional/g_demoguide.bas +++ b/testautomation/graphics/optional/g_demoguide.bas diff --git a/testautomation/graphics/optional/g_dimensions.bas b/testautomation/graphics/optional/g_dimensions.bas index 3644dfd3b0d8..3644dfd3b0d8 100644..100755 --- a/testautomation/graphics/optional/g_dimensions.bas +++ b/testautomation/graphics/optional/g_dimensions.bas diff --git a/testautomation/graphics/optional/g_edit.bas b/testautomation/graphics/optional/g_edit.bas index 305967f73112..305967f73112 100644..100755 --- a/testautomation/graphics/optional/g_edit.bas +++ b/testautomation/graphics/optional/g_edit.bas diff --git a/testautomation/graphics/optional/g_export_html.bas b/testautomation/graphics/optional/g_export_html.bas index faa2783b6d2f..faa2783b6d2f 100644..100755 --- a/testautomation/graphics/optional/g_export_html.bas +++ b/testautomation/graphics/optional/g_export_html.bas diff --git a/testautomation/graphics/optional/g_findreplace.bas b/testautomation/graphics/optional/g_findreplace.bas index 9de7acfa2bc5..9de7acfa2bc5 100644..100755 --- a/testautomation/graphics/optional/g_findreplace.bas +++ b/testautomation/graphics/optional/g_findreplace.bas diff --git a/testautomation/graphics/optional/g_format.bas b/testautomation/graphics/optional/g_format.bas index 1c03f7bf8801..1c03f7bf8801 100644..100755 --- a/testautomation/graphics/optional/g_format.bas +++ b/testautomation/graphics/optional/g_format.bas diff --git a/testautomation/graphics/optional/g_group.bas b/testautomation/graphics/optional/g_group.bas index 93f542bcc027..93f542bcc027 100644..100755 --- a/testautomation/graphics/optional/g_group.bas +++ b/testautomation/graphics/optional/g_group.bas diff --git a/testautomation/graphics/optional/g_imagemap.bas b/testautomation/graphics/optional/g_imagemap.bas index b2dd4a62c182..b2dd4a62c182 100644..100755 --- a/testautomation/graphics/optional/g_imagemap.bas +++ b/testautomation/graphics/optional/g_imagemap.bas diff --git a/testautomation/graphics/optional/g_insert.bas b/testautomation/graphics/optional/g_insert.bas index a006e2f04c3e..a006e2f04c3e 100644..100755 --- a/testautomation/graphics/optional/g_insert.bas +++ b/testautomation/graphics/optional/g_insert.bas diff --git a/testautomation/graphics/optional/g_line.bas b/testautomation/graphics/optional/g_line.bas index c1327e21bc96..c1327e21bc96 100644..100755 --- a/testautomation/graphics/optional/g_line.bas +++ b/testautomation/graphics/optional/g_line.bas diff --git a/testautomation/graphics/optional/g_load_save.bas b/testautomation/graphics/optional/g_load_save.bas index b68da93657fc..b68da93657fc 100644..100755 --- a/testautomation/graphics/optional/g_load_save.bas +++ b/testautomation/graphics/optional/g_load_save.bas diff --git a/testautomation/graphics/optional/g_mediaplayer.bas b/testautomation/graphics/optional/g_mediaplayer.bas index e237ce752a2d..e237ce752a2d 100644..100755 --- a/testautomation/graphics/optional/g_mediaplayer.bas +++ b/testautomation/graphics/optional/g_mediaplayer.bas diff --git a/testautomation/graphics/optional/g_navigator.bas b/testautomation/graphics/optional/g_navigator.bas index cc165c76b37e..cc165c76b37e 100644..100755 --- a/testautomation/graphics/optional/g_navigator.bas +++ b/testautomation/graphics/optional/g_navigator.bas diff --git a/testautomation/graphics/optional/g_ole.bas b/testautomation/graphics/optional/g_ole.bas index 98f99e4ab931..98f99e4ab931 100644..100755 --- a/testautomation/graphics/optional/g_ole.bas +++ b/testautomation/graphics/optional/g_ole.bas diff --git a/testautomation/graphics/optional/g_paneview.bas b/testautomation/graphics/optional/g_paneview.bas index 021a95cfbfad..021a95cfbfad 100644..100755 --- a/testautomation/graphics/optional/g_paneview.bas +++ b/testautomation/graphics/optional/g_paneview.bas diff --git a/testautomation/graphics/optional/g_paragraph.bas b/testautomation/graphics/optional/g_paragraph.bas index 502728773a6e..502728773a6e 100644..100755 --- a/testautomation/graphics/optional/g_paragraph.bas +++ b/testautomation/graphics/optional/g_paragraph.bas diff --git a/testautomation/graphics/optional/g_savepictureas.bas b/testautomation/graphics/optional/g_savepictureas.bas index 332632dcdac6..332632dcdac6 100644..100755 --- a/testautomation/graphics/optional/g_savepictureas.bas +++ b/testautomation/graphics/optional/g_savepictureas.bas diff --git a/testautomation/graphics/optional/g_shaddow.bas b/testautomation/graphics/optional/g_shaddow.bas index c6e963ae1658..c6e963ae1658 100644..100755 --- a/testautomation/graphics/optional/g_shaddow.bas +++ b/testautomation/graphics/optional/g_shaddow.bas diff --git a/testautomation/graphics/optional/g_slidelayer.bas b/testautomation/graphics/optional/g_slidelayer.bas index 3ffd9a4ab37a..3ffd9a4ab37a 100644..100755 --- a/testautomation/graphics/optional/g_slidelayer.bas +++ b/testautomation/graphics/optional/g_slidelayer.bas diff --git a/testautomation/graphics/optional/g_spellcheck.bas b/testautomation/graphics/optional/g_spellcheck.bas index 7dad1b0d9e40..bf49f64329b5 100644..100755 --- a/testautomation/graphics/optional/g_spellcheck.bas +++ b/testautomation/graphics/optional/g_spellcheck.bas @@ -42,19 +42,18 @@ sub main use "graphics\optional\includes\global\g_spellcheck.inc" hSetLocaleStrings ( gTesttoolPath + "graphics\tools\locale_1.txt" , glLocale () ) - PrintLog "-------------------------" + gApplication + "-------------------" - Call tiToolsSpellcheckCorrect - Call tiToolsSpellcheckError - Call tiToolsSpellcheckCheck - Call tToolsSpellcheckAutoSpellcheck + call tiToolsSpellcheckError + call tiToolsSpellcheckCheck_AlwaysIgnore + call tiToolsSpellcheckCheck_Change + call tiToolsSpellcheckCheck_ChangeAll gApplication = "DRAW" PrintLog "-------------------------" + gApplication + "-------------------" - Call tiToolsSpellcheckCorrect - Call tiToolsSpellcheckError - Call tiToolsSpellcheckCheck - Call tToolsSpellcheckAutoSpellcheck + call tiToolsSpellcheckError + call tiToolsSpellcheckCheck_AlwaysIgnore + call tiToolsSpellcheckCheck_Change + call tiToolsSpellcheckCheck_ChangeAll Call hStatusOut end sub diff --git a/testautomation/graphics/optional/g_stylist.bas b/testautomation/graphics/optional/g_stylist.bas index 50da6610c41a..50da6610c41a 100644..100755 --- a/testautomation/graphics/optional/g_stylist.bas +++ b/testautomation/graphics/optional/g_stylist.bas diff --git a/testautomation/graphics/optional/g_tables.bas b/testautomation/graphics/optional/g_tables.bas index dee2e14c67a5..dee2e14c67a5 100644..100755 --- a/testautomation/graphics/optional/g_tables.bas +++ b/testautomation/graphics/optional/g_tables.bas diff --git a/testautomation/graphics/optional/g_toolbars.bas b/testautomation/graphics/optional/g_toolbars.bas index b643e02c9e9b..b643e02c9e9b 100644..100755 --- a/testautomation/graphics/optional/g_toolbars.bas +++ b/testautomation/graphics/optional/g_toolbars.bas diff --git a/testautomation/graphics/optional/g_tools.bas b/testautomation/graphics/optional/g_tools.bas index 4e79a89ca469..4e79a89ca469 100644..100755 --- a/testautomation/graphics/optional/g_tools.bas +++ b/testautomation/graphics/optional/g_tools.bas diff --git a/testautomation/graphics/optional/g_zoom.bas b/testautomation/graphics/optional/g_zoom.bas index 1b494950ce44..1b494950ce44 100644..100755 --- a/testautomation/graphics/optional/g_zoom.bas +++ b/testautomation/graphics/optional/g_zoom.bas diff --git a/testautomation/graphics/optional/gallery.bas b/testautomation/graphics/optional/gallery.bas index 9b81954f8902..9b81954f8902 100644..100755 --- a/testautomation/graphics/optional/gallery.bas +++ b/testautomation/graphics/optional/gallery.bas diff --git a/testautomation/graphics/optional/gallery2.bas b/testautomation/graphics/optional/gallery2.bas index d467b0a74876..d467b0a74876 100644..100755 --- a/testautomation/graphics/optional/gallery2.bas +++ b/testautomation/graphics/optional/gallery2.bas diff --git a/testautomation/graphics/optional/i_animation.bas b/testautomation/graphics/optional/i_animation.bas index 85503fc790c1..85503fc790c1 100644..100755 --- a/testautomation/graphics/optional/i_animation.bas +++ b/testautomation/graphics/optional/i_animation.bas diff --git a/testautomation/graphics/optional/i_headerfooter.bas b/testautomation/graphics/optional/i_headerfooter.bas index e050b914ca9e..e050b914ca9e 100644..100755 --- a/testautomation/graphics/optional/i_headerfooter.bas +++ b/testautomation/graphics/optional/i_headerfooter.bas diff --git a/testautomation/graphics/optional/i_only_updt_1.bas b/testautomation/graphics/optional/i_only_updt_1.bas deleted file mode 100644 index fd1e4ae68215..000000000000 --- a/testautomation/graphics/optional/i_only_updt_1.bas +++ /dev/null @@ -1,77 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Only Required Test (Part 1) -'* -'\***************************************************************** - -public glLocale (15*20) as string -global ExtensionString as String - -sub main - Printlog " -------------------- Impress-Only-Required-Test -----------------------------" - Call hStatusIn ( "Graphics","i_only_updt_1.bas") - - use "graphics\tools\id_tools.inc" - use "graphics\tools\id_tools_2.inc" - use "graphics\required\includes\global\id_002.inc" 'Edit - use "graphics\required\includes\global\id_003.inc" 'View - use "graphics\required\includes\global\id_004.inc" 'Insert - use "graphics\required\includes\global\id_005.inc" 'Format - use "graphics\required\includes\global\id_006.inc" 'Tools - use "graphics\required\includes\impress\im_003_.inc" 'Ansicht - use "graphics\required\includes\impress\im_004_.inc" 'Einfuegen - - if hSetLocaleStrings ( gTesttoolPath + "graphics\tools\locale_1.txt" , glLocale () ) = FALSE then - qaErrorLog "Locales doesn't exist in file : "+gTesttoolPath + "graphics\tools\locale_1.txt" ' this is needed for spellchecking. - endif - - call id_002 - call im_003_ - call id_003 - call im_004_ - call id_004 - call id_005 - call id_006 - - Call hStatusOut -end sub - -'---------------------------------------------- -sub LoadIncludeFiles - use "global\system\includes\master.inc" - use "global\system\includes\gvariabl.inc" - use "global\required\includes\g_option.inc" - use "global\required\includes\g_customize.inc" - use "global\required\includes\g_001.inc" - use "global\required\includes\g_009.inc" - gApplication = "IMPRESS" - Call GetUseFiles() -end sub - diff --git a/testautomation/graphics/optional/i_only_updt_2.bas b/testautomation/graphics/optional/i_only_updt_2.bas deleted file mode 100644 index 7b35dbab5740..000000000000 --- a/testautomation/graphics/optional/i_only_updt_2.bas +++ /dev/null @@ -1,76 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Only Required (Test Part 2) -'* -'\***************************************************************** - -public glLocale (15*20) as string -global ExtensionString as String - -sub main - Printlog " -------------------- Impress-Only-Required-Test -----------------------------" - Call hStatusIn ( "Graphics","i_only_updt_2.bas") - - use "graphics\tools\id_tools.inc" - use "graphics\tools\id_tools_2.inc" - use "graphics\required\includes\global\id_001.inc" 'File - use "graphics\required\includes\global\id_007.inc" 'Kontext - use "graphics\required\includes\global\id_008.inc" 'Window - use "graphics\required\includes\global\id_009.inc" 'Help - use "graphics\required\includes\global\id_011.inc" 'Toolbars - use "graphics\required\includes\impress\im_007_.inc" 'Praesentation - - if hSetLocaleStrings ( gTesttoolPath + "graphics\tools\locale_1.txt" , glLocale () ) = FALSE then - qaErrorLog "Locales doesn't exist in file : "+gTesttoolPath + "graphics\tools\locale_1.txt" ' this is needed for spellchecking. - endif - - call id_011 - Call tFileExportAsPDF - Call tExportAsPDFButton - Call im_007_ - call id_008 - call id_009 - call id_007 - - Call hStatusOut -end sub - -'---------------------------------------------- -sub LoadIncludeFiles - use "global\system\includes\master.inc" - use "global\system\includes\gvariabl.inc" - use "global\required\includes\g_option.inc" - use "global\required\includes\g_customize.inc" - use "global\required\includes\g_001.inc" - use "global\required\includes\g_009.inc" - gApplication = "IMPRESS" - Call GetUseFiles() -end sub - diff --git a/testautomation/graphics/optional/i_pengine.bas b/testautomation/graphics/optional/i_pengine.bas index 5ddefe26ca94..5ddefe26ca94 100644..100755 --- a/testautomation/graphics/optional/i_pengine.bas +++ b/testautomation/graphics/optional/i_pengine.bas diff --git a/testautomation/graphics/optional/i_saveloadlayout.bas b/testautomation/graphics/optional/i_saveloadlayout.bas index 137007da7c8f..137007da7c8f 100644..100755 --- a/testautomation/graphics/optional/i_saveloadlayout.bas +++ b/testautomation/graphics/optional/i_saveloadlayout.bas diff --git a/testautomation/graphics/optional/i_shape.bas b/testautomation/graphics/optional/i_shape.bas index 0ebb3c1e4864..0ebb3c1e4864 100644..100755 --- a/testautomation/graphics/optional/i_shape.bas +++ b/testautomation/graphics/optional/i_shape.bas diff --git a/testautomation/graphics/optional/i_slidecopy.bas b/testautomation/graphics/optional/i_slidecopy.bas index c780904e542d..c780904e542d 100644..100755 --- a/testautomation/graphics/optional/i_slidecopy.bas +++ b/testautomation/graphics/optional/i_slidecopy.bas diff --git a/testautomation/graphics/optional/i_slideshow.bas b/testautomation/graphics/optional/i_slideshow.bas index 8a9062c87c05..e52427f1402a 100644..100755 --- a/testautomation/graphics/optional/i_slideshow.bas +++ b/testautomation/graphics/optional/i_slideshow.bas @@ -52,7 +52,7 @@ sub main warnlog "Add 'slide' to FILE /input/impress/locale_1.txt (take string from below)!!!" endif - '/// LOCALE Slide - 2 ///' + printlog "LOCALE Slide - 2" S1 = glLocale (2) + " 1" S2 = glLocale (2) + " 2" S3 = glLocale (2) + " 3" diff --git a/testautomation/graphics/optional/i_us_presentation.bas b/testautomation/graphics/optional/i_us_presentation.bas index fc1196fdb182..c8836cad4887 100644..100755 --- a/testautomation/graphics/optional/i_us_presentation.bas +++ b/testautomation/graphics/optional/i_us_presentation.bas @@ -42,14 +42,7 @@ sub main PrintLog "------------ Graphics User-scenario-test: PowerUser creates a Presentation ------------" - Call i_us_presentation1 ' User-Scenario: Pro. - Call i_us_presentation2 - Call i_us_presentation3 - Call i_us_presentation4 - Call i_us_presentation5 - Call i_us_presentation6 - Call i_us_presentation7 - + Call i_us_presentation ' User-Scenario: Pro. Call i_us2_pres1 ' User-Scenario: Beginner. Call i_us2_pres2 diff --git a/testautomation/graphics/optional/i_view.bas b/testautomation/graphics/optional/i_view.bas index 7dacea82d1b2..7dacea82d1b2 100644..100755 --- a/testautomation/graphics/optional/i_view.bas +++ b/testautomation/graphics/optional/i_view.bas diff --git a/testautomation/graphics/optional/includes/draw/d_002_.inc b/testautomation/graphics/optional/includes/draw/d_002_.inc deleted file mode 100644 index 9b2f267a0729..000000000000 --- a/testautomation/graphics/optional/includes/draw/d_002_.inc +++ /dev/null @@ -1,109 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\***************************************************************** - - -testcase tdEditCrossFading - - printlog " open application " - Call hNewDocument - printlog " create 2 rectangles " - gMouseClick 50,50 - Call hRechteckErstellen ( 10, 10, 20, 40 ) - Call hRechteckErstellen ( 30, 30, 50, 60 ) - printlog " Edit-YSelect All " - EditSelectAll - try - printlog " Edit->Cross-fading " - EditCrossFading - catch - warnlog "EditCrossFading not accessible :-(" - endcatch - - Kontext "Ueberblenden" - Call DialogTest ( Ueberblenden ) - printlog " Change : 'Increments'; 1 more, 1 less " - Schritte.More - Schritte.Less - printlog " Change: Cross-fading attributes; uncheck, check " - Attributierung.uncheck - Attributierung.check - printlog " Change: same orientation; uncheck, check " - GleicheOrientierung.Uncheck - GleicheOrientierung.Check - printlog " cancel dialog 'Cross-fading'; uncheck, check " - Ueberblenden.Cancel - printlog " close application " - Call hCloseDocument - -endcase 'tdEditCrossFading -'------------------------------------------------------------------------------ -testcase tdEditLayer - - printlog " open application " - Call hNewDocument - printlog " View->Layer " - ViewLayer - printlog " Edit->Layer->Insert " - InsertLayer - Kontext "EbeneEinfuegenDlg" - Call DialogTest ( EbeneEinfuegenDlg ) - printlog " Change: Set another name for the layer " - EbenenName.SetText "SomeThing" - printlog " Change: Visible; uncheck, check " - Sichtbar.UnCheck - Sichtbar.Check - printlog " Change: Printable; uncheck, check " - Druckbar.UnCheck - Druckbar.Check - printlog " Change: Locked; check, uncheck " - Gesperrt.Check - Gesperrt.UnCheck - EbeneEinfuegenDlg.OK - printlog " (Edit->Layer->Modify is tested in format-menu-test) " - printlog " Edit->Layer->Rename " - EditLayerRename - kontext "DocumentDrawImpress" - LayerTabBar.TypeKeys "Apply!!<Return>" , true - printlog " Edit->Layer->Delete " - EditDeleteLayer - printlog " Messagebox: really delete? YES " - Kontext "Messagebox" - Messagebox.Yes - sleep (2) - printlog " View->Layer " - ViewLayer - printlog " close application " - Call hCloseDocument - -endcase 'tdEditLayer -'------------------------------------------------------------------------------ diff --git a/testautomation/graphics/optional/includes/draw/d_003_.inc b/testautomation/graphics/optional/includes/draw/d_003_.inc deleted file mode 100644 index 744461061559..000000000000 --- a/testautomation/graphics/optional/includes/draw/d_003_.inc +++ /dev/null @@ -1,82 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\***************************************************************** - -testcase tdViewPagePane - - printlog " open application " - Call hNewDocument - sleep 1 - kontext "pagepane" - if (NOT pagepane.exists) then - qaerrorlog "Pages Panel not visible on opening application. Opening now." - ViewPagePane - endif - kontext "pagepane" - sleep (2) - try - printlog " View->Page Pane " - ViewPagePane - sleep (2) - if (pagepane.exists) then - warnlog "View->Page Pane failed." - ViewPagePane - endif - catch - warnlog "View->Page Pane couldn't get executed" - endcatch - sleep 1 - if (NOT pagepane.exists) then - ViewPagePane - sleep (1) - endif - printlog " close application " - Call hCloseDocument - -endcase 'tdViewPagePane - -'------------------------------------------------------------------------------- -testcase tdViewSlide - - printlog " open application " - hNewDocument - kontext "DocumentDrawImpress" ' special case :-) - printlog " click the button on the bottom: 'Master View' (because it is not accessible via the menu :-() " - ViewMasterPage - sleep 1 - printlog " View->Slide " - ViewPagePane - Sleep 1 - printlog " close application " - Call hCloseDocument - -endcase 'tdViewSlide diff --git a/testautomation/graphics/optional/includes/draw/d_005_.inc b/testautomation/graphics/optional/includes/draw/d_005_.inc deleted file mode 100644 index 6c3e7b2484df..000000000000 --- a/testautomation/graphics/optional/includes/draw/d_005_.inc +++ /dev/null @@ -1,51 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\***************************************************************** - -testcase tiFormatLayer - - printlog " open application " - Call hNewDocument - printlog " View->Layer " - ViewLayer - printlog " Format->Layer " - FormatLayer - Kontext "EbeneAendernDlg" - DialogTest ( EbeneAendernDlg ) - printlog " cancel dialog 'Modify Layer' " - EbeneAendernDlg.Cancel - printlog " View->Layer " - ViewLayer - printlog " close application " - Call hCloseDocument - -endcase 'tiFormatLayer diff --git a/testautomation/graphics/optional/includes/draw/d_007.inc b/testautomation/graphics/optional/includes/draw/d_007.inc deleted file mode 100644 index 89fef373f161..000000000000 --- a/testautomation/graphics/optional/includes/draw/d_007.inc +++ /dev/null @@ -1,47 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\***************************************************************** - -testcase tdModifyRotate - - printlog " open application " - Call hNewDocument - printlog " create a rectangle " - Call hRechteckErstellen 20,20,40,40 - sleep 1 - printlog " Modify->Rotate " - ModifyRotate - sleep 1 - printlog " close application " - Call hCloseDocument - -endcase 'tdModifyRotate diff --git a/testautomation/graphics/optional/includes/global/export_graphic.inc b/testautomation/graphics/optional/includes/global/export_graphic.inc index 3fe39632521c..a5ab31c82cdc 100644 --- a/testautomation/graphics/optional/includes/global/export_graphic.inc +++ b/testautomation/graphics/optional/includes/global/export_graphic.inc @@ -32,76 +32,78 @@ '\****************************************************************************** testcase tEPS + + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + dim x as integer dim i as integer + const sFilter = "EPS - Encapsulated PostScript (.eps)" const sExt = ".eps" printlog "open the document" hFileOpen( gTesttoolPath + "graphics\required\input\graphicexport." + ExtensionString ) + if ( hCallExport ( OutputGrafikTBO , sFilter ) ) then - Kontext "EPSOptionen" - if ( EPSOptionen.Exists( 2 ) ) then + Kontext "EPSOptions" + if ( EPSOptions.Exists( 2 ) ) then printlog "check if all properties have the right count, and depend on each other" - ' they do not affect annything, i can check (TBO) - ' VorschauTIF.Check - ' InterchangeEPSI.Check + Level1.Check - if Farbe.IsEnabled then warnlog " :-(" - if Graustufen.IsEnabled then warnlog " :-(" - if LZWKodierung.IsEnabled then warnlog " :-(" - if Keine.IsEnabled then warnlog " :-(" - ' if (TextEinstellungen.IsEnabled <> TRUE) then warnlog " :-(" + if Color.IsEnabled then warnlog " :-(" + if Greyscale.IsEnabled then warnlog " :-(" + if LZWEncoding.IsEnabled then warnlog " :-(" + if NoneCompression.IsEnabled then warnlog " :-(" + Level2.Check - if (Farbe.IsEnabled <> TRUE) then warnlog " :-(" - if (Graustufen.IsEnabled <> TRUE) then warnlog " :-(" - if (LZWKodierung.IsEnabled <> TRUE) then warnlog " :-(" - if (Keine.IsEnabled <> TRUE) then warnlog " :-(" - ' if (TextEinstellungen.IsEnabled <> TRUE) then warnlog " :-(" - printlog "'Color Resolution' listbox contains eight items" - ' x = TextEinstellungen.GetItemCount - ' if x <> 2 then warnlog "'TextEinstellungen' Count is wrong; should:2, is:" + x - ' for i = 1 to x - ' TextEinstellungen.Select i - ' sleep 1 - ' Printlog " - " + i + ": '" +TextEinstellungen.GetSelText + "'" - ' next i + if (Color.IsEnabled <> TRUE) then warnlog " :-(" + if (Greyscale.IsEnabled <> TRUE) then warnlog " :-(" + if (LZWEncoding.IsEnabled <> TRUE) then warnlog " :-(" + if (NoneCompression.IsEnabled <> TRUE) then warnlog " :-(" + printlog "leave dialog with cancel -> there has to be no file created!" - hCloseDialog( EPSOptionen, "cancel" ) + hCloseDialog( EPSOptions, "cancel" ) + if ( FileExists( OutputGrafikTBO+sExt ) ) then ' inspired by bug #99932 Graphic is exported though cancel is pressed warnlog "Dialog was canceled, but file got saved, too :-( - i35177" endif else warnlog( "No export options dialog was displayed" ) end if + Kontext "Active" if Active.Exists(2) then Warnlog "'" + sFilter + "' has a problem" Active.OK end if end if + printlog( "Save the file" ) if ( hCallExport( OutputGrafikTBO, sFilter ) ) then - Kontext "EPSOptionen" - if ( EPSOptionen.Exists( 2 ) ) then - printlog "TextEinstellungen.select 2" - hCloseDialog( EPSOptionen, "ok" ) + Kontext "EPSOptions" + if ( EPSOptions.Exists( 2 ) ) then + hCloseDialog( EPSOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif + printlog( "Close file and re-insert graphics into new document" ) - if ( lcase( gPlatform ) <> "osx" ) then - hInsertGraphicsToNewFile( OutputGrafikTBO + sExt ) ' local helper function, see bottom of this file - else - qaErrorLog "#i100253# crash on MacOS X 10.4" - endif + hInsertGraphicsToNewFile( OutputGrafikTBO + sExt ) ' local helper function, see bottom of this file endif + call hCloseDocument + endcase 'tEPS '------------------------------------------------------------------------- testcase tPCT + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + + dim x as integer dim i as integer dim iWaitIndex as integer @@ -122,24 +124,13 @@ testcase tPCT printlog "open the document" sDocument = convertpath( gTesttoolPath + "graphics\required\input\graphicexport." + ExtensionString ) hFileOpen( sDocument ) - + printlog "----------1st: Trying export and canceling it." if ( hCallExport( OutputGrafikTBO , sFilter ) ) then - - Kontext "PICTOptionen" + Kontext "PCTOptions" printlog( "Export options dialog" ) - if ( PICTOptionen.Exists( 2 ) ) then - - printlog "check if all properties have the right count, and depend on each other" - Original.Check - if Breite.IsEnabled then warnlog " :-(" - if Hoehe.IsEnabled then warnlog " :-(" - Groesse.Check - Breite.More - Hoehe.Less - + if PCTOptions.Exists(2) then printlog "leave dialog with cancel -> there has to be no file created!" - hCloseDialog( PICTOptionen, "cancel" ) - + hCloseDialog( PCTOptions, "cancel" ) if ( FileExists( OutputGrafikTBO + sExt ) ) then warnlog( "#i35177# - dialog <PictOptions> canceled, still the file was saved" ) endif @@ -152,33 +143,25 @@ testcase tPCT Warnlog " '" + sFilter + "' has a problem" Active.OK end if - end if - printlog " now save it realy and load the file afterwards" + printlog "----------2nd: now save it really and load the file afterwards" if ( hCallExport( OutputGrafikTBO, sFilter ) ) then - Kontext "PICTOptionen" + Kontext "PCTOptions" printlog( "Export options dialog" ) - if ( PICTOptionen.Exists( 2 ) ) then - Groesse.Check - Breite.Less - Hoehe.More - hCloseDialog( PICTOptionen, "ok" ) + if ( PCTOptions.Exists( 2 ) ) then + hCloseDialog( PCTOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif - sOutputFile = OutputGrafikTBO+sExt - if ( hWaitForOutputFile( sOutputFile ) ) then - - printlog( "Close file and re-insert graphics into new document" ) + printlog "Close file and re-insert graphics into new document" hInsertGraphicsToNewFile( sOutputFile ) ' local helper function, see bottom of this file else warnlog( "File was not saved: " & sOutputFile ) endif - endif hFileReOpen( sDocument ) @@ -192,104 +175,15 @@ testcase tPCT endif endif - hTypeKeys ("<escape><tab>") - fGetSizeXY sx1, sY, TRUE - - if ( hCallExport( OutputGrafikTBO + "1", sFilter, TRUE ) ) then - - Kontext "PICTOptionen" - printlog( "Export options dialog" ) - if ( PICTOptionen.Exists( 2 ) ) then - Original.Check - hCloseDialog( PICTOptionen, "ok" ) - else - warnlog( "No export options dialog was displayed" ) - endif - - sOutputFile = OutputGrafikTBO + "1" + sExt - if ( hWaitForOutputFile( sOutputFile ) ) then - printlog( "Close file and re-insert graphics into new document" ) - hInsertGraphicsToNewFile( sOutputFile ) ' local helper function, see bottom of this file - else - warnlog( "File was not saved: " & sOutputFile ) - endif - - bTemp = fGetSizeXY( sx1, sY, bTemp ) - if (bTemp = FALSE) then - warnlog "Selected original size NOT OK :-(" - endif - endif - - hFileReOpen( "" ) - hRechteckErstellen ( 10, 10, 30, 40 ) - - if ( hCallExport( OutputGrafikTBO + "2" , sFilter, TRUE ) ) then - - Kontext "PICTOptionen" - printlog( "Export options dialog" ) - if ( PICTOptionen.Exists( 2 ) ) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check - - printlog "Check 'Size' one more time to make the change go through" - sx1 = Breite.GetText - sY = Hoehe.GetText - hCloseDialog( PICTOptionen, "ok" ) - else - warnlog( "No export options dialog was displayed" ) - endif - - sOutputFile = OutputGrafikTBO + "2" + sExt - - if ( not hWaitForOutputFile( sOutputFile ) ) then - warnlog( "File was not saved: " & sOutputFile ) - endif - - printlog( "Reload file if it exists. Warn if not" ) - hFileReOpen( sOutputFile ) - - kontext "DocumentDraw" - DocumentDraw.TypeKeys ("<escape><tab>") - ContextOriginalSize - bTemp = fGetSizeXY( sx1, sY, bTemp ) - if ( not bTemp ) then warnlog "Selected original size NOT OK :-(" - endif - - if ( hCallExport( OutputGrafikTBO + "3", sFilter, TRUE ) ) then - - Kontext "PICTOptionen" - printlog( "Export options dialog" ) - if ( PICTOptionen.Exists( 2 ) ) then - Groesse.Check - sX2 = Breite.GetText - if (LiberalMeasurement(sx1, sX2)) <> TRUE then - if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then - Printlog "Width was ok. Expected: " + sx1 + "' was: '" + sX2 + "'" - else - warnLog "Width is different expected: '" + sx1 + "' is: '" + sX2 + "'" - endif - endif - sY2 = Hoehe.GetText - if (LiberalMeasurement(sY, sY2)) <> TRUE then - if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then - Printlog "Height was ok. Expected: " + sY + "' was: '" + sY2 + "'" - else - warnLog "Height is different expected: '" + sY + "' is: '" + sY2 + "'" - endif - endif - hCloseDialog( PICTOptionen, "cancel" ) - else - warnlog( "No export options dialog was displayed" ) - endif - endif - call hCloseDocument endcase 'tPCT '------------------------------------------------------------------------------- testcase tPBM + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "PBM - Portable Bitmap (.pbm)" const sExt = ".pbm" @@ -300,15 +194,17 @@ testcase tPBM printlog "Save it" if ( hCallExport (OutputGrafikTBO , sFilter ) ) then - Kontext "PBMOptionen" - if ( PBMOptionen.Exists( 2 ) ) then - Ascii.Check - hCloseDialog( PBMOptionen, "ok" ) + Kontext "PBMOptions" + if ( PBMOptions.Exists( 2 ) ) then + QualityBinary.Check + QualityText.Check + hCloseDialog( PBMOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif printlog( "Close file and re-insert graphics into new document" ) + sleep (1) hInsertGraphicsToNewFile( OutputGrafikTBO + sExt ) ' local helper function, see bottom of this file endif @@ -318,6 +214,10 @@ testcase tPBM endcase 'tPBM '------------------------------------------------------------------------------- testcase tPGM + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "PGM - Portable Graymap (.pgm)" const sExt = ".pgm" @@ -328,10 +228,11 @@ testcase tPGM printlog "Save it" if ( hCallExport (OutputGrafikTBO , sFilter ) ) then - Kontext "PGMOptionen" - if ( PGMOptionen.Exists( 2 ) ) then - Ascii.Check - hCloseDialog( PGMOptionen, "ok" ) + Kontext "PGMOptions" + if ( PGMOptions.Exists( 2 ) ) then + QualityBinary.Check + QualityText.Check + hCloseDialog( PGMOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif @@ -346,6 +247,10 @@ testcase tPGM endcase 'tPGM '------------------------------------------------------------------------------- testcase tPPM + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "PPM - Portable Pixelmap (.ppm)" const sExt = ".ppm" @@ -356,10 +261,11 @@ testcase tPPM printlog "Save it" if ( hCallExport (OutputGrafikTBO , sFilter ) ) then - Kontext "PPMOptionen" - if ( PPMOptionen.Exists( 2 ) ) then - Ascii.Check - hCloseDialog( PPMOptionen, "ok" ) + Kontext "PPMOptions" + if ( PPMOptions.Exists( 2 ) ) then + QualityBinary.Check + QualityText.Check + hCloseDialog( PPMOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif @@ -374,6 +280,10 @@ testcase tPPM endcase 'tPPM '------------------------------------------------------------------------------ testcase tRAS + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "RAS - Sun Raster Image (.ras)" const sExt = ".ras" @@ -394,6 +304,10 @@ testcase tRAS endcase 'tRAS '------------------------------------------------------------------------------ testcase tTIFF + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + dim x as integer dim i as integer @@ -417,6 +331,10 @@ testcase tTIFF endcase 'tTIFF '------------------------------------------------------------------------------ testcase tXPM + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "XPM - X PixMap (.xpm)" const sExt = ".xpm" @@ -437,6 +355,10 @@ testcase tXPM endcase 'tXPM '------------------------------------------------------------------------------- testcase tGIF + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "GIF - Graphics Interchange Format (.gif)" const sExt = ".gif" @@ -447,16 +369,17 @@ testcase tGIF printlog "save it" if ( hCallExport( OutputGrafikTBO, sFilter ) ) then - Kontext "GIFOptionen" - if GIFOptionen.Exists (2) then - Interlace.Uncheck - TransparentSpeichern.UnCheck - hCloseDialog( GIFOptionen, "ok" ) + Kontext "GIFOptions" + if GIFOptions.Exists (2) then + Interlaced.Uncheck + Transparency.UnCheck + hCloseDialog( GIFOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif printlog( "Close file and re-insert graphics into new document" ) + sleep (1) hInsertGraphicsToNewFile( OutputGrafikTBO + sExt ) ' local helper function, see bottom of this file endif @@ -466,6 +389,10 @@ testcase tGIF endcase 'tGIF '------------------------------------------------------------------------------- testcase tJPEG + warnlog( "#i115138# - Test document freezes draw" ) + goto endsub + + const sFilter = "JPEG - Joint Photographic Experts Group (.jpg;.jpeg;.jfif;.jif;.jpe)" const sExt = ".jpg" @@ -476,11 +403,10 @@ testcase tJPEG printlog " save it " if ( hCallExport( OutputGrafikTBO , sFilter ) ) then - Kontext "JpegOptionen" - if ( JpegOptionen.Exists( 2 ) ) then - Echtfarben.Check - Qualitaet.ToMin - hCloseDialog( JpegOptionen, "ok" ) + Kontext "JPGOptions" + if ( JPGOptions.Exists( 2 ) ) then + Quality.ToMin + hCloseDialog( JPGOptions, "ok" ) else warnlog( "No export options dialog was displayed" ) endif @@ -497,7 +423,7 @@ endcase 'tJPEG '******************************************************************************* function hInsertGraphicsToNewFile( sOutputFile as string ) - + sleep (1) if ( FileExists( sOutputFile ) ) then hFileReOpen( "" ) Call hGrafikEinfuegen( sOutputFile ) @@ -533,21 +459,26 @@ end function '******************************************************************************* function hWaitForOutputFile( sOutputFile as string ) as boolean + const FILE_WRITE_TIMEOUT = 30 dim iWait as integer : iWait = 0 for iWait = 1 to FILE_WRITE_TIMEOUT + ' File found if ( FileExists( sOutputFile ) ) then hWaitForOutputFile() = true exit function endif + ' Timeout if ( iWait = FILE_WRITE_TIMEOUT ) then hWaitForOutputFile() = false exit function endif + wait( 1000 ) + next iWait -end function +end function diff --git a/testautomation/graphics/optional/includes/global/export_graphic_2.inc b/testautomation/graphics/optional/includes/global/export_graphic_2.inc index be5ed49ca423..c33b5c10f126 100644 --- a/testautomation/graphics/optional/includes/global/export_graphic_2.inc +++ b/testautomation/graphics/optional/includes/global/export_graphic_2.inc @@ -32,6 +32,9 @@ '\****************************************************************************** testcase tPNG + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim iWaitIndex as integer @@ -44,13 +47,13 @@ testcase tPNG hFileOpen( gTesttoolPath & "graphics\required\input\graphicexport." & ExtensionString ) if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "PNGOptionen" - if PNGOptionen.Exists (2) then - Kompression.ToMax + Kontext "PNGOptions" + if PNGOptions.Exists (2) then + Compression.ToMax Interlaced.UnCheck - PNGOptionen.OK + PNGOptions.OK iWaitIndex = 0 - do while PNGOptionen.Exists AND iWaitIndex < 30 + do while PNGOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -73,6 +76,10 @@ endcase 'tPNG '------------------------------------------------------------------------------- testcase tSVM + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + + dim x as integer dim i as integer dim sFilter as string @@ -87,25 +94,19 @@ testcase tSVM sFilter = "SVM - StarView Metafile (.svm)" sExt = ".svm" - + printlog "opening test file" sDocument = ConvertPath ( gTesttoolPath & "graphics\required\input\graphicexport." & ExtensionString) hFileOpen sDocument + printlog "Trying export and canceling it.." if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - if Breite.IsEnabled then - warnlog " :-(" - endif - if Hoehe.IsEnabled then - warnlog " :-(" - endif - Groesse.Check - Breite.More - Hoehe.Less - SVMOptionen.Cancel + Kontext "SVMOptions" + if SVMOptions.Exists (2) then + Exportwidth.More + Exportheight.Less + SVMOptions.Cancel sleep 5 + printlog "Checking if directory is still empty.." if ( dir(OutputGrafikTBO+sExt) = "") then ' inspired by bug #99932 Graphic is exported though cancel is pressed Printlog "ok :-)" else @@ -122,13 +123,14 @@ testcase tSVM Active.OK end if end if + + printlog "Doing real SVM export." if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.Less - Hoehe.More - SVMOptionen.OK + Kontext "SVMOptions" + if SVMOptions.Exists (2) then + Exportwidth.Less + Exportheight.More + SVMOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO+sExt) <> "") then @@ -136,56 +138,77 @@ testcase tSVM else warnlog "File didn't get saved :-(" endif - hCloseDocument () - sleep 5 - hNewDocument() - sleep 5 - Call hGrafikEinfuegen ( OutputGrafikTBO+sExt ) endif + printlog "Closing TestDoc." + hCloseDocument () + sleep 5 + printlog "Opening new doc and inserting exported file." + hNewDocument() + sleep 5 + Call hGrafikEinfuegen ( OutputGrafikTBO+sExt ) + printlog "Closing doc with inserted file." hCloseDocument () + + printlog "Loading testdoc." hFileOpen (sDocument) sleep (10) - + printlog "Making doc editable." call fMakeDocumentWritable - + printlog "Selecting part of doc." hTypeKeys ("<escape><tab>") + printlog "getting size of part. " fGetSizeXY sx1, sY, TRUE + printlog "exporting part of doc." if hCallExport (OutputGrafikTBO & "1" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - SVMOptionen.OK - sleep 5 - endif + Kontext "SVMOptions" + SVMOptions.OK + sleep 5 if ( dir(OutputGrafikTBO & "1" & sExt) <> "") then Printlog "Ok :-) Saved as: '" & OutputGrafikTBO & "1" & sExt & "'" else warnlog "File didn't get saved :-(" endif + printlog "Closing testdoc." hCloseDocument () sleep 5 + printlog "Opening new doc." hNewDocument() sleep 5 + printlog "Inserting exported part of Testdoc." Call hGrafikEinfuegen ( OutputGrafikTBO & "1" & sExt ) bTemp = FALSE + printlog "checking size of inserted file." fGetSizeXY sx1, sY, bTemp if (bTemp = FALSE) then warnlog "Selected original size NOT OK :-(" endif endif + printlog "closing doc." hCloseDocument () + + printlog "opening new doc." hNewDocument() + printlog "inserting Rectangle." hRechteckErstellen ( 10, 10, 30, 40 ) + printlog "Exporting Rectangle" if hCallExport (OutputGrafikTBO & "2" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check 'Check to make settings go throught - sx1 = Breite.GetText - sY = Hoehe.GetText - SVMOptionen.OK + Kontext "SVMOptions" + if SVMOptions.Exists (2) then + Exportwidth.SetText "9" + if Exportmeasurement.GetSelText = "inches" then + sx1 = (Exportwidth.GetText)+ """" + printlog "sx1= " & sx1 + else + sx1 = (Exportwidth.GetText)+ "cm" + endif + + if Exportmeasurement.GetSelText = "inches" then + sY = (Exportheight.GetText)+ """" + printlog "sY= " & sY + else + sY = (Exportwidth.GetText)+ "cm" + endif + SVMOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO & "2" & sExt) <> "") then @@ -193,8 +216,10 @@ testcase tSVM else warnlog "File didn't get saved :-(" endif + printlog "Closing doc." hCloseDocument () sleep 5 + printlog "Opening exported rectangle." hFileOpen (OutputGrafikTBO & "2" & sExt) kontext "Filterauswahl" if Filterauswahl.exists then @@ -204,6 +229,7 @@ testcase tSVM endif kontext "DocumentDraw" DocumentDraw.TypeKeys ("<escape><tab>") + printlog "Selecting and checking size.." ContextOriginalSize bTemp = FALSE fGetSizeXY sx1, sY, bTemp @@ -211,207 +237,144 @@ testcase tSVM warnlog "Selected original size NOT OK :-(" endif endif - if hCallExport (OutputGrafikTBO & "3" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - sX2 = Breite.GetText - if (LiberalMeasurement(sx1, sX2)) <> TRUE then - if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then - Printlog "Width was ok. Expected: " & sx1 & "' was: '" & sX2 & "'" - else - warnLog "Width is different expected: '" & sx1 & "' is: '" & sX2 & "'" - endif - endif - sY2 = Hoehe.GetText - if (LiberalMeasurement(sY, sY2)) <> TRUE then - if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then - Printlog "Height was ok. Expected: " & sY & "' was: '" & sY2 & "'" - else - warnLog "Height is different expected: '" & sY & "' is: '" & sY2 & "'" - endif - endif - SVMOptionen.Cancel - sleep 5 - endif - endif + printlog "Closing doc." call hCloseDocument endcase 'tSVM '------------------------------------------------------------------------------- testcase tPDF + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + + dim sPath as string dim sTemp as string dim iFileSize(12) as long dim i as integer - '/// Export the file 12 times: ///' - '///+ every compression level (3) and every range (3), check if button in toolbar uses last settings (6) (-> 12) ///' + printlog "Export the file 12 times: " + printlog "every compression level (3) and every range (3), check if button in toolbar uses last settings (6) (-> 12) " hFileOpen (ConvertPath ( gTesttoolPath + "graphics\required\input\graphicexport_pdf."+ExtensionString )) sleep (10) '--------------------------------------------------------------------------------------------------------------------------------------------------------- - '###### all / Screen optimized ###### - '/// File->Export as PDF document printlog "File->Export as PDF document" - '///+ range = All printlog " range = All" - '///+ compression = Screen optimized printlog " compression = Screen optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '--------------------------------------------------------- Output the first file --------------------------------------------------------------- + printlog "------------------- Output the first file ---------------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 1, TRUE, FALSE, 1, 1) - '/// Export using Button in toolbar printlog "Export using Button in toolbar" - '///+ use the settings from the export before printlog " use the settings from the export before" - kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------- Output the second file ------------------------------------------------------------- + printlog "--------------------- Output the second file -------------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 2, TRUE, FALSE, 1, 1) ' button in toolbar -> last settings have to be used - '###### range / Screen optimized ###### - '/// File->Export as PDF document + printlog "File->Export as PDF document" - '///+ range = Range printlog " range = Range" - '///+ compression = Screen optimized printlog " compression = Screen optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '--------------------------------------------------------- Output the third file --------------------------------------------------------------- + printlog "---------------- Output the third file --------------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 3, TRUE, FALSE, 2, 1, "2") - '/// Export using Button in toolbar printlog "Export using Button in toolbar" - '///+ use the settings from the export before printlog " use the settings from the export before" - kontext "Standardbar" checkexppdfwaitmax10sec - '--------------------------------------------------------- Output the fourth file ------------------------------------------------------------- + printlog "---------------------- Output the fourth file -----------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 4, TRUE, FALSE, 2, 1) ' button in toolbar -> last settings have to be used - '###### all / Print optimized ###### - '/// File->Export as PDF document printlog "File->Export as PDF document" - '///+ range = all printlog " range = all" - '///+ compression = Print optimized printlog " compression = Print optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------------ Output the fifth file -------------------------------------------------------------- + printlog "----------------------------- Output the fifth file ------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 5, TRUE, FALSE, 1, 2) - '/// Export using Button in toolbar printlog "Export using Button in toolbar" - '///+ use the settings from the export before printlog " use the settings from the export before" - kontext "Standardbar" checkexppdfwaitmax10sec - '----------------------------------------------------------- Output the sixth file --------------------------------------------------------------- + printlog "---------------------- Output the sixth file -------------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 6, TRUE, FALSE, 1, 2) ' button in toolbar -> last settings have to be used - '###### range / Print optimized ###### - '/// File->Export as PDF document printlog "File->Export as PDF document" - '///+ range = Range printlog " range = Range" - '///+ compression = Screen optimized printlog " compression = Screen optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '--------------------------------------------------------- Output the seventh file ------------------------------------------------------------- + printlog "------------------ Output the seventh file ---------------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 7, TRUE, FALSE, 2, 2, "2") - '/// Export using Button in toolbar printlog "Export using Button in toolbar" -' '///+ use the settings from the export before printlog " use the settings from the export before" - kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------------ Output the eight file ---------------------------------------------------------------- + printlog "---------------------- Output the eight file -------------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 8, TRUE, FALSE, 2, 2) ' button in toolbar -> last settings have to be used - '###### all / Press optimized ###### - '/// File->Export as PDF document ///' - printlog "File->Export as PDF document ///'" - '///+ range = all + printlog "File->Export as PDF document" printlog " range = all" - '///+ compression = Press optimized printlog " compression = Press optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------------ Output the ninth file ---------------------------------------------------------------- + printlog "------------------- Output the ninth file ----------------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 9, TRUE, FALSE, 1, 3) - '/// Export using Button in toolbar - '///+ use the settings from the export before - + printlog "Export using Button in toolbar" + printlog "use the settings from the export before" kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------------ Output the tenth file ---------------------------------------------------------------- + printlog "------------------------- Output the tenth file ----------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 10, TRUE, FALSE, 1, 3) ' button in toolbar -> last settings have to be used - '###### range / Press optimized ###### - '/// File->Export as PDF document ///' - printlog "File->Export as PDF document ///'" - '///+ range = all + printlog "File->Export as PDF document" printlog " range = all" - '///+ compression = Press optimized printlog " compression = Press optimized" - kontext "Standardbar" checkexppdfwaitmax10sec - '----------------------------------------------------------- Output the eleventh file ------------------------------------------------------------- + printlog "----------------- Output the eleventh file ---------------------" hExportAsPDFmulti (3, TRUE, OutputGrafikTBO + 11, TRUE, FALSE, 2, 3, "2") - '/// Export using Button in toolbar - '///+ use the settings from the export before - + printlog "Export using Button in toolbar" + printlog "use the settings from the export before" kontext "Standardbar" checkexppdfwaitmax10sec - '------------------------------------------------------------- Output the twelfth file -------------------------------------------------------------- + printlog "------------------ Output the twelfth file ---------------------" hExportAsPDFmulti (1, TRUE, OutputGrafikTBO + 12, TRUE, FALSE, 2, 3) ' button in toolbar -> last settings have to be used - kontext "Standardbar" checkexppdfwaitmax10sec - '----------------------------------------------------------------------------------------------------------------------------------------------------------------- + '--------------------------------------------------------------------------- for i=1 to 12 sPath = OutputGrafikTBO @@ -420,12 +383,12 @@ testcase tPDF Printlog (" - " + i + ": " + " " + iFileSize(i) + " " + sPath if (dir(sPath) <> "") then sleep(1) - '/// the first line has to be '%PDF-1.4' ///' + printlog " the first line has to be %PDF-1.4" sTemp = fGetFileText(sPath, 8) if (sTemp <> "%PDF-1.4") then Warnlog "File doesn't start with '%PDF-1.4' it is: '" + sTemp + "'" endif - '/// the last line has to be '%%EOF' ///' + printlog "the last line has to be '%%EOF' " sTemp = left(fGetFileText(sPath, -6),5) if (sTemp <> "%%EOF") then Warnlog "File doesn't end with '%%EOF' it is: '" + sTemp + "'" @@ -435,25 +398,21 @@ testcase tPDF endif next i - ' Check if the file size is the same when exporting via toolbar and file/export - ' if the size different then the options are not used when exporting via the toolbar + printlog "Check if the file size is the same when exporting via toolbar and file/export" + printlog "if the size is different then the options are not used when exporting via the toolbar" if (iFileSize(1) <> iFileSize(2)) then qaerrorlog "i100919: pdf export: different file size when exporting with file/export or button" 'Warnlog ("Diffrence in filesize for file 1 and 2") endif - ' print optimized if (iFileSize(5) <> iFileSize(6)) then qaerrorlog "i100919: pdf export: different file size when exporting with file/export or button" 'Warnlog ("Difference in filesize for file 5 and 6") endif - ' press optimized if (iFileSize(9) <> iFileSize(10)) then qaerrorlog "i100919: pdf export: different file size when exporting with file/export or button" 'Warnlog ("Difference in filesize for file 9 and 10") endif - - if (iFileSize(1) > iFileSize(5)) then qaerrorlog "i100919: pdf export: different file size when exporting with file/export or button" 'Warnlog ("Filesize for file 1 is greater then for file 5. The compression level doesn't work.") @@ -593,6 +552,9 @@ endcase 'tPDF_Creator '------------------------------------------------------------------------------- testcase tSVG + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim sFilter as string @@ -625,7 +587,10 @@ endcase 'tSVG '------------------------------------------------------------------------------- testcase tBMP -qaerrorlog + + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim bTemp as boolean @@ -636,50 +601,24 @@ qaerrorlog dim sY2 as string dim sDocument as string - '/// open the document + printlog "open the Test-document" sDocument = ConvertPath ( gTesttoolPath + "graphics\required\input\graphicexport."+ExtensionString) hFileOpen sDocument - if hCallExport (OutputGrafikTBO , "BMP - Windows Bitmap (.bmp)" ) = TRUE then - Kontext "BMPOptionen" - if BMPOptionen.Exists (2) then - '/// check if all properties have the right count, and depend on each other ///' - '/// 'Color Resolution' listbox contains eight items ///' - x = Farbaufloesung.GetItemCount - if x <> 8 then warnlog "Color Resolution Count is wrong; should be:8, is:" + x + printlog "Trying to export and canceling.." + if hCallExport (OutputGrafikTBO , "BMP - Windows Bitmap (.bmp)" ) = TRUE then + Kontext "BMPOptions" + if BMPOptions.Exists (2) then + x = Colordepth.GetItemCount + if x <> 7 then warnlog "Color Resolution Count is wrong; should be:7, is:" + x for i = 1 to x - Farbaufloesung.Select i + Colordepth.Select i sleep 1 - Printlog " - " + i + ": '" +Farbaufloesung.GetSelText + "'" - '/// checkbox RLE coding has to be enabled only for '4 and 8 bit' color palettes ///' - if ((i > 3) AND (i < 8)) then - if RLEKodierung.IsEnabled <> TRUE then warnlog "'RLE coding' is not checkable :-(" - else - if RLEKodierung.IsEnabled <> FALSE then warnlog "'RLE coding' is checkable :-(" - endif + Printlog " - " + i + ": '" +Colordepth.GetSelText + "'" next i - '/// if Mode 'original' is selected, DPI///' - Original.Check - if DPI.IsEnabled then warnlog " :-(" - if Breite.IsEnabled then warnlog " :-(" - if Hoehe.IsEnabled then warnlog " :-(" - Aufloesung.Check - x = DPI.GetItemCount - '/// 'DPI' listbox contains eight items ///' - if x <> 4 then warnlog "'DPI' Count is wrong; should be:4, is:" + x - for i = 1 to x - DPI.Select i - Printlog " - " + i + ": '" +DPI.GetSelText + "'" - next i - if Breite.IsEnabled then warnlog " :-(" - if Hoehe.IsEnabled then warnlog " :-(" - Groesse.Check - if DPI.IsEnabled then warnlog " :-(" - Breite.More - Hoehe.Less Sleep 1 - '/// leave dialog with cancel -> there has to be no file created! ///' - BMPOptionen.Cancel + printlog "Leave dialog with cancel -> there has to be no file created!" + BMPOptions.Cancel sleep 5 if ( dir(OutputGrafikTBO+".bmp") = "") then ' inspired by bug #99932 Graphic is exported though cancel is pressed Printlog "ok :-)" @@ -697,15 +636,14 @@ qaerrorlog Active.OK end if end if - Printlog "'/// now save it realy and load the file afterwards ///'" + + Printlog " now save it really and load the file afterwards" if hCallExport (OutputGrafikTBO , "BMP - Windows Bitmap (.bmp)" ) = TRUE then - Kontext "BMPOptionen" - if BMPOptionen.Exists (2) then - Farbaufloesung.Select 7 - RLEKodierung.Check - Aufloesung.Check - DPI.Select 3 - BMPOptionen.OK + Kontext "BMPOptions" + if BMPOptions.Exists (2) then + Colordepth.Select 7 + Compression.Check + BMPOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO+".bmp") <> "") then @@ -713,14 +651,18 @@ qaerrorlog else warnlog "File didn't get saved :-(" endif + printlog "Closing doc." hCloseDocument () sleep 5 + printlog "Opening new doc." hNewDocument() sleep 5 + printlog "Inserting exported file." Call hGrafikEinfuegen ( OutputGrafikTBO+".bmp" ) endif + printlog "Closing doc again." hCloseDocument () - Printlog "'/// now save a SELECTION in ORIGINAL SIZE and load the file afterwards ///'" + Printlog "Now save a SELECTION in and load the file afterwards" hFileOpen (sDocument) kontext "Filterauswahl" @@ -730,51 +672,58 @@ qaerrorlog goto endsub endif - ' check if the document is writable + printlog "check if the document is writable" call fMakeDocumentWritable hTypeKeys ("<escape><tab>") fGetSizeXY sx1, sy, TRUE - if hCallExport (OutputGrafikTBO + "1" , "BMP - Windows Bitmap (.bmp)", TRUE ) = TRUE then - Kontext "BMPOptionen" - if BMPOptionen.Exists (2) then - Original.Check - BMPOptionen.OK - sleep 5 - endif - if ( dir(OutputGrafikTBO + "1"+".bmp") <> "") then - Printlog "Ok :-) Saved as: '" + OutputGrafikTBO + "1"+".bmp" + "'" - else - warnlog "File didn't get saved :-(" - endif - hCloseDocument () - sleep 5 - hNewDocument() - sleep 5 - Call hGrafikEinfuegen ( OutputGrafikTBO + "1"+".bmp" ) - bTemp = FALSE - fGetSizeXY sx1, sY, bTemp - if (bTemp = FALSE) then - warnlog "Selected original size NOT OK :-(" + if hCallExport (OutputGrafikTBO + "1" , "BMP - Windows Bitmap (.bmp)", TRUE ) = TRUE then + Kontext "BMPOptions" + if BMPOptions.Exists (2) then + BMPOptions.OK + sleep 5 + endif + if ( dir(OutputGrafikTBO + "1"+".bmp") <> "") then + Printlog "Ok :-) Saved as: '" + OutputGrafikTBO + "1"+".bmp" + "'" + else + warnlog "File didn't get saved :-(" + endif + hCloseDocument () + sleep 5 + hNewDocument() + sleep 5 + Call hGrafikEinfuegen ( OutputGrafikTBO + "1"+".bmp" ) + bTemp = FALSE + fGetSizeXY sx1, sY, bTemp + if (bTemp = FALSE) then + warnlog "Selected original size NOT OK :-(" endif endif hCloseDocument () - Printlog "'/// now CREATE a rectangle, select it, save it in SIZE and load the file afterwards ///'" + Printlog "Now create a rectangle, select it, save it in SIZE and load the file afterwards" hNewDocument() hTypeKeys "<TAB>" gMouseClick 50, 50 hRechteckErstellen ( 10, 10, 30, 40 ) if hCallExport (OutputGrafikTBO + "2" , "BMP - Windows Bitmap (.bmp)", TRUE ) = TRUE then - Kontext "BMPOptionen" - if BMPOptionen.Exists (2) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check 'Press "Size" one more time in order to make the change go through" - sx1 = Breite.GetText - sY = Hoehe.GetText - BMPOptionen.OK + Kontext "BMPOptions" + if BMPOptions.Exists (2) then + Exportwidth.SetText "9" + if Exportmeasurement.GetSelText = "inches" then + sx1 = (Exportwidth.GetText)+ """" + printlog "sx1= " & sx1 + else + sx1 = (Exportwidth.GetText)+ "cm" + endif + + if Exportmeasurement.GetSelText = "inches" then + sY = (Exportheight.GetText)+ """" + printlog "sY= " & sY + else + sY = (Exportwidth.GetText)+ "cm" + endif + BMPOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO + "2"+".bmp") <> "") then @@ -782,6 +731,7 @@ qaerrorlog else warnlog "File didn't get saved :-(" endif + printlog "Closing doc." hCloseDocument () sleep 5 hFileOpen (OutputGrafikTBO + "2"+".bmp") @@ -802,37 +752,15 @@ qaerrorlog endif endif - if hCallExport (OutputGrafikTBO + "3" , "BMP - Windows Bitmap (.bmp)", TRUE ) = TRUE then - Kontext "BMPOptionen" - if BMPOptionen.Exists (2) then - Groesse.Check - sX2 = Breite.GetText - if (LiberalMeasurement(sx1, sX2)) <> TRUE then - if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then - Printlog "Width was ok. Expected: " + sx1 + "' was: '" + sX2 + "'" - else - warnLog "Width is different expected: '" + sx1 + "' is: '" + sX2 + "'" - endif - endif - sY2 = Hoehe.GetText - if (LiberalMeasurement(sY, sY2)) <> TRUE then - if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then - Printlog "Height was ok. Expected: " + sY + "' was: '" + sY2 + "'" - else - warnLog "Height is different expected: '" + sY + "' is: '" + sY2 + "'" - endif - endif - BMPOptionen.Cancel - sleep 5 - endif - endif - call hCloseDocument endcase 'tBMP '------------------------------------------------------------------------------- testcase tEMF + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim sFilter as string @@ -852,19 +780,11 @@ testcase tEMF hFileOpen sDocument if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - if Breite.IsEnabled then - warnlog " :-(" - endif - if Hoehe.IsEnabled then - warnlog " :-(" - endif - Groesse.Check - Breite.More - Hoehe.Less - SVMOptionen.Cancel + Kontext "EMFOptions" + if EMFOptions.Exists (2) then + Exportwidth.More + Exportheight.Less + EMFOptions.Cancel sleep 5 if ( dir(OutputGrafikTBO+sExt) = "") then ' inspired by bug #99932 Graphic is exported though cancel is pressed Printlog "ok :-)" @@ -883,12 +803,11 @@ testcase tEMF end if end if if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.Less - Hoehe.More - SVMOptionen.OK + Kontext "EMFOptions" + if EMFOptions.Exists (2) then + Exportwidth.More + Exportheight.Less + EMFOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO+sExt) <> "") then @@ -903,53 +822,26 @@ testcase tEMF Call hGrafikEinfuegen ( OutputGrafikTBO+sExt ) endif hCloseDocument () - hFileOpen (sDocument) - kontext "Filterauswahl" - if Filterauswahl.Exists(10) then - Warnlog "Error when loading the file. The Filter-dialogue came up. Test aborted." - Filterauswahl.Cancel - goto endsub - endif - 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 - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - SVMOptionen.OK - sleep 5 - endif - if ( dir(OutputGrafikTBO & "1" & sExt) <> "") then - Printlog "Ok :-) saved as: '" & OutputGrafikTBO & "1" & sExt & "'" - else - warnlog "File didn't get saved :-(" - endif - hCloseDocument () - sleep 5 - hNewDocument() - sleep 5 - Call hGrafikEinfuegen ( OutputGrafikTBO & "1" & sExt ) - bTemp = FALSE - fGetSizeXY sx1, sY, bTemp - if (bTemp = FALSE) then - warnlog "Selected original size NOT OK :-(" - endif - endif - hCloseDocument () + hNewDocument() hRechteckErstellen ( 10, 10, 30, 40 ) if hCallExport (OutputGrafikTBO & "2" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check 'Press "Size" one more time to make the change go through" - sx1 = Breite.GetText - sY = Hoehe.GetText - SVMOptionen.OK + Kontext "EMFOptions" + if EMFOptions.Exists (2) then + Exportwidth.SetText "9" + if Exportmeasurement.GetSelText = "inches" then + sx1 = (Exportwidth.GetText)+ """" + printlog "sx1= " & sx1 + else + sx1 = (Exportwidth.GetText)+ "cm" + endif + if Exportmeasurement.GetSelText = "inches" then + sY = (Exportheight.GetText)+ """" + printlog "sY= " & sY + else + sY = (Exportwidth.GetText)+ "cm" + endif + EMFOptions.OK sleep 5 endif if ( dir(OutputGrafikTBO & "2" & sExt) <> "") then @@ -970,10 +862,9 @@ testcase tEMF endif if hCallExport (OutputGrafikTBO & "3" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - sX2 = Breite.GetText + Kontext "EMFOptions" + if EMFOptions.Exists (2) then + sX2 = Exportwidth.GetText if (LiberalMeasurement(sx1, sX2)) <> TRUE then if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then Printlog "Width was ok. Expected: " & sx1 & "' was: '" & sX2 & "'" @@ -981,7 +872,7 @@ testcase tEMF warnLog "Width is different expected: '" & sx1 & "' is: '" & sX2 & "'" endif endif - sY2 = Hoehe.GetText + sY2 = Exportheight.GetText if (LiberalMeasurement(sY, sY2)) <> TRUE then if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then Printlog "Height was ok. Expected: " & sY & "' was: '" & sY2 & "'" @@ -989,7 +880,7 @@ testcase tEMF warnLog "Height is different expected: '" & sY & "' is: '" & sY2 & "'" endif endif - SVMOptionen.Cancel + EMFOptions.Cancel sleep 5 endif endif @@ -1001,6 +892,9 @@ endcase 'tEMF '------------------------------------------------------------------------------- testcase tMET + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim iWaitIndex as integer @@ -1018,32 +912,26 @@ testcase tMET sExt = ".met" sDocument = gTesttoolPath & "graphics\required\input\graphicexport." & ExtensionString + printlog "loading Test File" hFileOpen sDocument + printlog "----------1st: Trying to export and then canceling it" if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "METOptionen" - if METOptionen.Exists (2) then - Original.Check - if Breite.IsEnabled then - warnlog " :-(" - endif - if Hoehe.IsEnabled then - warnlog " :-(" - endif - Groesse.Check - sTemp = Breite.getText - Breite.More - if (sTemp = Breite.getText) then + Kontext "METOptions" + if METOptions.Exists (2) then + sTemp = Exportwidth.getText + Exportwidth.More + if (sTemp = Exportwidth.getText) then qaErrorLog "Width didn't change on pressing button 'More' #112225#" - Breite.setText "10" - Hoehe.setText "10" + Exportwidth.setText "10" endif - sTemp = Hoehe.getText - Hoehe.Less - if (sTemp = Hoehe.getText) then + sTemp = Exportheight.getText + Exportheight.Less + if (sTemp = Exportheight.getText) then warnlog "Height didn't change on pressing button 'Less'" endif - METOptionen.Cancel + printlog "Canceling export..." + METOptions.Cancel sleep 5 if ( dir(OutputGrafikTBO+sExt) = "") then ' inspired by bug #99932 Graphic is exported though cancel is pressed Printlog "ok :-)" @@ -1061,25 +949,24 @@ testcase tMET Active.OK end if end if + printlog "----------2nd: doing real export.." if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "METOptionen" - if METOptionen.Exists (2) then - Groesse.Check - sTemp = Breite.getText - Breite.Less - if (sTemp = Breite.getText) then + Kontext "METOptions" + if METOptions.Exists (2) then + sTemp = Exportwidth.getText + Exportwidth.Less + if (sTemp = Exportwidth.getText) then warnlog "Width didn't change on pressing button 'Less'" endif - sTemp = Hoehe.getText - Hoehe.More - if (sTemp = Hoehe.getText) then + sTemp = Exportheight.getText + Exportheight.More + if (sTemp = Exportheight.getText) then qaErrorLog "Height didn't change on pressing button 'More' #112225#" - Breite.setText "10" - Hoehe.setText "10" + Exportwidth.setText "10" endif - METOptionen.OK + METOptions.OK iWaitIndex = 0 - do while METOptionen.Exists AND iWaitIndex < 30 + do while METOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1089,28 +976,33 @@ testcase tMET else warnlog "File didn't get saved :-(" endif + printlog "Closing test doc." hCloseDocument () sleep 5 + printlog "----------3rd: Inserting export into new doc." + printlog "Opening new doc." hNewDocument() sleep 5 + printlog "Inserting the exported file..." Call hGrafikEinfuegen ( OutputGrafikTBO+sExt ) endif + printlog "Closing file with inserted graphic." hCloseDocument () + printlog "----------4th: Exporting part of test doc." + printlog "Opening test file.." hFileOpen (sDocument) sleep (10) - printlog "making doc editable if it is readonly" call fMakeDocumentWritable - + printlog "Selecting part of doc for export.." hTypeKeys ("<escape><tab>") fGetSizeXY sx1, sY, TRUE if hCallExport (OutputGrafikTBO & "1" , sFilter, TRUE ) = TRUE then - Kontext "METOptionen" - if METOptionen.Exists (2) then - Original.Check - METOptionen.OK + Kontext "METOptions" + if METOptions.Exists (2) then + METOptions.OK iWaitIndex = 0 - do while METOptionen.Exists AND iWaitIndex < 30 + do while METOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1120,32 +1012,51 @@ testcase tMET else warnlog "File didn't get saved :-(" endif + printlog "Closing testfile" hCloseDocument () sleep 5 + printlog "----------5th: Inserting exported part into new doc." + printlog "Opening new file.." hNewDocument() sleep 5 + printlog "inserting exported part." Call hGrafikEinfuegen ( OutputGrafikTBO & "1" & sExt ) bTemp = FALSE + printlog "Checking size." fGetSizeXY sx1, sY, bTemp if (bTemp = FALSE) then warnlog "Selected original size NOT OK :-(" endif endif + printlog "Closing doc." hCloseDocument () + printlog "----------6th: exporting fresh rectangle." + printlog "opening new file." hNewDocument() + printlog "inserting rectangle." hRechteckErstellen ( 10, 10, 30, 40 ) + printlog "Exporting rectangle.." if hCallExport (OutputGrafikTBO & "2" , sFilter, TRUE ) = TRUE then - Kontext "METOptionen" - if METOptionen.Exists (2) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check ' Click "Size" one more time to make the changes go through. - sx1 = Breite.GetText - sY = Hoehe.GetText - METOptionen.OK + Kontext "METOptions" + if METOptions.Exists (2) then + Exportwidth.SetText "9" + if Exportmeasurement.GetSelText = "inches" then + sx1 = (Exportwidth.GetText)+ """" + printlog "sx1= " & sx1 + else + sx1 = (Exportwidth.GetText)+ "cm" + endif + + if Exportmeasurement.GetSelText = "inches" then + sY = (Exportheight.GetText)+ """" + printlog "sY= " & sY + else + sY = (Exportwidth.GetText)+ "cm" + endif + + METOptions.OK iWaitIndex = 0 - do while METOptionen.Exists AND iWaitIndex < 30 + do while METOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1155,11 +1066,14 @@ testcase tMET else warnlog "File didn't get saved :-(" endif + printlog "closing doc." hCloseDocument () sleep 5 + printlog "----------7th:Opening exported file with rectangle" hFileOpen (OutputGrafikTBO & "2" & sExt) kontext "DocumentDraw" DocumentDraw.TypeKeys ("<escape><tab>") + printlog "Checking file size." ContextOriginalSize bTemp = FALSE fGetSizeXY sx1, sY, bTemp @@ -1167,30 +1081,6 @@ testcase tMET warnlog "Selected original size NOT OK :-(" endif endif - if hCallExport (OutputGrafikTBO & "3" , sFilter, TRUE ) = TRUE then - Kontext "METOptionen" - if METOptionen.Exists (2) then - Groesse.Check - sX2 = Breite.GetText - if (LiberalMeasurement(sx1, sX2)) <> TRUE then - if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then - Printlog "Width was ok. Expected: " & sx1 & "' was: '" & sX2 & "'" - else - warnLog "Width is different expected: '" & sx1 & "' is: '" & sX2 & "'" - endif - endif - sY2 = Hoehe.GetText - if (LiberalMeasurement(sY, sY2)) <> TRUE then - if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then - Printlog "Height was ok. Expected: " & sY & "' was: '" & sY2 & "'" - else - warnLog "Height is different expected: '" & sY & "' is: '" & sY2 & "'" - endif - endif - METOptionen.Cancel - sleep 5 - endif - endif call hCloseDocument endcase 'tMET @@ -1198,6 +1088,9 @@ endcase 'tMET '------------------------------------------------------------------------------- testcase tSWF + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim sFilter as string dim sExt as string dim x as integer @@ -1223,6 +1116,9 @@ endcase 'tSWF '------------------------------------------------------------------------------ testcase tWMF + warnlog( "#i115138 - Loading test document freezes the office" ) + goto endsub + dim x as integer dim i as integer dim iWaitIndex as integer @@ -1238,27 +1134,20 @@ testcase tWMF sFilter = "WMF - Windows Metafile (.wmf)" sExt = ".wmf" - sDocument = gTesttoolPath & "graphics\required\input\graphicexport." & ExtensionString + printlog "Loading testdoc." hFileOpen sDocument + printlog "Starting export as WMF and canceling.." if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - if Breite.IsEnabled then - warnlog " :-(" - endif - if Hoehe.IsEnabled then - warnlog " :-(" - endif - Groesse.Check - Breite.More - Hoehe.Less - SVMOptionen.Cancel + Kontext "WMFOptions" + if WMFOptions.Exists (2) then + Exportwidth.Less + Exportheight.More + WMFOptions.Cancel sleep 5 if ( dir(OutputGrafikTBO+sExt) = "") then ' inspired by bug #99932 Graphic is exported though cancel is pressed - Printlog "ok :-)" + Printlog "ok :-), nothing exported due to canceling." else warnlog "Dialog was canceled, but file got saved, too :-( - i35177" endif @@ -1273,15 +1162,15 @@ testcase tWMF Active.OK end if end if + printlog "Doing real export." if hCallExport (OutputGrafikTBO , sFilter ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.Less - Hoehe.More - SVMOptionen.OK + Kontext "WMFOptions" + if WMFOptions.Exists (2) then + Exportwidth.Less + Exportheight.More + WMFOptions.OK iWaitIndex = 0 - do while SVMOptionen.Exists AND iWaitIndex < 30 + do while WMFOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1291,13 +1180,18 @@ testcase tWMF else warnlog "File didn't get saved :-(" endif + Printlog "Closing test doc." hCloseDocument () sleep 5 + printlog "Opening new odc." hNewDocument() sleep 5 + printlog "Inserting exported graphic." Call hGrafikEinfuegen ( OutputGrafikTBO+sExt ) endif + printlog "Closing." hCloseDocument () + Printlog "Opening exported file." hFileOpen (sDocument) sleep (10) @@ -1307,12 +1201,11 @@ testcase tWMF hTypeKeys ("<escape><tab>") fGetSizeXY sx1, sY, TRUE if hCallExport (OutputGrafikTBO & "1" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Original.Check - SVMOptionen.OK + Kontext "WMFOptions" + if WMFOptions.Exists (2) then + WMFOptions.OK iWaitIndex = 0 - do while SVMOptionen.Exists AND iWaitIndex < 30 + do while WMFOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1337,17 +1230,25 @@ testcase tWMF hNewDocument() hRechteckErstellen ( 10, 10, 30, 40 ) if hCallExport (OutputGrafikTBO & "2" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - Breite.SetText "9" - Hoehe.SetText "9" - Groesse.Check 'Check "Size" to make changes really go through. - sx1 = Breite.GetText - sY = Hoehe.GetText - SVMOptionen.OK + Kontext "WMFOptions" + if WMFOptions.Exists (2) then + Exportwidth.SetText "9" + if Exportmeasurement.GetSelText = "inches" then + sx1 = (Exportwidth.GetText)+ """" + printlog "sx1= " & sx1 + else + sx1 = (Exportwidth.GetText)+ "cm" + endif + + if Exportmeasurement.GetSelText = "inches" then + sY = (Exportheight.GetText)+ """" + printlog "sY= " & sY + else + sY = (Exportwidth.GetText)+ "cm" + endif + WMFOptions.OK iWaitIndex = 0 - do while SVMOptionen.Exists AND iWaitIndex < 30 + do while WMFOptions.Exists AND iWaitIndex < 30 sleep (1) iWaitIndex = iWaitIndex + 1 loop @@ -1369,30 +1270,6 @@ testcase tWMF warnlog "Selected original size NOT OK :-(" endif endif - if hCallExport (OutputGrafikTBO & "3" , sFilter, TRUE ) = TRUE then - Kontext "SVMOptionen" - if SVMOptionen.Exists (2) then - Groesse.Check - sX2 = Breite.GetText - if (LiberalMeasurement(sx1, sX2)) <> TRUE then - if (val(str(StrToDouble(sx1)+5)) >= StrToDouble(sX2) ) AND (val(str(StrToDouble ( sx1 )-5)) <= StrToDouble ( sX2 )) then - Printlog "Width was ok. Expected: " & sx1 & "' was: '" & sX2 & "'" - else - warnLog "Width is different expected: '" & sx1 & "' is: '" & sX2 & "'" - endif - endif - sY2 = Hoehe.GetText - if (LiberalMeasurement(sY, sY2)) <> TRUE then - if ( val(str(StrToDouble(sY)+5)) >= StrToDouble(sY2) ) AND (val(str(StrToDouble ( sY )-5)) <= StrToDouble ( sY2 )) then - Printlog "Height was ok. Expected: " & sY & "' was: '" & sY2 & "'" - else - warnLog "Height is different expected: '" & sY & "' is: '" & sY2 & "'" - endif - endif - SVMOptionen.Cancel - sleep 5 - endif - endif call hCloseDocument endcase 'tWMF @@ -1400,31 +1277,31 @@ endcase 'tWMF '------------------------------------------------------------------------- function fGetFileText (sFilename as string, iCount as long) as string -'/// This function is for getting the first or last n characters of a file -'///+<u>Input</u>:<ul><li>filename</li><li>number</li></ul>If the number greater 0 then get n characters from start. -'///+A number smaller 0 get from end of file. -'///+<u>Output</u>:<ul><li>string with <b><i>n</i></b> characters</li></ul> - - dim iFile as integer ' filehandle - dim iTem as integer ' get 2 bytes of the file - dim iTemByte(2) as integer ' move 1 byte from iTem in each item - dim sTemp as string ' string of file - dim iSize as long ' size in bytes of file - dim i as long ' runner :-) - - iFile = FreeFile -' Printlog "FreeFile: " + iFile - if (dir (sFilename) <> "") then -' Printlog "FileLen: " + FileLen(sFile) - Open sFilename For binary access read shared As #iFile -' Printlog "Loc: " + Loc(#iFile) ' LONG! where am i in the file? - - iSize = Lof(#iFile) ' get size in bytes of file - if (iSize > 65530) then '65536 = 64kB - 'Warnlog "fGetFileText: file '" + sFilename + "' might get problems on reading it? size is > 65530 Byte: '" + iSize + "'" - else -' printlog "iSize: " + iSize - endif + printlog "This function is for getting the first or last n characters of a file" + printlog "Input:filename number If the number greater 0 then get n characters from start." + printlog "number smaller 0 get from end of file." + printlog "Output:string with characters" + + dim iFile as integer ' filehandle + dim iTem as integer ' get 2 bytes of the file + dim iTemByte(2) as integer ' move 1 byte from iTem in each item + dim sTemp as string ' string of file + dim iSize as long ' size in bytes of file + dim i as long ' runner :-) + + iFile = FreeFile + Printlog "FreeFile: " + iFile + if (dir (sFilename) <> "") then + Printlog "FileLen: " + FileLen(sFile) + Open sFilename For binary access read shared As #iFile + Printlog "Loc: " + Loc(#iFile) ' LONG! where am i in the file? + + iSize = Lof(#iFile) ' get size in bytes of file + if (iSize > 65530) then '65536 = 64kB + 'Warnlog "fGetFileText: file '" + sFilename + "' might get problems on reading it? size is > 65530 Byte: '" + iSize + "'" + else + printlog "iSize: " + iSize + endif sTemp = "" if (iCount >= 0) then ' get bytes from file start @@ -1449,7 +1326,7 @@ function fGetFileText (sFilename as string, iCount as long) as string sTemp = chr(iTemByte(1)) + chr(iTemByte(2)) + sTemp ' put them together endif endif -' printlog "'"+left(sTemp,iSize)+"'" ' gotcha! + printlog "'"+left(sTemp,iSize)+"'" ' gotcha! if (iSize-(Abs(iCount)) >= 0) then fGetFileText = left(sTemp,Abs(iCount)) diff --git a/testautomation/graphics/optional/includes/global/g_area.inc b/testautomation/graphics/optional/includes/global/g_area.inc index 758044290d45..eb53faaa9bb3 100644 --- a/testautomation/graphics/optional/includes/global/g_area.inc +++ b/testautomation/graphics/optional/includes/global/g_area.inc @@ -39,341 +39,378 @@ testcase tiFormatArea Dim Zaehler dim Entf$ - hNewDocument '/// New impress document ///' - hRechteckErstellen (20,20,60,60) '/// create rectangle ///' - Printlog " - Change Format" '/// change format for the rectangle ///' - FormatArea - Kontext - active.SetPage TabArea - Kontext "TabArea" - FillOptions.Select 5 '/// apply bitmap as texture ///' - BitmapList.Select 3 '/// Select "Water" ///' - Tile.Check '/// tile bitmap ///' - Kontext - active.SetPage TabSchatten - kontext "TabSchatten" - Anzeigen.Check '/// apply shadow ///' - Entfernung.SetText "30" '/// set angle to 30���///' - Entf$=Entfernung.GetText '/// change distance ///' - Farbe.Select 15 '/// select color 15///' - TabSchatten.OK '/// close dialog ///' - Sleep 3 + printlog "New impress document " + hNewDocument + printlog "create rectangle " + hRechteckErstellen (20,20,60,60) + Printlog " - Change Format" + printlog "change format for the rectangle " + FormatArea + Kontext + active.SetPage TabArea + Kontext "TabArea" + printlog "apply bitmap as texture " + FillOptions.Select 5 + printlog "Select Water " + BitmapList.Select 3 + printlog "tile bitmap " + Tile.Check + Kontext + active.SetPage TabSchatten + kontext "TabSchatten" + printlog "apply shadow " + Anzeigen.Check + printlog "set angle to 30���" + Entfernung.SetText "30" + printlog "change distance " + Entf$=Entfernung.GetText + printlog "select color 15" + Farbe.Select 15 + printlog "close dialog " + TabSchatten.OK + Sleep 3 - Printlog " - Test various formats" - FormatArea '/// Format area, check if changes are saved for this object ///' - Kontext - active.SetPage TabArea - Kontext "TabArea" - if NOT FillOptions.GetSelIndex = 5 then - Warnlog "Bitmap is not checked" - else - if BitmapList.GetSelIndex <> 3 then Warnlog "Wrong bitmap used. "+ BitmapAuswahl.GetSelIndex - if NOT Tile.IsChecked then Warnlog "Tile is not checked" -' if Original.IsChecked then Warnlog "Original is not checked" -' if NOT Relativ.IsChecked then Warnlog "Relative is not checked" -' if Breite.GetText <> "90 %" then Warnlog "Width is not 90%, it is: "+Breite.GetText -' if XOffset.GetText <> "30 %" then Warnlog "XOffset is not 30%, it is: "+XOffset.GetText -' if NOT Zeile.IsChecked then Warnlog "Line is not checked" -' if Verschiebung.GetText <> "20 %" then Warnlog "Displace is not 20%, it is: " + Verschiebung.GetText - Kontext - active.SetPage TabSchatten - kontext "TabSchatten" - if NOT Anzeigen.IsChecked then - Warnlog "Show shadows is not checked" - else - if Entfernung.GetText <> Entf$ then Warnlog "Distance is not " + Entf$ + " it is: "+ Entfernung.GetText - if Farbe.GetSelIndex <> 15 then Warnlog "Wrong color for shadow. It is: "+ Farbe.GetSelIndex - end if - end if + Printlog " - Test various formats" + printlog "Format area, check if changes are saved for this object " + FormatArea + Kontext + active.SetPage TabArea + Kontext "TabArea" + if NOT FillOptions.GetSelIndex = 5 then + Warnlog "Bitmap is not checked" + else + if BitmapList.GetSelIndex <> 3 then Warnlog "Wrong bitmap used. "+ BitmapAuswahl.GetSelIndex + if NOT Tile.IsChecked then Warnlog "Tile is not checked" + ' if Original.IsChecked then Warnlog "Original is not checked" + ' if NOT Relativ.IsChecked then Warnlog "Relative is not checked" + ' if Breite.GetText <> "90 %" then Warnlog "Width is not 90%, it is: "+Breite.GetText + ' if XOffset.GetText <> "30 %" then Warnlog "XOffset is not 30%, it is: "+XOffset.GetText + ' if NOT Zeile.IsChecked then Warnlog "Line is not checked" + ' if Verschiebung.GetText <> "20 %" then Warnlog "Displace is not 20%, it is: " + Verschiebung.GetText + Kontext + active.SetPage TabSchatten + kontext "TabSchatten" + if NOT Anzeigen.IsChecked then + Warnlog "Show shadows is not checked" + else + if Entfernung.GetText <> Entf$ then Warnlog "Distance is not " + Entf$ + " it is: "+ Entfernung.GetText + if Farbe.GetSelIndex <> 15 then Warnlog "Wrong color for shadow. It is: "+ Farbe.GetSelIndex + end if + end if TabSchatten.Cancel - - hCloseDocument '/// close document ///' + printlog "close document " + hCloseDocument endcase 'tiFormatArea '-------------------------------------------------------- testcase tdFormatArea1 -Dim i -Dim j -Dim k -Dim m -Dim n -Dim Winkel_1 as string -Dim ZaehlerFarbe -Dim ZaehlerVerlauf -Dim ZaehlerSchraffur -Dim ZaehlerBitmap -Dim ColorName$ + Dim i + Dim j + Dim k + Dim m + Dim n + Dim Winkel_1 as string + Dim ZaehlerFarbe + Dim ZaehlerVerlauf + Dim ZaehlerSchraffur + Dim ZaehlerBitmap + Dim ColorName$ ColorName$ = "Bullshit" - dim Zaehler as integer + dim Zaehler as integer - Call hNewDocument '/// new document ///' - sleep 3 - Call hRechteckErstellen (30,30,70,70) '/// create rectangle ///' - sleep 2 - FormatArea '/// format area ///' - Kontext - Active.SetPage TabArea - Kontext "TabArea" - FillOptions.Select 1 '/// Select no fill ///' - sleep 2 - TabArea.OK - sleep 1 - FormatArea - Kontext - Active.SetPage TabArea - Kontext "TabArea" - sleep 1 '/// control if changes are still there after closing and reopening dialog ///' - FillOptions.Select 3'/// check gradient and select 1 ///' - ZaehlerVerlauf = GradientList.GetItemCount - for j = 1 To 2 - GradientList.Select j - TabArea.OK - FormatArea - Kontext - Active.SetPage TabArea - Kontext "TabArea" - PrintLog GradientList.GetSelText - next j - FillOptions.Select 4 '/// select hatching, control after closing and reopening dialog if changes are recognized ///' - HatchingList.GetItemCount - ZaehlerSchraffur = HatchingList.GetItemCount - for k=1 to 2'ZaehlerSchraffur - HatchingList.Select k - TabArea.OK - FormatArea - Kontext - Active.SetPage TabArea - Kontext "TabArea" - PrintLog HatchingList.GetSelText + printlog "new document " + Call hNewDocument + sleep 3 + printlog "create rectangle " + Call hRechteckErstellen (30,30,70,70) + sleep 2 + printlog "format area " + FormatArea + Kontext + Active.SetPage TabArea + Kontext "TabArea" + printlog "Select no fill " + FillOptions.Select 1 + sleep 2 + TabArea.OK + sleep 1 + FormatArea + Kontext + Active.SetPage TabArea + Kontext "TabArea" + sleep 1 + printlog "control if changes are still there after closing and reopening dialog " + printlog "check gradient and select 1 " + FillOptions.Select 3' + ZaehlerVerlauf = GradientList.GetItemCount + for j = 1 To 2 + GradientList.Select j + TabArea.OK + FormatArea + Kontext + Active.SetPage TabArea + Kontext "TabArea" + PrintLog GradientList.GetSelText + next j + printlog "select hatching, control after closing and reopening dialog if changes are recognized " + FillOptions.Select 4 + HatchingList.GetItemCount + ZaehlerSchraffur = HatchingList.GetItemCount + for k=1 to 2'ZaehlerSchraffur + HatchingList.Select k + TabArea.OK + FormatArea + Kontext + Active.SetPage TabArea + Kontext "TabArea" + PrintLog HatchingList.GetSelText next k - FillOptions.Select 5 '/// check bitmap, control if changes are permanent after closing and reopening dialog ///' - BitmapList.GetItemCount - ZaehlerBitmap = BitmapList.GetItemCount - for n=1 to ZaehlerBitmap - BitmapList.Select n - TabArea.OK - FormatArea - sleep 1 - Kontext - Active.SetPage TabArea - Kontext "TabArea" - PrintLog BitmapList.GetSelText - next n + printlog "check bitmap, control if changes are permanent after closing and reopening dialog " + FillOptions.Select 5 + BitmapList.GetItemCount + ZaehlerBitmap = BitmapList.GetItemCount + for n=1 to ZaehlerBitmap + BitmapList.Select n + TabArea.OK + FormatArea + sleep 1 + Kontext + Active.SetPage TabArea + Kontext "TabArea" + PrintLog BitmapList.GetSelText + next n - if Tile.IsChecked = False Then Tile.Check '/// check tile ///' -' if Anpassen.IsEnabled = False Then PrintLog " Option Tile activated" -' if Anpassen.IsEnabled = True Then WarnLog " Option Tile not activated" -' if Relativ.IsChecked = False Then -' SetClipboard Breite.GetText -' Relativ.Check -' If Breite.GetText = GetClipboardText Then -' WarnLog " Relative isnt working" -' else -' PrintLog " Relative works" -' end if -' end if -' -' if Kacheln.IsChecked = True Then Kacheln.UnCheck -' Anpassen.Check -' if Relativ.IsEnabled = True Then WarnLog " Option Anpassen konnte nicht aktiviert werden" -' if not Relativ.IsEnabled Then PrintLog " Option Anpassen funktioniert" -' Anpassen.Uncheck -' Original.Check -' if Breite.IsEnabled And Hoehe.IsEnabled = True Then WarnLog " Button Original funktioniert nicht" -' if Breite.IsEnabled And Hoehe.IsEnabled = False Then PrintLog " Button Original funktioniert" -' Kacheln.Check -' setClipboard XOffset.GetText -' XOffset.More 3 -' if XOffset.GetText <> GetClipboardText Then PrintLog " Position XOffset funktioniert" -' if XOffset.GetText = GetClipboardText Then WarnLog " Position XOffset funktioniert nicht" -' SetClipboard YOffset.GetText -' YOffset.More 5 -' if YOffset.GetText <> GetClipboardText Then PrintLog " Position YOffset funktioniert" -' if YOffset.GetText = GetClipboardText Then WarnLog " Position YOffset funktioniert nicht" -' PrintLog " TabArea fertig" - Kontext - Active.SetPage TabSchatten - Kontext "TabSchatten" - sleep 1 - if Anzeigen.IsChecked = True Then Anzeigen.UnCheck '/// uncheck shadow ///' - sleep 1 - if Entfernung.IsEnabled = False Then '/// check if shadow related controls are disabled with no shadow ///' - PrintLog " Show shadow works" - else - WarnLog " Show shadow does not work" - end if + printlog "check tile " + if Tile.IsChecked = False Then Tile.Check + ' if Anpassen.IsEnabled = False Then PrintLog " Option Tile activated" + ' if Anpassen.IsEnabled = True Then WarnLog " Option Tile not activated" + ' if Relativ.IsChecked = False Then + ' SetClipboard Breite.GetText + ' Relativ.Check + ' If Breite.GetText = GetClipboardText Then + ' WarnLog " Relative isnt working" + ' else + ' PrintLog " Relative works" + ' end if + ' end if + ' + ' if Kacheln.IsChecked = True Then Kacheln.UnCheck + ' Anpassen.Check + ' if Relativ.IsEnabled = True Then WarnLog " Option Anpassen konnte nicht aktiviert werden" + ' if not Relativ.IsEnabled Then PrintLog " Option Anpassen funktioniert" + ' Anpassen.Uncheck + ' Original.Check + ' if Breite.IsEnabled And Hoehe.IsEnabled = True Then WarnLog " Button Original funktioniert nicht" + ' if Breite.IsEnabled And Hoehe.IsEnabled = False Then PrintLog " Button Original funktioniert" + ' Kacheln.Check + ' setClipboard XOffset.GetText + ' XOffset.More 3 + ' if XOffset.GetText <> GetClipboardText Then PrintLog " Position XOffset funktioniert" + ' if XOffset.GetText = GetClipboardText Then WarnLog " Position XOffset funktioniert nicht" + ' SetClipboard YOffset.GetText + ' YOffset.More 5 + ' if YOffset.GetText <> GetClipboardText Then PrintLog " Position YOffset funktioniert" + ' if YOffset.GetText = GetClipboardText Then WarnLog " Position YOffset funktioniert nicht" + ' PrintLog " TabArea fertig" + Kontext + Active.SetPage TabSchatten + Kontext "TabSchatten" + sleep 1 + printlog "uncheck shadow " + if Anzeigen.IsChecked = True Then Anzeigen.UnCheck + sleep 1 + printlog "check if shadow related controls are disabled with no shadow " + if Entfernung.IsEnabled = False Then + PrintLog " Show shadow works" + else + WarnLog " Show shadow does not work" + end if - Anzeigen.Check '/// check shadow ///' - SetClipboard Entfernung.GetText '/// change distance ///' - Entfernung.More 4 - if GetClipboardText = Entfernung.GetText Then - WarnLog " Distance does not work" - else - PrintLog " Distance does work" - end if - Farbe.Select 5 '/// change shadow color ///' + printlog "check shadow " + Anzeigen.Check + printlog "change distance " + SetClipboard Entfernung.GetText + Entfernung.More 4 + if GetClipboardText = Entfernung.GetText Then + WarnLog " Distance does not work" + else + PrintLog " Distance does work" + end if + printlog "change shadow color " + Farbe.Select 5 - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - Farbe.Select 24 - sleep 1 - Farbe.Select 18 - sleep 1 - Farbe.Select 7 - Farbname.SetText "Bullshit" '/// change color ///' - Aendern.Click - sleep 1 - TabFarben.OK - FormatArea - Kontext - Active.SetPage TabArea - Kontext "TabArea" - FillOptions.Select 2 - if ColourList.GetSelText = "Bullshit" Then - PrintLog " Color selection changed " - else - WarnLog " Color selection not changed" - end if - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - Farbmodell.Select 1 + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + Farbe.Select 24 + sleep 1 + Farbe.Select 18 + sleep 1 + Farbe.Select 7 + printlog "change color " + Farbname.SetText "Bullshit" + Aendern.Click + sleep 1 + TabFarben.OK + FormatArea + Kontext + Active.SetPage TabArea + Kontext "TabArea" + FillOptions.Select 2 + if ColourList.GetSelText = "Bullshit" Then + PrintLog " Color selection changed " + else + WarnLog " Color selection not changed" + end if + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + Farbmodell.Select 1 - Kontext - Active.SetPage TabFarben '/// test RGB color model ///' - Kontext "TabFarben" - Farbmodell.Select 1 '/// switch to RGB values ///' ' 33:RVB,CMJN - printlog " Selected colourmodel RGB?: "+Farbmodell.GetSelText - if left(Farbmodell.GetSelText,1) <> "R" then warnlog "not RGB selected ? :-(" - try - R.SetText "50" - G.SetText "10" - B.SetText "90" - catch - warnlog "RGB text fields are not enabled :-(" - endcatch - Aendern.Click - TabFarben.OK - Kontext "DocumentDraw" - FormatArea - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - if (R.GetText = "50" And G.GetText = "10" And B.GetText = "90") Then - PrintLog "Changes in RGB done" - else - WarnLog " Chancges in RGB values not recognized, instead of R=50 , G=10 und B=90 it is " +R.GetText + " " + G.GetText + " " + B.GetText - end if - Farbe.Select 10 - FarbName.SetText "Brighter" '/// add a color ///' - Hinzufuegen.Click - Farbe.Select "Brighter" - Loeschen.Click '/// delete color ///' - Kontext "Active" - Active.Yes - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - Bearbeiten.Click '/// edit color ///' - Kontext "FarbeDlg" - FarbeDlg.OK - sleep 2 - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - TabFarben.OK - FormatArea - Kontext - Active.SetPage TabFarben - Kontext "TabFarben" - TabFarben.OK + Kontext + printlog "test RGB color model " + Active.SetPage TabFarben + Kontext "TabFarben" + printlog "switch to RGB values " ' 33:RVB,CMJN + Farbmodell.Select 1 + printlog " Selected colourmodel RGB?: "+Farbmodell.GetSelText + if left(Farbmodell.GetSelText,1) <> "R" then warnlog "not RGB selected ? :-(" + try + R.SetText "50" + G.SetText "10" + B.SetText "90" + catch + warnlog "RGB text fields are not enabled :-(" + endcatch + Aendern.Click + TabFarben.OK + Kontext "DocumentDraw" + FormatArea + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + if (R.GetText = "50" And G.GetText = "10" And B.GetText = "90") Then + PrintLog "Changes in RGB done" + else + WarnLog " Chancges in RGB values not recognized, instead of R=50 , G=10 und B=90 it is " +R.GetText + " " + G.GetText + " " + B.GetText + end if + Farbe.Select 10 - FormatArea - Kontext - Active.SetPage TabFarbverlaeufe - Kontext "TabFarbverlaeufe" - TabFarbverlaeufe.OK - sleep 2 + FarbName.SetText "Brighter" + printlog "add a color " + Hinzufuegen.Click + Farbe.Select "Brighter" + printlog "delete color " + Loeschen.Click + Kontext "Active" + Active.Yes + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + printlog "edit color " + Bearbeiten.Click + Kontext "FarbeDlg" + FarbeDlg.OK + sleep 2 + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + TabFarben.OK + FormatArea + Kontext + Active.SetPage TabFarben + Kontext "TabFarben" + TabFarben.OK + + FormatArea + Kontext + Active.SetPage TabFarbverlaeufe + Kontext "TabFarbverlaeufe" + TabFarbverlaeufe.OK + sleep 2 -FormatArea - sleep 2 - Kontext - Active.SetPage TabTransparenz - Kontext "TabTransparenz" - KeineTransparenz.Check '/// check if controls are disabled if transparence is disabled ///' + FormatArea + sleep 2 + Kontext + Active.SetPage TabTransparenz + Kontext "TabTransparenz" + printlog "check if controls are disabled if transparence is disabled " + KeineTransparenz.Check Printlog "- No transparency is checked, all controls should be disabled." - if MFLinTransparenz.IsEnabled Then Warnlog "- Transparency enabled" - if TransparenzverlaufTyp.IsEnabled Then Warnlog "- Graidient enabled" - if MFZentrumX.IsEnabled Then Warnlog "- Center X enabled" - if MFZentrumY.IsEnabled Then Warnlog "- Center Y enabled" - if MFWinkel.IsEnabled Then Warnlog "- Angle enabled" - if MFRand.IsEnabled Then Warnlog "- Border enabled" - if MFStartwert.IsEnabled Then Warnlog "- Start value enabled" - if MFEndwert.IsEnabled Then Warnlog "- End value enabled" + if MFLinTransparenz.IsEnabled Then Warnlog "- Transparency enabled" + if TransparenzverlaufTyp.IsEnabled Then Warnlog "- Graidient enabled" + if MFZentrumX.IsEnabled Then Warnlog "- Center X enabled" + if MFZentrumY.IsEnabled Then Warnlog "- Center Y enabled" + if MFWinkel.IsEnabled Then Warnlog "- Angle enabled" + if MFRand.IsEnabled Then Warnlog "- Border enabled" + if MFStartwert.IsEnabled Then Warnlog "- Start value enabled" + if MFEndwert.IsEnabled Then Warnlog "- End value enabled" - LineareTransparenz.Check '/// check linear tranparency ///' - Printlog "- Set transparency to linear, all controls should be enabled now" '/// control if related controls are now enabled ///' - sleep 1 - MFLinTransparenz.ToMax '/// change values of controls ///' - if MFLinTransparenz.GetText <>"100%" Then Warnlog "- Maximum value not correct" - MFLinTransparenz.ToMin - if MFLinTransparenz.GetText <>"0%" Then Warnlog "- Minimum value not correct" - if TransparenzverlaufTyp.IsEnabled Then Warnlog "- Gradient enabled" - if MFZentrumX.IsEnabled Then Warnlog "- Centrum X enabled" - if MFZentrumY.IsEnabled Then Warnlog "- Centrum Y enabled" - if MFWinkel.IsEnabled Then Warnlog "- Angle enabled" - if MFRand.IsEnabled Then Warnlog "- Border enabled" - if MFStartwert.IsEnabled Then Warnlog "- Start value enabled" - if MFEndwert.IsEnabled Then Warnlog "- End value enabled" + printlog "check linear tranparency " + LineareTransparenz.Check + Printlog "- Set transparency to linear, all controls should be enabled now" + sleep 1 + printlog "change values of controls " + MFLinTransparenz.ToMax + if MFLinTransparenz.GetText <>"100%" Then Warnlog "- Maximum value not correct" + MFLinTransparenz.ToMin + if MFLinTransparenz.GetText <>"0%" Then Warnlog "- Minimum value not correct" + if TransparenzverlaufTyp.IsEnabled Then Warnlog "- Gradient enabled" + if MFZentrumX.IsEnabled Then Warnlog "- Centrum X enabled" + if MFZentrumY.IsEnabled Then Warnlog "- Centrum Y enabled" + if MFWinkel.IsEnabled Then Warnlog "- Angle enabled" + if MFRand.IsEnabled Then Warnlog "- Border enabled" + if MFStartwert.IsEnabled Then Warnlog "- Start value enabled" + if MFEndwert.IsEnabled Then Warnlog "- End value enabled" - Transparenzverlauf.Check + Transparenzverlauf.Check Printlog "- Gradient for transprency enabled" - if MFLinTransparenz.IsEnabled = "false" Then Warnlog "- Transparency disabled" - if TransparenzverlaufTyp.IsEnabled = "false" Then Warnlog "- Gradient disabled" - if MFZentrumX.IsEnabled = "false" Then Warnlog "- Center X disabled" - if MFZentrumY.IsEnabled = "false" Then Warnlog "- Center Y disabled" - if MFWinkel.IsEnabled = "false" Then Warnlog "- Anlge disabled" - if MFRand.IsEnabled = "false" Then Warnlog "- Border disabled" - if MFStartwert.IsEnabled = "false" Then Warnlog "- Start value disabled" - if MFEndwert.IsEnabled = "false" Then Warnlog "- End value disabled" + if MFLinTransparenz.IsEnabled = "false" Then Warnlog "- Transparency disabled" + if TransparenzverlaufTyp.IsEnabled = "false" Then Warnlog "- Gradient disabled" + if MFZentrumX.IsEnabled = "false" Then Warnlog "- Center X disabled" + if MFZentrumY.IsEnabled = "false" Then Warnlog "- Center Y disabled" + if MFWinkel.IsEnabled = "false" Then Warnlog "- Anlge disabled" + if MFRand.IsEnabled = "false" Then Warnlog "- Border disabled" + if MFStartwert.IsEnabled = "false" Then Warnlog "- Start value disabled" + if MFEndwert.IsEnabled = "false" Then Warnlog "- End value disabled" Printlog "- Check if changed values are saved" - Zaehler=TransparenzverlaufTyp.GetItemCount - for i=1 to Zaehler - TransparenzverlaufTyp.Select i - SetClipboard Transparenzverlauftyp.GetSelText - TabTransparenz.OK - sleep 2 + Zaehler=TransparenzverlaufTyp.GetItemCount + for i=1 to Zaehler + TransparenzverlaufTyp.Select i + SetClipboard Transparenzverlauftyp.GetSelText + TabTransparenz.OK + sleep 2 + FormatArea + sleep 1 + Kontext + printlog "check if values are saved after closing and reopening dialog " + Active.SetPage TabTransparenz + Kontext "TabTransparenz" + if not Transparenzverlauftyp.GetSelIndex = i Then Warnlog "- Values are not correct for gradient transparency" + next i + TransparenzverlaufTyp.Select 2 + if MFZentrumX.IsEnabled Then Warnlog "- Center X should not be enabled" + if MFZentrumY.IsEnabled Then Warnlog "- Center Y should not be enabled" + MFWinkel.SetText "45" + Winkel_1 = MFWinkel.GetText + TabTransparenz.OK + sleep 2 FormatArea - sleep 1 - Kontext - Active.SetPage TabTransparenz '/// check if values are saved after closing and reopening dialog ///' - Kontext "TabTransparenz" - if not Transparenzverlauftyp.GetSelIndex = i Then Warnlog "- Values are not correct for gradient transparency" - next i - TransparenzverlaufTyp.Select 2 - if MFZentrumX.IsEnabled Then Warnlog "- Center X should not be enabled" - if MFZentrumY.IsEnabled Then Warnlog "- Center Y should not be enabled" - MFWinkel.SetText "45" - Winkel_1 = MFWinkel.GetText - TabTransparenz.OK - sleep 2 - FormatArea - sleep 2 - Kontext - Active.SetPage TabTransparenz - Kontext "TabTransparenz" + sleep 2 + Kontext + Active.SetPage TabTransparenz + Kontext "TabTransparenz" if TransparenzverlaufTyp.GetSelIndex <>2 Then - Warnlog "- Second menu-item is not choosen" + Warnlog "- Second menu-item is not choosen" end if TransparenzverlaufTyp.Select 3 - if MFWinkel.GetText <> Winkel_1 then Warnlog "- The inserted value is not accepted" - if MFWinkel.GetText <> Winkel_1 Then TransparenzverlaufTyp.Select 3 - if MFWinkel.IsEnabled Then Warnlog " - Angle should not be active when Radial is choosen" + if MFWinkel.GetText <> Winkel_1 then Warnlog "- The inserted value is not accepted" + if MFWinkel.GetText <> Winkel_1 Then TransparenzverlaufTyp.Select 3 + if MFWinkel.IsEnabled Then Warnlog " - Angle should not be active when Radial is choosen" sleep 1 MFZentrumX.SetText "30" MFZentrumY.SetText "30" @@ -384,8 +421,8 @@ FormatArea Kontext Active.SetPage TabTransparenz Kontext "TabTransparenz" - if MFZentrumX.GetText <> "30%" Then Warnlog "- Setted value for Center X is not applied." - if MFZentrumY.GetText <> "30%" Then Warnlog "- Setted value for Center Y is not applied." + if MFZentrumX.GetText <> "30%" Then Warnlog "- Setted value for Center X is not applied." + if MFZentrumY.GetText <> "30%" Then Warnlog "- Setted value for Center Y is not applied." MFRand.SetText "10" MFStartwert.SetText "20" MFEndwert.SetText "30" @@ -396,12 +433,13 @@ FormatArea Kontext Active.SetPage TabTransparenz Kontext "TabTransparenz" - if MFRand.GetText <> "10%" Then Warnlog "- Border-value was not set." - if MFEndwert.GetText <> "30%" Then Warnlog "- End-value was not set." - if MFStartwert.GetText <> "20%" Then Warnlog "- Start-value was not set." + if MFRand.GetText <> "10%" Then Warnlog "- Border-value was not set." + if MFEndwert.GetText <> "30%" Then Warnlog "- End-value was not set." + if MFStartwert.GetText <> "20%" Then Warnlog "- Start-value was not set." TabTransparenz.OK - Call hCloseDocument '/// close document ///' + printlog "close document " + Call hCloseDocument endcase 'tdFormatArea1 diff --git a/testautomation/graphics/optional/includes/global/g_arrangealign.inc b/testautomation/graphics/optional/includes/global/g_arrangealign.inc index 48c6599efa72..929f139ed1ef 100644 --- a/testautomation/graphics/optional/includes/global/g_arrangealign.inc +++ b/testautomation/graphics/optional/includes/global/g_arrangealign.inc @@ -32,29 +32,45 @@ '\****************************************************************************** testcase tiDatei_Fuer_Anordnen_Erstellen - dim sTemp as string - dim i as integer - 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 - call sSelectEmptyLayout '/// new document ///' - if Dir(Datei)<>"" then app.Kill(Datei) ' kill old file - for Zaehler = 1 to 3 '/// create 3 overlapping objects ///' + dim sTemp as string + dim i as integer + dim zaehler as integer + printlog "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_ + printlog "new document " + call hNewDocument + if gApplication = "DRAW" then + kontext "DocumentDraw" + else + kontext "DocumentImpress" + DocumentImpress.UseMenu + hMenuSelectNr(4) + hMenuSelectNr(13) + call sSelectEmptyLayout + end if + + + if Dir(Datei)<>"" then app.Kill(Datei) ' kill old file + printlog "create 3 overlapping objects " + for Zaehler = 1 to 3 Kontext Select Case Zaehler Case 1: WL_SD_Wuerfel - gMouseMove (20,5, 80,60) '/// cubicel 20,5, 80,60 /// + printlog "cubicel 20,5, 80,60" + gMouseMove (20,5, 80,60) Printlog " Object start ---------------------- "+ Zaehler +" cubicel " Case 2: WL_SD_RechteckVoll - gMouseMove (40,35, 90,90) '/// rectangel 40,35, 90,90 /// - Printlog " Object start ---------------------- "+ Zaehler +" rectangel " + printlog "rectangel 40,35, 90,90" + gMouseMove (40,35, 90,90) + Printlog " Object start ---------------------- "+ Zaehler +" rectangel " Case 3: WL_SD_Torus - gMouseMove (1,35, 60,95) '/// donut ;-) 1,35, 60,95 /// + printlog "donut 1,35, 60,95 " + gMouseMove (1,35, 60,95) Printlog " Object start ---------------------- "+ Zaehler +" donut " End Select sleep (1) - FormatArea '/// assign different area properties for created objects (use rnd function)///' + printlog "assign different area properties for created objects (use rnd function)" + FormatArea sleep (1) kontext Select Case Zaehler @@ -75,12 +91,13 @@ testcase tiDatei_Fuer_Anordnen_Erstellen TabFarben.OK End Select sleep 1 - ContextPositionAndSize '/// save position and size values into varialbes ///' + printlog "save position and size values into varialbes " + ContextPositionAndSize sleep (1) kontext active.SetPage TabPositionAndSize kontext "TabPositionAndSize" - '/// the variables : Ueber_Text_[1-3] get set here ! with x position of object/// + printlog "the variables : Ueber_Text_[1-3] get set here ! with x position of object" Select Case Zaehler Case 1: Ueber_Text_1 = PositionX.GetText : printlog "xpos: "+zaehler+": "+PositionX.GetText Case 2: Ueber_Text_2 = PositionX.GetText : printlog "xpos: "+zaehler+": "+PositionX.GetText @@ -90,41 +107,43 @@ testcase tiDatei_Fuer_Anordnen_Erstellen gMouseClick 96,5 next Zaehler sleep 1 - call hFileSaveAsKill (Datei) '/// save document ///' + printlog "save document " + call hFileSaveAsKill (Datei) printlog "OK saved at ", Datei sleep 1 - '/// select in default order and take Position X in mind ;-) ///' - '///+ has to be from bottom to top: cubicel, rectangel, donut ///' + printlog "select in default order and take Position X in mind ;-)" + printlog "+ has to be from bottom to top: cubicel, rectangel, donut" sPrintCheckOrder (TRUE) - call hCloseDocument '/// close document ///' + printlog "close document " + call hCloseDocument endcase 'tiDatei_Fuer_Anordnen_Erstellen '------------------------------------------------------------------------------- testcase tdContextSendBackward dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the middle object: rectangle, with keys: [TAB],[TAB] ///' + printlog "select the middle object: rectangle, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") - '/// Send Backward / [Strg]+[-] -> one level more to the back ///' + printlog "Send Backward / [Strg]+[-] -> one level more to the back" WL_TB_ANORDNUNG_WeiterNachHinten - '///+ has to be from bottom to top: rectangel cubicel donut ///' + printlog "+ has to be from bottom to top: rectangel cubicel donut" sleep 2 sPrintCheckOrder - '/// deselect all ///' + printlog "deselect all" hTypeKeys ("<escape><escape>") sleep 2 - '/// select the middle object: cubical, with keys: [TAB],[TAB] ///' + printlog "select the middle object: cubical, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") sleep 2 sTemp = fGetPositionX if sTemp <> Ueber_Text_1 then warnlog "Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_1+";" end if - '/// close document ///' + printlog "close document" Call hCloseDocument endif sleep 2 @@ -134,18 +153,18 @@ endcase 'tdContextSendBackward testcase tdContextBringForward dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the middle object: rectangle, with keys: [TAB],[TAB] ///' + printlog "select the middle object: rectangle, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") - '/// Bring Forward / [Strg]+[+] -> one level more to the front ///' + printlog "Bring Forward / [Strg]+[+] -> one level more to the front" WL_TB_ANORDNUNG_WeiterNachVorn - '/// has to be from bottom to top: cubicel donut rectangel ///' + printlog "has to be from bottom to top: cubicel donut rectangel" sleep 1 sPrintCheckOrder - '/// select the middle object: donut, with keys: [TAB],[TAB] ///' + printlog "select the middle object: donut, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") sleep 2 sTemp = fGetPositionX @@ -153,7 +172,7 @@ testcase tdContextBringForward warnlog "Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_3+";" end if sleep 1 - '/// close document ///' + printlog "close document" Call hCloseDocument endif @@ -162,18 +181,18 @@ endcase 'tdContextBringForward testcase tdContextSendToBack dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the top object: donut, with keys: [TAB],[TAB],[TAB] ///' + printlog "select the top object: donut, with keys: [TAB],[TAB],[TAB]" hTypeKeys ("<TAB><TAB><TAB>") - '/// Send to Back / [Strg]+[Shift]+[-] -> backmost object ///' + printlog "Send to Back / [Strg]+[Shift]+[-] -> backmost object" OL_DRAW_GanzNachHinten - '/// has to be from bottom to top: rectangel cubicel donut ///' + printlog "has to be from bottom to top: rectangel cubicel donut" sleep 3 sPrintCheckOrder - '/// select the middle object: cubical, with keys: [TAB],[TAB] ///' + printlog "select the middle object: cubical, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") sleep 1 sTemp = fGetPositionX @@ -181,7 +200,7 @@ testcase tdContextSendToBack warnlog "Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_1+";" end if sleep 3 - '/// close document ///' + printlog "close document" Call hCloseDocument endif @@ -190,17 +209,17 @@ endcase 'tdContextSendToBack testcase tdContextBringToFront dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the bottom object: cubical, with keys: [TAB] ///' + printlog "select the bottom object: cubical, with keys: [TAB]" hTypeKeys ("<TAB>") - '/// Bring to Front / [Strg]+[Shift]+[+] -> frontmost object ///' + printlog "Bring to Front / [Strg]+[Shift]+[+] -> frontmost object" OL_DRAW_GanzNachVorn - '/// has to be from bottom to top: rectangel, donut, cubicel ///' + printlog "has to be from bottom to top: rectangel, donut, cubicel" sPrintCheckOrder - '/// select the middle object: donut, with keys: [TAB],[TAB] ///' + printlog "select the middle object: donut, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") sleep 1 sTemp = fGetPositionX @@ -208,7 +227,7 @@ testcase tdContextBringToFront warnlog "Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_3+";" end if sleep 3 - '/// close document ///' + printlog "close document" Call hCloseDocument endif @@ -217,26 +236,26 @@ endcase 'tdContextBringToFront testcase tdContextInFrontOfObject dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the top object: donut, with keys: [TAB],[TAB],[TAB] ///' + printlog "select the top object: donut, with keys: [TAB],[TAB],[TAB]" hTypeKeys ("<TAB><TAB><TAB>") - '/// In Front of object ///' + printlog "In Front of object" OL_DRAW_VorDasObjekt - '/// left click the cubicel with the mouse ///' + printlog "left click the cubicel with the mouse" gMouseClick 50,5 - '/// has to be from bottom to top: cubicel, donut, rectangel ///' + printlog "has to be from bottom to top: cubicel, donut, rectangel" sPrintCheckOrder sleep 1 - '/// select the middle object: donut, with keys: [TAB],[TAB] ///' + printlog "select the middle object: donut, with keys: [TAB],[TAB]" hTypeKeys ("<TAB><TAB>") sTemp = fGetPositionX if sTemp <> Ueber_Text_3 then printlog "DISABLED the WARNLOG, because mouseaction is not always the same :-( : Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_3+";" end if - '/// close document ///' + printlog "close document" Call hCloseDocument endif @@ -245,27 +264,27 @@ endcase 'tdContextInFrontOfObject testcase tdContextBehindObject dim sTemp as string - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// select the top object: donut, with keys: [TAB],[TAB],[TAB] ///' + printlog "select the top object: donut, with keys: [TAB],[TAB],[TAB]" hTypeKeys ("<TAB><TAB><TAB>") - '/// Behind object ///' + printlog "Behind object" OL_DRAW_HinterDasObjekt sleep 1 - '/// left click the cubicel with the mouse ///' + printlog "left click the cubicel with the mouse" gMouseClick 50,5 - '/// has to be from bottom to top: donut, cubicel, rectangel ///' + printlog "has to be from bottom to top: donut, cubicel, rectangel" sPrintCheckOrder sleep 1 - '/// select the bottom object: donut, with keys: [TAB] ///' + printlog "select the bottom object: donut, with keys: [TAB]" hTypeKeys ("<TAB>") sTemp = fGetPositionX if sTemp <> Ueber_Text_3 then printlog "DISABLED the WARNLOG, because mouseaction is not always tthe same Arrangement is wrong; is: "+sTemp+"; should: "+Ueber_Text_3+";" end if - '/// close document ///' + printlog "close document" Call hCloseDocument endif @@ -276,17 +295,17 @@ testcase tdContextReverse dim sTemp as string dim sTemp2 as string dim i as integer - '/// open created document 'with 3 figures' ///' + printlog "open created document 'with 3 figures'" if (hFileOpen (Datei)) then sleep 10 sPrintCheckOrder (TRUE) - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll sleep 3 - '/// Reverse ///' + printlog "Reverse" WL_TB_ANORDNUNG_Vertauschen sPrintCheckOrder - '/// select in default order and take Position X in mind ;-) ///' + printlog "select in default order and take Position X in mind ;-)" hTypeKeys ("<escape><escape>") for i = 1 to 3 hTypeKeys ("<TAB>") @@ -300,10 +319,9 @@ testcase tdContextReverse warnlog " - " + i + " Arrangement is wrong; is: "+sTemp+"; should: "+sTemp2+";" end if next i - '/// close document ///' - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endif endcase 'tdContextReverse '------------------------------------------------------------------------------- - diff --git a/testautomation/graphics/optional/includes/global/g_autocorrection.inc b/testautomation/graphics/optional/includes/global/g_autocorrection.inc index 731c9e0ed21f..42e3bc745ab4 100644 --- a/testautomation/graphics/optional/includes/global/g_autocorrection.inc +++ b/testautomation/graphics/optional/includes/global/g_autocorrection.inc @@ -38,13 +38,6 @@ '* '\******************************************************************* -' Tools->Autocorrect... -' Replace; Exceptions; Options; Custom Quotes -' these are Language -' dependant in the -' listbox above!! -' box only enabled, if the both tabpages are selected ... - testcase tToolsAutocorrectReplace dim i as integer @@ -76,7 +69,9 @@ testcase tToolsAutocorrectReplace TabErsetzung.OK hCloseDocument -endcase +endcase 'tToolsAutocorrectReplace + +'------------------------------------------------------------------------------- testcase tToolsAutocorrectExceptions dim i as integer @@ -119,9 +114,10 @@ testcase tToolsAutocorrectExceptions TabAusnahmen.OK hCloseDocument -endcase +endcase 'tToolsAutocorrectExceptions '------------------------------------------------------------------------------- + testcase tToolsAutocorrectCustomQuotes(bSimple as boolean) ' bSinple = true: use simple quotes ;; else Double Quotes @@ -151,8 +147,6 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean) warnlog "The language-file was not found or accessible! The test ends." goto endsub endif - - 'HDE has same problems in w_106a.inc ;-) !!! migrate ?!?! ///' Call hNewDocument hFileOpen sFileName @@ -381,7 +375,7 @@ testcase tToolsAutocorrectCustomQuotes(bSimple as boolean) sleep 1 hCloseDocument -endcase +endcase 'tToolsAutocorrectCustomQuotes '------------------------------------------------------------------------------- testcase tToolsAutocorrectOption @@ -455,6 +449,6 @@ testcase tToolsAutocorrectOption hCloseDocument sleep 1 -endcase +endcase 'tToolsAutocorrectOption -'------------------------------------------------------------------------------- +'-------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_character.inc b/testautomation/graphics/optional/includes/global/g_character.inc index a9d578665c5a..a1ee4285036b 100644 --- a/testautomation/graphics/optional/includes/global/g_character.inc +++ b/testautomation/graphics/optional/includes/global/g_character.inc @@ -42,44 +42,46 @@ testcase tFormatCharacter dim sTemp as string dim iTemp as integer - '/// open application ///' + printlog "open application " Call hNewDocument sleep 1 - '/// create a textframe with content ///' + printlog "create a textframe with content " hTextrahmenErstellen ("This is a check, a check, a check.",10,10,60,30) - '/// type with keys [strg]+[home] [shift]+[end] to select the inserted text ///' + printlog "type with keys [strg]+[home] [shift]+[end] to select the inserted text " hTypeKeys "<MOD1 HOME><shift end>" sleep 1 - '/// Format->Character ///' + printlog "Format->Character " FormatCharacter - sleep 1 - '/// switch to tabpage 'Font' ///' - Kontext - Messagebox.SetPage TabFont - Kontext "TabFont" - sleep 1 - - '/// switch to tabpage 'Font Effects' ///' - Kontext - Messagebox.SetPage TabFontEffects - kontext "TabFontEffects" - sleep 1 - - '/// switch to tabpage 'Position' ///' - Kontext - Messagebox.SetPage TabFontPosition - Kontext "TabFontPosition" - sleep 1 - - '/// close dialog 'Character' with 'OK' ///' - TabFontPosition.OK - '/// close application ///' + sleep 1 + printlog "switch to tabpage 'Font' " + Kontext + Messagebox.SetPage TabFont + Kontext "TabFont" + sleep 1 + + printlog "switch to tabpage 'Font Effects' " + Kontext + Messagebox.SetPage TabFontEffects + kontext "TabFontEffects" + sleep 1 + + printlog "switch to tabpage 'Position' " + Kontext + Messagebox.SetPage TabFontPosition + Kontext "TabFontPosition" + sleep 1 + + printlog "close dialog 'Character' with 'OK' " + TabFontPosition.OK + printlog "close application " Call hCloseDocument endcase 'tFormatCharacter + '--------------------------------------------------------- + testcase tDialogCharacter Dim i as integer @@ -101,11 +103,13 @@ testcase tDialogCharacter ToolsOptions hToolsOptions ( "LanguageSettings", "Languages" ) - if Aktivieren.IsChecked then '/// Check in what state Asian support is ///' + printlog "Check in what state Asian support is " + if Aktivieren.IsChecked then Asiansupportsetting = TRUE else + printlog "Activate if not already activated " Asiansupportsetting = FALSE - Aktivieren.Check '/// Activate if not already activated ///' + Aktivieren.Check end if Kontext "ExtrasOptionenDlg" @@ -118,8 +122,8 @@ testcase tDialogCharacter FormatCharacter sleep 1 - Kontext '"Active" ' insert this, perhaps another - Active.SetPage TabFont ' tabpage is active at open + Kontext '"Active" + Active.SetPage TabFont Kontext "TabFont" CountOfThem = FontWest.GetItemCount for y = 1 to CountOfThem @@ -275,12 +279,14 @@ testcase tDialogCharacter next y Kontext - Active.SetPage TabFontPosition '/// Changes the active tab to "Position" + printlog "Changes the active tab to Position" + Active.SetPage TabFontPosition Kontext "TabFontPosition" printlog "TabFontPosition" SuperScript.Check Super.Check - RelativeFontSize.ToMin '/// Testing the "Relative Font Size"-Listbox + printlog "Testing the Relative Font Size-Listbox" + RelativeFontSize.ToMin ThisIsMyTextFromControl = RelativeFontSize.GetText ' printlog "The Relative Font Size minimum is: " & ThisIsMyTextFromControl for y = 1 to 99 @@ -290,7 +296,8 @@ testcase tDialogCharacter next y Automatic.Check - ScaleWith.ToMin '/// Testing the "Scale With"-Listbox + printlog "Testing the Scale With-Listbox" + ScaleWith.ToMin ThisIsMyTextFromControl = ScaleWith.GetText printlog "ScaleWith minimum is:" & ThisIsMyTextFromControl ' ScaleWith.TypeKeys "<TAB>" @@ -303,8 +310,10 @@ testcase tDialogCharacter Normal.Check Subscript.Check - RelativeFontSize.ToMin '/// Testing the "Reliative Font Size"-Listbox again but this time - ThisIsMyTextFromControl = RelativeFontSize.GetText '/// with "Subscript" and "Normal" Checked + printlog "Testing the Reliative Font Size-Listbox again but this time" + RelativeFontSize.ToMin + printlog "with Subscript and Normal Checked" + ThisIsMyTextFromControl = RelativeFontSize.GetText printlog "The Relative Font Size minimum is: " & ThisIsMyTextFromControl for y = 1 to 99 RelativeFontSize.TypeKeys "<UP>" @@ -314,7 +323,8 @@ testcase tDialogCharacter Automatic.Check - ScaleWith.ToMin '/// Testing the "ScaleWith"-Listbox + printlog "Testing the ScaleWith-Listbox" + ScaleWith.ToMin ThisIsMyTextFromControl = ScaleWith.GetText printlog "The ScaleWith Size is: " & ThisIsMyTextFromControl for y = 1 to 100 @@ -323,13 +333,15 @@ testcase tDialogCharacter ' printlog "The ScaleWith Size is: " & ThisIsMyTextFromControl next y - ThisIsMyTextFromControl = Spacing.GetSelText '/// Testing the "Spacing"-ListBox + printlog "Testing the Spacing-ListBox" + ThisIsMyTextFromControl = Spacing.GetSelText printlog "The Spacing is first: " & ThisIsMyTextFromControl for y = 2 to 3 Spacing.Select y ThisIsMyTextFromControl = Spacing.GetSelText printlog "The Spacing is: " & ThisIsMyTextFromControl - ThisIsMyTextFromControl = SpacingBy.GetText '/// Testing the "Spacing By"-Scrollbox + printlog "Testing the Spacing By-Scrollbox" + ThisIsMyTextFromControl = SpacingBy.GetText ' printlog "The SpacingBy Size minimum is: " & ThisIsMyTextFromControl SpacingBy.ToMin for z = 1 to 4 @@ -347,7 +359,8 @@ testcase tDialogCharacter kontext ToolsOptions hToolsOptions ( "LanguageSettings", "Languages" ) - Aktivieren.UnCheck '/// Deactivate if not already deactivated ///' + printlog "Deactivate if not already deactivated " + Aktivieren.UnCheck Printlog "Reseted the Asiansupport-value to it's original state" Kontext "ExtrasOptionenDlg" @@ -385,41 +398,41 @@ testcase tSetFormatCharacter end if sFile = convertPath(gTesttoolpath + "graphics\required\input\spellb_" + iSprache + "."+ExtensionString) - '/// create document, if it doesn't exist, else skip this case :-) ///' + printlog "create document, if it doesn't exist, else skip this case :-) " if (dir(sFile)="") then - '/// open application ///' + printlog "open application " Call hNewDocument - '/// activate all languages in options ///' - '///+ Tools->Options ///' + printlog "activate all languages in options " + printlog " Tools->Options " ToolsOptions - '///+ select tabpage 'Languages' from set 'Language Settings' ///' + printlog " select tabpage 'Languages' from set 'Language Settings' " hToolsOptions("LANGUAGESETTINGS","Languages") kontext "TabSprachen" - '///+ save state and check checkbox 'Asian languages support' ///' - '/// if the language is Asian, skip this part ///' + printlog " save state and check checkbox 'Asian languages support' " + printlog "if the language is Asian, skip this part " printlog "iSprache = " + iSprache if bAsianLan = FALSE then bAsian = Aktivieren.isEnabled Aktivieren.check endif - '///+ save state and check checkbox 'Complex text layout (CTL) support' ///' + printlog " save state and check checkbox 'Complex text layout (CTL) support' " bComplex = ComplexScriptEnabled.isEnabled ComplexScriptEnabled.check - '///+ close dialog 'Options' with OK ///' + printlog "close dialog 'Options' with OK " Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK - '/// get count of languages ///' - '///+ Format->Character ///' + printlog "get count of languages " + printlog " Format->Character " FormatCharacter sleep 1 Kontext - '///+ switch to tabpage 'Font' ///' + printlog "switch to tabpage 'Font' " Messagebox.SetPage TabFont kontext "TabFont" sleep 1 - '///+ get count of languages for Western/Asian/CTL fonts ///' + printlog " get count of languages for Western/Asian/CTL fonts " iWest = LanguageWest.getItemCount iAsian = LanguageEast.getItemCount iComplex = LanguageCTL.getItemCount @@ -456,39 +469,39 @@ testcase tSetFormatCharacter Printlog "CTL font languages count : " + iComplex endif endif - '///+ close dialog 'Character' with OK ///' + printlog "close dialog 'Character' with OK " TabFont.Ok WL_SD_TextEinfuegenDraw gMouseMove ( 1, 1, 100, 100 ) - '///+ print the language counts into the first line of the document ///' + printlog "print the language counts into the first line of the document " hTypeKeys(" "+iWest+" "+iAsian+" "+iComplex+"<return>") - '/// set all languages to '[None]' ///' - '///+ Format->Character ///' + printlog "set all languages to '[None]' " + printlog "Format->Character " FormatCharacter kontext "TabFont" - '///+ select '[None]' (should be the first entry in every listbox) ///' + printlog "select '[None]' (should be the first entry in every listbox) " LanguageWest.select 1 LanguageEast.select 1 LanguageCTL.select 1 - '///+ close dialog 'Character' with OK ///' + printlog "close dialog 'Character' with OK " TabFont.Ok - '/// print one line with language formated text for every language ///' + printlog "print one line with language formated text for every language " for i = 1 to iWest - '///+ Format->Character ///' + printlog "Format->Character " FormatCharacter kontext "TabFont" - '///+ select the next language ///' + printlog "select the next language " LanguageWest.select i sTemp = LanguageWest.getItemText (i) ListAppend(sLanguage(), sTemp) - '///+ close dialog 'Character' with OK ///' + printlog "close dialog 'Character' with OK " TabFont.Ok - '///+ type [return][number of language in list][Tab][Language name][Tab] ///' + printlog "type [return][number of language in list][Tab][Language name][Tab] " hTypeKeys(""+i+"<tab>"+sTemp+"<tab><return>") next i @@ -528,7 +541,7 @@ testcase tSetFormatCharacter hTypeKeys(""+i+"<tab>"+sTemp+"<tab><return>") next i - '/// save the created document & the languages list if they don't exists ///' + printlog "save the created document & the languages list if they don't exists " hFileSaveAs (sFile) qaErrorLog "Created file. Please check it and then commit it! " + sTemp sTemp = convertPath(gTesttoolpath + "graphics\required\input\spellb_" + iSprache + ".txt") @@ -536,29 +549,29 @@ testcase tSetFormatCharacter ListWrite(sLanguage(), sTemp,"utf8") endif - '/// restore the options ///' - '///+ Tools->Options ///' + printlog "restore the options " + printlog "Tools->Options " ToolsOptions - '///+ select tabpage 'Languages' from set 'Language Settings' ///' + printlog "select tabpage 'Languages' from set 'Language Settings' " hToolsOptions("LANGUAGESETTINGS","Languages") kontext "TabSprachen" - '///+ restore state of checkbox 'Asian languages support' ///' - '/// if the language is Asian, skip this part ///' + printlog "restore state of checkbox 'Asian languages support' " + printlog "if the language is Asian, skip this part " if bAsianLan = FALSE then if (bAsian <> TRUE) then Aktivieren.UNcheck endif endif - '///+ restore state of checkbox 'Complex text layout (CTL) support' ///' + printlog "restore state of checkbox 'Complex text layout (CTL) support' " if (bComplex <> TRUE) then ComplexScriptEnabled.UNcheck endif - '///+ close dialog 'Options' with OK ///' + printlog "close dialog 'Options' with OK " Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK - '/// close application ///' + printlog "close application " Call hCloseDocument endif @@ -586,29 +599,29 @@ testcase tGetFormatCharacter ExtensionString = "odg" end if - '/// open the english document with all languages ///' + printlog "open the english document with all languages " hDateiOeffnen (convertPath(gTesttoolpath + "graphics\required\input\spellb_" + iSprache + "."+ExtensionString) ListRead(sLanguageR(), convertPath(gTesttoolpath + "graphics\required\input\spellb_1.txt"),"utf8") - '/// activate all languages in options ///' - '///+ Tools->Options ///' + printlog "activate all languages in options " + printlog " Tools->Options " ToolsOptions - '///+ select tabpage 'Languages' from set 'Language Settings' ///' + printlog "select tabpage 'Languages' from set 'Language Settings' " hToolsOptions("LANGUAGESETTINGS","Languages") kontext "TabSprachen" - '///+ save state and check checkbox 'Asian languages support' ///' + printlog "save state and check checkbox 'Asian languages support' " bAsian = Aktivieren.isEnabled Aktivieren.check - '///+ save state and check checkbox 'Complex text layout (CTL) support' ///' + printlog "save state and check checkbox 'Complex text layout (CTL) support' " bComplex = ComplexScriptEnabled.isEnabled ComplexScriptEnabled.check - '///+ close dialog 'Options' with OK ///' + printlog "close dialog 'Options' with OK " Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK sleep (1) - '/// get count of languages ///' + printlog "get count of languages " hTypeKeys("<tab><f2>") - '///+ first how many are in the reference document (printed in the first line)///' + printlog "first how many are in the reference document (printed in the first line)" hTypeKeys("<mod1 home><shift end>") sleep (1) editcopy @@ -619,15 +632,15 @@ testcase tGetFormatCharacter iAsian(1) = mid(sTemp, iTemp+1, iTemp-i) iComplex(1) = right(sTemp, Len(sTemp) - i) sleep (1) - '///+ Format->Character ///' + printlog "Format->Character " FormatCharacter sleep 1 Kontext - '///+ switch to tabpage 'Font' ///' + printlog "switch to tabpage 'Font' " Messagebox.SetPage TabFont kontext "TabFont" sleep 1 - '///+ get count of languages for Western/Asian/CTL fonts ///' + printlog "get count of languages for Western/Asian/CTL fonts " iWest(2) = LanguageWest.getItemCount iAsian(2) = LanguageEast.getItemCount iComplex(2) = LanguageCTL.getItemCount @@ -646,10 +659,10 @@ testcase tGetFormatCharacter else Printlog "CTL font languages count : " + iComplex(2) endif - '///+ close dialog 'Character' with OK ///' + printlog "close dialog 'Character' with OK " TabFont.Ok - '/// write the language for every line in the current language ///' + printlog "write the language for every line in the current language " hTypeKeys("<mod1 home><down><home>") for i = 1 to iWest(2) FormatCharacter @@ -659,7 +672,7 @@ testcase tGetFormatCharacter sTemp = LanguageWest.getSelText ListAppend(sLanguage(), sTemp) TabFont.Ok - '///+ type [end][number of language in list][Tab][Language name][down][home] ///' + printlog "type [end][number of language in list][Tab][Language name][down][home] " hTypeKeys("<end>"+iTemp+"<tab>"+sTemp+"<down><home>") next i @@ -685,7 +698,7 @@ testcase tGetFormatCharacter hTypeKeys("<end>"+iTemp+"<tab>"+sTemp+"<down><home>") next i - '/// save the created document & the languages list ///' + printlog "save the created document & the languages list " sTemp = convertPath(gOfficePath + "user\work\spellb_" + iSprache) hFileSaveAsKill (sTemp) sTemp = convertPath(gOfficePath + "user\work\spellb_" + iSprache + ".txt") @@ -709,6 +722,6 @@ testcase tGetFormatCharacter endif next i - '/// close application ///' + printlog "close application " Call hCloseDocument endcase 'tGetFormatCharacter diff --git a/testautomation/graphics/optional/includes/global/g_clipboard.inc b/testautomation/graphics/optional/includes/global/g_clipboard.inc index 4c1900876565..8da14643d748 100644 --- a/testautomation/graphics/optional/includes/global/g_clipboard.inc +++ b/testautomation/graphics/optional/includes/global/g_clipboard.inc @@ -30,95 +30,106 @@ '* short description : '* '************************************************************************************** -' #1 tiEditUndo -' #1 tiEditRedo -' #1 tiEditClipboard -' #1 tiEditPasteSpecial_HTML -' #1 tdEditPasteSpecial_Text -' #1 tdEditPasteSpecial_Graphic -' #1 tdEditPasteSpecial_Circle -' #1 tiEditPasteSpecial -'\************************************************************************************* testcase tiEditUndo - Dim sDatei as string Dim Ueber_Text_1 as string + dim sTestfile as string + dim sLocaltestfile as string - if (gApplication = "IMPRESS") then + if (gApplication = "IMPRESS") then ExtensionString = "odp" else ExtensionString = "odg" end if - sDatei = gTesttoolPath + "graphics\required\input\leer."+ExtensionString - - hFileOpen ConvertPath (sDatei) - sleep 5 - printlog "Checking for readonly state. If so, make it editable." - sMakeReadOnlyDocumentEditable - + sTestfile = gTesttoolPath + "graphics\required\input\leer."+ExtensionString + printlog "Loading test file.." + hFileOpenLocally( sTestfile ) + sleep 3 + printlog "Selecting grey rectangle.." hTypeKeys "<TAB><TAB>" sleep 3 + printlog "Opening Position and size dialog." ContextPositionAndSize Kontext if Messagebox.exists (5) then - Messagebox.SetPage TabPositionAndSize + Messagebox.SetPage TabPositionAndSize else - print "what" + printlog "Not the expected Dialog came up. Please check." endif Kontext "TabPositionAndSize" - Ueber_Text_1=PositionX.GetText '/// defining variable for original position of object ///' + printlog "defining variable for original position of object" + Ueber_Text_1=PositionX.GetText + printlog "Position X is: " & Ueber_Text_1 + printlog "Canceling dialog." TabPositionAndSize.Cancel sleep 2 Kontext "Toolbar" Auswahl.Click sleep 1 - ContextArrangeBringBackward '/// Bring Object backward ///' + printlog "Sending Rectangle backwards." + ContextArrangeBringBackward sleep 1 + printlog "Deselect." gMouseClick 60,60 sleep 1 Kontext "Toolbar" Auswahl.Click sleep 1 + printlog "trying to select blue rectangle in front" hTypeKeys "<TAB><TAB>" Kontext "Toolbar" Auswahl.Click sleep 1 - ContextPositionAndSize '/// Open Position and Size dialog, checking position ///' + printlog "Open Position and Size dialog, checking position" + ContextPositionAndSize Kontext Messagebox.SetPage TabPositionAndSize Kontext "TabPositionAndSize" - if PositionX=0 Then Warnlog " Command was not completely executed, and it could not be undone." + printlog "Position X is: " & PositionX.GetText + if (PositionX.GetText)=0 Then Warnlog "Command was not completely executed, and it could not be undone." TabPositionAndSize.Cancel sleep 2 gMouseClick 60,60 sleep 1 - - EditUndo '/// Edit Undo for BringBackward ///' + + printlog "Edit Undo for BringBackward" + EditUndo Sleep 2 gMouseClick 60,60 sleep 1 Kontext "Toolbar" Auswahl.Click + printlog "Trying to select grey rectangle again." hTypeKeys "<TAB><TAB>" sleep 1 Kontext "Toolbar" Auswahl.Click - ContextPositionAndSize '/// Again checking position using Position and Size dialog ///' + printlog "Again checking position using Position and Size dialog" + ContextPositionAndSize kontext Messagebox.SetPage TabPositionAndSize kontext "TabPositionAndSize" + printlog "Checking if x Position is like ata the start again." if PositionX.GetText = Ueber_Text_1 then printlog "OK, last order could be redone" else warnlog "Last order could not be redone" end if TabPositionAndSize.Cancel - - Call hCloseDocument '/// Close document ///' - -endcase + printlog "Close document" + Call hCloseDocument + sLocaltestfile = hFileGetLocalPath( gTesttoolPath + "leer."+ExtensionString ) + printlog sLocaltestfile + if (FileExists (sLocaltestfile)) then + app.kill (sLocaltestfile) + printlog "Deleting used file." + else + warnlog "File is missing." + endif + +endcase 'tiEditUndo '------------------------------------------------------------------------------- testcase tiEditRedo @@ -133,8 +144,9 @@ testcase tiEditRedo end if Datei$ = gTesttoolPath + "graphics\required\input\leer."+ExtensionString - - hFileOpen ConvertPath (Datei$) '/// Open test document (leer.od?) ///' + + printlog "Open test document (leer.od?)" + hFileOpen ConvertPath (Datei$) sleep 3 ' check if the document is writable if fIsDocumentWritable = false then @@ -159,7 +171,8 @@ testcase tiEditRedo sleep 1 hTypeKeys "<TAB>" sleep 1 - ContextArrangeBringBackward '/// move object behind other object ///' + printlog "move object behind other object" + ContextArrangeBringBackward sleep 1 gMouseClick 60,60 sleep 1 @@ -168,25 +181,29 @@ testcase tiEditRedo ContextPositionAndSize sleep 1 Kontext - Messagebox.SetPage TabPositionAndSize '/// checking new position values ///' + printlog "checking new position values" + Messagebox.SetPage TabPositionAndSize Kontext "TabPositionAndSize" if PositionX.GetText = Ueber_Text_1 Then Warnlog " Nothing changed, so nothing can be undone" TabPositionAndSize.Cancel sleep 1 gMouseClick 60,60 - EditUndo '/// Edit Undo///' + printlog "Edit Undo" + EditUndo sleep 1 hTypeKeys "<TAB>" sleep 1 ContextPositionAndSize sleep 1 kontext - Messagebox.SetPage TabPositionAndSize '/// checking again position ///' + printlog "checking again position" + Messagebox.SetPage TabPositionAndSize kontext "TabPositionAndSize" if PositionX.GetText <> Ueber_Text_1 Then Warnlog " Undo didn't worked, so repeat last action wont work either" TabPositionAndSize.Cancel sleep 2 - EditRedo '/// Edit Redo ///' + printlog "Edit Redo" + EditRedo sleep 2 gMouseClick 60,60 sleep 2 @@ -197,16 +214,18 @@ testcase tiEditRedo kontext Messagebox.SetPage TabPositionAndSize kontext "TabPositionAndSize" - if PositionX.GetText <> Ueber_Text_1 then '/// checking position ///' + printlog "checking position" + if PositionX.GetText <> Ueber_Text_1 then printlog "Action Undo repeated" else warnlog "Action Undo not repeated" end if TabPositionAndSize.OK sleep 1 - call hCloseDocument '/// close document ///' + printlog "close document" + call hCloseDocument sleep 1 -endcase +endcase 'tiEditRedo '------------------------------------------------------------------------------- testcase tiEditClipboard @@ -214,61 +233,63 @@ testcase tiEditClipboard Dim Ueber_Text_4 as string dim sTemp as string - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout sleep 1 SetClipboard "" - '/// Create rectangle ///' + printlog "Create rectangle" Call hRechteckErstellen ( 65, 65, 80, 80 ) sleep 1 - '///+ RightClick onto rectangle///' + printlog "RightClick onto rectangle" gMouseClick 70,70 sleep 1 - Ueber_Text_4 = fGetPositionX() '/// Get values for position variables ///' + printlog "Get values for position variables" + Ueber_Text_4 = fGetPositionX() Sleep 1 - '/// <b> Edit->Copy </b> ///' + printlog " Edit->Copy" EditCopy - '///+ Type Key [Deletee] ///' + printlog " Type Key [Delete]" hTypeKeys "<DELETE>" - '///+ <i> Edit->Paste </i> ///' + printlog "Edit->Paste" EditPaste sleep 1 - '///+ Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll sTemp = fGetPositionX() - if LiberalMeasurement(sTemp, Ueber_Text_4) then '/// TabPositionAndSize: comparing position with original position ///' + printlog "TabPositionAndSize: comparing position with original position" + if LiberalMeasurement(sTemp, Ueber_Text_4) then printlog "OK EditCopy and EditPaste" else warnlog "- Edit paste did not work; is: '" + sTemp + "' ; should: '" + Ueber_Text_4 + "'" end if sleep 1 - '/// Type Keys [escape], + EditSelectAll (to deselect object and to select again) ///' + printlog "Type Keys [escape], + EditSelectAll (to deselect object and to select again)" hTypeKeys "<escape>" EditSelectAll sleep 2 - '/// <b> Edit->Cut </b>///' + printlog "<b> Edit->Cut" EditCut sleep 1 hTypeKeys "<TAB>" try - '///+ - Format->Position And Size -> HAS TO FAIL / IS NOT AVAILABLE !!! '///' + printlog "Format->Position And Size -> HAS TO FAIL / IS NOT AVAILABLE !!! " ContextPositionAndSize kontext - '///+ - select TabPage 'Position And Size' ///' + printlog "select TabPage 'Position And Size'" Messagebox.SetPage TabPositionAndSize Kontext "TabPositionAndSize" if TabPositionAndSize.NOTexists then warnlog "TabPositionAndSize isn't up ?!!" endif - '///+ - Ok dialog 'Position And Size' ///' + printlog "Ok dialog 'Position And Size'" TabPositionAndSize.Ok warnlog "TabPositionAndSize IS up :-( Doesn't have to be, because object should be deleted !!!" catch Printlog " - There is no object in the document anymore :-)" endcatch sleep 1 - '///+ <i> Edit->Paste </i> ///' + printlog "Edit->Paste" EditPaste sleep 2 sTemp = fGetPositionX() @@ -278,9 +299,9 @@ testcase tiEditClipboard warnlog "- Edit paste did not work; is: '" + sTemp + "' ; should: '" + Ueber_Text_4 + "'" end if sleep 3 - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiEditClipboard '------------------------------------------------------------------------------- testcase tiEditPasteSpecial_HTML @@ -288,7 +309,8 @@ testcase tiEditPasteSpecial_HTML dim Zaehler as integer Kontext "Standardbar" sleep 1 - Call hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\frame1.htm") '/// Load html document ///' + printlog "Load html document" + Call hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\frame1.htm") sleep 5 autoexecute=false Kontext "DocumentWriter" @@ -297,49 +319,61 @@ testcase tiEditPasteSpecial_HTML autoexecute=true EditSelectAll sleep 3 - EditCopy '/// Copy selection ///' + printlog "Copy selection" + EditCopy Sleep 2 - FileClose '/// Close document ///' + printlog "Close document" + FileClose sleep 3 - Call hNewDocument '/// Create new Impress document ///' + printlog "Create new Impress document" + Call hNewDocument sleep 1 - EditPasteSpecial '/// Edit paste special ///' + printlog "Edit paste special" + EditPasteSpecial sleep 1 Kontext "InhaltEinfuegen" For Zaehler = 1 to Auswahl.GetItemCount Auswahl.select Zaehler printlog Zaehler, ". Selection = ", Auswahl.GetSelText next Zaehler - - if Auswahl.GetItemCount <> 4 then '/// Controlling number of possible formats ///' + + printlog "Controlling number of possible formats" + if Auswahl.GetItemCount <> 4 then warnlog "formats for inserting Html <> 4" else printlog "OK 4 formats for HTML-Document" end if sleep 3 - InhaltEinfuegen.OK '/// Paste clipboard content ///' + printlog "Paste clipboard content" + InhaltEinfuegen.OK sleep 3 try - EditCopy '/// Copy object back into clipboard ///' + printlog "Copy object back into clipboard" + EditCopy catch Warnlog "- Nothing inserted into document" endcatch sleep 3 - Call hCloseDocument '/// Close document ///' + printlog "Close document" + Call hCloseDocument sleep 3 -endcase +endcase 'tiEditPasteSpecial_HTML '------------------------------------------------------------------------------- testcase tdEditPasteSpecial_Text printlog "Insert Text" - call hNewDocument '/// new document ///' - SetClipboard "I am a cool test-text in the Clipboard" '/// put text into clipboard ///' - EditPasteSpecial '/// edit paste special ///' + printlog "new document " + call hNewDocument + printlog "put text into clipboard" + SetClipboard "I am a cool test-text in the Clipboard" + printlog "edit paste special" + EditPasteSpecial sleep 1 Kontext "InhaltEinfuegen" - Auswahl.Select 1 '/// select list entree 1 ///' + printlog "select list entree 1" + Auswahl.Select 1 printlog "Selection = ", Auswahl.GetSelText sleep 1 if Auswahl.GetItemCount <> 1 then @@ -347,53 +381,64 @@ testcase tdEditPasteSpecial_Text else printlog "Format Text OK" end if - InhaltEinfuegen.OK '/// close dialog ///' + printlog "close dialog" + InhaltEinfuegen.OK sleep 1 - - Call hCloseDocument '/// close document ///' -endcase + + printlog "close document" + Call hCloseDocument +endcase 'tdEditPasteSpecial_Text '------------------------------------------------------------------------------- testcase tdEditPasteSpecial_Graphic dim Zaehler as integer - - call hNewDocument '/// ^new document ///' + + printlog "new document " + call hNewDocument printlog "Insert graphic file" - InsertGraphicsFromFile '/// insert graphic (sample.bmp)///' + InsertGraphicsFromFile Kontext "GrafikEinfuegenDlg" - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") - Oeffnen.Click + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") + Oeffnen.Click sleep 1 - EditSelectAll '/// select graphic ///' - EditCut '/// cut graphic ///' - EditPasteSpecial '/// edit paste special ///' + printlog "select graphic" + EditSelectAll + printlog "cut graphic" + EditCut + printlog "edit paste special" + EditPasteSpecial sleep 1 Kontext "InhaltEinfuegen" - For Zaehler = 1 to Auswahl.GetItemCount '/// get item count for Auswahl ///' + printlog "get item count for Auswahl" + For Zaehler = 1 to Auswahl.GetItemCount Auswahl.select Zaehler printlog Zaehler, ". Selection = ", Auswahl.GetSelText next Zaehler - - if Auswahl.GetItemCount <> 4 then '/// check if item count = 4 ///' + + printlog "check if item count = 4" + if Auswahl.GetItemCount <> 4 then warnlog "Format for insert graphic files should be 4, but is: " + Auswahl.GetItemCount else printlog "There are " + Auswahl.GetItemCount + " formats for graphic files" end if - InhaltEinfuegen.OK '/// insert graphic from clipboard ///' + printlog "insert graphic from clipboard" + InhaltEinfuegen.OK gMouseClick 90,90 sleep 1 - Call hCloseDocument '/// close document ///' -endcase + printlog "close document " + Call hCloseDocument +endcase 'tdEditPasteSpecial_Graphic '------------------------------------------------------------------------------- testcase tdEditPasteSpecial_Circle - dim Zaehler as integer - call hNewDocument '/// new document ///' + dim Zaehler as integer + printlog "new document " + call hNewDocument sleep 5 - printlog "Insert circle" '/// create circle ///' + printlog "Insert circle" Kontext "Toolbar" Ellipsen.Click sleep 3 @@ -401,28 +446,36 @@ testcase tdEditPasteSpecial_Circle sleep 1 hTypeKeys "<escape>" sleep 2 - EditSelectAll '/// select circle ///' + printlog "select circle" + EditSelectAll sleep 5 - EditCut '/// cut circle ///' + printlog "cut circle" + EditCut sleep 1 - EditPasteSpecial '/// edit paste special ///' + printlog "edit paste special" + EditPasteSpecial sleep 1 Kontext "InhaltEinfuegen" - if EinfuegenAls.IsVisible Then EinfuegenAls.Check '/// check "EinfuegenAls" ///' - For Zaehler = 1 to Auswahl.GetItemCount '/// get item count for Auswahl ///' + printlog "check Insert as.." + if EinfuegenAls.IsVisible Then EinfuegenAls.Check + printlog "get item count for Auswahl" + For Zaehler = 1 to Auswahl.GetItemCount Auswahl.select Zaehler printlog Zaehler, ". Selection = ", Auswahl.GetSelText next Zaehler - if Auswahl.GetItemCount <> 4 then '/// check if item count = 4 ///' + printlog "check if item count = 4" + if Auswahl.GetItemCount <> 4 then warnlog "Number of possible formats <> 4" else printlog "There are 4 formats for circle" end if sleep 1 - InhaltEinfuegen.OK '/// paste circle ///' + printlog "paste circle" + InhaltEinfuegen.OK sleep 1 - Call hCloseDocument '/// close document ///' -endcase + printlog "close document " + Call hCloseDocument +endcase 'tdEditPasteSpecial_Circle '------------------------------------------------------------------------------- testcase tiEditPasteSpecial @@ -430,8 +483,8 @@ testcase tiEditPasteSpecial dim i as integer dim x as integer ' warnlog "TODOTBO: from draw, impress, math..." - '/// go into writer, type a text, select all, Edit->Cut, close writer ///' - '/// go into application to test, insert every format you can get from Edit->Paste->Special :-) ///' + printlog "go into writer, type a text, select all, Edit->Cut, close writer" + printlog "go into application to test, insert every format you can get from Edit->Paste->Special :-)" gApplication = "WRITER" call hNewDocument kontext "DocumentWriter" @@ -442,28 +495,29 @@ testcase tiEditPasteSpecial call hNewDocument sleep 1 - Printlog " get count of possibilities: " - EditPasteSpecial - sleep 1 - Kontext "InhaltEinfuegen" - x = Auswahl.GetItemCount - for i = 1 to x - printlog " - " + i + " - " + Auswahl.GetItemText (i) - next i - InhaltEinfuegen.Cancel + Printlog " get count of possibilities: " + EditPasteSpecial + sleep 1 + Kontext "InhaltEinfuegen" + x = Auswahl.GetItemCount + for i = 1 to x + printlog " - " + i + " - " + Auswahl.GetItemText (i) + next i + InhaltEinfuegen.Cancel - Printlog " insert every possibility" - for i = 1 to x - Printlog " - processing number: "+i - EditPasteSpecial - sleep 1 - Kontext "InhaltEinfuegen" - Auswahl.Select i - sleep 1 - InhaltEinfuegen.OK - sleep 1 - next i - Call hCloseDocument '/// close document ///' -endcase + Printlog " insert every possibility" + for i = 1 to x + Printlog " - processing number: "+i + EditPasteSpecial + sleep 1 + Kontext "InhaltEinfuegen" + Auswahl.Select i + sleep 1 + InhaltEinfuegen.OK + sleep 1 + next i + printlog "close document" + Call hCloseDocument +endcase 'tiEditPasteSpecial '------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/global/g_clipexport.inc b/testautomation/graphics/optional/includes/global/g_clipexport.inc index 64385ffd78c3..c9569cbf8741 100644 --- a/testautomation/graphics/optional/includes/global/g_clipexport.inc +++ b/testautomation/graphics/optional/includes/global/g_clipexport.inc @@ -165,87 +165,138 @@ global Text5 as string global Text6 as string global Text7 as string +'--------------------------- Tests for Writer ---------------------------------- +sub writertest + + try + call Make_And_Check_Formatted_Text_Line_From_Application + catch + warnlog "Something went wrong with testing writertest" + endcatch + + try + call Make_Rectangle_From_Application + call Full_test_Draw + call Full_test_Impress + call Full_test_Writer + call Full_test_Calc + catch + warnlog "something wrong with testing writertest" + endcatch +end sub ' big one + +'---------------------------- Tests for Calc ----------------------------------- +sub calctest + + try + call Make_Rectangle_From_Application + call Full_test_Draw + call Full_test_Impress + call Full_test_Writer + call Full_test_Calc + catch + warnlog "something wrong with calctest" + endcatch + printlog "currently no specific tests from Calc" +end sub + +'------------------------------------------------------------------------------- +sub tClipboardFromDrawTest + + EnableQAErrors = false + FromApp2 = gApplication + printlog "gApplication = " + gApplication + + select case( gApplication ) + case "WRITER" : call writertest() + case "CALC" : call calctest() + case else : warnlog( "Unsupported gApplication provided: " & gApplication ) + end select + +end sub + '------------------------------- "object"-dependant tests ---------------------- -try - call Make_Rectangle_From_Application - call Full_test_Draw - call Full_test_Impress - call Full_test_Writer - call Full_test_Calc -catch - warnlog "something wrong with testing Rectangle" -endcatch - -try - call Make_Make3dObject_From_Application - call Full_test_Draw - call Small_test_Impress - call Small_test_Calc - call Small_test_Writer -catch - warnlog "something wrong with testing 3dObject" -endcatch - -'qaerrorlog "Make_CurveObject_From_Application needs an overview - FHA" -try - call Make_CurveObject_From_Application - call Small_test_Draw - call Small_test_Impress - call Small_test_Calc - call Small_test_Writer -catch - warnlog "something wrong with testing CurveObj" -endcatch - -try - call Make_ConnectorObject_From_Application - call Small_test_Draw - call Small_test_Impress - call Small_test_Calc - call Small_test_Writer -catch - warnlog "something wrong with testing ConnectorObject" -endcatch - -try - call Make_LineObject_From_Application - call Small_test_Draw - call Small_test_Impress - ' call Small_test_Calc - ' call Small_test_Writer -catch - warnlog "something wrong with testing LineObject" -endcatch - -try -catch - warnlog "something wrong with testing ConnectorObject" -endcatch - -try - call Make_Circle_From_Application - call Small_test_Draw - call Small_test_Impress - call Small_test_Calc - call Small_test_Writer -catch - warnlog "something wrong with testing Circle" -endcatch - -try - call Make_TextSquare_From_Application - call Small_test_Draw - call Small_test_Impress - call Small_test_Calc - call Small_test_Writer - -catch - warnlog "something wrong with testing TextSquare" -endcatch - -call clear_all_and_close -Printlog "tClipboardFromDrawTest finished" +sub g_clipexport + try + call Make_Rectangle_From_Application + call Full_test_Draw + call Full_test_Impress + call Full_test_Writer + call Full_test_Calc + catch + warnlog "something wrong with testing Rectangle" + endcatch + + try + call Make_Make3dObject_From_Application + call Full_test_Draw + call Small_test_Impress + call Small_test_Calc + call Small_test_Writer + catch + warnlog "something wrong with testing 3dObject" + endcatch + + 'qaerrorlog "Make_CurveObject_From_Application needs an overview - FHA" + try + call Make_CurveObject_From_Application + call Small_test_Draw + call Small_test_Impress + call Small_test_Calc + call Small_test_Writer + catch + warnlog "something wrong with testing CurveObj" + endcatch + + try + call Make_ConnectorObject_From_Application + call Small_test_Draw + call Small_test_Impress + call Small_test_Calc + call Small_test_Writer + catch + warnlog "something wrong with testing ConnectorObject" + endcatch + + try + call Make_LineObject_From_Application + call Small_test_Draw + call Small_test_Impress + ' call Small_test_Calc + ' call Small_test_Writer + catch + warnlog "something wrong with testing LineObject" + endcatch + + try + catch + warnlog "something wrong with testing ConnectorObject" + endcatch + + try + call Make_Circle_From_Application + call Small_test_Draw + call Small_test_Impress + call Small_test_Calc + call Small_test_Writer + catch + warnlog "something wrong with testing Circle" + endcatch + + try + call Make_TextSquare_From_Application + call Small_test_Draw + call Small_test_Impress + call Small_test_Calc + call Small_test_Writer + + catch + warnlog "something wrong with testing TextSquare" + endcatch + + call clear_all_and_close + Printlog "tClipboardFromDrawTest finished" end sub diff --git a/testautomation/graphics/optional/includes/global/g_clipexport2.inc b/testautomation/graphics/optional/includes/global/g_clipexport2.inc index fae2cdcc7820..44fb7bbd5070 100644 --- a/testautomation/graphics/optional/includes/global/g_clipexport2.inc +++ b/testautomation/graphics/optional/includes/global/g_clipexport2.inc @@ -61,7 +61,7 @@ sub MakeRectangle end sub '------------------------------------------------------------------------------- -sub MakeCircle +testcase MakeCircle printlog "Create Circle" if gApplication = "WRITER" then @@ -81,10 +81,10 @@ sub MakeCircle gMouseUp (30,30) sleep 1 -end sub +endcase '------------------------------------------------------------------------------- -sub Make3dObject +testcase Make3dObject printlog "Create 3dObject" if (Ucase(gApplication) = "CALC") then @@ -158,10 +158,10 @@ sub Make3dObject endif end if -end sub +endcase '------------------------------------------------------------------------------- -sub MakeCurveObject +testcase MakeCurveObject if (Ucase(gApplication) = "WRITER") then warnlog "Cant make circle in this application" @@ -195,10 +195,10 @@ sub MakeCurveObject hMenuItemUnCheck (7) sleep 1 -end sub +endcase '------------------------------------------------------------------------------- -sub MakeLineObject +testcase MakeLineObject if gApplication = "WRITER" then warnlog "Currently no support for line-object in this application" @@ -224,10 +224,10 @@ sub MakeLineObject Kontext "Arrowshapes" Arrowshapes.Close -end sub +endcase '------------------------------------------------------------------------------- -sub MakeConnectorObject +testcase MakeConnectorObject if gApplication = "WRITER" then warnlog "Cant make connector in this application" @@ -268,7 +268,7 @@ sub MakeConnectorObject gMouseUp (30,37) end if -end sub +endcase '------------------------------------------------------------------------------- sub MakeFormattedTextLine diff --git a/testautomation/graphics/optional/includes/global/g_clipexport3.inc b/testautomation/graphics/optional/includes/global/g_clipexport3.inc index 5a6e86ac2a9c..d43cbacb02ec 100644 --- a/testautomation/graphics/optional/includes/global/g_clipexport3.inc +++ b/testautomation/graphics/optional/includes/global/g_clipexport3.inc @@ -48,7 +48,7 @@ Sub Get_Position_Size_Attributes - Printlog " Get_Position_Size_Attributes Starts" + Printlog "Get_Position_Size_Attributes Starts" FormatPositionAndSize @@ -63,7 +63,7 @@ Sub Get_Position_Size_Attributes End Select sleep 1 - ' /// Size-values ///' + printlog "Size-values" PositionWidth = Width.GetText PositionHeight = Height.GetText @@ -86,7 +86,7 @@ Sub Get_Position_Size_Attributes sleep 3 Printlog " Get_Position_Size_Attributes Ends" -end sub +end sub 'Get_Position_Size_Attributes '------------------------------------------------------------------------------- sub Get_Colour_Attributes @@ -100,7 +100,7 @@ sub Get_Colour_Attributes Kontext "TabArea" - ' /// Area ///' + printlog "Area" FillOptions.Select 2 if FillOptions.GetSelIndex <> 2 then Errorlog "Couldnt click on 'Color' in FormatArea" AreaColourListValue = ColourList.GetSelText @@ -273,7 +273,7 @@ sub Get_Colour_Attributes TabArea.Cancel printlog " Get_Colour_Attributes ends" -end sub +end sub 'Get_Colour_Attributes '------------------------------------------------------------------------------- sub Check_Position_Size_Attributes @@ -355,7 +355,7 @@ sub Check_Position_Size_Attributes sleep 3 printlog " Check_Position_Size_Attributes Ends" -end sub +end sub 'Check_Position_Size_Attributes '---------------------------------------------------------------------------------------------------- sub Check_Text_Formatting @@ -412,8 +412,10 @@ sub Check_Text_Formatting SetKontextApplication printlog " Check_Text_Formatting Ends" +end sub 'Check_Text_Formatting + +'------------------------------------------------------------------------------- - '---------------------------------------------------------------------------------------------------- sub Check_Colors_Borders_Attributes printlog " Check_Colors_Borders_Attributes Starts" @@ -425,7 +427,7 @@ sub Check_Colors_Borders_Attributes Active.setpage TabArea Kontext "TabArea" - ' /// Area ///' + printlog "Area" FillOptions.Select 2 if FillOptions.GetSelIndex <> 2 then Errorlog "Couldnt click on 'Color' in FormatArea" @@ -558,26 +560,10 @@ sub Check_Colors_Borders_Attributes ColorModel = Farbmodell.GetSelText printlog " " + ColorModel - select case iSprache ' Prepared for future language-problematics. - if ColorR <> R.GetText then Warnlog "Wrong R-Color. Should be: " + ColorR + " but was: " + R.GetText - if ColorG <> G.GetText then Warnlog "Wrong V-Color. Should be: " + ColorG + " but was: " + G.GetText - if ColorB <> B.GetText then Warnlog "Wrong B-Color. Should be: " + ColorB + " but was: " + B.GetText - Else if ColorC <> C.GetText then Warnlog "Wrong C-Color. Should be: " + ColorC + " but was: " + C.GetText if ColorM <> M.GetText then Warnlog "Wrong M-Color. Should be: " + ColorM + " but was: " + M.GetText if ColorY <> Y.GetText then Warnlog "Wrong J-Color. Should be: " + ColorY + " but was: " + Y.GetText if ColorK <> K.GetText then Warnlog "Wrong N-Color. Should be: " + ColorK + " but was: " + K.GetText - End if - if ColorR <> R.GetText then Warnlog "Wrong R-Color. Should be: " + ColorR + " but was: " + R.GetText - if ColorG <> G.GetText then Warnlog "Wrong G-Color. Should be: " + ColorG + " but was: " + G.GetText - if ColorB <> B.GetText then Warnlog "Wrong B-Color. Should be: " + ColorB + " but was: " + B.GetText - Else - if ColorC <> C.GetText then Warnlog "Wrong C-Color. Should be: " + ColorC + " but was: " + C.GetText - if ColorM <> M.GetText then Warnlog "Wrong M-Color. Should be: " + ColorM + " but was: " + M.GetText - if ColorY <> Y.GetText then Warnlog "Wrong Y-Color. Should be: " + ColorY + " but was: " + Y.GetText - if ColorK <> K.GetText then Warnlog "Wrong K-Color. Should be: " + ColorK + " but was: " + K.GetText - End if - end select Kontext Active.setpage TabFarbverlaeufe @@ -624,7 +610,8 @@ sub Check_Colors_Borders_Attributes Printlog "End of one application" - '---------------------------------- Set the Kontext to the current Application ----------------------------------' +end sub 'Check_Colors_Borders_Attributes + '---------------------------------- Set the Kontext to the current Application ----------------------------------' sub SetKontextApplication sleep 1 @@ -648,7 +635,7 @@ sub SetKontextApplication end select sleep 1 -end sub +end sub 'SetKontextApplication '------------------------- Part with "create new windows" --------------------- sub New_Draw @@ -659,7 +646,7 @@ sub New_Draw Call hNewDocument SetKontextApplication -end sub +end sub 'New_Draw '------------------------------------------------------------------------------- sub New_Impress @@ -671,7 +658,7 @@ sub New_Impress Call hNewDocument SetKontextApplication -end sub +end sub 'New_Impress '------------------------------------------------------------------------------- sub New_Calc @@ -683,7 +670,7 @@ sub New_Calc Call hNewDocument SetKontextApplication -end sub +end sub 'New_Calc '------------------------------------------------------------------------------- sub New_Writer @@ -695,10 +682,10 @@ sub New_Writer Call hNewDocument SetKontextApplication -end sub +end sub 'New_Writer '------------------------------------------------------------------------------- -sub Choose_Toapplication +testcase Choose_Toapplication For ToAppCounter = 1 to 4 @@ -724,6 +711,6 @@ sub Choose_Toapplication Call hNewDocument SetKontextApplication -end sub +endcase 'Choose_Toapplication '-------------------------------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/global/g_convertto.inc b/testautomation/graphics/optional/includes/global/g_convertto.inc index 33eb157bc465..3a829b1ef275 100644 --- a/testautomation/graphics/optional/includes/global/g_convertto.inc +++ b/testautomation/graphics/optional/includes/global/g_convertto.inc @@ -30,15 +30,6 @@ '* short description : '* '************************************************************************************** -' #1 tiAendernUmwandelnInPolygon -' #1 tiModifyConvertToPolygon -' #1 tdContextConvertIntoBitmap -' #1 tiAendernUmwandelnInKurve -' #1 tiAendernUmwandelnInPolygonGrafik -' #1 tiAendernUmwandelnIn3D -' #1 tiAendernUmwandelnIn3DRotationskoerper -' #1 tiAendernUmwandelnInMetaFile -'\************************************************************************************* ' Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\columbia.dxf") ' Call hGrafikEinfuegen ConvertPath ( gTesttoolPath + "global\input\graf_inp\enter.bmp" ) @@ -52,29 +43,29 @@ ' Call tdContextConvertIntoMetaFile testcase tiModifyConvertToPolygon - Dim PosX as string - Dim PosY as string - Dim Maxanzahl as string - Dim Minanzahl as string + Dim PosX as string + Dim PosY as string + Dim Maxanzahl as string + 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 - hTypeKeys "<Escape>" - sleep 1 - EditSelectAll - sleep 1 - ContextConvertIntoPolygon - sleep 1 - ContextPositionAndSize - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - PosX = Width.GetText - PosY = Height.GetText - TabPositionAndSize.OK + 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 + hTypeKeys "<Escape>" + sleep 1 + EditSelectAll + sleep 1 + ContextConvertIntoPolygon + sleep 1 + ContextPositionAndSize + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + PosX = Width.GetText + PosY = Height.GetText + TabPositionAndSize.OK sleep 1 FormatCharacter Kontext @@ -120,7 +111,7 @@ testcase tiModifyConvertToPolygon Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" - '/// compare width and heigth to control is it is still text ///' + printlog "compare width and heigth to control is it is still text" if ( Width.GetText = PosX or Height.GetText = PosY ) Then Printlog "- Text converted into polygon" else @@ -133,7 +124,7 @@ testcase tiModifyConvertToPolygon Call hNewDocument sleep 3 - '/// insert graphic (input\\impress\\grafik\\sample.bmp)///' + printlog "insert graphic (input\\impress\\grafik\\sample.bmp)" Call hGrafikEinfuegen ConvertPath ( gTesttoolPath + "global\input\graf_inp\enter.bmp" ) sleep 3 ContextConvertIntoPolygon @@ -142,9 +133,11 @@ testcase tiModifyConvertToPolygon MaxAnzahl = Farbanzahl.GetText Farbanzahl.More 1 If Maxanzahl < Farbanzahl.GetText Then Warnlog "- Maximum value could be raised." - Farbanzahl.ToMin '/// set color to min ///' + printlog "set color to min" + Farbanzahl.ToMin MinAnzahl = Farbanzahl.GetText - Farbanzahl.Less 1 '/// try to set a value lower than minimum ///' + printlog "try to set a value lower than minimum" + Farbanzahl.Less 1 If Farbanzahl.GetText < Minanzahl then Warnlog "- Minimum value could be lowered." Farbanzahl.SetText "2" Vorschau.Click @@ -166,18 +159,20 @@ endcase 'tiModifyConvertToPolygon '-------------------------------------------------------- testcase tdContextConvertIntoBitmap - Call hNewDocument '/// new document ///' - sleep 3 - InsertGraphicsFromFile '/// insert graphic ///' - sleep 3 - kontext "Active" + printlog "new document" + Call hNewDocument + sleep 3 + printlog "insert graphic" + InsertGraphicsFromFile + sleep 3 + kontext "Active" if Active.Exists Then - Active.OK + Active.OK end if - sleep 5 - Kontext "GrafikEinfuegenDlg" - sleep 2 -'/// uses input\\impress\\grafik\\columbia.dxf /// + sleep 5 + Kontext "GrafikEinfuegenDlg" + sleep 2 +printlog " uses input\impress\grafik\columbia.dxf" Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\columbia.dxf") sleep 2 Oeffnen.Click @@ -192,44 +187,53 @@ testcase tdContextConvertIntoBitmap end if Kontext "DocumentImpress" try - ContextConvertIntoBitmap '/// convert dxf file to bitmap ///' + printlog "convert dxf file to bitmap" + ContextConvertIntoBitmap sleep 1 Printlog "- Convert into bitmap works" catch Warnlog "- Convert into bitmap does not work" endcatch - sleep 2 - Call hCloseDocument '/// close document ///' - + sleep 2 + printlog "close document" + Call hCloseDocument + endcase 'tdContextConvertIntoBitmap '-------------------------------------------------------- testcase tiAendernUmwandelnInKurve Printlog " ----- ContextConvertIntoCurve testen" - - Call hNewDocument '/// New impress document///' + printlog "New impress document" + Call hNewDocument Call sSelectEmptyLayout - Call hTextrahmenErstellen ("I test,test,test,test only, if it works for you",20,20,60,30) '/// create textbox///' - sleep 2 - Kontext "DocumentImpress" - gMouseDoubleClick 70,70 '/// deselect textbox ///' - sleep 2 - EditSelectAll '/// select textbox ///' - sleep 2 - ContextConvertIntoCurve '/// convert into curve ///' - sleep 3 - gMouseClick 30,15 + printlog "create textbox" + Call hTextrahmenErstellen ("I test,test,test,test only, if it works for you",20,20,60,30) + sleep 2 + Kontext "DocumentImpress" + printlog "deselect textbox " + gMouseDoubleClick 70,70 + sleep 2 + printlog "select textbox " + EditSelectAll + sleep 2 + printlog "convert into curve " + ContextConvertIntoCurve + sleep 3 + gMouseClick 30,15 - hTypeKeys "<SHIFT RIGHT>",3 '/// try to select 3 letters ///' + printlog "try to select 3 letters " + hTypeKeys "<SHIFT RIGHT>",3 try - EditCopy '/// try edit copy to check if its still text ///' + printlog "try edit copy to check if its still text " + EditCopy Warnlog " - Convert into curve, seperate letters should not be selectable anymore" catch Printlog " - Text converted into a curve" endcatch - Call hCloseDocument '/// close document ///' + printlog "close document " + Call hCloseDocument endcase 'tiAendernUmwandelnInKurve '-------------------------------------------------------- @@ -237,13 +241,15 @@ testcase tiAendernUmwandelnInPolygonGrafik Printlog "- Context/ConvertIntoPolygon" - Call hNewDocument '/// new document ///' + printlog "new document " + Call hNewDocument Call sSelectEmptyLayout - InsertGraphicsFromFile '/// insert graphic (desp.bmp) ///' + printlog "insert graphic (desp.bmp) " + InsertGraphicsFromFile Kontext "GrafikEinfuegenDlg" - '///use graphic : input\\impress\\grafik\\desp.bmp /// + printlog "use graphic : input\impress\grafik\desp.bmp" Dateiname.SetText ConvertPath ( gTesttoolPath + "global\input\graf_inp\desp.bmp" ) Oeffnen.Click sleep 3 @@ -251,53 +257,66 @@ testcase tiAendernUmwandelnInPolygonGrafik EditSelectAll sleep 1 - ContextConvertIntoPolygon '/// convert into polygon ///' + printlog " convert into polygon " + ContextConvertIntoPolygon Kontext "UmwandelnInPolygon" Printlog "- Testing vectorize dialog" - Farbanzahl.ToMax '/// set number of colors to max ///' + printlog "set number of colors to max" + Farbanzahl.ToMax if Farbanzahl.GetText <> "32" Then Warnlog "- Maximum value for color depth should be 32, but it is: " + Farbanzahl.GetText - Farbanzahl.ToMin '/// set number of colors to min ///' + printlog "set number of colors to min" + Farbanzahl.ToMin sleep 1 if Farbanzahl.GetText <> "8" Then Warnlog "- Minimum value for color depth should be 8 but it is: " + Farbanzahl.GetText sleep 2 - Punktreduktion.SetText "50" '/// set point reduction to 50 ///' + printlog "set point reduction to 50 " + Punktreduktion.SetText "50" sleep 2 if Punktreduktion.GetText <> "32 Pixel" Then Warnlog "- Maximum value should be 32, but it is: " + Punktreduktion.GetText sleep 1 - Punktreduktion.SetText "-50" '/// set an out of range value ///' + printlog "set an out of range value" + Punktreduktion.SetText "-50" sleep 1 if Punktreduktion.GetText <> "0 Pixel" Then Warnlog "- Minimum value should be 0, but it is: " + Punktreduktion.GetText - Loecherfuellen.Uncheck '/// uncheck fill holes ///' + printlog "uncheck fill holes" + Loecherfuellen.Uncheck if Not Kachelgroesse.IsEnabled Then Printlog "- Control disabled." else Warnlog "- Control should be disabled if Fill is not checked." end if - Vorschau.Click '/// open preview ///' + printlog "open preview" + Vorschau.Click sleep 2 - UmwandelnInPolygon.OK '/// close dialog ///' + printlog "close dialog " + UmwandelnInPolygon.OK sleep 5 - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endcase 'tiAendernUmwandelnInPolygonGrafik '-------------------------------------------------------- testcase tiAendernUmwandelnIn3D Printlog "- Convert into 3D" - Call hNewDocument - sleep 1 '/// new impress document ///' - hRechteckErstellen (10,10,40,40) '/// create rectangle ///' - '/// convert into 3D ///' + printlog "new impress document " + Call hNewDocument + sleep 1 + printlog "create rectangle" + hRechteckErstellen (10,10,40,40) + printlog "convert into 3D " sleep 2 gMouseclick 35,35 sleep 1 try - ContextConvertInto3D '/// try to access convert ito 3d a 2nd time, should be impossible using a 3d object as source ///' + printlog "try to access convert ito 3d a 2nd time, should be impossible using a 3d object as source " + ContextConvertInto3D Printlog "- Convert into 3D works" catch Warnlog "- Convert into 3D does not work" endcatch - Call hCloseDocument '/// close document '/// + printlog "close document" + Call hCloseDocument endcase 'tiAendernUmwandelnIn3D '-------------------------------------------------------- @@ -307,11 +326,14 @@ testcase tiAendernUmwandelnIn3DRotationskoerper Dim PosX Dim PosY - Call hNewDocument '/// new document '/// + printlog "new document" + Call hNewDocument Kontext "DocumentImpress" - hRechteckErstellen (20,20,50,50) '/// create rectangle ///' + printlog "create rectangle" + hRechteckErstellen (20,20,50,50) sleep 1 - ContextPositionAndSize '/// get position values for the rectangle ///' + printlog "get position values for the rectangle " + ContextPositionAndSize Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" @@ -320,26 +342,31 @@ testcase tiAendernUmwandelnIn3DRotationskoerper TabPositionAndSize.OK sleep 1 Kontext "DocumentImpress" - ContextConvertInto3DRotationObject '/// convert into 3d lathe object ///' + printlog "convert into 3d lathe object" + ContextConvertInto3DRotationObject sleep 2 ContextPositionAndSize Kontext - Active.SetPage TabPositionAndSize '/// control changes in position values to confirm convert action ///' + printlog "control changes in position values to confirm convert action" + Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" if PositionX.GetText = PosX and PositionY.GetText = PosY Then Warnlog "- No change in position or dimension, converting seemd not to work" TabPositionAndSize.OK sleep 1 - Call hCloseDocument '/// close document ///' + printlog "close document " + Call hCloseDocument endcase 'tiAendernUmwandelnIn3DRotationskoerper '-------------------------------------------------------- testcase tiAendernUmwandelnInMetaFile Printlog "- ConvertIntoMetaFile" - - Call hNewDocument '/// new document ///' + + printlog "new document " + Call hNewDocument sleep 3 - InsertGraphicsFromFile '/// insert graphic ///' + printlog "insert graphic" + InsertGraphicsFromFile sleep 1 kontext "Active" sleep 1 @@ -349,21 +376,21 @@ testcase tiAendernUmwandelnInMetaFile sleep 1 Kontext "GrafikEinfuegenDlg" sleep 2 - '/// uses input\\impress\\grafik\\desp.gif") /// + printlog " uses input\impress\grafik\desp.gif" Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\purzel.gif") sleep 2 Oeffnen.Click sleep 5 Kontext "DocumentImpress" try - ContextConvertIntoMetafile '/// convert bitmap into metafile ///' + printlog "convert bitmap into metafile" + ContextConvertIntoMetafile sleep 2 Printlog "- Convert into Metafile does work" catch Warnlog "- Convert into Metafile does not work" endcatch sleep 2 - Call hCloseDocument '/// close document ///' - -endcase 'tiAendernUmwandelnInMetaFile - + printlog "close document" + Call hCloseDocument +endcase 'tiAendernUmwandelnInMetaFile
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_crossfading.inc b/testautomation/graphics/optional/includes/global/g_crossfading.inc index 0d7142b9ae46..e9df826aaff9 100644 --- a/testautomation/graphics/optional/includes/global/g_crossfading.inc +++ b/testautomation/graphics/optional/includes/global/g_crossfading.inc @@ -43,39 +43,47 @@ testcase tCrossfading dim CounterForX as integer dim anothercounter as integer + printlog "New Impress document" Call hNewDocument - Call sSelectEmptyLayout '/// New Impress document ///' + Call sSelectEmptyLayout gMouseClick 50,50 - sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + sleep 1 + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - sleep 1 - EditSelectAll '/// Select all ///' - sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + sleep 1 + printlog "Select all" + EditSelectAll + sleep 1 + printlog "Choose Edit / CrossFading" + EditCrossFading kontext "Ueberblenden" - X = Schritte.GetText ' /// Get counter-value and save it in X ///' + printlog "Get counter-value and save it in X" + X = Schritte.GetText printlog "Steps before we start the test: " + X printlog "Schritte.GetText= " + Schritte.GetText Schritte.ToMin if Schritte.GetText <> "1" then qaerrorlog "Could not change the step-number to 1." - - for I = 2 to 10 ' /// How many steps do you want? ///' + printlog "How many steps do you want?" + for I = 2 to 10 Schritte.More 1 if Schritte.GetText <> I then qaerrorlog "Could not change the step-number to" + I Ueberblenden.OK sleep 1 try - FormatUngroupDraw '/// open context menu and ungroup objects ///' + printlog "open context menu and ungroup objects" + FormatUngroupDraw catch qaerrorlog "Could not ungroup objects" endcatch sleep 1 - hTypeKeys "<TAB>" '/// Should make the first object active ///' + printlog "Should make the first object active" + hTypeKeys "<TAB>" - '/// Get position and dimensions of elements ///' + printlog "Get position and dimensions of elements" try ContextPositionAndSize catch @@ -88,62 +96,76 @@ testcase tCrossfading if TabPositionAndSize.exists (5) then CounterForX=0 CheckX=0 - FirstX=PositionX.GetText '/// Tet Dimensions of first object ///' + printlog "Tet Dimensions of first object" + FirstX=PositionX.GetText TabPositionAndSize.OK else qaerrorlog "Couldn't switch tab page :-( " endif + printlog "How many objects we have on the screen" + anothercounter = I+2 -anothercounter = I+2 '/// How many objects we have on the screen ///' - - for Y = 1 to anothercounter '/// How many times we should step to (hopefully) get back to the first one ///' + printlog "How many times we should step to (hopefully) get back to the first one" + for Y = 1 to anothercounter if Y > anothercounter then warnlog "Too many steps, something is wrong." try - hTypeKeys "<TAB>" '/// Step to the next object ///' + printlog "Step to the next object" + hTypeKeys "<TAB>" catch errolog "Could not step to the next object" endcatch ' Printlog "- Get position and dimensions of elements" - ContextPositionAndSize '/// Open Position and Size for this object ///' + printlog "Open Position and Size for this object" + ContextPositionAndSize sleep 1 Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" - CheckX=PositionX.GetText '/// Get Position X for this object ///' + printlog "Get Position X for this object" + CheckX=PositionX.GetText sleep 1 TabPositionAndSize.OK Kontext "DocumentDraw" - CounterForX=CounterForX+1 '/// Up one on the object-counter ///' - if CheckX=FirstX then '/// Check if Position is the same as the first one ///' + printlog "Up one on the object-counter" + CounterForX=CounterForX+1 + printlog "Check if Position is the same as the first one" + if CheckX=FirstX then if anothercounter = CounterForX then printlog "The first box is at: " + CheckX + " And we're now at " + FirstX + " = Correct steps between the objects, everything's fine." - printlog "We should have " + Y + " objects to go through." '/// Just here for debugging. - FHA -' printlog "anothercounter= " + anothercounter '/// Just here for debugging. - FHA + printlog "We should have " + Y + " objects to go through." printlog "Number of objects: " + anothercounter printlog "" endif - next Y '/// End or go on with the checking-loop ///' - - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + printlog "End or go on with the checking-loop" + next Y + printlog "Select all" + EditSelectAll + printlog "Delete all" + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" +Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) sleep 1 - EditSelectAll '/// Select all ///' + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' - sleep 2 - kontext "Ueberblenden" + printlog "Choose Edit / CrossFading" + EditCrossFading + sleep 2 + kontext "Ueberblenden" next I - '/// And now we're gonna check if we can separate the object into it's parts ///' - '/// And check if the numbers of steps / objects is correct ///' + printlog "And now we're gonna check if we can separate the object into it's parts" + printlog "And check if the numbers of steps / objects is correct" - Schritte.ToMin '/// Select minimum value for number of steps ///' + printlog "Select minimum value for number of steps" + Schritte.ToMin for Z = 1 to X -1 - Schritte.More '/// Raise the value for number of steps with one ///' + printlog "Raise the value for number of steps with one" + Schritte.More next Z printlog "Value has been restored to: " + Schritte.GetText printlog "X is now: " + X @@ -151,101 +173,149 @@ anothercounter = I+2 '/// How many objects we have on the screen ///' Ueberblenden.OK sleep 1 Kontext "DocumentDraw" - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + printlog "Select all" + EditSelectAll + printlog "Delete all" + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// Create second rectangle ///' - EditSelectAll '/// Select all ///' + printlog "Create second rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading Kontext "Ueberblenden" if Attributierung.IsChecked = TRUE then qaerrorlog "Attributierung / was NOT unchecked." - GleicheOrientierung.UnCheck '/// Uncheck "same orienation" ///' -???? - Ueberblenden.OK '/// Close CrossFading-window with "OK" ///' + printlog "Uncheck same orienation" + GleicheOrientierung.UnCheck + printlog "Close CrossFading-window with OK" + Ueberblenden.OK sleep 1 Kontext "DocumentDraw" - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + printlog "Select all" + EditSelectAll + printlog "Delete all" + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - EditSelectAll '/// Select all ///' + printlog "create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading Kontext "Ueberblenden" if GleicheOrientierung.IsChecked = TRUE then qaerrorlog "GleicheOrientierung / was NOT unchecked." - Attributierung.Check '/// Check "Attributing" ///' - ??? - Ueberblenden.OK '/// Close CrossFading-window with "OK" ///' + printlog "Check Attributing" + Attributierung.Check + printlog "Close CrossFading-window with OK" + Ueberblenden.OK sleep 1 Kontext "DocumentDraw" - EditSelectAll '/// Select all ///' + printlog "Select all" + EditSelectAll sleep 1 - EditDelete '/// Delete all ///' + printlog "Delete all" + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// Create second rectangle ///' - EditSelectAll '/// Select all ///' + printlog "Create second rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading Kontext "Ueberblenden" if Attributierung.IsChecked = FALSE then qaerrorlog "Attributierung / was NOT checked again." - GleicheOrientierung.UnCheck '/// Check "same orientation" ///' -???? + printlog "Check same orientation" + GleicheOrientierung.UnCheck Ueberblenden.OK sleep 1 Kontext "DocumentDraw" - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + printlog "Select all" + printlog "Delete all" + EditSelectAll + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - EditSelectAll '/// Select all ///' + printlog "create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading Kontext "Ueberblenden" - if GleicheOrientierung.IsChecked = TRUE then qaerrorlog "GleicheOrientierung / was NOT checked again." - GleicheOrientierung.Check '/// Check "same orientation" ///' -???? - Ueberblenden.OK '/// Close CrossFading-window with "OK" ///' + if GleicheOrientierung.IsChecked = TRUE then qaerrorlog "GleicheOrientierung / was NOT checked again." + printlog "Check same orientation" + GleicheOrientierung.Check + printlog "Close CrossFading-window with OK" + Ueberblenden.OK sleep 1 Kontext "DocumentDraw" - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Select all" + EditSelectAll + printlog "Delete all" + EditDelete + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - EditSelectAll '/// Select all ///' + printlog "create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + printlog "Select all" + EditSelectAll sleep 1 - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading Kontext "Ueberblenden" if GleicheOrientierung.IsChecked = FALSE then qaerrorlog "GleicheOrientierung / was NOT checked again." - GleicheOrientierung.Check '/// Check "same orientation" ///' -???? - Ueberblenden.OK '/// Close CrossFading-window with "OK" ///' + printlog "Check same orientation" + GleicheOrientierung.Check + printlog "Close CrossFading-window with OK" + Ueberblenden.OK sleep 1 - - Kontext "DocumentDraw" '/// EditCrossFading should not be enabled if more than two objects is selected. ///' - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + + printlog "EditCrossFading should not be enabled if more than two objects is selected." + Kontext "DocumentDraw" + printlog "Select all" + EditSelectAll + printlog "Delete all" + EditDelete sleep 1 - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' + printlog "Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) gMouseClick 90,90 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// Create second rectangle ///' + printlog "Create second rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) gMouseClick 90,90 - Call hRechteckErstellen ( 20, 20, 50, 50 ) '/// Create third rectangle ///' + printlog "Create third rectangle" + Call hRechteckErstellen ( 20, 20, 50, 50 ) sleep 1 - EditSelectAll '/// Select all ///' + printlog "Select all" + EditSelectAll sleep 1 try - EditCrossFading '/// Choose Edit / CrossFading ///' + printlog "Choose Edit / CrossFading" + EditCrossFading sleep 2 If active = "Ueberblenden" then qaerrorlog "CrossFading should NOT be selectable since more than two objects is selected." kontext "Ueberblenden" - Ueberblenden.CANCEL '/// Close CrossFading-window with "CANCEL" ///' + printlog "Close CrossFading-window with CANCEL" + Ueberblenden.CANCEL endif sleep 2 Kontext "DocumentDraw" @@ -254,14 +324,17 @@ anothercounter = I+2 '/// How many objects we have on the screen ///' endcatch try - EditSelectAll '/// Select all ///' - EditDelete '/// Delete all ///' + EditSelectAll + EditSelectAll + printlog "Delete all" + EditDelete catch warnlog "Could not select and delete all objects." endcatch printlog "End of test" - Call hCloseDocument '/// Close document ///' + printlog "Close document" + Call hCloseDocument -endcase 'tCrossfading +endcase 'tCrossfading
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_customshapes.inc b/testautomation/graphics/optional/includes/global/g_customshapes.inc index 28c2e22ed301..1a38090914e6 100644 --- a/testautomation/graphics/optional/includes/global/g_customshapes.inc +++ b/testautomation/graphics/optional/includes/global/g_customshapes.inc @@ -38,20 +38,19 @@ testcase tCustomshapes dim counter as Integer dim MakeInto3Dcounter as Integer - '/// Create new document ///' + printlog "Create new document " Call hNewDocument Call sSelectEmptyLayout - if gApplication = "DRAW" then + if gApplication = "DRAW" then Kontext "Documentdraw" - else '(Impress) + else '(Impress) Kontext "DocumentImpress" - endif - kontext "Toolbar" - sleep 1 - printlog "insert a Smiley." - '/// From the toolbar: Insert three objects: ///' - '/// insert a Smiley. ///' - kontext "Toolbar" + endif + kontext "Toolbar" + sleep 1 + printlog "From the toolbar: Insert three objects: " + printlog "1st: insert a Smiley. " + kontext "Toolbar" if Toolbar.Exists then if Toolbar.IsVisible then sleep 1 @@ -73,17 +72,15 @@ testcase tCustomshapes kontext "SymbolShapes" SymbolShapes.Close - '/// Unmark all objects ///' + printlog "Unmark all objects " hTypeKeys "<ESCAPE>" - '/// Mark the Smiley ///' + printlog "Mark the Smiley " hTypeKeys "<TAB>" printlog "Rename the object to 'First'." - '/// Rename the object to 'First' ///" hOpenContextMenu sleep 2 - 'Choose rename. if hMenuFindSelect(27027, true, 15) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -93,11 +90,9 @@ testcase tCustomshapes NameField.SetText "First" NameDlgObject.OK - printlog "Set the object -Title/Description to 'SecondTitle' and 'SecondText'" - '/// Open the Context-menu and set the description of the object to 'First' ///" + printlog "Open the Context-menu and set the description of the object to 'First'" hOpenContextMenu sleep (2) - 'Choose "Description" if hMenuFindSelect(27033, true, 14) = false then Warnlog "Context-Menu-entry `Description` was not found. Therefore the test ends." Call hCloseDocument @@ -115,8 +110,7 @@ testcase tCustomshapes endif gMouseClick 90, 90 - printlog "Insert a Triangle." - '/// Insert a Triangle ///' + printlog "2nd: Insert a Triangle " kontext "Toolbar" if Toolbar.Exists then if Toolbar.IsVisible then @@ -138,16 +132,14 @@ testcase tCustomshapes BasicShapes.Close sleep 1 - '/// Unmark all objects ///' + printlog "Unmark all objects " hTypeKeys "<ESCAPE>" - '/// Mark the Triangle ///' + printlog "Mark the Triangle " hTypeKeys "<TAB>", 2 - printlog "Rename the object into 'Second'." - '/// Rename the object into 'Second'. ///' + printlog "Rename the object into 'Second'. " hOpenContextMenu sleep 2 - 'Choose rename. if hMenuFindSelect(27027, true, 15) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -159,11 +151,9 @@ testcase tCustomshapes NameField.SetText "Second" NameDlgObject.OK - printlog "Set the object -Title/Description to 'SecondTitle' and 'SecondText'." - '/// Open the Context-menu and set the description of the object to 'SecondTitle' and 'SecondText' ///" + printlog "Open the Context-menu and set the description of the object to 'SecondTitle' and 'SecondText'" hOpenContextMenu sleep (2) - 'Choose "Description" if hMenuFindSelect(27033, true, 14) = false then Warnlog "Context-Menu-entry `Description` was not found. Therefore the test ends." Call hCloseDocument @@ -181,14 +171,13 @@ testcase tCustomshapes endif gMouseClick 90, 90 - printlog "Insert Thinking-cloud." - '/// Insert Thinking-cloud. ///' + printlog "3rd: Insert Thinking-cloud." kontext "Toolbar" if Toolbar.Exists then if Toolbar.IsVisible then sleep 1 try - CalloutShapes.TearOff ' insert Thinking-cloud + CalloutShapes.TearOff catch warnlog "bug for GH from FHA; .tearoff doesnt tell success" endcatch @@ -206,16 +195,14 @@ testcase tCustomshapes Callouts.Close sleep 1 - '/// Unmark all objects ///' + printlog "Unmark all objects " hTypeKeys "<ESCAPE>" - '/// Mark the cloud ///' + printlog "Mark the cloud " hTypeKeys "<TAB>", 3 - printlog "Rename the object to 'Third'." - '/// Rename the object to 'Third'. ///' + printlog "Rename the object to 'Third'. " hOpenContextMenu sleep 2 - 'Choose rename. if hMenuFindSelect(27027, true, 15) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -225,11 +212,9 @@ testcase tCustomshapes NameField.SetText "Third" NameDlgObject.OK - printlog "Set the object -Title/Description to 'ThirdTitle' and 'ThirdText'." - '/// Open the Context-menu and set the description of the object to 'First' ///" + printlog "Open the Context-menu and set the description of the object to 'First'" hOpenContextMenu sleep (2) - 'Choose "Description" if hMenuFindSelect(27033, true, 14) = false then Warnlog "Context-Menu-entry `Description` was not found. Therefore the test ends." Call hCloseDocument @@ -247,8 +232,7 @@ testcase tCustomshapes endif gMouseClick 90, 90 - printlog "Change all objects into 3D." - '/// Change all objects into 3D. ///' + printlog "Change all objects into 3D. " if gApplication = "DRAW" then Kontext "Documentdraw" else '(Impress) @@ -294,9 +278,8 @@ testcase tCustomshapes hTypeKeys "<ESCAPE>" Next MakeInto3Dcounter - printlog "See if the objects still are Custom Shapes." - '/// See if the objects still are Custom Shapes ///' - '/// We do so by moving the lower part of the the thinking-cloud. ///' + printlog "See if the objects still are Custom Shapes " + printlog "We do so by moving the lower part of the the thinking-cloud. " gMouseClick 90, 1 hTypeKeys "<TAB><TAB><TAB>" @@ -313,8 +296,7 @@ testcase tCustomshapes gMouseClick 90, 1 hTypeKeys "<TAB>" - printlog "Check the name of the selected object (should be 'First')" - '/// Check the name of the selected object (should be 'First') ///' + printlog "Check the name of the selected object (should be 'First') " hOpenContextMenu sleep 2 'Choose rename. @@ -334,7 +316,6 @@ testcase tCustomshapes NameDlgObject.OK printlog "Open the Context-menu and check if the description of the object is right" - '/// Open the Context-menu and check if the description of the object is right ///" hOpenContextMenu sleep (2) 'Choose "Description" @@ -363,10 +344,9 @@ testcase tCustomshapes gMouseClick 90, 1 hTypeKeys "<TAB><TAB>" - '/// Check the name of the selected object (should be 'Second') ///' + printlog "Check the name of the selected object (should be 'Second') " hOpenContextMenu sleep 2 - '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 +363,6 @@ testcase tCustomshapes NameDlgObject.OK printlog "Open the Context-menu and check if the description of the object is right" - '/// Open the Context-menu and check if the description of the object is right ///" hOpenContextMenu sleep (2) 'Choose "Description" @@ -416,7 +395,7 @@ testcase tCustomshapes gMouseClick 90, 1 hTypeKeys "<TAB><TAB><TAB>" - '/// Check the name of the selected object (should be "Third") ///' + printlog "Check the name of the selected object (should be Third) " hOpenContextMenu sleep 2 'Choose rename. @@ -436,7 +415,6 @@ testcase tCustomshapes NameDlgObject.OK printlog "Open the Context-menu and check if the description of the object is right" - '/// Open the Context-menu and check if the description of the object is right ///" hOpenContextMenu sleep (2) 'Choose "Description" @@ -468,14 +446,14 @@ testcase tCustomshapes endif printlog "End of test. Close the document." - Call hCloseDocument '/// Close Document ///' + Call hCloseDocument endcase 'tCustomshapes '--------------------------------------------------------- testcase tFormatPaintbrush dim counter, ZaehlerVerlauf, j as Integer - '/// Hatching ///' + printlog "Hatching " dim HatchingDistance as string dim HatchingAngle as string dim HatchingLineType as string @@ -524,23 +502,24 @@ testcase tFormatPaintbrush dim front_value as string dim background_value as string - '/// Create new document ///' + printlog "Create new document " Call hNewDocument - '/// Create a new rectangle ///' + printlog "Create a new rectangle " hRechteckErstellen ( 10, 10, 30, 30 ) FormatArea - '/// Switch to Tabpage "Area" ///' + printlog "Switch to Tabpage Area " Kontext Active.SetPage TabArea Kontext "TabArea" sleep 1 - FillOptions.Select 4 '/// Select hatching, control after closing and reopening dialog if changes are recognized ///' - '/// Switch to Tabpage "Hatching" ///' + printlog "Select hatching, control after closing and reopening dialog if changes are recognized " + FillOptions.Select 4 + printlog "Switch to Tabpage Hatching " Kontext Active.setpage TabSchraffuren Kontext "TabSchraffuren" - '/// Get the values for the Rectangle ///' + printlog "Get the values for the Rectangle " HatchingDistance = Abstand.GetText HatchingAngle = Winkel.GetText 'Definition @@ -551,7 +530,7 @@ testcase tFormatPaintbrush sleep 1 ' FormatArea - '/// Switch to Tabpage "Shaddow" ///' + printlog "Switch to Tabpage Shaddow " Kontext Active.setpage TabSchatten Kontext "TabSchatten" @@ -565,7 +544,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Transparency" ///' + printlog "Switch to Tabpage Transparency " Kontext Active.SetPage TabTransparenz Kontext "TabTransparenz" @@ -583,7 +562,7 @@ testcase tFormatPaintbrush MFEnd_value = MFEndwert.GetText sleep 1 - '/// Switch to Tabpage "Color" ///' + printlog "Switch to Tabpage Color " Kontext Active.setpage TabFarben Kontext "TabFarben" @@ -603,7 +582,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Gradient" ///' + printlog "Switch to Tabpage Gradient " Kontext Active.setpage TabFarbverlaeufe Kontext "TabFarbverlaeufe" @@ -619,7 +598,7 @@ testcase tFormatPaintbrush tovalue_value = BisWert.GetText sleep 1 - '/// Switch to Tabpage "Bitmap" ///' + printlog "Switch to Tabpage Bitmap " Kontext Active.setpage TabBitmap Kontext "TabBitmap" @@ -627,11 +606,11 @@ testcase tFormatPaintbrush front_value = Vordergrund.GetSelText background_value = Hintergrund.GetSelText sleep 1 - '/// Close the FormatArea-dialogue with "OK" ///' + printlog "Close the FormatArea-dialogue with OK " TabBitmap.OK sleep 2 - '/// Create a second rectangle, and use the "Paintbrush-icon" to copy the settings for the first rectangle onto the new one ///' + printlog "Create a second rectangle, and use the Paintbrush-icon to copy the settings for the first rectangle onto the new one " hRechteckErstellen ( 70, 70, 90, 90 ) if gApplication = "DRAW" then kontext "Documentdraw" @@ -659,21 +638,23 @@ testcase tFormatPaintbrush sleep 1 endif - '/// Check if the Formatting is like the first one. ///' + printlog "Check if the Formatting is like the first one. " FormatArea - '/// Switch to Tabpage "Area" ///' + printlog "Switch to Tabpage Area " Kontext Active.SetPage TabArea Kontext "TabArea" -' if FillOptions.GetSelIndex <> 4 then '/// The selected value should be 'no fill' ///' +' if FillOptions.GetSelIndex <> 4 then printlog "The selected value should be 'no fill' " ' warnlog "The FillOptions-value was not transferred correctly." ' else ' printlog "The FillOptions-value was transferred correctly." ' endif - sleep 1 '/// control if changes are still there after closing and reopening dialog ///' - FillOptions.Select 4 '/// Select hatching, control after closing and reopening dialog if changes are recognized ///' - '/// Switch to Tabpage "Hatching" ///' + sleep 1 + printlog "control if changes are still there after closing and reopening dialog " + FillOptions.Select 4 + printlog "Select hatching, control after closing and reopening dialog if changes are recognized " + printlog "Switch to Tabpage Hatching " kontext Active.setpage TabSchraffuren kontext "TabSchraffuren" @@ -693,7 +674,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Shaddow" ///' + printlog "Switch to Tabpage Shaddow " Kontext Active.setpage TabSchatten Kontext "TabSchatten" @@ -718,7 +699,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Transparency" ///' + printlog "Switch to Tabpage Transparency " Kontext Active.SetPage TabTransparenz Kontext "TabTransparenz" @@ -757,7 +738,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Color" ///' + printlog "Switch to Tabpage Color " Kontext Active.setpage TabFarben Kontext "TabFarben" @@ -798,7 +779,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Gradient" ///' + printlog "Switch to Tabpage Gradient " Kontext Active.setpage TabFarbverlaeufe Kontext "TabFarbverlaeufe" @@ -831,7 +812,7 @@ testcase tFormatPaintbrush endif sleep 1 - '/// Switch to Tabpage "Bitmap" ///' + printlog "Switch to Tabpage Bitmap " Kontext Active.setpage TabBitmap Kontext "TabBitmap" @@ -843,6 +824,7 @@ testcase tFormatPaintbrush endif sleep 1 TabBitmap.OK - Call hCloseDocument '/// Close Document ///' + printlog "Close Document " + Call hCloseDocument endcase 'tFormatPaintbrush diff --git a/testautomation/graphics/optional/includes/global/g_demoguide.inc b/testautomation/graphics/optional/includes/global/g_demoguide.inc index d733c878aeb4..0860e8cb942a 100644 --- a/testautomation/graphics/optional/includes/global/g_demoguide.inc +++ b/testautomation/graphics/optional/includes/global/g_demoguide.inc @@ -41,12 +41,10 @@ testcase t_Introduction gApplication = "IMPRESS" - '///Open new presentation printlog "Open new presentation" Call hNewDocument Call sSelectEmptyLayout - '///Open the Gallery printlog "Open the Gallery" ToolsGallery Sleep (1) @@ -55,7 +53,6 @@ testcase t_Introduction ToolsGallery end if - '///Choose computer theme and insert the third image printlog "Choose an item from the gallery" Gallerys.Select(2) View.TypeKeys "<HOME><RIGHT><RIGHT>" @@ -65,7 +62,7 @@ testcase t_Introduction 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 @@ -93,15 +90,16 @@ testcase t_Introduction catch Warnlog "Insert graphic doesn't work" endcatch - - '///Resize object + sleep 5 + printlog "Resize object" Kontext "DocumentImpress" gMouseClick (10, 10) sleep 1 EditSelectAll sleep 1 - ContextPositionAndSize '/// Format-position and size + printlog "Format-position and size" + ContextPositionAndSize Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" @@ -111,7 +109,6 @@ testcase t_Introduction Width.SetText CStr((CInt(Width.GetText)) * 2) TabPositionAndSize.OK - '///Break object printlog "Break object" Kontext "DocumentImpress" gMouseClick (10, 10) @@ -120,7 +117,6 @@ testcase t_Introduction sleep 1 hOpenContextMenu '(when the object is marked) hMenuSelectNr(13) - '/// Select part of object and make it black printlog "Select part of object and make it black" DocumentImpress.TypeKeys "<SHIFT TAB>" FormatArea @@ -131,14 +127,12 @@ testcase t_Introduction ColourList.Select 1 TabArea.OK - '///Group the objects printlog "Group the object" kontext "DocumentImpress" DocumentImpress.TypeKeys "<MOD1 A>" hOpenContextMenu '(when the object is marked) hMenuSelectNr(12) - '///Add Layout "Title Only" Printlog "Add Layout" kontext "Tasks" if (NOT Tasks.exists) then @@ -146,19 +140,18 @@ testcase t_Introduction ViewTaskPane endif - ' enable all items in the task pane. - ' may be one item is not enabled due to a previous testrun + printlog "enable all items in the task pane" + printlog "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 + printlog "ok" else MenuSelect(MenuGetItemId(4)) endif hMenuSelectNr(0) - 'sleep(1) next View.OpenMenu @@ -170,10 +163,8 @@ testcase t_Introduction View.OpenMenu MenuSelect(MenuGetItemId(5)) - LayoutsPreview.TypeKeys "<HOME> <DOWN> <DOWN> <RETURN>" sleep (5) - '///Add a background Printlog "Add background" Kontext "Tasks" @@ -193,7 +184,6 @@ testcase t_Introduction Tasks.TypeKeys "<MOD1 HOME>",true AvailableForUsePreview.TypeKeys "<HOME> <RIGHT> <RETURN>" sleep (5) - '///Add a transition effect Printlog "Add a transition effect" Kontext "Tasks" sleep(5) @@ -206,35 +196,33 @@ testcase t_Introduction View.OpenMenu MenuSelect(MenuGetItemID(4)) - TransitionSound.GetItemCount 'needed for select + TransitionSound.GetItemCount Sleep 1 TransitionSound.Select 4 - '///Close the document Printlog "Close the document" Call hCloseDocument endcase 't_Introduction + '-------------------------------------------------------------------- + testcase t_Interoperability Dim sTemplatename as string gApplication = "IMPRESS" - '///Open PowerPoint presentation printlog "Open PowerPoint presentation" - hFileOpen (Convertpath (gTesttoolPath + "graphics/required/input/dotNetOverview.ppt")) + hFileOpenLocally( gTesttoolPath + "graphics/required/input/dotNetOverview.ppt" ) - Call sMakeReadOnlyDocumentEditable - - 'Save the name of the origin background (taken from last slide) + printlog "Save the name of the origin background (taken from last slide)" Kontext "DocumentImpress" DocumentImpress.TypeKeys "<END>" sleep (4) sTemplatename = DocumentImpress.StatusGetText (6) - printlog " Background = " & sTemplatename 'Debugcode - + printlog "Background = " & sTemplatename 'Debugcode + printlog "Choose a masterpage from right pane" Kontext "Tasks" @@ -251,46 +239,45 @@ testcase t_Interoperability wait(20000) Kontext "AvailableForUsePreview" AvailableForUsePreview.TypeKeys "<HOME> <RIGHT> <RETURN>" - sleep (5) - printlog " Verify that the background has changed" + sleep (10) + printlog "Verify that the background has changed" Kontext "DocumentImpress" - printlog " Background is " & DocumentImpress.StatusGetText (6) 'Debugcode + printlog "Background is " & DocumentImpress.StatusGetText (6) 'Debugcode if DocumentImpress.StatusGetText (6) = sTemplatename then warnlog "The background is not changed" else printlog " Background has been changed" endif - '///Switch back to original background printlog "Switch back to original background" Kontext "Tasks" Kontext "AvailableForUsePreview" AvailableForUsePreview.TypeKeys "<HOME> <RETURN>" - sleep (5) + sleep (10) Kontext "DocumentImpress" if DocumentImpress.StatusGetText (6) = sTemplatename then printlog " The background has been set back to default" else warnlog "The background is " & DocumentImpress.StatusGetText (6) & " but should be: " & sTemplatename endif - '///Resort slides printlog "Resort slides" Kontext "DocumentImpress" Kontext "Slides" Kontext "SlidesControl" - SlidesControl.TypeKeys "<Mod1 X>" + SlidesControl.OpenContextMenu + sleep 1 + hMenuSelectNr (8) Kontext "DocumentImpress" - DocumentImpress.TypeKeys "<HOME>" + DocumentImpress.TypeKeys "<HOME>", true Kontext "Slides" Kontext "SlidesControl" - SlidesControl.TypeKeys "<Mod1 V>" - kontext "InsertPaste" - if InsertPaste.Exists(1) then - Before.Check - InsertPaste.OK - endif + SlidesControl.OpenContextMenu + sleep 1 + hMenuSelectNr (10) + Printlog " Verify that the slide was moved correctly" Kontext "Slides" - SlidesControl.TypeKeys "<PAGEUP>" + sleep (5) + SlidesControl.TypeKeys "<SHIFT F10>" if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." @@ -301,24 +288,22 @@ testcase t_Interoperability if NameField.GetText <> ".NET Enterprise Federation" then Warnlog "Wrong slide found! Expected no 3, but found " + NameField.GetText + "." else - Printlog " The slide was correctly moved" + Printlog "The slide was correctly moved" endif NameDlgPage.OK sleep 1 - '///Switch views printlog "Switch views" ViewWorkspaceOutlineView sleep (2) setclipboard("") try Kontext "DocumentImpressOutlineView" - DocumentImpressOutlineView.TypeKeys "<MOD1 HOME><SHIFT END>" DocumentImpressOutlineView.TypeKeys "<Mod1 C>" sleep (5) - if getclipboard() <> ".NET Enterprise" then - warnlog " Wrong selection in outlineview. Should be '.NET Enterprise', but is '" & getclipboard() +"'." - else printlog " Switching to Outlineview was successfull" + if getclipboard() <> ".NET Enterprise Federation" then + warnlog "Wrong selection in outlineview. Should be '.NET Enterprise', but is '" & getclipboard() +"'." + else printlog "Switching to Outlineview was successfull" endif catch warnlog "Switching to Outlineview was not successfull" @@ -333,7 +318,7 @@ testcase t_Interoperability MenuSelect(MenuGetItemID(3)) 'Open Contextmenu Line Kontext "TabLinie" TabLinie.Cancel - printlog " Switching to Notesview was successfull" + printlog "Switching to Notesview was successfull" catch warnlog "Switching to Notesview was not successfull" endcatch @@ -342,7 +327,7 @@ testcase t_Interoperability try Kontext "DocumentImpressHandoutView" DocumentImpressHandoutView.TypeKeys "<TAB>" - printlog " Switching to Handoutview was successfull" + printlog "Switching to Handoutview was successfull" catch warnlog "Switching to Handoutview was not successfull" endcatch @@ -352,7 +337,7 @@ testcase t_Interoperability try Kontext "Slides" SlidesControl.TypeKeys "<TAB>" - printlog " Switching to Slideview was successfull" + printlog "Switching to Slideview was successfull" catch warnlog "Switching to Slideview was not successfull" endcatch @@ -362,12 +347,11 @@ testcase t_Interoperability try Kontext "DocumentImpress" DocumentImpress.TypeKeys "<TAB>" - printlog " Switching back to Drawingview was successfull" + printlog "Switching back to Drawingview was successfull" catch warnlog "Switching to Drawingview was not successfull" endcatch - '///Travel through the presentation by left pane printlog "Travel through the presentation by left pane to slide 7" Kontext "DocumentImpress" DocumentImpress.TypeKeys "<HOME><PAGEDOWN><PAGEDOWN><PAGEDOWN><PAGEDOWN><PAGEDOWN><PAGEDOWN><PAGEDOWN>" @@ -418,18 +402,16 @@ testcase t_DrawingEngine gApplication = "DRAW" - '///Open a drawing printlog "Open a drawing" hFileOpen (Convertpath (gTesttoolPath + "graphics/required/input/Blueprint.odg")) Call fMakeDocumentWritable - '///Select grouped object and enter group printlog "Select group" Kontext "DocumentDraw" DocumentDraw.TypeKeys "<TAB><TAB>" sleep (5) - printlog " Save position of group" + printlog "Save position of group" ContextPositionAndSize 'Format-position and size Kontext Active.SetPage TabPositionAndSize @@ -442,7 +424,6 @@ testcase t_DrawingEngine FormatEditGroupDraw sleep 1 - '///Select and move single object printlog "Select and move single object" printlog " Select object" Kontext "DocumentDraw" @@ -454,48 +435,46 @@ testcase t_DrawingEngine kontext "NameDlgObject" if NameField.GetText <> "Chair" then Warnlog "Wrong object selected!" - else Printlog " The correct object is selected" + else Printlog "The correct object is selected" endif NameDlgObject.OK sleep 1 - printlog " Save position of group" - ContextPositionAndSize 'Format-position and size + printlog "Save position of group" + ContextPositionAndSize Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" sObjectPosition = PositionY.GetText - printlog " - ObjectPosition is " & sObjectPosition + printlog "ObjectPosition is " & sObjectPosition TabPositionAndSize.OK - printlog " Move object" + printlog "Move object" Kontext "DocumentDraw" DocumentDraw.TypeKeys "<UP><UP><UP>" sleep (5) - printlog " Verify that the object was moved" - ContextPositionAndSize '/// Format-position and size + printlog "Verify that the object was moved" + ContextPositionAndSize Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" if PositionY.GetText <> sObjectPosition then - printlog " Single object was moved" + printlog "Single object was moved" else warnlog "The object has not been moved" endif TabPositionAndSize.OK - printlog " Exit group" + printlog "Exit group" FormatExitGroupDraw Printlog "Verify that the group is still on position" - printlog " Verify position" ContextPositionAndSize 'Format-position and size Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" if PositionY.GetText = sGroupPosition then - printlog " Group is still on position" + printlog "Group is still on position" else warnlog "Group has moved from " & sGroupPosition & " to " & PositionY.GetText endif TabPositionAndSize.OK - '///Close document printlog "Close document" Call hCloseDocument -endcase 't_DrawingEngine +endcase 't_DrawingEngine
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_edit.inc b/testautomation/graphics/optional/includes/global/g_edit.inc index fdff948d0bfb..59cf4e3a404a 100644 --- a/testautomation/graphics/optional/includes/global/g_edit.inc +++ b/testautomation/graphics/optional/includes/global/g_edit.inc @@ -43,32 +43,41 @@ ' Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") testcase tEditDuplicate - dim Ueber_Text_1 - dim Zaehler - Call hNewDocument '/// New Impress document ///' - Call hRechteckErstellen ( 5, 5, 20, 30 ) '/// Create rectangle ///' - EditSelectAll '/// Select rectangle ///' - EditDuplicate '/// Edit-duplicate ///' - Kontext "Duplizieren" - Ueber_Text_1 = AnzahlAnKopien.GetText - AnzahlAnKopien.SetText "50" '/// Set number of copies to 50 ///' - Duplizieren.Cancel '/// Cancel Edit Duplicate ///' - sleep 1 - For Zaehler = 1 to 8 - EditDuplicate '/// Edit Duplicate ///' - sleep 1 - Kontext "Duplizieren" - AnzahlAnKopien.SetText "30" '/// Number of copies = 30 ///' + dim Ueber_Text_1 + dim Zaehler - Select Case Zaehler '/// Setting values for axis and angles ///' - Case 1: XAchse.SetText "0,0" + printlog " New Impress document" + Call hNewDocument + printlog " Create rectangle" + Call hRechteckErstellen ( 5, 5, 20, 30 ) + printlog " Select rectangle" + EditSelectAll + printlog " Edit-duplicate" + EditDuplicate + Kontext "Duplizieren" + Ueber_Text_1 = AnzahlAnKopien.GetText + printlog " Set number of copies to 50" + AnzahlAnKopien.SetText "50" + printlog " Cancel Edit Duplicate" + Duplizieren.Cancel + sleep 1 + For Zaehler = 1 to 8 + printlog " Edit Duplicate" + EditDuplicate + sleep 1 + Kontext "Duplizieren" + printlog " Number of copies = 30" + AnzahlAnKopien.SetText "30" + printlog " Setting values for axis and angles" + Select Case Zaehler + Case 1: XAchse.SetText "0,0" YAchse.SetText "0,45" Hoehe.SetText "-0,1" Breite.SetText "-0,1" Drehwinkel.SetText "3" Anfang.Select Int((Anfang.GetItemCount * Rnd)+1) - Case 2,6: XAchse.SetText "0,6" + Case 2,6: XAchse.SetText "0,6" YAchse.SetText "0,0" Hoehe.SetText "0,15" Breite.SetText "0,01" @@ -78,26 +87,28 @@ testcase tEditDuplicate Hoehe.SetText "-0,1" Breite.SetText "0,06" Drehwinkel.SetText "11" - Case 4,8: XAchse.SetText "-0,6" + Case 4,8: XAchse.SetText "-0,6" YAchse.SetText "0,0" Hoehe.SetText "0,05" Breite.SetText "-0,08" Drehwinkel.SetText "347" - Case 5: XAchse.SetText "0,1" + Case 5: XAchse.SetText "0,1" YAchse.SetText "0,48" Hoehe.SetText "-0,05" Breite.SetText "-0,05" Drehwinkel.SetText "355" - End Select - Ende.Select Int((Ende.GetItemCount * Rnd)+1) - Duplizieren.OK '/// Execute Duplicate ///' - sleep 1 - Next Zaehler - sleep 2 - Call hCloseDocument '/// Close document ///' + End Select + Ende.Select Int((Ende.GetItemCount * Rnd)+1) + printlog " Execute Duplicate" + Duplizieren.OK + sleep 1 + Next Zaehler + sleep 2 + printlog " Close document" + Call hCloseDocument endcase 'tEditDuplicate -'--------------------------------------------------------- +'------------------------------------------------------------------------------- testcase tEditFields Call hNewDocument @@ -148,68 +159,85 @@ endcase 'tEditFields '-------------------------------------------------------- testcase tEditDeleteSlide - dim Ueber_Text_1 as string - dim Ueber_Text_2 as string - dim Ueber_Text_3 as string - Call hNewDocument '/// New impress document ///' - sleep 3 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - sleep 1 - ContextPositionAndSize '/// open Position and Size dialog ///' - kontext - Messagebox.SetPage TabPositionAndSize - kontext "TabPositionAndSize" - Ueber_Text_1 = PositionX.GetText '/// get position values for rectangle ///' - TabPositionAndSize.OK - InsertSlide '/// insert slide ///' - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 - Call hRechteckErstellen ( 40, 40, 60, 60 ) '/// create rectangle ///' - sleep 1 - EditDeleteSlide '/// Delete slide ///' - sleep 1 - Ueber_Text_2 = "OK Page was closed" - Ueber_Text_3 = "Page was not closed" - call Position_Vergleichen (Ueber_Text_1,Ueber_Text_2,Ueber_Text_3) '/// compare position of rectange ///' - sleep 1 - Call hCloseDocument '/// close document ///' + dim Ueber_Text_1 as string + dim Ueber_Text_2 as string + dim Ueber_Text_3 as string + + printlog " New impress document" + Call hNewDocument + sleep 3 + printlog " create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + sleep 1 + printlog " open Position and Size dialog" + ContextPositionAndSize + kontext + Messagebox.SetPage TabPositionAndSize + kontext "TabPositionAndSize" + printlog " get position values for rectangle" + Ueber_Text_1 = PositionX.GetText + TabPositionAndSize.OK + printlog " insert slide" + InsertSlide + sleep 2 + hTypekeys "<Pagedown>" + sleep 2 + printlog " create rectangle" + Call hRechteckErstellen ( 40, 40, 60, 60 ) + sleep 1 + printlog " Delete slide" + EditDeleteSlide + sleep 1 + Ueber_Text_2 = "OK Page was closed" + Ueber_Text_3 = "Page was not closed" + printlog " compare position of rectange" + call Position_Vergleichen (Ueber_Text_1,Ueber_Text_2,Ueber_Text_3) + sleep 1 + printlog " close document" + Call hCloseDocument endcase 'tEditDeleteSlide '-------------------------------------------------------- testcase tEditLinks - Call hNewDocument '/// New document ///' - InsertGraphicsFromFile '/// insert graphic (sample.bmp) ///' - Kontext "GrafikEinfuegenDlg" - Link.Check '/// check link ///' - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") - Oeffnen.Click - sleep 3 - EditLinksDraw '/// edit links ///' - Kontext "VerknuepfungenBearbeiten" - Aktualisieren.Click '/// refresh ///' - sleep 1 - 'Aendern 'kann man noch den Dialog aufrufen... - Loesen.Click - sleep 1 - Kontext - Messagebox.Yes - VerknuepfungenBearbeiten.Close '/// close dialog ///' - sleep 1 - try - EditLinksDraw '/// check if last changes remain in the dialog ///' + printlog " New document" + Call hNewDocument + printlog " insert graphic (sample.bmp)" + InsertGraphicsFromFile + Kontext "GrafikEinfuegenDlg" + printlog " check link" + Link.Check + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") + Oeffnen.Click + sleep 3 + printlog " edit links" + EditLinksDraw Kontext "VerknuepfungenBearbeiten" + printlog " refresh" + Aktualisieren.Click + sleep 1 Loesen.Click sleep 1 Kontext Messagebox.Yes + printlog " close dialog" VerknuepfungenBearbeiten.Close - warnlog "Break link does not work" + sleep 1 + try + printlog " check if last changes remain in the dialog" + EditLinksDraw + Kontext "VerknuepfungenBearbeiten" + Loesen.Click + sleep 1 + Kontext + Messagebox.Yes + VerknuepfungenBearbeiten.Close + warnlog "Break link does not work" catch - printlog "OK Link broken" + printlog "OK Link broken" endcatch - Call hCloseDocument '/// close document ///' + printlog " close document" + Call hCloseDocument endcase 'tEditLinks '--------------------------------------------------------- @@ -218,77 +246,87 @@ testcase tdEditDeleteLayer dim Ueber_Text_1 as string dim Ueber_Text_2 as string dim Ueber_Text_3 as string - Call hNewDocument '/// new document ///' - sleep 2 - Call hRechteckErstellen ( 30, 30, 70, 70 ) '/// create rectangle ///' - sleep 1 -'/// View->Layer ///' - ViewLayer - ContextPositionAndSize '/// get position values for rectangle ///' - kontext - active.SetPage TabPositionAndSize - kontext "TabPositionAndSize" - Ueber_Text_1 = PositionX.GetText - TabPositionAndSize.OK - InsertLayer '/// insert layer ///' - Kontext "EbeneEinfuegenDlg" - EbeneEinfuegenDlg.OK - Call hRechteckErstellen ( 10, 40, 90, 60 ) '/// create rectangle on created layer ///' - sleep 1 - EditDeleteLayer '/// delete layer ///' - sleep 1 - Kontext - Active.Yes - sleep 1 - Ueber_Text_2 = "OK Layer was deleted" '/// compare position of selected rectangle with position of created rectangle in deteted layer ///' - Ueber_Text_3 = "Layer was not deleted" - Call Position_Vergleichen (Ueber_Text_1,Ueber_Text_2,Ueber_Text_3) - sleep 1 - Call hCloseDocument '/// close document ///' + + printlog " new document" + Call hNewDocument + sleep 2 + printlog " create rectangle" + Call hRechteckErstellen ( 30, 30, 70, 70 ) + sleep 1 + printlog " View->Layer" + ViewLayer + printlog " get position values for rectangle" + ContextPositionAndSize + kontext + active.SetPage TabPositionAndSize + kontext "TabPositionAndSize" + Ueber_Text_1 = PositionX.GetText + TabPositionAndSize.OK + printlog " insert layer" + InsertLayer + Kontext "EbeneEinfuegenDlg" + EbeneEinfuegenDlg.OK + printlog " create rectangle on created layer" + Call hRechteckErstellen ( 10, 40, 90, 60 ) + sleep 1 + printlog " delete layer" + EditDeleteLayer + sleep 1 + Kontext + Active.Yes + sleep 1 + Ueber_Text_2 = "OK Layer was deleted" + Ueber_Text_3 = "Layer was not deleted" + printlog " compare position of selected rectangle with position of created rectangle in deteted layer" + Call Position_Vergleichen (Ueber_Text_1,Ueber_Text_2,Ueber_Text_3) + sleep 1 + printlog " close document" + Call hCloseDocument endcase 'tdEditDeleteLayer '-------------------------------------------------------- testcase tEditObjectEdit - Dim Schrieb as string - - Schrieb = gOLEWriter - if Schrieb = "" then - warnlog " the OLE is not defined :-((( gOLEWriter: " + iSprache - else + Dim Schrieb as string - Call hNewDocument - call sSelectEmptyLayout - sleep 1 '/// new document ///' - InsertObjectOLEObject '/// insert writer ole object ///' - Kontext "OLEObjektEinfuegen" - sleep 3 - if ObjektTyp.GetItemCount = 0 Then - Warnlog "- No available Ole-entry in the list, maybe an error in the Install.ini?" - sleep 1 - OleObjektEinfuegen.Cancel - sleep 1 - else - - ObjektTyp.Select Schrieb - sleep 1 - OLEObjektEinfuegen.OK - sleep 3 ' Changed from Sleep 1 to Sleep 3 - gMouseMove 10,10,90,90 - sleep 1 - EditSelectAll + Schrieb = gOLEWriter + if Schrieb = "" then + warnlog " the OLE is not defined :-((( gOLEWriter: " + iSprache + else + printlog " new document" + Call hNewDocument + call sSelectEmptyLayout + sleep 1 + printlog " insert writer ole object" + InsertObjectOLEObject + Kontext "OLEObjektEinfuegen" + sleep 3 + if ObjektTyp.GetItemCount = 0 Then + Warnlog "- No available Ole-entry in the list, maybe an error in the Install.ini?" + sleep 1 + OleObjektEinfuegen.Cancel + sleep 1 + else + ObjektTyp.Select Schrieb + sleep 1 + OLEObjektEinfuegen.OK + sleep 3 + gMouseMove 10,10,90,90 + sleep 1 + EditSelectAll - try - EditObjectEdit 'keine ID '/// try edit-objects ///' - sleep 2 - catch - Warnlog "- The EditObjectEdit did not work" - endcatch + try + EditObjectEdit + sleep 2 + catch + Warnlog "- The EditObjectEdit did not work" + endcatch - gMouseClick 90,90 + gMouseClick 90,90 end if - sleep 1 - Call hCloseDocument '/// close document ///' - endif -endcase 'tEditObjectEdit + sleep 1 + printlog " close document" + Call hCloseDocument + endif +endcase 'tEditObjectEdit
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_find_replace.inc b/testautomation/graphics/optional/includes/global/g_find_replace.inc index 4f6a045578e0..3b9fc48ae10f 100644 --- a/testautomation/graphics/optional/includes/global/g_find_replace.inc +++ b/testautomation/graphics/optional/includes/global/g_find_replace.inc @@ -36,19 +36,21 @@ '* '\********************************************************************************** testcase tiEditSearchAndReplace - '/// This test tests the 'Search and Replace' -dialogue. ///' + printlog "This test tests the 'Search and Replace' -dialogue." + qaerrorlog "#i115121# Find and replace: wrong replacement" + goto endsub Dim sFile 'as string Dim sExpression(2) as string ' Expression to look for: ... Replace with dim sExt as string - Select Case Ucase(gApplication) - case "DRAW" : sExt = ".odg" - case "IMPRESS" : sExt = ".odp" - end select + Select Case Ucase(gApplication) + case "DRAW" : sExt = ".odg" + case "IMPRESS" : sExt = ".odp" + end select - 'First we need some errornes words to replace. (sExpression) - 'sExpression(1) has to be 3 times in the document - select case iSprache + printlog "First we need some errornes words to replace. (sExpression)" + printlog "sExpression(1) has to be 3 times in the document" + select case iSprache case 01 : sExpression(1) = "Alle" : sExpression(2) = "Allz" case 03 : sExpression(1) = "empreza" : sExpression(2) = "Emperor" ' Portuguese case 07 : qaerrorlog "No files for Russian yet, will use english instead." @@ -91,9 +93,9 @@ testcase tiEditSearchAndReplace else Call hFileOpen (gTesttoolpath + "graphics\required\input\recht_"+iSprache+sExt) endif - ' check if the document is writable + printlog "check if the document is writable" if fIsDocumentWritable = false then - ' make the document writable and check if it's succesfull + printlog "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 @@ -108,24 +110,28 @@ testcase tiEditSearchAndReplace Messagebox.OK end if sleep 2 - hTypeKeys "<MOD1 HOME>" '/// Select the text ///' + printlog "Select the text" + hTypeKeys "<MOD1 HOME>" - '/// Edit-Find & Replace I///' + printlog "Edit-Find & Replace" EditSearchAndReplace sleep 1 Kontext "FindAndReplace" - '/// Clap the 'more options'-part open ///' + printlog "Clap the 'more options'-part open" More.Click - '/// verify, that search is done without 'similarity search' !!! ///' + printlog "verify, that search is done without 'similarity search' !!!" if SimilaritySearch.IsChecked = TRUE then SimilaritySearch.UnCheck warnlog "'Similar search' checkbox was enabled! It shouldn't be the default!" end if - SearchFor.SetText sExpression(1) '/// set Search text ///' - ReplaceWith.SetText sExpression(2) '/// set Replace text///' + printlog "set Search text" + SearchFor.SetText sExpression(1) + printlog "set Replace text" + ReplaceWith.SetText sExpression(2) - '/// Word has to be there ONLY three times ///' - SearchNow.Click '/// 1st search for text ///' + printlog "Word has to be there ONLY three times" + printlog "1st search for text" + SearchNow.Click Kontext "Messagebox" if Messagebox.Exists(2) then Printlog Messagebox.GetText @@ -134,7 +140,8 @@ testcase tiEditSearchAndReplace sleep 1 Kontext "FindAndReplace" - SearchNow.Click '/// 2nd search for text ///' + printlog "2nd search for text" + SearchNow.Click Kontext "Messagebox" if Messagebox.Exists(2) then Printlog Messagebox.GetText @@ -143,7 +150,8 @@ testcase tiEditSearchAndReplace sleep 1 Kontext "FindAndReplace" - SearchNow.Click '/// 3th search for text///' + printlog "3th search for text" + SearchNow.Click Kontext "Messagebox" if Messagebox.Exists(2) then Printlog Messagebox.GetText @@ -151,15 +159,16 @@ testcase tiEditSearchAndReplace end if sleep 1 Kontext "FindAndReplace" - - SearchNow.Click '/// 4th search for text; but it is no more available!///' + printlog "4th search for text; but it is no more available!" + SearchNow.Click sleep 2 kontext "Messagebox" if Messagebox.Exists Then Printlog "- The word was found 3 times: '" + messagebox.gettext + "'" Messagebox.OK else - SearchNow.Click '/// 5th search for word 1///' + printlog "5th search for word 1" + SearchNow.Click kontext if Messagebox.Exists (5) Then Printlog "?: "+Messagebox.gettext @@ -169,7 +178,7 @@ testcase tiEditSearchAndReplace Warnlog "- No MsgBox appeared: 'changed'" end if - '/// Replace all ///' + printlog "Replace all" Kontext "FindAndReplace" sleep 1 ReplaceAll.Click @@ -183,7 +192,8 @@ testcase tiEditSearchAndReplace end if Kontext "FindAndReplace" sleep 2 - SearchNow.Click '/// Search for word 1 to check if all words are replaced ///' + printlog "Search for word 1 to check if all words are replaced" + SearchNow.Click Kontext "Messagebox" if Not Messagebox.Exists then Warnlog " Not all words are replaced (Replace All)" @@ -195,17 +205,20 @@ testcase tiEditSearchAndReplace FindAndReplace.Close sleep 3 - '/// Edit-Find & Replace II ///' + printlog "Edit-Find & Replace II" gMouseClick 50,50 sleep 1 hTypeKeys "<MOD1 HOME>" EditSearchAndReplace sleep 1 Kontext "FindAndReplace" - SearchFor.SetText sExpression(2) '/// Search for word 2 ///' - ReplaceWith.SetText sExpression(1) '/// Replace with word 1 ///' + printlog "Search for word 2" + SearchFor.SetText sExpression(2) + printlog "Replace with word 1" + ReplaceWith.SetText sExpression(1) - ReplaceBtn.Click '/// Replace 1 ///' + printlog "Replace 1" + ReplaceBtn.Click Kontext "Messagebox" if Messagebox.Exists(4) Then Kontext "Messagebox" @@ -217,7 +230,8 @@ testcase tiEditSearchAndReplace Kontext "FindAndReplace" sleep 1 - SearchNow.Click '/// 2nd search for word 2 ///' + printlog "2nd search for word 2" + SearchNow.Click Kontext "Messagebox" if Messagebox.Exists(2) Then Warnlog " All words got replaced, but only the 1st should have been" @@ -228,7 +242,7 @@ testcase tiEditSearchAndReplace Printlog " Word replaced" end if - '/// Replace all ///' + printlog "Replace all" Kontext "FindAndReplace" ReplaceAll.Click kontext "Messagebox" @@ -238,7 +252,7 @@ testcase tiEditSearchAndReplace Printlog "- No messagebox after replace all" end if - '/// Search for word 2 to check if all are replaced ///' + printlog "Search for word 2 to check if all are replaced" Kontext "FindAndReplace" SearchNow.Click kontext "Messagebox" @@ -253,21 +267,23 @@ testcase tiEditSearchAndReplace More.Click FindAndReplace.Close sleep 2 - '/// Close document ///' + printlog "Close document" Call hCloseDocument endcase 'tiEditSearchAndReplace + '-------------------------------------------------------- + testcase tiEditSearchAndReplaceBUGS -'/// inspired by bugs: 101974, 101975, 101976 ///' +printlog "inspired by bugs: 101974, 101975, 101976" dim i as integer dim bTemp as boolean - '/// open application ///' + printlog "open application" Call hNewDocument sleep 3 - '/// Edit->Search and Replace ///' + printlog "Edit->Search and Replace" EditSearchAndReplace Kontext "FindAndReplace" if FindAndReplace.Exists (5) then @@ -276,7 +292,7 @@ testcase tiEditSearchAndReplaceBUGS Warnlog "Dialog for Search&Replace could NOT be opened :-(" endif - '/// for al 5 views in 'View->Workspace->...' do: ///' + printlog "for al 5 views in 'View->Workspace->...' do: " for i = 1 to 6 Printlog "- " + i + " View->Workspace->... ------------------------------------------------------" try @@ -315,7 +331,7 @@ testcase tiEditSearchAndReplaceBUGS endcatch sleep 5 Kontext "FindAndReplace" - '///+ if not already open, open. edit->search and replace ///' + printlog "if not already open, open. edit->search and replace" if (FindAndReplace.exists <> TRUE) then try EditSearchAndReplace @@ -330,13 +346,13 @@ testcase tiEditSearchAndReplaceBUGS endif else Kontext "FindAndReplace" - '///+ set text to look for to "a" ///' + printlog "set text to look for to a" SearchFor.SetText "a" - Printlog "'///+ click button 'find' ///'" + Printlog " click button 'find'" SearchNow.Click sleep 5 kontext - '///+ if active exists 'wrap/not found...' say OK ///' + printlog "if active exists 'wrap/not found...' say OK" if active.exists(5) then Printlog "Active: '" + active.GetText + "'" try @@ -357,7 +373,7 @@ testcase tiEditSearchAndReplaceBUGS next i Kontext "FindAndReplace" FindAndReplace.cancel - '/// close application ///' + printlog "close application" Call hCloseDocument endcase 'tiEditSearchAndReplaceBUGS diff --git a/testautomation/graphics/optional/includes/global/g_format.inc b/testautomation/graphics/optional/includes/global/g_format.inc index 8cf37d5432a3..edd57185e73b 100644 --- a/testautomation/graphics/optional/includes/global/g_format.inc +++ b/testautomation/graphics/optional/includes/global/g_format.inc @@ -46,267 +46,265 @@ testcase tiFormatText Dim ZaehlerEffekt dim sTemp as string - '/// open application ///' + printlog "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) + printlog "create a textbox with text" + Call hTextrahmenErstellen ("This is a text, which, I hope, in Openoffice, will be automaticly formatted. Should that not be the case, then it doesn't matter.",20,20,70,20) WaitSlot (1000) - '/// click outside of textbox, to leave edit mode of textbox and deselect it ///' + printlog "click outside of textbox, to leave edit mode of textbox and deselect it" gMouseClick 99,99 - '/// type key [TAB] to select textbox again ///' + printlog "type key [TAB] to select textbox again" hTypeKeys "<TAB>" - '/// Format->Position and Size ///' + printlog "Format->Position and Size" FormatPositionAndSize - Kontext - '/// select tabpage 'Format and Size' on dialog 'Position and Size' ///' - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - sleep 2 - '/// get and remember Position: 'Position X' ///' - a = PositionX.GetText - '/// close dialog 'Position and Size' with OK ///' - TabPositionAndSize.OK + Kontext + printlog "select tabpage 'Format and Size' on dialog 'Position and Size'" + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + sleep 2 + printlog "get and remember Position: 'Position X'" + a = PositionX.GetText + printlog "close dialog 'Position and Size' with OK" + TabPositionAndSize.OK - '/// Format -> Text... ///' + printlog "Format -> Text..." FormatTextDraw - Kontext - '/// select tabpage 'Text' ///' - Active.SetPage TabText - Kontext "TabText" - '/// Check checkbox 'Fit width to text' ///' - BreiteAnTextAnpassen.Check - '/// leave dialog with OK ///' - TabText.OK + Kontext + printlog "select tabpage 'Text'" + Active.SetPage TabText + Kontext "TabText" + printlog "Check checkbox 'Fit width to text'" + BreiteAnTextAnpassen.Check + printlog "leave dialog with OK" + TabText.OK + printlog "Dialog should have been resized and moved now!" - '/// Dialog should have been resized and moved now! ///' - - '/// Format->Position and Size ///' + printlog "Format->Position and Size" ContextPositionAndSize - Kontext - '/// select tabpage 'Format and Size' on dialog 'Position and Size' ///' - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - WaitSlot (2000) - '/// compare 'Position X' with saved value - has to be different ///' - sTemp = PositionX.GetText - if (sTemp <> a) Then - Printlog " - Fit to frame does work" - else - warnlog " - Fit to frame doesn't work: expected: '" + a + "' is: '" + + "'" - end if - '/// get and remember Position: 'Position Y' ///' - b=PositionY.GetText - TabPositionAndSize.OK + Kontext + printlog "select tabpage 'Format and Size' on dialog 'Position and Size'" + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + WaitSlot (2000) + printlog "compare 'Position X' with saved value - has to be different" + sTemp = PositionX.GetText + if (sTemp <> a) Then + Printlog " - Fit to frame does work" + else + warnlog " - Fit to frame doesn't work: expected: '" + a + "' is: '" + + "'" + end if + printlog "get and remember Position: 'Position Y'" + b=PositionY.GetText + TabPositionAndSize.OK - '/// Format -> Text... ///' + printlog "Format -> Text..." FormatTextDraw - Kontext - '/// select tabpage 'Text' ///' - Active.SetPage TabText - Kontext "TabText" - '/// UNCheck checkbox 'Fit width to text' ///' - BreiteAnTextAnpassen.Uncheck - '/// check checkbox 'Fit height to text' ///' - HoeheAnTextAnpassen.Check - '/// if checkbox 'Fit to frame' is enabled: this state only happens, if 'Fit height to text' and 'Fit width to text' are checked ///' - if AmRahmenAnpassen.IsEnabled Then - WarnLog " - checkbox 'Fit to frame' is enabled, which is wrong!" - else - PrintLog " - checkbox 'Fit to frame' is disabled." - end if - WaitSlot (1000) - '/// UNcheck checkbox 'Fit height to text' ///' - HoeheAnTextAnpassen.UnCheck - '/// UNCheck checkbox 'Fit width to text' ///' - BreiteAnTextAnpassen.UnCheck - '/// if checkbox 'Fit to frame' is disabled: this state only happens, if 'Fit height to text' and/or 'Fit width to text' are checked ///' - if AmRahmenAnpassen.IsEnabled Then - PrintLog " - checkbox 'Fit to frame' is enabled." - else - WarnLog " - checkbox 'Fit to frame' is disabled, which is wrong!" - end if -' PrintLog "Full width: " + GanzeBreite.IsChecked - '/// set metric field 'Left' to 10 ///' - Links.SetText "10" - '/// set metric field 'Right' to 10 ///' - Rechts.SetText "10" - '/// set metric field 'Top' to 10 ///' - Oben.SetText "10" - '/// set metric field 'Bottom' to 10 ///' - Unten.SetText "10" - '/// leave dialog with OK ///' - TabText.OK + Kontext + printlog "select tabpage 'Text'" + Active.SetPage TabText + Kontext "TabText" + printlog "UNCheck checkbox 'Fit width to text'" + BreiteAnTextAnpassen.Uncheck + printlog "check checkbox 'Fit height to text'" + HoeheAnTextAnpassen.Check + printlog "if checkbox 'Fit to frame' is enabled: this state only happens, if 'Fit height to text' and 'Fit width to text' are checked" + if AmRahmenAnpassen.IsEnabled Then + WarnLog " - checkbox 'Fit to frame' is enabled, which is wrong!" + else + PrintLog " - checkbox 'Fit to frame' is disabled." + end if + WaitSlot (1000) + printlog "UNcheck checkbox 'Fit height to text'" + HoeheAnTextAnpassen.UnCheck + printlog "UNCheck checkbox 'Fit width to text'" + BreiteAnTextAnpassen.UnCheck + printlog "if checkbox 'Fit to frame' is disabled: this state only happens, if 'Fit height to text' and/or 'Fit width to text' are checked" + if AmRahmenAnpassen.IsEnabled Then + PrintLog " - checkbox 'Fit to frame' is enabled." + else + WarnLog " - checkbox 'Fit to frame' is disabled, which is wrong!" + end if + printlog "set metric field 'Left' to 10" + Links.SetText "10" + printlog "set metric field 'Right' to 10" + Rechts.SetText "10" + printlog "set metric field 'Top' to 10" + Oben.SetText "10" + printlog "set metric field 'Bottom' to 10" + Unten.SetText "10" + printlog "leave dialog with OK" + TabText.OK - '/// Edit -> Select All ///' + printlog "Edit -> Select All" EditSelectAll - '/// type Keys [Strg]+[x] to cut object ///' + printlog "type Keys [Strg]+[x] to cut object" hTypeKeys "<MOD1 X>" - '/// No object exists in dokument right now! ///' - '/// Format -> Text... ///' + printlog "No object exists in dokument right now!" + printlog "Format -> Text..." FormatTextDraw - Kontext - '/// select tabpage 'Text' ///' - Active.SetPage TabText - Kontext "TabText" - '/// check checkbox 'Adjust to contour' ///' - Konturfluss.Check - '/// now every other control on the dialog has to get disabled ///' - if ((AmRahmenAnpassen.IsEnabled=False) And (Links.IsEnabled=False) And (Rechts.IsEnabled=False) And (Oben.IsEnabled=False) And (Unten.IsEnabled =False)) Then - PrintLog " - Adjust to contour is working" - else - WarnLog " - contourflow aktivated doesn't work it's supposed to" - end if - '/// leave dialog with OK ///' - TabText.OK + Kontext + printlog "select tabpage 'Text'" + Active.SetPage TabText + Kontext "TabText" + printlog "check checkbox 'Adjust to contour'" + Konturfluss.Check + printlog "now every other control on the dialog has to get disabled" + if ((AmRahmenAnpassen.IsEnabled=False) And (Links.IsEnabled=False) And (Rechts.IsEnabled=False) And (Oben.IsEnabled=False) And (Unten.IsEnabled =False)) Then + PrintLog " - Adjust to contour is working" + else + WarnLog " - contourflow aktivated doesn't work it's supposed to" + end if + printlog "leave dialog with OK" + TabText.OK - '/// create a textbox with text ///' - Call hTextrahmenErstellen ("blablablablablablablablablablablabla",20,20,60,60) + printlog "create a textbox with text" + Call hTextrahmenErstellen ("Just some test-text...",20,20,60,60) WaitSlot (5000) - '/// Format -> Text... ///' + printlog "Format -> Text..." FormatTextDraw - Kontext - '/// select tabpage 'Text Animation' ///' - Active.SetPage TabLauftext - Kontext "TabLauftext" + Kontext + printlog "select tabpage 'Text Animation'" + Active.SetPage TabLauftext + Kontext "TabLauftext" - ZaehlerEffekt = Effekt.GetItemCount - if (ZaehlerEffekt <> 5) then - qaerrorlog "There are now more or less than 5 Effects - Change testcase! " + ZaehlerEffekt + ZaehlerEffekt = Effekt.GetItemCount + if (ZaehlerEffekt <> 5) then + qaerrorlog "There are now more or less than 5 Effects - Change testcase! " + ZaehlerEffekt + end if + for n=1 to ZaehlerEffekt + Effekt.Select n + printlog n + ": '" + Effekt.getSelText + "' -------------------------------" + if (n > 2) then + printlog "test all directions" + for i = 1 to 4 + printlog "" + i + select case i + case 1: NachOben.click + case 2: NachLinks.click + case 3: NachRechts.click + case 4: NachUnten.click + end select + sFormatTextDrawAnimation + next i end if - for n=1 to ZaehlerEffekt - Effekt.Select n - printlog "" + n + ": '" + Effekt.getSelText + "' -------------------------------" - if (n > 2) then - '/// test all directions ///' - for i = 1 to 4 - printlog "" + i - select case i - case 1: NachOben.click - case 2: NachLinks.click - case 3: NachRechts.click - case 4: NachUnten.click - end select - sFormatTextDrawAnimation - next i - end if - if ((n > 1) AND (n < 5)) then - '/// test all Start/End Text visibility ///' - for i = 1 to 4 - printlog "" + i - select case i - case 1: TextSichtbarBeimStarten.check : TextSichtbarBeimBeenden.uncheck - case 2: TextSichtbarBeimBeenden.check - case 3: TextSichtbarBeimStarten.uncheck - case 4: TextSichtbarBeimBeenden.uncheck - end select - sFormatTextDrawAnimation - next i - end if - if ((n > 1) AND (n < 5)) then - '/// test all Animation cycles ///' - for i = 1 to 3 - printlog "" + i - select case i - case 1: Endlos.check - case 2: Endlos.UnCheck : Anzahl.typeKeys ("<PageUp>") - case 3: If Endlos.IsChecked = true then - QaErrorLog "#i74067# - Checkbox checked when it shouldn't have been." - Endlos.UnCheck - end if - Anzahl.setText ("1") - end select - sFormatTextDrawAnimation - next i - end if - if (n > 2) then - '/// test all Increment ///' - for i = 1 to 4 - printlog "" + i - select case i - case 1: Pixel.check : Schrittweite.setText("1") - case 2: printlog "#114551# Loop, if Step greater than object size" - case 3: Pixel.UnCheck : Schrittweite.typeKeys ("<PageDown>") - case 4: printlog "#114551# Loop, if Step greater than object size" - end select - sFormatTextDrawAnimation - next i - end if - if (n > 1) then - '/// test all Delay ///' - for i = 1 to 3 - printlog "" + i - select case i - case 1: Automatisch.check - case 2: Automatisch.UnCheck : Verzoegerung.setText("1") - case 3: Verzoegerung.typeKeys ("<PageUp>") - end select - sFormatTextDrawAnimation - next i - end if - next n - TabLauftext.OK + if ((n > 1) AND (n < 5)) then + printlog "test all Start/End Text visibility" + for i = 1 to 4 + printlog "" + i + select case i + case 1: TextSichtbarBeimStarten.check : TextSichtbarBeimBeenden.uncheck + case 2: TextSichtbarBeimBeenden.check + case 3: TextSichtbarBeimStarten.uncheck + case 4: TextSichtbarBeimBeenden.uncheck + end select + sFormatTextDrawAnimation + next i + end if + if ((n > 1) AND (n < 5)) then + printlog "test all Animation cycles" + for i = 1 to 3 + printlog "" + i + select case i + case 1: Endlos.check + case 2: Endlos.UnCheck : Anzahl.typeKeys ("<PageUp>") + case 3: If Endlos.IsChecked = true then + QaErrorLog "#i74067# - Checkbox checked when it shouldn't have been." + Endlos.UnCheck + end if + Anzahl.setText ("1") + end select + sFormatTextDrawAnimation + next i + end if + if (n > 2) then + printlog "test all Increment" + for i = 1 to 4 + printlog "" + i + select case i + case 1: Pixel.check : Schrittweite.setText("1") + case 2: printlog "#114551# Loop, if Step greater than object size" + case 3: Pixel.UnCheck : Schrittweite.typeKeys ("<PageDown>") + case 4: printlog "#114551# Loop, if Step greater than object size" + end select + sFormatTextDrawAnimation + next i + end if + if (n > 1) then + printlog "test all Delay" + for i = 1 to 3 + printlog "" + i + select case i + case 1: Automatisch.check + case 2: Automatisch.UnCheck : Verzoegerung.setText("1") + case 3: Verzoegerung.typeKeys ("<PageUp>") + end select + sFormatTextDrawAnimation + next i + end if + next n + TabLauftext.OK Call hCloseDocument endcase 'tiFormatText '------------------------------------------------------------------------------- testcase tdFormatLayer - '/// open application ///' + printlog "open application" Call hNewDocument - '/// Edit->Layer->Insert (in DRAW also via Insert->Layer) ///' + printlog "Edit->Layer->Insert (in DRAW also via Insert->Layer)" InsertLayer - Kontext "EbeneEinfuegenDlg" - EbenenName.SetText " Test 4" - LayerTitle.SetText " Test no 4" - LayerDescription.SetText " This is the Description of the Layer." - EbeneEinfuegenDlg.OK + Kontext "EbeneEinfuegenDlg" + EbenenName.SetText " Test 4" + LayerTitle.SetText " Test no 4" + LayerDescription.SetText " This is the Description of the Layer." + EbeneEinfuegenDlg.OK - '/// Edit->Layer->Modify (in DRAW also via Format->Layer)///' + printlog "Edit->Layer->Modify (in DRAW also via Format->Layer)" FormatLayer - Kontext "EbeneAendernDlg" - if EbenenName.GetText = " Test 4" Then - EbenenName.SetText "Layer 5" - end if - if LayerTitle.GetText = " Test no 4" Then - LayerTitle.SetText "Layer test 5" - end if - if LayerDescription.GetText = " This is the Description of the Layer." Then - LayerDescription.SetText " This is the changed Description of the Layer." - end if + Kontext "EbeneAendernDlg" + if EbenenName.GetText = " Test 4" Then + EbenenName.SetText "Layer 5" + end if + if LayerTitle.GetText = " Test no 4" Then + LayerTitle.SetText "Layer test 5" + end if + if LayerDescription.GetText = " This is the Description of the Layer." Then + LayerDescription.SetText " This is the changed Description of the Layer." + end if - Sichtbar.Check - Druckbar.Check - Gesperrt.Check - EbeneAendernDlg.OK + Sichtbar.Check + Druckbar.Check + Gesperrt.Check + EbeneAendernDlg.OK - '/// Edit->Layer->Modify (in DRAW also via Format->Layer)///' + printlog "Edit->Layer->Modify (in DRAW also via Format->Layer)" FormatLayer - Kontext "EbeneAendernDlg" - if EbenenName.GetText <> "Layer 5" Then - WarnLog " Name-Value either didn't change at all, or was empty. Expected: 'Layer 5', but was: " + EbenenName.GetText - end if - if LayerTitle.GetText <> "Layer test 5" Then - WarnLog " Title-Value either didn't change at all, or was empty. Expected: 'Layer test 5', but was: " + LayerTitle.GetText - end if - if LayerDescription.GetText <> " This is the changed Description of the Layer." Then - WarnLog " Description-Value either didn't change at all, or was empty. Expected: ' This is the changed Description of the Layer.', but was: " + LayerDescription.GetText - end if - - if Sichtbar.IsChecked=False Then - WarnLog " Value changed: visible" - end if - if Druckbar.IsChecked=False Then - WarnLog " Value changed: printable" - end if - if Gesperrt.IsChecked=False then - WarnLog " Value changed: locked" - end if - EbeneAendernDlg.OK + Kontext "EbeneAendernDlg" + if EbenenName.GetText <> "Layer 5" Then + WarnLog " Name-Value either didn't change at all, or was empty. Expected: 'Layer 5', but was: " + EbenenName.GetText + end if + if LayerTitle.GetText <> "Layer test 5" Then + WarnLog " Title-Value either didn't change at all, or was empty. Expected: 'Layer test 5', but was: " + LayerTitle.GetText + end if + if LayerDescription.GetText <> " This is the changed Description of the Layer." Then + WarnLog " Description-Value either didn't change at all, or was empty. Expected: ' This is the changed Description of the Layer.', but was: " + LayerDescription.GetText + end if - '/// close application ///' + if Sichtbar.IsChecked=False Then + WarnLog " Value changed: visible" + end if + if Druckbar.IsChecked=False Then + WarnLog " Value changed: printable" + end if + if Gesperrt.IsChecked=False then + WarnLog " Value changed: locked" + end if + EbeneAendernDlg.OK + + printlog "close application" Call hCloseDocument endcase 'tdFormatLayer @@ -326,29 +324,29 @@ testcase tdFormatConnector end if Call hNewDocument - '/// insert connector /// - kontext "Connectorsbar" - if Connectorsbar.Exists then - Connectorsbar.Close - end if + printlog "insert connector" + kontext "Connectorsbar" + if Connectorsbar.Exists then + Connectorsbar.Close + end if - kontext "Toolbar" - Sleep (1) - try - Verbinder.TearOff ' insert connector - catch - warnlog "bug for GH from TBO; .tearoff doesn't tell success" - endcatch + kontext "Toolbar" + Sleep (1) + try + Verbinder.TearOff ' insert connector + catch + warnlog "bug for GH from TBO; .tearoff doesn't tell success" + endcatch kontext "Connectorsbar" Verbinder.click gMouseMove ( 10,10,30,30) Call hCloseDocument - '/// Open file with a finished scenario ///' - hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\FormatConnector." + ExtensionString) + printlog "Open file with a finished scenario" + hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\FormatConnector." + ExtensionString) sleep (1) - '/// Check if the document is writable ///' + printlog "Check if the document is writable" if fIsDocumentWritable = false then ' Make the document writable and check if it's succesfull if fMakeDocumentWritable = false then @@ -358,82 +356,84 @@ testcase tdFormatConnector end if gMouseClick 1,1 - '/// Press TAB three times to select the connector. ///' + printlog "Press TAB three times to select the connector." hTypekeys "<TAB>" hTypekeys "<TAB>" hTypekeys "<TAB>" WaitSlot (1000) - hTypeKeys "<SHIFT F10>" 'OpenContextMenu(true) + printlog "OpenContextMenu(true)" + hTypeKeys "<SHIFT F10>" sleep (3) - hMenuSelectNr(2) ' Connector + printlog "Select Connector" + hMenuSelectNr(2) Kontext "Verbinder" - Typ.Select 2 ' the one with 2 from 3 posibilities to set a value... + Typ.Select 2 ' the one with 2 from 3 posibilities to set a value... Sleep (1) - AnfangHorizontal.SetText "1" - Verbinder.TypeKeys "<TAB>" - AnfangVertikal.SetText "1" + AnfangHorizontal.SetText "1" + Verbinder.TypeKeys "<TAB>" + AnfangVertikal.SetText "1" + Verbinder.TypeKeys "<TAB>" + EndeHorizontal.SetText "1" + Verbinder.TypeKeys "<TAB>" + EndeVertikal.SetText "1" + Verbinder.TypeKeys "<TAB>" + printlog EndeVertikal.getText + try + Linie1.SetText "10" Verbinder.TypeKeys "<TAB>" - EndeHorizontal.SetText "1" + sTemp = Linie1.getText + sUnit = GetMeasUnit(sTemp) + cDecSep = GetDecimalSeperator(sTemp) + catch + PrintLog " Lineoffset not activated -> you have to choose another linetype: 1" + endcatch + try + Linie2.SetText "10" Verbinder.TypeKeys "<TAB>" - EndeVertikal.SetText "1" + catch + PrintLog " Lineoffset not activated -> you have to choose another linetype: 2" + endcatch + try + Linie3.SetText "10" Verbinder.TypeKeys "<TAB>" - printlog EndeVertikal.getText - try - Linie1.SetText "10" - Verbinder.TypeKeys "<TAB>" - sTemp = Linie1.getText - sUnit = GetMeasUnit(sTemp) - cDecSep = GetDecimalSeperator(sTemp) - catch - PrintLog " Lineoffset not activated -> you have to choose another linetype: 1" - endcatch - try - Linie2.SetText "10" - Verbinder.TypeKeys "<TAB>" - catch - PrintLog " Lineoffset not activated -> you have to choose another linetype: 2" - endcatch - try - Linie3.SetText "10" - Verbinder.TypeKeys "<TAB>" - catch - PrintLog " Lineoffset not activated -> you have to choose another linetype: 3 when will this be enabled ?" - endcatch + catch + PrintLog " Lineoffset not activated -> you have to choose another linetype: 3 when will this be enabled ?" + endcatch Verbinder.OK FormatConnector - Kontext "Verbinder" - sTemp = AnfangHorizontal.GetText + Kontext "Verbinder" + sTemp = AnfangHorizontal.GetText - if fCompareTwoValues(sTemp, "1"+cDecSep+"00"+sUnit) Then - WarnLog " value not changed" - printlog "AnfangHorizontal = is '" + sTemp + "' should: '"+"1"+cDecSep+"00"+sUnit+"'" - end if - if fCompareTwoValues(AnfangVertikal.GetText, "1"+cDecSep+"00"+sUnit) Then - WarnLog " value not changed" - printlog "AnfangVertikal.GetText = " + AnfangVertikal.GetText - end if - if fCompareTwoValues(EndeHorizontal.GetText, "1"+cDecSep+"00"+sUnit) Then - WarnLog " value not changed" - printlog "EndeHorizontal.GetText = " + EndeHorizontal.GetText - end if - if fCompareTwoValues(EndeVertikal.GetText, "1"+cDecSep+"00"+sUnit) Then - WarnLog " value not changed" - printlog "EndeHorizontal.GetText = " + EndeHorizontal.GetText - end if + if fCompareTwoValues(sTemp, "1"+cDecSep+"00"+sUnit) Then + WarnLog " value not changed" + printlog "AnfangHorizontal = is '" + sTemp + "' should: '"+"1"+cDecSep+"00"+sUnit+"'" + end if + if fCompareTwoValues(AnfangVertikal.GetText, "1"+cDecSep+"00"+sUnit) Then + WarnLog " value not changed" + printlog "AnfangVertikal.GetText = " + AnfangVertikal.GetText + end if + if fCompareTwoValues(EndeHorizontal.GetText, "1"+cDecSep+"00"+sUnit) Then + WarnLog " value not changed" + printlog "EndeHorizontal.GetText = " + EndeHorizontal.GetText + end if + if fCompareTwoValues(EndeVertikal.GetText, "1"+cDecSep+"00"+sUnit) Then + WarnLog " value not changed" + printlog "EndeHorizontal.GetText = " + EndeHorizontal.GetText + end if - Zaehler = Typ.GetItemCount - for i = 1 to Zaehler - Typ.Select i - SetClipboard Typ.GetSelText - Verbinder.OK - FormatConnector - Kontext "Verbinder" - if GetClipboardText <> Typ.GetSelText Then - WarnLog " Selection not saved. Was: " + Typ.GetSelText + " . But should have been: " +GetClipboardText - end if - next i + Zaehler = Typ.GetItemCount + for i = 1 to Zaehler + Typ.Select i + SetClipboard Typ.GetSelText + Verbinder.OK + FormatConnector + Kontext "Verbinder" + if GetClipboardText <> Typ.GetSelText Then + WarnLog " Selection not saved. Was: " + Typ.GetSelText + " . But should have been: " +GetClipboardText + end if + next i Verbinder.OK Call hCloseDocument @@ -451,7 +451,6 @@ testcase tiFormatPositionAndSize printlog "New impress doc" Call hNewDocument WaitSlot (3000) - printlog "RECTANGLE-----1/2" printlog "create rectangle" Call hRechteckErstellen (20,20,70,30) WaitSlot (1000) @@ -459,119 +458,119 @@ printlog "New impress doc" WaitSlot (1000) printlog "Format-position and size" ContextPositionAndSize - WaitSlot (1000) - Kontext - printlog "TabPositionAndSize" - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "put x and y position into clipboard" - printlog "x = " & PositionX.GetText - printlog "y = " & PositionY.GetText - SetClipboard (PositionX.GetText + PositionY.GetText) - TabPositionAndSize.OK + WaitSlot (1000) + Kontext + printlog "TabPositionAndSize" + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "put x and y position into clipboard" + printlog "x = " & PositionX.GetText + printlog "y = " & PositionY.GetText + SetClipboard (PositionX.GetText + PositionY.GetText) + TabPositionAndSize.OK WaitSlot (1000) printlog "move rectangle down and right" hTypeKeys "<DOWN>",10 hTypeKeys "<RIGHT>",10 printlog "open PositionAndSize" ContextPositionAndSize - WaitSlot (1000) - Kontext - printlog "TabPositionAndSize" - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "control position changes with clipboard content" - if (PositionX.GetText + PositionY.GetText) = GetClipboardText Then WarnLog "Der Dialog hat die Positionsaenderung nicht registriert" - printlog "set position of rectange using the edit fields" - PositionX.SetText "2" - x=PositionX.GetText - PositionY.SetText "2" - y=PositionY.GetText - printlog "check protect" - ProtectPosition.Check - TabPositionAndSize.OK + WaitSlot (1000) + Kontext + printlog "TabPositionAndSize" + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "control position changes with clipboard content" + if (PositionX.GetText + PositionY.GetText) = GetClipboardText Then WarnLog "Der Dialog hat die Positionsaenderung nicht registriert" + printlog "set position of rectange using the edit fields" + PositionX.SetText "2" + x=PositionX.GetText + PositionY.SetText "2" + y=PositionY.GetText + printlog "check protect" + ProtectPosition.Check + TabPositionAndSize.OK WaitSlot (1000) ContextPositionAndSize - WaitSlot (1000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "check if values are correct" - if PositionX.GetText = x And PositionY.GetText = y Then PrintLog " Values could be changed" - printlog "check if protect works" - if PositionX.GetText<> x Then - WarnLog "Protect does not work" - else - PrintLog "Protext works, X axis checked" - end if - if PositionY.GetText<> y Then - WarnLog "Protect does not work" - else - PrintLog " Protext does work, checked y axis" - end if - printlog "uncheck protect" - ProtectPosition.UnCheck - TabPositionAndSize.OK + WaitSlot (1000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "check if values are correct" + if PositionX.GetText = x And PositionY.GetText = y Then PrintLog " Values could be changed" + printlog "check if protect works" + if PositionX.GetText<> x Then + WarnLog "Protect does not work" + else + PrintLog "Protext works, X axis checked" + end if + if PositionY.GetText<> y Then + WarnLog "Protect does not work" + else + PrintLog " Protext does work, checked y axis" + end if + printlog "uncheck protect" + ProtectPosition.UnCheck + TabPositionAndSize.OK WaitSlot (1000) ContextPositionAndSize - WaitSlot (1000) - Kontext - printlog "TabPositionAndSize" - WaitSlot (1000) - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - KeepRatio.UnCheck - printlog "set width to 10" - WaitSlot (1000) - Width.SetText "10" - printlog "put value into a variable" - WaitSlot (1000) - b=Width.GetText - printlog "Width is " & b - SetClipboard Width.GetText - '/// set heigth to 5 ///' - Height.SetText "5" - printlog "put value into variable" - WaitSlot (1000) - h=Height.GetText - printlog "Height is " & h - printlog "check protect" - ProtectPosition.Check - printlog "close dialog" - TabPositionAndSize.OK + WaitSlot (1000) + Kontext + printlog "TabPositionAndSize" + WaitSlot (1000) + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + KeepRatio.UnCheck + printlog "set width to 10" + WaitSlot (1000) + Width.SetText "10" + printlog "put value into a variable" + WaitSlot (1000) + b=Width.GetText + printlog "Width is " & b + SetClipboard Width.GetText + printlog "set heigth to 5" + Height.SetText "5" + printlog "put value into variable" + WaitSlot (1000) + h=Height.GetText + printlog "Height is " & h + printlog "check protect" + ProtectPosition.Check + printlog "close dialog" + TabPositionAndSize.OK WaitSlot (1000) ContextPositionAndSize - WaitSlot (1000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - WaitSlot (2000) - printlog "control size changes" - printlog "Width value is: " & Width.GetText - printlog "Value from Clipboard is: " & GetClipboardText - if Width.GetText = GetClipboardText Then - PrintLog " Size of rectangle could be changed. It is = " + Width.GetText + " but it should be = " + b - else - WarnLog " Controls for height and width do not work" - end if - printlog "Uncheck the Position-Protection, so we can work with this window." - if ProtectPosition.isChecked = FALSE then - printlog "Should be checked since it was checked just 16 rows ago" - ErrorLog "ProtectPosition was not checked - why?" - else - ProtectPosition.Uncheck - end if + WaitSlot (1000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + WaitSlot (2000) + printlog "control size changes" + printlog "Width value is: " & Width.GetText + printlog "Value from Clipboard is: " & GetClipboardText + if Width.GetText = GetClipboardText Then + PrintLog " Size of rectangle could be changed. It is = " + Width.GetText + " but it should be = " + b + else + WarnLog " Controls for height and width do not work" + end if + printlog "Uncheck the Position-Protection, so we can work with this window." + if ProtectPosition.isChecked = FALSE then + printlog "Should be checked since it was checked just 16 rows ago" + ErrorLog "ProtectPosition was not checked - why?" + else + ProtectPosition.Uncheck + end if - KeepRatio.Check - printlog "raise value for width" - Width.More 5 - if Height.GetText = h Then - WarnLog " Keep ratio does not work properly" - else - PrintLog " Keep ratio does work" - KeepRatio.UnCheck - end if - TabPositionAndSize.OK + KeepRatio.Check + printlog "raise value for width" + Width.More 5 + if Height.GetText = h Then + WarnLog " Keep ratio does not work properly" + else + PrintLog " Keep ratio does work" + KeepRatio.UnCheck + end if + TabPositionAndSize.OK WaitSlot (2000) gMouseClick 90,90 WaitSlot (2000) @@ -581,107 +580,107 @@ printlog "New impress doc" WaitSlot (2000) printlog "Format-Postion and Size" FormatPositionAndSize - WaitSlot (1000) - Kontext - printlog "TabPositionAndSize" - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "default value ?: width :-----"+Width.IsEnabled - printlog "check fit width to text" - if Width.IsEnabled then FitWidthText.Check - if Width.IsEnabled = True Then - WarnLog " Fit width does not work" - else - PrintLog " Fit width does work" - end if - printlog "fit heigth to text" - FitHeightText.Check - if Height.IsEnabled = True Then - WarnLog " fit heigth doe not work" - else - PrintLog " fit heigth does work" - end if - ' PrintLog " Fit width to text active: " + FitWidthText.IsChecked - ' PrintLog " Fit heigth to text active: " + FitHeightText.IsChecked - printlog "uncheck fit width to text" - FitWidthText.UnCheck - printlog "uncheck fit heigth to text" - FitHeightText.Uncheck - TabPositionAndSize.OK + WaitSlot (1000) + Kontext + printlog "TabPositionAndSize" + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "default value ?: width :-----"+Width.IsEnabled + printlog "check fit width to text" + if Width.IsEnabled then FitWidthText.Check + if Width.IsEnabled = True Then + WarnLog " Fit width does not work" + else + PrintLog " Fit width does work" + end if + printlog "fit heigth to text" + FitHeightText.Check + if Height.IsEnabled = True Then + WarnLog " fit heigth doe not work" + else + PrintLog " fit heigth does work" + end if + ' PrintLog " Fit width to text active: " + FitWidthText.IsChecked + ' PrintLog " Fit heigth to text active: " + FitHeightText.IsChecked + printlog "uncheck fit width to text" + FitWidthText.UnCheck + printlog "uncheck fit heigth to text" + FitHeightText.Uncheck + TabPositionAndSize.OK WaitSlot (1000) hTypeKeys "<escape>",2 hTypeKeys "<TAB>",2 WaitSlot (1000) ContextPositionAndSize - WaitSlot (1000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "check x-position of textbox" - SetClipboard PositionX.GetText - WaitSlot (1000) - Kontext - printlog "set rotation angle to 50 and position x and y to 1" - Active.SetPage TabDrehung - Kontext "TabDrehung" - PositionX.SetText "1" - PositionY.SetText "1" - Winkel.SetText "50" - w=Winkel.GetText - TabDrehung.OK + WaitSlot (1000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "check x-position of textbox" + SetClipboard PositionX.GetText + WaitSlot (1000) + Kontext + printlog "set rotation angle to 50 and position x and y to 1" + Active.SetPage TabDrehung + Kontext "TabDrehung" + PositionX.SetText "1" + PositionY.SetText "1" + Winkel.SetText "50" + w=Winkel.GetText + TabDrehung.OK WaitSlot (3000) printlog "check position of manipulated textbox" ContextPositionAndSize - WaitSlot (3000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - if PositionX = GetClipboardText Then PrintLog " Position changed due to rotation" - Kontext - Active.SetPage TabDrehung - Kontext "TabDrehung" - WaitSlot (1000) - printlog "check rotation angle" - if Winkel.GetText = w Then PrintLog " Object rotated" - TabDrehung.OK + WaitSlot (3000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + if PositionX = GetClipboardText Then PrintLog " Position changed due to rotation" + Kontext + Active.SetPage TabDrehung + Kontext "TabDrehung" + WaitSlot (1000) + printlog "check rotation angle" + if Winkel.GetText = w Then PrintLog " Object rotated" + TabDrehung.OK printlog "RECTANGLE-----2/2" printlog "create rectangle" Call hRechteckErstellen (10,60,70,90) WaitSlot (2000) ContextPositionAndSize - WaitSlot (1000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - printlog "put x-axis postion of rectangle into clipboard" - SetClipboard PositionX.GetText - Kontext - printlog "set slant angle to 5" - Active.SetPage TabSchraegstellen - Kontext "TabSchraegstellen" - WaitSlot (1000) - printlog "set radius to 5" - Radius.SetText "5" - r=Radius.GetText - Winkel.SetText w - TabSchraegstellen.OK + WaitSlot (1000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + printlog "put x-axis postion of rectangle into clipboard" + SetClipboard PositionX.GetText + Kontext + printlog "set slant angle to 5" + Active.SetPage TabSchraegstellen + Kontext "TabSchraegstellen" + WaitSlot (1000) + printlog "set radius to 5" + Radius.SetText "5" + r=Radius.GetText + Winkel.SetText w + TabSchraegstellen.OK WaitSlot (1000) ContextPositionAndSize - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - if PositionX <> GetClipboardText Then PrintLog " Object changed position due to scaling" - printlog "Before we change tab, we set the Position-marker back to checked " - ProtectPosition.Check - Kontext - printlog "check slant angle and radius" - Active.SetPage TabSchraegstellen - Kontext "TabSchraegstellen" - if Radius.GetText = r Then PrintLog " Cornwer radius changed" - if Winkel.GetText =w Then PrintLog " Object rotated over 45°" - TabSchraegstellen.OK + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + if PositionX <> GetClipboardText Then PrintLog " Object changed position due to scaling" + printlog "Before we change tab, we set the Position-marker back to checked " + ProtectPosition.Check + Kontext + printlog "check slant angle and radius" + Active.SetPage TabSchraegstellen + Kontext "TabSchraegstellen" + if Radius.GetText = r Then PrintLog " Cornwer radius changed" + if Winkel.GetText =w Then PrintLog " Object rotated over 45°" + TabSchraegstellen.OK Call hCloseDocument endcase 'tiFormatPositionAndSize @@ -701,64 +700,76 @@ testcase tiFormat3D_Effekte Dim Posi as string Call hNewDocument - Call sSelectEmptyLayout + Call sSelectEmptyLayout printlog "new document" '-----------------------------------RECTANGLE------------------------------------------------------ - Call hRechteckErstellen (20,20,60,70) '/// create rectangle ///' + printlog "create rectangle" + Call hRechteckErstellen (20,20,60,70) WaitSlot (1000) - ContextPositionAndSize '/// get position and size of rectangle ///' - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - PositionX.SetText "5" - X=PositionX.GetText - printlog "--- created RECTANGLE; xPosition @ "+ x - TabPositionAndSize.OK - ContextConvertInto3D '/// convert rectangle into 3d ///' + printlog "get position and size of rectangle" + ContextPositionAndSize + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + PositionX.SetText "5" + X=PositionX.GetText + printlog "--- created RECTANGLE; xPosition @ "+ x + TabPositionAndSize.OK + printlog "convert rectangle into 3d" + ContextConvertInto3D WaitSlot (1000) Kontext "Drei_D_Effekte" if Drei_D_Effekte.exists(3) then qaerrorlog " The 3D-Effects-dialogue was open. Check why." else - Format3D_Effects '/// open 3d flyer///' + printlog "open 3d flyer" + Format3D_Effects end if - try - if Perspektive.isvisible then - Perspektive.Click '/// check perspective ///' - else - warnlog "why not in draw?" - end if - catch - warnlog "something is wrong mit perspective" - endcatch - Zuweisen.Click '/// assign perspective ///' - Kontext "DocumentImpress" - hTypeKeys "<MOD1 A>" - ContextPositionAndSize '/// check position and size ///' - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - if PositionX.GetText = X Then - printlog "- Perspective acitvated x: "+PositionX.GetText - else - warnlog "- Perspective seems to have a problem, x value has changed!" - end if - TabPositionAndSize.OK - Kontext "Drei_D_Effekte" - Aktualisieren.Click - Drei_D_Effekte.Close - EditSelectAll '/// delete rectangle ///' + try + if Perspektive.isvisible then + printlog "check perspective" + Perspektive.Click + else + warnlog "why not in draw?" + end if + catch + warnlog "something is wrong mit perspective" + endcatch + printlog "assign perspective" + Zuweisen.Click + Kontext "DocumentImpress" + hTypeKeys "<MOD1 A>" + printlog "check position and size" + ContextPositionAndSize + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + if PositionX.GetText = X Then + printlog "- Perspective acitvated x: "+PositionX.GetText + else + warnlog "- Perspective seems to have a problem, x value has changed!" + end if + TabPositionAndSize.OK + Kontext "Drei_D_Effekte" + Aktualisieren.Click + Drei_D_Effekte.Close + EditSelectAll + printlog "delete rectangle" hTypeKeys "<DELETE>" '-----------------------------------RECTANGLE------------------------------------------------------ - hRechteckErstellen (20,20,60,70) '/// create new rectangle ///' + printlog "create new rectangle" + hRechteckErstellen (20,20,60,70) printlog "--- created RECTANGLE 2" - Format3D_Effects '/// open 3d flyer ///' + printlog "open 3d flyer" + Format3D_Effects Kontext "Drei_D_Effekte" - Rotationskoerper.Click '/// create lathe object ///' + printlog "create lathe object" + Rotationskoerper.Click WaitSlot (1000) Kontext "DocumentImpress" - ContextPositionAndSize '/// check position and size ///' + printlog "check position and size" + ContextPositionAndSize Kontext Active.SetPage TabPositionAndSize Kontext "TabPositionAndSize" @@ -769,14 +780,17 @@ testcase tiFormat3D_Effekte end if TabPositionAndSize.OK EditSelectAll - hTypeKeys "<DELETE>" '/// delete object ///' + printlog "delete object" + hTypeKeys "<DELETE>" Sleep (1) '-----------------------------------RECTANGLE------------------------------------------------------ - hRechteckErstellen (20,20,60,70) '/// create rectangle ///' + printlog "create rectangle" + hRechteckErstellen (20,20,60,70) printlog "--- created RECTANGLE 3" Kontext "Drei_D_Effekte" WaitSlot (1000) - In_3D_Umwandeln.Click '/// convert to 3d in 3d flyer ///' + printlog "convert to 3d in 3d flyer" + In_3D_Umwandeln.Click WaitSlot (2000) gMouseClick 40,40 qaerrorlog "#i92910: automation: crash when executing tiFormat3D_Effekte in test g_format" @@ -798,27 +812,36 @@ testcase tiFormat3D_Effekte 'end select EditSelectAll - hTypeKeys "<DELETE>" '/// delete object ///' + printlog "delete object" + hTypeKeys "<DELETE>" '-----------------------------------ZYLINDER------------------------------------------------------ Sleep (1) - printlog "--- create CYLINDER" - WL_SD_Zylinder '/// create cylinder ///' - gMousemove 30,30,80,80 '/// This affects the Vertical-value down to 15 ///' + printlog "create CYLINDER" + WL_SD_Zylinder + printlog "This affects the Vertical-value down to 15" + gMousemove 30,30,80,80 Sleep (1) hTypeKeys "<ESC>" Kontext "Drei_D_Effekte" - Geometrie.Click '/// geometry ///' + printlog " geometry" + Geometrie.Click WaitSlot (1000) ' Endwinkel.More - Vert=Vertikale_Segmente.GetText '/// get value for vertical segments (default) ///' - Hor =Horizontale_Segmente.GetText '/// get value for horizontal segments (default) ///' - Rund=Kantenrundung.GetText '/// get value for edge rounding ///' - Skal=Tiefenskalierung.GetText '/// get value for scale ///' - Tief=Tiefe.GetText '/// get value for depth ///' - Winkel=Endwinkel.GetText '/// get value for angle ///' + printlog "get value for vertical segments (default)" + Vert=Vertikale_Segmente.GetText + printlog "get value for horizontal segments (default)" + Hor =Horizontale_Segmente.GetText + printlog "get value for edge rounding" + Rund=Kantenrundung.GetText + printlog "get value for scale" + Skal=Tiefenskalierung.GetText + printlog "get value for depth" + Tief=Tiefe.GetText + printlog "get value for angle" + Winkel=Endwinkel.GetText - '/// Check if every entry has a value <> "" -> an init value is shown. ///' + printlog "Check if every entry has a value <> "" -> an init value is shown." if Vert ="" then warnlog "Vertical Segment has no init value" if Hor ="" then warnlog "Horizontal Segment has no init value" if Rund ="" then warnlog "Rounded edges has no init value" @@ -826,49 +849,54 @@ testcase tiFormat3D_Effekte if Tief ="" then warnlog "Depth has no init value" if Winkel="" then printlog "Rotation angle has no init value" - '/// Go back to the 3d-effects-dialogue and change the value for the cylinder ///' - - hTypeKeys "<ESC>" '/// Deselect object and check if 3d controller has default values again ///' + printlog "Go back to the 3d-effects-dialogue and change the value for the cylinder" + hTypeKeys "<ESC>" Kontext "Drei_D_Effekte" - '/// Check if value for vertical segments has changed in 3d controller ///' + printlog "Check if value for vertical segments has changed in 3d controller" if Vertikale_Segmente.GetText = Vert Then Printlog "- Vertical segment value read from object's properties in the 3d flyer" else Warnlog "- 3D flyer could not read vertical segment information from object. It is = '"+ Vertikale_Segmente.GetText + "' but should be = '" + Vert + "'" end if - if Horizontale_Segmente.GetText = Hor Then '/// check if value for horizontal segments has changed ///' + printlog "check if value for horizontal segments has changed" + if Horizontale_Segmente.GetText = Hor Then Printlog "- Horizontal segment value read from object's properties in the 3d flyer" else Warnlog "- 3D flyer not be able to read horizonal segment information from object. It is = '"+ Horizontale_Segmente.GetText + "' but should be = '" + Hor + "'" end if - if Kantenrundung.GetText = Rund Then '/// check if value for edge rounding has changed ///' + printlog "check if value for edge rounding has changed" + if Kantenrundung.GetText = Rund Then Printlog "- Rounded edges works" else Warnlog "- Rounded edges value could not be read by the 3d flyer It is = '" + Kantenrundung.GetText + "' but should be = '" + rund + "'" end if - if Tiefenskalierung.GetText = Skal Then '/// check value for scale ///' + printlog "check value for scale" + if Tiefenskalierung.GetText = Skal Then Printlog "- Scaled depth works" else Warnlog "- Scale depth value could not be read by the 3d flyer It is = '" + Tiefenskalierung.GetText + "' but should be = '" + skal + "'" end if - if Tiefe.GetText = Tief Then '/// check value for depth ///' + printlog "check value for depth" + if Tiefe.GetText = Tief Then Printlog "- Depth value could be read by the 3d flyer" else Warnlog "- Depth value of object could not be read by the flyer It is = '"+ Tiefe.GetText + "' but should be = '" + tief + "'" end if - if Endwinkel.GetText = Winkel Then '/// check value for angle ///' + printlog "check value for angle" + if Endwinkel.GetText = Winkel Then Printlog "- Angle value could be read by the 3d flyer" else Warnlog "- Angle value is not correct" end if - hTypeKeys "<ESC>" '/// deselect object and check if 3d controller has default values again ///' + printlog "deselect object and check if 3d controller has default values again" + hTypeKeys "<ESC>" Kontext "Drei_D_Effekte" Sleep (2) Printlog "- check if 3D flyer goes back to default values if object is deselected" @@ -881,16 +909,19 @@ testcase tiFormat3D_Effekte hTypeKeys "<TAB>" Kontext "Drei_D_Effekte" - Sleep (2) - Horizontale_Segmente.SetText "32" '/// change horizontal and vertical segments ///' - Vertikale_Segmente.SetText "32" - Kantenrundung.SetText "100" - Endwinkel.Settext "300" - Tiefenskalierung.SetText "500" - Tiefe.SetText "100" - Zuweisen.Click '/// assign changes ///' + Sleep (2) + printlog "change horizontal and vertical segments" + Horizontale_Segmente.SetText "32" + Vertikale_Segmente.SetText "32" + Kantenrundung.SetText "100" + Endwinkel.Settext "300" + Tiefenskalierung.SetText "500" + Tiefe.SetText "100" + printlog "assign changes" + Zuweisen.Click - WaitSlot (1000) '/// check value changes ///' + printlog "check value changes" + WaitSlot (1000) if Vertikale_Segmente.GetText = Vert Then Warnlog "- Default value is wrong" if Horizontale_Segmente.GetText = Hor Then Warnlog "- Default value is wrong" if Kantenrundung.GetText = Rund Then Warnlog "- Default value is wrong" @@ -898,87 +929,103 @@ testcase tiFormat3D_Effekte if Endwinkel.GetText = Winkel Then Warnlog "- Default value is wrong" if Tiefe.GetText=Tief Then Warnlog "- Default value is wrong" EditSelectAll - hTypeKeys "<DELETE>" '/// delete cylinder ///' + printlog "delete cylinder" + hTypeKeys "<DELETE>" '-----------------------------------ZYLINDER------------------------------------------------------ - WL_SD_Zylinder '/// create new cylinder ///' + printlog "create new cylinder" + WL_SD_Zylinder gMouseMove (20,20,60,60) WaitSlot (3000) Kontext "Drei_D_Effekte" - Printlog "- Change basic geometric parameters for the object" - Printlog "Segments : Horizontal: 8; Vertical: 8; Rounded edges: 50 %" - Horizontale_Segmente.SetText "8" '/// changing values for cylinder ///' - Vertikale_Segmente.SetText "8" - Kantenrundung.SetText "50 %" - Sleep (1) - Zuweisen.Click + Printlog "- Change basic geometric parameters for the object" + Printlog "Segments : Horizontal: 8; Vertical: 8; Rounded edges: 50 %" + printlog "changing values for cylinder" + Horizontale_Segmente.SetText "8" + Vertikale_Segmente.SetText "8" + Kantenrundung.SetText "50 %" + Sleep (1) + Zuweisen.Click WaitSlot (2000) gMouseClick 90,90 Sleep (2) - EditSelectAll '/// select object ///' + printlog "select object" + EditSelectAll WaitSlot (1000) - Kontext "Drei_D_Effekte" '/// control if changes are done ///' - if Horizontale_Segmente.GetText <> "8" Then Warnlog "- Horizontal segment count is not correct "+Horizontale_Segmente.GetText - if Vertikale_Segmente.GetText <> "8" Then Warnlog "- Vertical segment count is not correct "+Vertikale_Segmente.GetText - if Kantenrundung.GetText <> "50 %" Then Warnlog "- Value for rounded edges is not correct "+Kantenrundung.GetText + printlog "control if changes are done" + Kontext "Drei_D_Effekte" + if Horizontale_Segmente.GetText <> "8" Then Warnlog "- Horizontal segment count is not correct "+Horizontale_Segmente.GetText + if Vertikale_Segmente.GetText <> "8" Then Warnlog "- Vertical segment count is not correct "+Vertikale_Segmente.GetText + if Kantenrundung.GetText <> "50 %" Then Warnlog "- Value for rounded edges is not correct "+Kantenrundung.GetText Darstellung.Click - Zaehler=Modus.GetItemCount '/// get number of pssibole render methods ///' + printlog "get number of pssibole render methods" + Zaehler=Modus.GetItemCount for i =1 to Zaehler Modus.Select i - Zuweisen.Click '/// assign every render method ///' + printlog "assign every render method" + Zuweisen.Click gMouseClick 90,90 Sleep (1) - EditSelectAll '/// select object ///' + printlog "select object" + EditSelectAll Sleep (1) Kontext "Drei_D_Effekte" - if Modus.GetSelIndex <> i Then Warnlog "- Value for render modus did not change" '/// check if render method has changed ///' + printlog "check if render method has changed" + if Modus.GetSelIndex <> i Then Warnlog "- Value for render modus did not change" next i - Printlog "- Check 3d shadow and surface angle" - Drei_DSchatten.Click '/// check 3d shadow ///' - Papierneigung.SetText "90 degree(s)" - vert = Papierneigung.getText - Zuweisen.Click '/// assign shadow ///' - gMouseClick 90,90 '/// deselect object ///' + Printlog "- Check 3d shadow and surface angle" + Drei_DSchatten.Click + Papierneigung.SetText "90 degree(s)" + vert = Papierneigung.getText + printlog "assign shadow" + Zuweisen.Click + printlog "deselect object" + gMouseClick 90,90 WaitSlot (1000) - EditSelectAll '/// select object ///' + printlog "select object" + EditSelectAll + printlog "check value changes" Kontext "Drei_D_Effekte" - if Papierneigung.GetText <> vert Then Warnlog "- Value for surface angle is not correct" '/// check value changes ///' - Entfernung.SetText "10" '/// set distance to 10 ///' - Sleep (1) - hor = Entfernung.getText - Sleep (1) - Zuweisen.Click + if Papierneigung.GetText <> vert Then Warnlog "- Value for surface angle is not correct" + printlog "set distance to 10" + Entfernung.SetText "10" + Sleep (1) + hor = Entfernung.getText + Sleep (1) + Zuweisen.Click if Entfernung.GetText <> hor Then Warnlog "- Value for distance is not correct; should: "+hor+"; is: "+Entfernung.GetText WaitSlot (2000) hTypeKeys "<TAB>" Sleep (2) ContextPositionAndSize - WaitSlot (2000) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - PositionX.SetText "5,00cm" - Posi=PositionX.GetText - TabPositionAndSize.OK + WaitSlot (2000) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + PositionX.SetText "5,00cm" + Posi=PositionX.GetText + TabPositionAndSize.OK WaitSlot (1000) Kontext "Drei_D_Effekte" - Brennweite.SetText "50" '/// set focval length to 50 ///' + printlog "set focval length to 50" + Brennweite.SetText "50" Zuweisen.Click - ContextPositionAndSize '/// check change in position of the object ///' - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - If PositionX.GetText = Posi Then - printlog "- Raising value for focal length has not changed optical appearence of object, ok." - else - warnlog "Problem with focal lenght here!" - endif - TabPositionAndSize.OK + printlog "check change in position of the object" + ContextPositionAndSize + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + If PositionX.GetText = Posi Then + printlog "- Raising value for focal length has not changed optical appearence of object, ok." + else + warnlog "Problem with focal lenght here!" + endif + TabPositionAndSize.OK WaitSlot (1000) Kontext "Drei_D_Effekte" - Brennweite.SetText "5" - Zuweisen.Click + Brennweite.SetText "5" + Zuweisen.Click WaitSlot (1000) EditSelectAll WaitSlot (3000) @@ -1007,71 +1054,78 @@ testcase tdFormatTemplates qaerrorlog "Not yet ready." goto endsub - dim Zaehler as integer - dim i as integer - dim x as integer - dim iWaitIndex as integer - dim sStyleName as string - dim bDouble as boolean - dim sTemp(2) as string - - Call hNewDocument '/// new impress document ///' - - WaitSlot (5000) - FormatStylesCatalog '/// format-Style catalog///' - iWaitIndex = 0 - do while Vorlagenkatalog.NotExists AND iWaitIndex < 10 + dim Zaehler as integer + dim i as integer + dim x as integer + dim iWaitIndex as integer + dim sStyleName as string + dim bDouble as boolean + dim sTemp(2) as string + + printlog "new impress document" + Call hNewDocument + + WaitSlot (5000) + printlog "format-Style catalog!" + FormatStylesCatalog + iWaitIndex = 0 + do while Vorlagenkatalog.NotExists AND iWaitIndex < 10 sleep (1) iWaitIndex = iWaitIndex + 1 - loop + loop - Kontext "Vorlagenkatalog" - Vorlagen.GetItemCount '/// get item count for templates ///' - Vorlagen.Select 2 '/// select template 2 ///' - - if Bereich.GetItemCount = Vorlagen.GetItemCount Then '/// check if area changes when selecting a template ///' - PrintLog " - Area did changed" - else - WarnLog " Number of entrees should be 2, but it is " + Bereich.GetItemCount - end if - - Zaehler = Ansicht.GetItemCount 'Vorlagenliste.GetItemCount + Kontext "Vorlagenkatalog" + printlog "get item count for templates" + Vorlagen.GetItemCount + printlog "select template 2" + Vorlagen.Select 2 + + printlog "check if area changes when selecting a template" + if Bereich.GetItemCount = Vorlagen.GetItemCount Then + PrintLog " - Area did changed" + else + WarnLog " Number of entrees should be 2, but it is " + Bereich.GetItemCount + end if - for i = 1 to Zaehler - Ansicht.TypeKeys "<DOWN>" ,i - SetClipboard Ansicht.GetSelText + Zaehler = Ansicht.GetItemCount 'Vorlagenliste.GetItemCount + + for i = 1 to Zaehler + Ansicht.TypeKeys "<DOWN>" ,i + SetClipboard Ansicht.GetSelText WaitSlot (2000) - Vorlagen.Select 1 - PrintLog " "+i+": Offset: '" + Vorlagen.GetSelText+"'" - if Bereich.GetItemCount=Vorlagen.GetItemCount Then WarnLog " Range has not changed" - Vorlagen.Select 2 + Vorlagen.Select 1 + PrintLog " "+i+": Offset: '" + Vorlagen.GetSelText+"'" + if Bereich.GetItemCount=Vorlagen.GetItemCount Then WarnLog " Range has not changed" + Vorlagen.Select 2 WaitSlot (1000) Ansicht.TypeKeys "<HOME>" WaitSlot (1000) - Ansicht.Select 1 + Ansicht.Select 1 WaitSlot (1000) - PrintLog " : Offset: '"+Vorlagen.GetSelText + "'; Opinion: '" + Ansicht.GetSelText+"'" - Vorlagenkatalog.OK - FormatStylesCatalog - Kontext "Vorlagenkatalog" - next i + PrintLog " : Offset: '"+Vorlagen.GetSelText + "'; Opinion: '" + Ansicht.GetSelText+"'" + Vorlagenkatalog.OK + FormatStylesCatalog + Kontext "Vorlagenkatalog" + next i - Vorlagen.Select 2 - WaitSlot (2000) - Vorlagen.Select 1 '/// select first template ///' - if Neu.IsEnabled =False Then WarnLog " Button must be choosable, but is not" - Ansicht.Select 1 - WaitSlot (1000) - Neu.Click '/// create new template ///' - Kontext - Active.SetPage TabVerwalten - Kontext "TabVerwalten" - sStyleName = VorlagenName.GetText - printlog " created new style: '"+sStyleName +"'" - TabVerwalten.OK - PrintLog " New template created" - Kontext "Vorlagenkatalog" - WaitSlot (1000) + Vorlagen.Select 2 + WaitSlot (2000) + printlog "select first template" + Vorlagen.Select 1 + if Neu.IsEnabled =False Then WarnLog " Button must be choosable, but is not" + Ansicht.Select 1 + WaitSlot (1000) + printlog "create new template" + Neu.Click + Kontext + Active.SetPage TabVerwalten + Kontext "TabVerwalten" + sStyleName = VorlagenName.GetText + printlog " created new style: '"+sStyleName +"'" + TabVerwalten.OK + PrintLog " New template created" + Kontext "Vorlagenkatalog" + WaitSlot (1000) ' find newly created style, because they are alphabetical ordered :-( i have to check every entry :-((((( Zaehler = Ansicht.GetItemCount i=1 @@ -1121,10 +1175,11 @@ testcase tdFormatTemplates wEnd end if if (i <= Zaehler) then printlog " found created entry for deleting it :-)" - ' Ansicht.TypeKeys "<DOWN>" ,( i + 1 ) '/// control if template list has created template included ///' + ' Ansicht.TypeKeys "<DOWN>" ,( i + 1 ) printlog "control if template list has created template included" WaitSlot (2000) try - Loeschen.Click '/// delete template ///' + printlog "delete template" + Loeschen.Click WaitSlot (1000) Kontext "Active" if active.exists then @@ -1144,7 +1199,8 @@ testcase tdFormatTemplates UseBindings Ansicht.Select 1 WaitSlot (1000) - Aendern.Click '/// modify template ///' + printlog "modify template" + Aendern.Click WaitSlot (2000) Kontext Active.SetPage TabSchatten @@ -1153,8 +1209,9 @@ testcase tdFormatTemplates TabSchatten.Cancel WaitSlot (2000) Kontext "Vorlagenkatalog" - - Verwalten.Click '/// organize templates ///' + + printlog "organize templates" + Verwalten.Click WaitSlot (2000) Kontext "DVVerwalten" DVVerwalten.OK @@ -1165,21 +1222,27 @@ testcase tdFormatTemplates catch Warnlog " - Style Catalog can't close unless the Template Management-dialog is closed" endcatch - PrintLog " FormatStylesCatalog finished" '/// close template catalog ///' + PrintLog " FormatStylesCatalog finished" WaitSlot (2000) - FormatModifyLayout '/// format modify layout ///' + printlog "format modify layout" + FormatModifyLayout WaitSlot (2000) Kontext "Seitenvorlage" - if HintergrundseiteAustauschen.IsChecked=True Then HintergrundseiteAustauschen.UnCheck '/// uncheck switch background page ///' - Laden.Click '/// load ///' + printlog "uncheck switch background page" + if HintergrundseiteAustauschen.IsChecked=True Then HintergrundseiteAustauschen.UnCheck + printlog "load" + Laden.Click WaitSlot (2000) Kontext "Neu" Neu.Cancel - Kontext "Seitenvorlage" '/// choose a page layout ///' + printlog "choose a page layout" + Kontext "Seitenvorlage" 'Waehlen.Click - Seitenvorlage.OK '/// close dialog ///' - - Call hCloseDocument '/// close document ///' + printlog "close dialog" + Seitenvorlage.OK + + printlog "close document" + Call hCloseDocument endcase 'tdFormatTemplates '------------------------------------------------------------------------------- @@ -1194,56 +1257,56 @@ testcase tiFormatAufzaehlungszeichen Kontext "DocumentImpress" hTextrahmenErstellen ("Hello <Return><Return>",20,20,60,60) for i=1 to 8 - Kontext "DocumentImpress" - gMouseClick 30,30 - EditSelectAll - WaitSlot (1000) - FormatNumberingBulletsDraw - WaitSlot (2000) - Kontext - Active.SetPage TabBullet - Kontext "TabBullet" - Auswahl.TypeKeys "<Right>", i - TabBullet.OK - Kontext "DocumentImpress" + Kontext "DocumentImpress" + gMouseClick 30,30 + EditSelectAll + WaitSlot (1000) + FormatNumberingBulletsDraw + WaitSlot (2000) + Kontext + Active.SetPage TabBullet + Kontext "TabBullet" + Auswahl.TypeKeys "<Right>", i + TabBullet.OK + Kontext "DocumentImpress" next i for i=1 to 8 - Kontext "DocumentImpress" - gMouseClick 30,30 - EditSelectAll - WaitSlot (1000) - FormatNumberingBulletsDraw - Kontext - Active.SetPage TabNumerierungsart - Kontext "TabNumerierungsart" - Auswahl.TypeKeys "<Right>", i - TabNumerierungsart.OK - Kontext "DocumentImpress" + Kontext "DocumentImpress" + gMouseClick 30,30 + EditSelectAll + WaitSlot (1000) + FormatNumberingBulletsDraw + Kontext + Active.SetPage TabNumerierungsart + Kontext "TabNumerierungsart" + Auswahl.TypeKeys "<Right>", i + TabNumerierungsart.OK + Kontext "DocumentImpress" next i for i=1 to 8 - Kontext "DocumentImpress" - gMouseClick 30,30 - EditSelectAll - FormatNumberingBulletsDraw - Kontext - Active.SetPage TabNumerierungsart - Kontext "TabNumerierungsart" - Auswahl.TypeKeys "<Right>", i - TabNumerierungsart.OK - Kontext "DocumentImpress" + Kontext "DocumentImpress" + gMouseClick 30,30 + EditSelectAll + FormatNumberingBulletsDraw + Kontext + Active.SetPage TabNumerierungsart + Kontext "TabNumerierungsart" + Auswahl.TypeKeys "<Right>", i + TabNumerierungsart.OK + Kontext "DocumentImpress" next i WaitSlot (3000) for i=1 to 29 - WaitSlot (3000) - FormatNumberingBulletsDraw - WaitSlot (3000) - Kontext - Active.SetPage TabGrafiken - Kontext "TabGrafiken" - sleep 1 - Auswahl.TypeKeys "<Right>", i - TabGrafiken.OK - Kontext "DocumentImpress" + WaitSlot (3000) + FormatNumberingBulletsDraw + WaitSlot (3000) + Kontext + Active.SetPage TabGrafiken + Kontext "TabGrafiken" + sleep 1 + Auswahl.TypeKeys "<Right>", i + TabGrafiken.OK + Kontext "DocumentImpress" next i gMouseClick 90,90 diff --git a/testautomation/graphics/optional/includes/global/g_group.inc b/testautomation/graphics/optional/includes/global/g_group.inc index a11b809355ce..7784303e207a 100644 --- a/testautomation/graphics/optional/includes/global/g_group.inc +++ b/testautomation/graphics/optional/includes/global/g_group.inc @@ -34,74 +34,87 @@ '\******************************************************************** testcase tiGruppierung - Dim PosX 'Variable fuer PositionX + Dim PosX 'Variable for PositionX + printlog "new document" Call hNewDocument - Call sSelectEmptyLayout '/// new document ///' - sleep 3 - Kontext "DocumentImpress" - sleep 2 - hRechteckErstellen (20,20,40,40) '/// create rectangle ///' - sleep 1 - hRechteckErstellen (60,60,70,10) '/// create 2nd rectangle ///' - sleep 1 - hRechteckErstellen (50,90,70,40) '/// create 3rd rectangle ///' - sleep 1 + printlog "Select empty layout" + Call sSelectEmptyLayout + sleep 3 + Kontext "DocumentImpress" + sleep 2 + printlog "create rectangle " + hRechteckErstellen (20,20,40,40) + sleep 1 + printlog "create 2nd rectangle" + hRechteckErstellen (60,60,70,10) + sleep 1 + printlog "create 3rd rectangle" + hRechteckErstellen (50,90,70,40) + sleep 1 Printlog "- Created 3 rectangles for group testing" - gMouseClick (50,50) '/// Put the mouse-marker in the middle of the screen ///' - EditSelectAll '/// select all rectangles ///' - if (gApplication = "DRAW") then - hOpenContextMenu + printlog "Put the mouse-marker in the middle of the screen" + gMouseClick (50,50) + printlog "select all rectangles" + EditSelectAll + if (gApplication = "DRAW") then + hOpenContextMenu sleep(2) - hMenuSelectNr(12) ' Select "Group" + printlog "Select Group" + hMenuSelectNr(12) sleep(2) - else - FormatGroupDraw '/// open context menue and group rectangles ///' - endif - sleep 1 + else + printlog "open context menue and group rectangles" + FormatGroupDraw + endif + sleep 1 Printlog "- Get position and dimensions of elements" - ContextPositionAndSize '/// get dimensions of group ///' - sleep 1 - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - sleep 1 - PosX=PositionX.GetText - TabPositionAndSize.OK - sleep 1 - Kontext "DocumentImpress" - gMouseClick 35,35 - sleep 1 - hTypeKeys "<F3>" '/// entering group using key "F3" ///' - sleep 3 - try - EditCut '/// cut rectangle out of document ///' - sleep 1 - Warnlog "- Entering the group, no object within the group should have been selected" - catch - Printlog "- entered group, nothing selected" - endcatch - gMouseClick (35,35) - gMouseMove (30,30,60,60) - sleep 1 - Printlog "- Exit group" -' DocumentImpress.OpenContextMenu '/// leave group, compare dimensions ///' -' sleep 1 -' hMenuSelectNr (13) - hTypeKeys "<mod1 F3>" '/// exit group using key "strg F3" ///' - ' would be better to call the slot TBO! - ContextPositionAndSize - sleep 1 - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - sleep 1 - if PosX = PositionX.GetText then - Warnlog "- No change in position for X axis, even we changed position of 1 object within the group" - TabPositionAndSize.OK - else - Printlog "- Moving within the group works" - TabPositionAndSize.OK - end if - Call hCloseDocument '/// close document ///' -endcase + ContextPositionAndSize + sleep 1 + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + sleep 1 + PosX=PositionX.GetText + TabPositionAndSize.OK + sleep 1 + Kontext "DocumentImpress" + gMouseClick 35,35 + sleep 1 + printlog "entering group using key F3" + hTypeKeys "<F3>" + sleep 3 + try + printlog "cut rectangle out of document" + EditCut + sleep 1 + Warnlog "- Entering the group, no object within the group should have been selected" + catch + Printlog "- entered group, nothing selected" + endcatch + gMouseClick (35,35) + gMouseMove (30,30,60,60) + sleep 1 + printlog "leave group, compare dimensions" + ' DocumentImpress.OpenContextMenu + ' sleep 1 + ' hMenuSelectNr (13) + printlog "exit group using key strg F3" + hTypeKeys "<mod1 F3>" + ' would be better to call the slot TBO! + ContextPositionAndSize + sleep 1 + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + sleep 1 + if PosX = PositionX.GetText then + Warnlog "- No change in position for X axis, even we changed position of 1 object within the group" + TabPositionAndSize.OK + else + Printlog "- Moving within the group works" + TabPositionAndSize.OK + end if + printlog "close document " + Call hCloseDocument +endcase
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_imagemap.inc b/testautomation/graphics/optional/includes/global/g_imagemap.inc index de53fdb6f647..5883bbc8d4ac 100644 --- a/testautomation/graphics/optional/includes/global/g_imagemap.inc +++ b/testautomation/graphics/optional/includes/global/g_imagemap.inc @@ -35,12 +35,15 @@ '\************************************************************************************* testcase tEditImageMap - Call hNewDocument '/// new document ///' - EditImageMap '/// edit image map ///' + printlog "new document" + Call hNewDocument + printlog "edit image map" + EditImageMap Kontext "ImageMapEditor" sleep 1 - if ImageMapEditor.Exists (2) then '/// test dialog controls ///' + if ImageMapEditor.Exists (2) then printlog "ImageMap editor exists" + printlog "test dialog controls" DialogTest ( ImageMapEditor ) try ImageMapEditor.Close @@ -60,52 +63,60 @@ testcase tEditImageMap Printlog "ImageMap closed using the edit-menu entry" endcatch end if - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endcase 'tEditImageMap -'------------------------------------------------------------------------------------------------------------------------------------ + +'------------------------------------------------------------------------------- + testcase tEditImageMapProperties qaerrorlog "test not yet ready." goto endsub - Call hNewDocument '/// new document ///' - InsertGraphicsFromFile '/// Insert a graphic and select it ///' + printlog "new document" + Call hNewDocument + printlog "Insert a graphic and select it" + InsertGraphicsFromFile sleep (1) Kontext "GrafikEinfuegenDlg" - sleep (2) - Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\SaveAsPicture\SaveAsPicture.pcx") - sleep (2) - Oeffnen.Click - sleep (2) - EditImageMap '/// Open the image map dialog ///' - Kontext "ImageMapEditor" - sleep (1) - if ImageMapEditor.Exists (2) then '/// test dialog controls ///' - printlog "ImageMap editor exists" - else - warnlog "Something is wrong, the Imagemap didn't show up." - end if - - Ellipse.Click '/// Insert an 'image map' object ///' - Dokument.MouseDown 50,50 - Dokument.MouseMove 50,50,10,10 - Dokument.MouseUp 10,10 - - Eigenschaften.Click '/// Click on the properties icon to open up the properties for the Object ///' - kontext "ImageMapHyperlink" - sleep (1) - if ImageMapHyperlink.Exists (2) then - printlog "ImageMapHyperlink (properties) editor exists" - else - warnlog "Something is wrong, the ImageMapHyperlink (properties) didn't show up." - end if + sleep (2) + Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\SaveAsPicture\SaveAsPicture.pcx") + sleep (2) + Oeffnen.Click + sleep (2) + printlog "Open the image map dialog" + EditImageMap + Kontext "ImageMapEditor" + sleep (1) + if ImageMapEditor.Exists (2) then + printlog "ImageMap editor exists" + else + warnlog "Something is wrong, the Imagemap didn't show up." + end if + printlog "Insert an 'image map' object" + Ellipse.Click + Dokument.MouseDown 50,50 + Dokument.MouseMove 50,50,10,10 + Dokument.MouseUp 10,10 - URL.SetText "http://www.cnn.com" '/// Write some text in each field ///' - Frame.SetText "http://www.framed.com" - Objectname.SetText "This is a strange name: Huckillerry Bohaahw" - Alternativetext.SetText "Alternative, the only way to fly..." - Description.SetText "Just a Foney-text... or whatever it's called." - ImageMapHyperlink.Ok '/// Close the Properties-Dialogue with "Ok" ///' + printlog "Click on the properties icon to open up the properties for the Object" + Eigenschaften.Click + kontext "ImageMapHyperlink" + sleep (1) + if ImageMapHyperlink.Exists (2) then + printlog "ImageMapHyperlink (properties) editor exists" + else + warnlog "Something is wrong, the ImageMapHyperlink (properties) didn't show up." + end if + printlog "Write some text in each field" + URL.SetText "http://www.cnn.com" + Frame.SetText "http://www.framed.com" + Objectname.SetText "This is a strange name: Huckillerry Bohaahw" + Alternativetext.SetText "Alternative, the only way to fly..." + Description.SetText "Just a Foney-text... or whatever it's called." + printlog "Close the Properties-Dialogue with Ok" + ImageMapHyperlink.Ok kontext "ImageMapEditor" Zuweisen.Click sleep (1) @@ -117,7 +128,8 @@ testcase tEditImageMapProperties kontext "DocumentImpress" end if - EditImageMap '/// Check if what we wrote in the Properites-Dialogue still is visible." + EditImageMap + printlog "Check if what we wrote in the Properites-Dialogue still is visible." Kontext "ImageMapEditor" sleep (1) if ImageMapEditor.Exists (2) then @@ -128,32 +140,33 @@ testcase tEditImageMapProperties Dokument.TypeKeys "<TAB>" sleep (1) + printlog "Click on the properties icon to open up the properties for the Object" + Eigenschaften.Click + kontext "ImageMapHyperlink" + sleep (1) + if ImageMapHyperlink.Exists (2) then + printlog "ImageMapHyperlink (properties) editor exists" + else + warnlog "Something is wrong, the ImageMapHyperlink (properties) didn't show up." + end if - Eigenschaften.Click '/// Click on the properties icon to open up the properties for the Object ///' - kontext "ImageMapHyperlink" - sleep (1) - if ImageMapHyperlink.Exists (2) then - printlog "ImageMapHyperlink (properties) editor exists" - else - warnlog "Something is wrong, the ImageMapHyperlink (properties) didn't show up." - end if - - '/// Check if the entries we set before has remained the same, with one exception: cnn.com should now have a slash after it. ///' - if URL.GetText <> "http://www.cnn.com/" then warnlog "URL should have been: http://www.cnn.com/ . But was " + URL.GetText + printlog "Check if the entries we set before has remained the same, with one exception: cnn.com should now have a slash after it. " + if URL.GetText <> "http://www.cnn.com/" then warnlog "URL should have been: http://www.cnn.com/ . But was " + URL.GetText ' if Frame.GetSelText <> "http://www.framed.com" then warnlog "Frame should have been: http://www.framed.com. But was " + Frame.GetSelText - if Objectname.GetText <> "This is a strange name: Huckillerry Bohaahw" then warnlog "Objectname. should have been: This is a strange name: Huckillerry Bohaahw. But was " + Objectname.GetText - if Alternativetext.GetText <> "Alternative, the only way to fly..." then warnlog "Alternativetext should have been: . But was " + Alternativetext.GetText - if Description.GetText <> "Just a Foney-text... or whatever it's called." then warnlog "Description. should have been: . But was " + Description.GetText - ImageMapHyperlink.Ok '/// Close the Properties-Dialogue ///' - sleep (1) + if Objectname.GetText <> "This is a strange name: Huckillerry Bohaahw" then warnlog "Objectname. should have been: This is a strange name: Huckillerry Bohaahw. But was " + Objectname.GetText + if Alternativetext.GetText <> "Alternative, the only way to fly..." then warnlog "Alternativetext should have been: . But was " + Alternativetext.GetText + if Description.GetText <> "Just a Foney-text... or whatever it's called." then warnlog "Description. should have been: . But was " + Description.GetText + printlog "Close the Properties-Dialogue" + ImageMapHyperlink.Ok + sleep (1) kontext "ImageMapEditor" Zuweisen.Click sleep (1) ImageMapEditor.Close sleep (1) - - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endcase 'tEditImageMapProperties '------------------------------------------------------------------------------------------------------------------------------------ diff --git a/testautomation/graphics/optional/includes/global/g_line.inc b/testautomation/graphics/optional/includes/global/g_line.inc index adc573a16e48..eb672b3b9716 100644 --- a/testautomation/graphics/optional/includes/global/g_line.inc +++ b/testautomation/graphics/optional/includes/global/g_line.inc @@ -43,35 +43,46 @@ testcase tiFormatLine Dim k 'Variable fuer Transparenz (Anzahl) Dim l Dim ZaehlerStilLinks - - Call hNewDocument '/// New impress document + + printlog "New impress document" + Call hNewDocument sleep 3 - Call hRechteckErstellen (10,10,60,60) '/// create rectangle + printlog "create rectangle" + Call hRechteckErstellen (10,10,60,60) sleep 2 - FormatLine '/// open Format line dialog + printlog "open Format line dialog" + FormatLine Kontext - Active.SetPage TabLinie '///Open TabLine Tabpage + printlog "Open TabLine Tabpage" + Active.SetPage TabLinie Kontext "TabLinie" sleep 2 - Stil.GetItemCount '/// Get item count for style ///' - Farbe.GetItemCount '/// Get item count for color ///' - Breite.More 1 '/// change value for ///' + printlog "Get item count for style" + Stil.GetItemCount + printlog "Get item count for color" + Farbe.GetItemCount + printlog "change value for" + Breite.More 1 ZaehlerStil = Stil.GetItemCount ZaehlerFarbe = Farbe.GetItemCount - - for i=1 to ZaehlerStil '/// Apply every style to the rectangle ///' - wait 10 - Stil.Select i - wait 10 - TabLinie.OK '/// Closing dialog with ok - ' Kontext "DocumentImpress" - FormatLine '///Open TabLine Tabpage - Kontext - Active.SetPage TabLinie - Kontext "TabLinie" + + printlog "Apply every style to the rectangle" + for i=1 to ZaehlerStil + wait 10 + Stil.Select i + wait 10 + printlog "Closing dialog with ok" + TabLinie.OK + ' Kontext "DocumentImpress" + printlog "Open TabLine Tabpage" + FormatLine + Kontext + Active.SetPage TabLinie + Kontext "TabLinie" next i - - for j=1 to ZaehlerFarbe '/// Apply every color to the rectangle///' + + printlog "Apply every color to the rectangle" + for j=1 to ZaehlerFarbe PrintLog "-- " + Farbe.GetSelText wait 10 Farbe.Select j @@ -83,38 +94,46 @@ testcase tiFormatLine Active.SetPage TabLinie Kontext "TabLinie" next j - Breite.More 3 '/// change Breite ///' + printlog "change Breite" + Breite.More 3 Breite.Less 2 for k=1 to 6 - Transparenz.More 1 '/// change tranparence///' + printlog "change tranparence" + Transparenz.More 1 next k TabLinie.OK '--------------------------------------- sleep 2 - EditSelectAll '/// Select all objects in document ///' + printlog "Select all objects in document" + EditSelectAll sleep 2 - hTypeKeys "<DELETE>" '/// Delete objects ///' + printlog "Delete objects" + hTypeKeys "<DELETE>" sleep 2 FormatLine Kontext - Active.SetPage TabLinie '/// TabLine ///' + printlog "TabLine" + Active.SetPage TabLinie Kontext "TabLinie" StilLinks.GetItemCount ZaehlerStilLinks=StilLinks.GetItemCount - for l=1 to ZaehlerStilLinks '/// Apply all line end styles///' - wait 10 - if EndenSynchronisieren.IsChecked=False Then EndenSynchronisieren.Check '/// check synchronize ///' - wait 10 - StilLinks.Select l - if StilLinks.GetSelText<>StilRechts.GetSelText Then - WarnLog " Ends not synchronized. " + StilLinks.GetSelText + " Right: " + StilRechts.GetSelText '/// check if style is automatically applied for both ends ///' - else - PrintLog " Left: " + StilLinks.GetSelText + " Right: " + StilRechts.GetSelText - end if - EndenSynchronisieren.UnCheck + printlog "Apply all line end styles" + for l=1 to ZaehlerStilLinks + wait 10 + printlog "check synchronize" + if EndenSynchronisieren.IsChecked=False Then EndenSynchronisieren.Check + wait 10 + StilLinks.Select l + printlog "check if style is automatically applied for both ends" + if StilLinks.GetSelText<>StilRechts.GetSelText Then + WarnLog " Ends not synchronized. " + StilLinks.GetSelText + " Right: " + StilRechts.GetSelText + else + PrintLog " Left: " + StilLinks.GetSelText + " Right: " + StilRechts.GetSelText + end if + EndenSynchronisieren.UnCheck next l - ZentriertLinks.Check +ZentriertLinks.Check if ZentriertRechts.isChecked = True Then PrintLog " Centered right does work" i = CornerStyle.GetItemCount if i <> 4 then warnlog "CornerStyle should contain four options, but currently has: " + i @@ -130,15 +149,18 @@ testcase tiFormatLine Kontext Active.SetPage TabLinienstile Kontext "TabLinienstile" - Hinzufuegen.Click '/// Add new line style ///' + printlog "Add new line style" + Hinzufuegen.Click Kontext "NameDlg" - Eingabefeld.SetText "Testlinie2" '/// insert name of style (Testlinie2) ///' + printlog "insert name of style (Testlinie2)" + Eingabefeld.SetText "Testlinie2" NameDlg.OK sleep 1 Kontext Active.SetPage TabLinienstile Kontext "TabLinienstile" - Loeschen.Click '/// delete created style ///' + printlog "delete created style" + Loeschen.Click Kontext "Active" Active.Yes Kontext @@ -151,33 +173,41 @@ testcase tiFormatLine LaengeLinks.More 3 LaengeRechts.More 3 Abstand.SetText "0,1" - if AnLinienbreite.IsChecked = True Then AnLinienbreite.Click '/// all fields changed in TabLinienstile ///' + printlog "all fields changed in TabLinienstile" + if AnLinienbreite.IsChecked = True Then AnLinienbreite.Click PrintLog " All controls could be manipulated." TypLinks.Select 1 TypRechts.Select 1 - if LaengeLinks.IsEnabled And LaengeRechts.IsEnabled =True Then '/// check if its possible to apply a length to a point ///' - WarnLog " A point where you can change its length is not a point anymore" + printlog "check if its possible to apply a length to a point" + if LaengeLinks.IsEnabled And LaengeRechts.IsEnabled =True Then + WarnLog " A point where you can change its length is not a point anymore" else - PrintLog " Line style pint tested" '/// All styles for points are changed ///' + printlog "All styles for points are changed " + PrintLog " Line style pint tested" end if sleep 1 try - Linienstil.Select 1 + Linienstil.Select 1 catch - if Linienstil.GetItemCount = 0 then '/// check if style list is filled ///' - Warnlog "- The list for line styles is empty" - Hinzufuegen.Click '/// new style ///' - Kontext "NameDlg" - NameDlg.OK - end if + printlog "check if style list is filled" + if Linienstil.GetItemCount = 0 then + Warnlog "- The list for line styles is empty" + printlog "new style" + Hinzufuegen.Click + Kontext "NameDlg" + NameDlg.OK + end if endcatch Kontext Active.SetPage TabLinienstile Kontext "TabLinienstile" - Aendern.Click '/// change style ///' + printlog "change style" + Aendern.Click Kontext "NameDlg" - Eingabefeld.SetText Eingabefeld.GetText + "1" '/// new name for changed style ///' - SetClipboard Eingabefeld.GetText '/// put name into clipboard ///' + printlog "new name for changed style" + Eingabefeld.SetText Eingabefeld.GetText + "1" + printlog "put name into clipboard" + SetClipboard Eingabefeld.GetText NameDlg.OK Kontext Active.SetPage TabLinienstile @@ -194,7 +224,8 @@ testcase tiFormatLine Hinzufuegen.Click endcatch Kontext "NameDlg" - if Eingabefeld.GetText <> GetClipboardText Then WarnLog "No changes for Line style" '/// check if changed style is in list ///' + printlog "check if changed style is in list" + if Eingabefeld.GetText <> GetClipboardText Then WarnLog "No changes for Line style" NameDlg.Cancel sleep 2 Kontext @@ -202,18 +233,19 @@ testcase tiFormatLine Kontext "TabLinienstile" sleep 1 try - Loeschen.Click '/// delete changed style ///' - Kontext "Active" - Active.Yes - sleep 3 + printlog "delete changed style" + Loeschen.Click + Kontext "Active" + Active.Yes + sleep 3 catch - if Linienstile.GetItemCount = 0 Then - Hinzufuegen.Click - Kontext "NameDlg" - sleep 1 - Eingabefeld.SetText "Delete" - NameDlg.OK - end if + if Linienstile.GetItemCount = 0 Then + Hinzufuegen.Click + Kontext "NameDlg" + sleep 1 + Eingabefeld.SetText "Delete" + NameDlg.OK + end if endcatch Kontext Active.SetPage TabLinienstile @@ -222,7 +254,8 @@ testcase tiFormatLine TabLinienstile.OK '-------------------------------------------- sleep 2 - Call hRechteckErstellen (40,40,80,50) '/// create rectangle ///' + printlog "create rectangle" + Call hRechteckErstellen (40,40,80,50) sleep 2 FormatLine Kontext @@ -230,7 +263,8 @@ testcase tiFormatLine Kontext "TabLinienenden" sleep 2 Kontext "Linienstil" - if Linienstil.Exists then Aendern.Click '/// change style ///' + printlog "change style" + if Linienstil.Exists then Aendern.Click sleep 1 Kontext Active.SetPage TabLinienenden @@ -238,14 +272,16 @@ testcase tiFormatLine sleep 1 Liste.GetItemCount Liste.Select 3 - Hinzufuegen.Click '/// add style ///' + printlog "add style" + Hinzufuegen.Click Kontext "NameDlg" NameDlg.OK Kontext Active.SetPage TabLinienenden Kontext "TabLinienenden" - Aendern.Click '/// change style ///' + printlog "change style" + Aendern.Click Kontext "Active" Printlog Active.GetText Active.OK @@ -256,20 +292,21 @@ testcase tiFormatLine Kontext if active.GetRt=304 then - active.ok - Kontext "NameDlg" - Eingabefeld.SetText Eingabefeld.GetText + "1" - PrintLog " Name inserted" - NameDlg.OK + active.ok + Kontext "NameDlg" + Eingabefeld.SetText Eingabefeld.GetText + "1" + PrintLog " Name inserted" + NameDlg.OK endif if active.GetRt=304 then - active.ok - warnlog "still not a valid name :-(" + active.ok + warnlog "still not a valid name :-(" endif Kontext Active.SetPage TabLinienenden Kontext "TabLinienenden" - Loeschen.Click '/// delete style ///' + printlog "delete style" + Loeschen.Click Kontext "Active" Active.Yes @@ -277,7 +314,8 @@ testcase tiFormatLine Active.SetPage TabLinienenden Kontext "TabLinienenden" sleep 1 - Speichern.Click '/// save style ///' + printlog "save style" + Speichern.Click sleep 1 Kontext "SpeichernDlg" sleep 1 @@ -287,13 +325,13 @@ testcase tiFormatLine TabLinienenden.Cancel sleep 2 - '///New part for line - 'EditSelectAll '/// Select all objects in document ///' + 'New part for line + 'EditSelectAll printlog "Select all objects in document" 'sleep 2 - 'hTypeKeys "<DELETE>" '/// Delete objects ///' + 'hTypeKeys "<DELETE>" printlog "Delete objects" 'sleep 2 - '/// Create line to test shadow tabpage in line dialog + 'printlog "Create line to test shadow tabpage in line dialog 'kontext "Toolbar" 'Kurven.Click 'sleep 1 @@ -311,7 +349,8 @@ testcase tiFormatLine 'Active.SetPage TabSchatten ' FormatLine.Cancel - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endcase 'tiFormatLine '-------------------------------------------------------------------------------' @@ -329,8 +368,9 @@ testcase tLineConnect QaErrorLog "tLineConnect ends because Asian languages are not fully supported." goto Endsub end if - - Call hNewDocument '/// New Impress / Draw document ///' + + printlog "New Impress / Draw document" + Call hNewDocument Call sSelectEmptyLayout sleep 3 kontext "GraphicObjectbar" @@ -352,7 +392,7 @@ testcase tLineConnect end if endif - '/// Create 2 lines ///' + printlog "Create 2 lines" kontext "Toolbar" Kurven.Click sleep 1 @@ -376,7 +416,7 @@ testcase tLineConnect printlog "'" + (gApplication) +"'" - '/// Check the amount of objects ///' + printlog "Check the amount of objects" gMouseClick (10, 10) sleep 1 EditSelectAll @@ -400,12 +440,12 @@ testcase tLineConnect end if end if - '/// Connect the two objects selected ///' + printlog "Connect the two objects selected" hOpenContextMenu sleep 1 hMenuSelectNr(13) sleep 1 - '/// Check the amount of objects ///' + printlog "Check the amount of objects" gMouseClick (10, 10) sleep 1 EditSelectAll @@ -419,7 +459,7 @@ testcase tLineConnect value2 = left(StatusBarText,1) printlog "StatusBarText was: " + StatusBarText - '/// if same as the first value = wrong ///' + printlog "if same as the first value = wrong" if value1 = value2 then warnlog "Expected to find one object, but found " + value2 + " instead." endif @@ -427,22 +467,22 @@ testcase tLineConnect warnlog "Connect was not successful. We should have one object, but have " + value2 + " instead." endif - '/// unmark the objects, thereafter mark them again ///' + printlog "unmark the objects, thereafter mark them again" gMouseClick (10, 10) sleep 1 EditSelectAll sleep 1 - '/// Break them from eachother ///' + printlog "Break them from eachother" hOpenContextMenu sleep 1 hMenuSelectNr(11) sleep 1 - '/// unmark the objects, thereafter mark them again ///' + printlog "unmark the objects, thereafter mark them again" gMouseClick (10, 10) sleep 1 EditSelectAll sleep 1 - '/// Check the amount of objects ///' + printlog "Check the amount of objects" if (gApplication = "IMPRESS") then StatusBarText = DocumentImpress.StatusGetText(DocumentImpress.StatusGetItemID(1)) else @@ -453,19 +493,19 @@ testcase tLineConnect printlog "StatusBarText was: " + StatusBarText - '/// if the same as any of the ones before: Wrong ///' + printlog "if the same as any of the ones before: Wrong" if (value3 = value1 OR value3 = value2) then warnlog "Expected to find three objects, but found " + value3 + " instead." endif - '/// if 3 objects, then everything is ok ///' + printlog "if 3 objects, then everything is ok" if value3 = 3 then printlog "Found three objects. Means the test was successful." else warnlog "Wrong value, expected three objects, but found " + value3 + "." endif - '/// Go through the different Corner-styles ///' + printlog "Go through the different Corner-styles" hOpenContextMenu sleep 1 @@ -496,7 +536,7 @@ testcase tLineConnect CornerStyle.Select cfirst TabLinie.Ok - '/// And a nice finish to make life a bit happier for anyone who looks at the test ///' + printlog "And a nice finish to make life a bit happier for anyone who looks at the test" kontext "Toolbar" Ellipsen.Click if (gApplication = "DRAW") then @@ -525,9 +565,9 @@ testcase tLineConnect gMouseMove (48,43, 53,50) endif gMouseClick (10, 10) - '/// Close the document ///' + printlog "Close the document" hCloseDocument - '/// Endcase ///' + printlog "Endcase" endcase 'tiLineConnect '-------------------------------------------------------------------------------' diff --git a/testautomation/graphics/optional/includes/global/g_load_save.inc b/testautomation/graphics/optional/includes/global/g_load_save.inc index 8d64e158eb2a..d0d51e8337c7 100644 --- a/testautomation/graphics/optional/includes/global/g_load_save.inc +++ b/testautomation/graphics/optional/includes/global/g_load_save.inc @@ -45,76 +45,79 @@ ' #1 tSaveLoadLayoutSpreadsheet '\************************************************************************************* testcase tFileOpenSaveEtc - Dim Dokument$ - Dim Dokument2$ + Dim Dokument$ + Dim Dokument2$ Dokument$ = ConvertPath ( gOfficePath + "user\work\test1") Dokument2$ = ConvertPath ( gOfficePath + "user\work\test1_2") - if (gApplication = "IMPRESS") then + if (gApplication = "IMPRESS") then ExtensionString = "odp" else ExtensionString = "odg" end if - '/// delete previous created documents: 'user\\work\\test1*.od?' ///' + printlog "delete previous created documents: 'user\\work\\test1*.od?'" if Dir (Dokument$ + ".odp") <> "" then kill (Dokument$ + ".odp") if Dir (Dokument2$ + ".odg") <> "" then kill (Dokument2$ + ".odg") - '/// open application ///' + printlog "open application" hNewDocument gMouseclick 90,90 - '/// create a textframe with content ///' + printlog "create a textframe with content" Call hTextrahmenErstellen ( "This is a test",20,20,40,30 ) - '/// save file as 'test1' ///' + printlog "save file as 'test1'" hFileSaveAsKill (Dokument$ + "." + ExtensionString) Sleep 10 - '/// close Document ///' + printlog "close Document" hCloseDocument - printlog "- Document Saved and Closed" + printlog "Document Saved and Closed" - '/// load document 'test1' ///' + printlog "load document 'test1'" hFileOpen (Dokument$ + "." + ExtensionString) - Sleep 10 - '/// close Document ///' - hCloseDocument - printlog "- document Loaded and closed" - Sleep 10 - '/// load document 'test1' ///' - hFileOpen (Dokument$ + "." + ExtensionString) - ' 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 - Sleep 10 - gMouseclick 90,90 - '/// create another textbox with content ///' - Call hTextrahmenerstellen ( "Change",60,60,80,80 ) - '/// File->Close needn't work, just say CANCEL to the question about saving changes! ///' - FileClose - Kontext ' message about 'something changed should i [overwrite discard cancel]?' - if Messagebox.exists (5) then + Sleep 10 + printlog "close Document" + hCloseDocument + printlog "- document Loaded and closed" + Sleep 10 + printlog "load document 'test1'" + hFileOpen (Dokument$ + "." + ExtensionString) + printlog "check if the document is writable" + if fIsDocumentWritable = false then + printlog "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 + Sleep 10 + gMouseclick 90,90 + printlog "create another textbox with content" + Call hTextrahmenerstellen ( "Change",60,60,80,80 ) + printlog "File->Close needn't work, just say CANCEL to the question about saving changes!" + FileClose + Kontext + printlog "message about 'something changed should i [overwrite discard cancel]?'" + if Messagebox.exists (5) then printlog "2:"+messagebox.gettext Messagebox.Cancel - else + else Warnlog "Mesagebox is missing :-(" - endif - printlog "- Document loaded, changed and closed discarding all changes" + endif + printlog "Document loaded, changed and closed discarding all changes" - printlog "- Last version" - try - FileReload '/// File Reload ///' + printlog "Last version" + try + printlog "File Reload" + FileReload + catch + kontext "DocumentImpress" + try + printlog "File Reload" + FileReload catch - kontext "documentimpress" - try - FileReload '/// File Reload ///' - catch - warnlog "Damn reload ?? Why ? BREAKPOINT! File reload doesn't work. Create new object and try again :-(" + warnlog "BREAKPOINT! File reload doesn't work. Create new object and try again :-(" endcatch endcatch Kontext @@ -128,22 +131,24 @@ testcase tFileOpenSaveEtc if GetClipboardText = "Change" then Warnlog "- Last version not loaded. Changes in the document still in." printlog "- Change document, save it under different name" Kontext "DocumentImpress" - Call hTextrahmenErstellen ("Change2",10,10,50,20 ) '/// new textbox ///' + printlog "new textbox" + Call hTextrahmenErstellen ("Change2",10,10,50,20 ) gMouseclick 90,90 sleep 1 - FileSaveAs - Kontext "SpeichernDlg" - Dateiname.SetText Dokument2$ - Speichern.Click - kontext "AlienWarning" - if AlienWarning.exists(5) then - warnlog "#i41983# Alien Warning on export not allowed" - AlienWarning.OK - endif - Kontext "Messagebox" - if Messagebox.Exists(2) then Messagebox.Yes + FileSaveAs + Kontext "SpeichernDlg" + Dateiname.SetText Dokument2$ + Speichern.Click + kontext "AlienWarning" + if AlienWarning.exists(5) then + warnlog "#i41983# Alien Warning on export not allowed" + AlienWarning.OK + endif + Kontext "Messagebox" + if Messagebox.Exists(2) then Messagebox.Yes Sleep 3 - FileClose '/// Close document ///' + printlog "Close document" + FileClose sleep 10 Kontext "Messagebox" if Messagebox.Exists Then @@ -152,42 +157,42 @@ testcase tFileOpenSaveEtc end if sleep 2 printlog "- Loading write protected file" - FileOpen '/// Open write protected file ///' + FileOpen + printlog "Open write protected file" Kontext "OeffnenDlg" Dateiname.SetText (Dokument2$ + "." + ExtensionString) NurLesen.Check Oeffnen.Click - Sleep 10 - ' check if the document is writable - try - Call hTextrahmenErstellen ( "Hello",85,85,95,95 ) '/// attempt to create a textbox ///' - hTypeKeys "<SHIFT LEFT>",5 - hTypeKeys "<MOD1 C>" - sleep 1 - if GetClipboardText = "Hello" then Warnlog "Write protected document could be edited" + Sleep 10 + printlog "check if the document is writable" + try + printlog "attempt to create a textbox" + Call hTextrahmenErstellen ( "Hello",85,85,95,95 ) + hTypeKeys "<SHIFT LEFT>",5 + hTypeKeys "<MOD1 C>" + sleep 1 + if GetClipboardText = "Hello" then Warnlog "Write protected document could be edited" catch - Printlog "- Write protected document could not be edited" + Printlog "- Write protected document could not be edited" endcatch sleep 5 - FileClose '/// Close document ///' + printlog "Close document" + FileClose endcase 'tFileOpenSaveEtc -'-------------------------------------------------------- +'------------------------------------------------------------------------------- testcase tFileProperties qaerrorlog "#i88163#, File/properties/user defined fields get mixed up." goto endsub Call hNewDocument Call hTextrahmenErstellen ("This is a document to test the Menupoint in File/Properties",30,30,60,40) - if (gApplication = "IMPRESS") then ExtensionString = "odp" else ExtensionString = "odg" end if - FileProperties - Kontext active.SetPage TabDokumentinfo Kontext "TabDokumentinfo" @@ -212,9 +217,7 @@ testcase tFileProperties RefreshThisDocument.Check TabInternet.OK - hFileSaveAsKill ConvertPath (gOfficePath + "user\work\eigen." & ExtensionString) - FileClose Kontext "Active" if Active.Exists(2) then Active.Yes @@ -223,45 +226,45 @@ testcase tFileProperties Sleep 2 hFileOpen ConvertPath (gOfficePath + "user\work\eigen." + ExtensionString) - ' check if the document is writable + printlog "check if the document is writable" if fIsDocumentWritable = false then - ' make the document writable and check if it's succesfull + printlog "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 - FileProperties - Kontext - active.SetPage TabDokumentinfo - Kontext "TabDokumentinfo" - if Titel.GetText <> "Properties" then Warnlog "Description / Titel is wrong" - if Thema.GetText <> "Documentproperties" then Warnlog "Description / Thema is wrong" - if Schluesselworte.GetText <> "None" then Warnlog "Description / Keywords is wrong" - - qaerrorlog "#i95523#" - 'Kontext - 'active.SetPage TabBenutzer - 'Kontext "TabBenutzer" - 'if Info2.GetText <> "Thorsten Peters" then Warnlog "User Defined / Info2 is wrong" - - 'Infofelder.Click - 'sleep 2 - 'Kontext "InfonamenBearbeiten" - 'if Namen2.GetText <> "Name" then Warnlog "Edit Field Names / Info2 is wrong" - 'InfonamenBearbeiten.OK - - Kontext - active.SetPage TabInternet - Kontext "TabInternet" - if RefreshThisDocument.IsChecked = FALSE then Warnlog "Internet / 'Refresh this document' is not checked" - - TabInternet.Close - - Call hCloseDocument -endcase - -'******************************************************************************************** + FileProperties + Kontext + active.SetPage TabDokumentinfo + Kontext "TabDokumentinfo" + if Titel.GetText <> "Properties" then Warnlog "Description / Titel is wrong" + if Thema.GetText <> "Documentproperties" then Warnlog "Description / Thema is wrong" + if Schluesselworte.GetText <> "None" then Warnlog "Description / Keywords is wrong" + + qaerrorlog "#i95523#" + 'Kontext + 'active.SetPage TabBenutzer + 'Kontext "TabBenutzer" + 'if Info2.GetText <> "Thorsten Peters" then Warnlog "User Defined / Info2 is wrong" + + 'Infofelder.Click + 'sleep 2 + 'Kontext "InfonamenBearbeiten" + 'if Namen2.GetText <> "Name" then Warnlog "Edit Field Names / Info2 is wrong" + 'InfonamenBearbeiten.OK + + Kontext + active.SetPage TabInternet + Kontext "TabInternet" + if RefreshThisDocument.IsChecked = FALSE then Warnlog "Internet / 'Refresh this document' is not checked" + + TabInternet.Close + + Call hCloseDocument +endcase 'tFileProperties + +'------------------------------------------------------------------------------- testcase tFilePassword52 Dim Datei$ @@ -271,7 +274,6 @@ testcase tFilePassword52 dim sExt() as string sExt = array("d","a") - ' passwo52.sd d-preas a-draw for i = 0 to 1 Datei$ = ConvertPath ( gTesttoolPath + "graphics\required\input\passwo52.sd"+sExt(i) ) hFileOpen(Datei$) @@ -290,9 +292,9 @@ testcase tFilePassword52 endif hCloseDocument next i -endcase +endcase 'tFilePassword52 -'******************************************************************************************** +'------------------------------------------------------------------------------- testcase tFileOpenImport dim q as integer @@ -324,28 +326,28 @@ testcase tFileOpenImport if (gApplication="DRAW") then Call hCloseDocument endif -endcase +endcase 'tFileOpenImport -'******************************************************************************************** +'------------------------------------------------------------------------------- testcase tTestDXF255CharBug -'/// tries to load a DXF-document which has a string-leght of 255 characters. ///' -dim q as integer - call hNewDocument - InsertGraphicsFromFile '/// insert graphic ///' - sleep 1 - kontext "Active" - sleep 1 + printlog "tries to load a DXF-document which has a string-leght of 255 characters." + dim q as integer + call hNewDocument + printlog "insert graphic " + InsertGraphicsFromFile + sleep 1 + kontext "Active" + sleep 1 if Active.Exists Then - Active.OK + Active.OK end if sleep 1 - Kontext "GrafikEinfuegenDlg" - sleep 2 - '/// Dateiname.SetText (ConvertPath (gTesttoolpath + "graphics\required\input\255chars.dxf")) ///' - Dateiname.SetText (ConvertPath (gTesttoolpath + "graphics\required\input\255chars.dxf")) - Oeffnen.Click - Sleep 2 + Kontext "GrafikEinfuegenDlg" + sleep 2 + Dateiname.SetText (ConvertPath (gTesttoolpath + "graphics\required\input\255chars.dxf")) + Oeffnen.Click + Sleep 2 if gApplication = "DRAW" then Kontext "Documentdraw" @@ -375,7 +377,7 @@ dim q as integer Call hCloseDocument endcase 'tTestDXF255CharBug -'******************************************************************************************** +'------------------------------------------------------------------------------- testcase tDeletedTemplate dim i as integer @@ -395,35 +397,35 @@ testcase tDeletedTemplate - '/// delete previous created documents: 'user\\work\\test*.odp' ///' + printlog "delete previous created documents: 'user\\work\\test*.odp'" if Dir (Dokument1$) <> "" then kill Dokument1$ if Dir (Dokument2$) <> "" then kill Dokument2$ - '/// open application ///' + printlog "open application" hNewDocument gMouseclick 90,90 - '/// create a textframe with content ///' + printlog "create a textframe with content" Call hTextrahmenErstellen ( "This is the first file",20,20,40,30 ) - '/// save file as 'test1.odp' ///' + printlog "save file as 'test1.odp'" hFileSaveAsKill (Dokument1$) Sleep 10 - '/// close Document ///' + printlog "close Document" hCloseDocument printlog "- Document 'test1.odp' Saved and Closed" - '/// open application again ///' + printlog "open application again" hNewDocument gMouseclick 90,90 - '/// create another textframe with content ///' + printlog "create another textframe with content" Call hTextrahmenErstellen ( "This is the second file",20,20,40,30 ) - '/// save file as 'test2.odp' ///' + printlog "save file as 'test2.odp'" hFileSaveAsKill (Dokument2$) Sleep 10 - '/// close Document ///' + printlog "close Document" hCloseDocument printlog "- Document 'test2.odp' Saved and Closed" - '/// Delete the first file ///' + printlog "Delete the first file" try kill Dokument1$ Printlog " Correctly deleted the file: " + Dokument1$ @@ -431,28 +433,29 @@ testcase tDeletedTemplate warnlog "Could not delete the file: " + Dokument1$ endcatch - '/// File => New => Presentation ///' - FileAutopilotPresentation '/// new document-autopilot ///' - Kontext "AutopilotPraesentation1" - sleep 5 - Existingpresentation.Check - sleep 5 - kontext "active" - if active.exists then - SavedActiveMessage = Active.GetText - QaErrorLog "Message: " + SavedActiveMessage - active.ok - Kontext "AutopilotPraesentation1" - if Existinglist.GetSelText = "test1.odp" then - warnlog " The deleted File was found. Messagebox said: " + SavedActiveMessage - endif - SavedActiveMessage = "" - endif - Kontext "AutopilotPraesentation1" - Existinglist.TypeKeys "<HOME>" - sleep 5 - found = false - for i = 1 to Existinglist.GetItemCount + printlog "File => New => Presentation" + printlog "new document-autopilot" + FileAutopilotPresentation + Kontext "AutopilotPraesentation1" + sleep 5 + Existingpresentation.Check + sleep 5 + kontext "active" + if active.exists then + SavedActiveMessage = Active.GetText + QaErrorLog "Message: " + SavedActiveMessage + active.ok + Kontext "AutopilotPraesentation1" + if Existinglist.GetSelText = "test1.odp" then + warnlog " The deleted File was found. Messagebox said: " + SavedActiveMessage + endif + SavedActiveMessage = "" + endif + Kontext "AutopilotPraesentation1" + Existinglist.TypeKeys "<HOME>" + sleep 5 + found = false + for i = 1 to Existinglist.GetItemCount kontext "active" if active.exists then SavedActiveMessage = Active.GetText @@ -473,7 +476,7 @@ testcase tDeletedTemplate if found = true then warnlog " An error-message showed up. Eventually a result of '138498'" AutopilotPraesentation1.Cancel Sleep 2 - '/// Delete the second file ///' + printlog "Delete the second file" try kill Dokument2$ Printlog " Correctly deleted the file: " + Dokument2$ @@ -482,7 +485,7 @@ testcase tDeletedTemplate endcatch endcase 'tDeletedTemplate -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutEmpty Dim NewFileDir as String @@ -492,7 +495,6 @@ testcase tSaveLoadLayoutEmpty printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -510,13 +512,12 @@ testcase tSaveLoadLayoutEmpty sleep (5) call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below. - - printlog " Will try to delete the directory: " + NewFileDir + printlog "Will try to delete the directory: " + NewFileDir app.rmDir NewFileDir endcase 'tSaveLoadLayoutEmpty -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutOLE qaerrorlog "not yet ready" @@ -525,7 +526,7 @@ testcase tSaveLoadLayoutOLE NewFileDir = ConvertPath (gOfficePath + "user\work\LayoutTest\") - printlog " Will try to create the directory: " + NewFileDir + printlog "Will try to create the directory: " + NewFileDir app.mkdir NewFileDir @@ -563,12 +564,12 @@ testcase tSaveLoadLayoutOLE call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below. - printlog " Will try to delete the directory: " + NewFileDir + printlog "Will try to delete the directory: " + NewFileDir app.rmDir ConvertPath (gOfficePath + "user\work\LayoutTest\")' NewFileDir endcase 'tSaveLoadLayoutOLE -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutText qaerrorlog "not yet ready" @@ -580,7 +581,6 @@ testcase tSaveLoadLayoutText printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -601,17 +601,16 @@ testcase tSaveLoadLayoutText hTypeKeys ("<TAB><TAB><TAB>") hTypeKeys ("<Return>") hTypeKeys ("<ESCAPE>") - ' LayoutsPreview.TypeKeys "<RETURN>" sleep (5) call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below. - printlog " Will try to delete the directory: " + NewFileDir + printlog "Will try to delete the directory: " + NewFileDir app.rmDir ConvertPath (gOfficePath + "user\work\LayoutTest\")' NewFileDir endcase 'tSaveLoadLayoutText -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutOutline qaerrorlog "not yet ready" @@ -623,7 +622,6 @@ testcase tSaveLoadLayoutOutline printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -653,7 +651,7 @@ testcase tSaveLoadLayoutOutline endcase 'tSaveLoadLayoutOutline -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutPicture qaerrorlog "not yet ready" @@ -665,7 +663,6 @@ testcase tSaveLoadLayoutPicture printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -695,7 +692,7 @@ testcase tSaveLoadLayoutPicture endcase 'tSaveLoadLayoutPicture -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutChart qaerrorlog "not yet ready" @@ -707,7 +704,6 @@ testcase tSaveLoadLayoutChart printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -737,7 +733,7 @@ testcase tSaveLoadLayoutChart endcase 'tSaveLoadLayoutChart -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSaveLoadLayoutSpreadsheet qaerrorlog "not yet ready" @@ -749,7 +745,6 @@ testcase tSaveLoadLayoutSpreadsheet printlog " Will try to create the directory: " + NewFileDir app.mkdir NewFileDir - gApplication = "IMPRESS" Call hNewDocument @@ -774,10 +769,10 @@ testcase tSaveLoadLayoutSpreadsheet call fSaveLoadAllFormats (NewFileDir) 'Runs the Function below. - printlog " Will try to delete the directory: " + NewFileDir + printlog "Will try to delete the directory: " + NewFileDir app.rmDir ConvertPath (gOfficePath + "user\work\LayoutTest\")' NewFileDir endcase 'tSaveLoadLayoutSpreadsheet -'**************************************************************************************************** +'------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/global/g_mediaplayer.inc b/testautomation/graphics/optional/includes/global/g_mediaplayer.inc index 5961a2132467..f78cdf816815 100644 --- a/testautomation/graphics/optional/includes/global/g_mediaplayer.inc +++ b/testautomation/graphics/optional/includes/global/g_mediaplayer.inc @@ -47,37 +47,39 @@ testcase g_mediaplayer goto endsub endif Datei$ = ConvertPath (convertPath (gTesttoolPath + "graphics\required\input\29secsound.wav")) - '/// Open New Document ///' + printlog "Open New Document" Call hNewDocument sleep 2 - '/// Check if the Media Player already exists - if so - close it ///' + printlog "Check if the Media Player already exists - if so - close it" kontext "mPlayer" - if mPlayer.exists then ' Close the MediaPlayer - warnlog "The MediaPlayer was visible since some earlier test. Plese notify FHA." + printlog "Close the MediaPlayer if it is open already" + if mPlayer.exists then + warnlog "The MediaPlayer was visible since some earlier test." ToolsMediaPlayer printlog "Closed the Media Player" endif - '/// Tools - MediaPlayer ///' + printlog "Tools - MediaPlayer" ToolsMediaPlayer sleep 2 - '/// Open file ///' 'a bigger / longer one + printlog "Open file" kontext "mPlayer" if mPlayer.exists then printlog "The MediaPlayer was open." else - warnlog "Tools - MediaPlayer didnt work. The MediaPlayer wasnt visible. Aborting test." - Call hCloseDocument '/// Close document ///' - goto endsub + warnlog "Tools - MediaPlayer didnt work. The MediaPlayer wasnt visible. Aborting test." + printlog "Close document" + Call hCloseDocument + goto endsub endif Mopen.Click kontext "OeffnenDlg" Pfad.SetText Datei$ Oeffnen.Click - '/// This test wont work correctly under Solaris and Linux, ///' - '/// unless some optional Media-libraries are installed. ///' - '/// Therefore we warn the tester about it if we cannot open the file. ///' + printlog "This test wont work correctly under Solaris and Linux," + printlog "unless some optional Media-libraries are installed." + printlog "Therefore we warn the tester about it if we cannot open the file." iWaitIndex = 0 do while OeffnenDlg.Exists AND iWaitIndex < 10 @@ -90,7 +92,8 @@ testcase g_mediaplayer Active.OK kontext "Mplayer" ToolsMediaPlayer - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument goto endsub else kontext "Mplayer" @@ -99,7 +102,7 @@ testcase g_mediaplayer timevalue1 = mTimeedit.GetText - '/// Stop ///' + printlog "Stop" sleep 2 mStop.Click printlog "Just pressed stop." @@ -109,17 +112,18 @@ testcase g_mediaplayer timevalue3 = mTimeedit.GetText printlog "The time was: " + mTimeedit.GetText if timevalue1 = timevalue2 AND timevalue2 = timevalue3 then - if gtSYSName <> "WinXP" then '("Solaris x86" OR "Linux" OR "Solaris") then - warnlog "The sound doesnt seem to be played at all. And since the test is run on a platform which needs extra libraries, the test ends now." - kontext "Mplayer" - if Mplayer.Exists(3) then - ToolsMediaPlayer - endif - Call hCloseDocument '/// close document ///' - goto endsub - else - warnlog "The sound doesnt seem to be played at all, but I will continue the test. The platform was: " + gtSYSName - endif + if gtSYSName <> "WinXP" then '("Solaris x86" OR "Linux" OR "Solaris") then + warnlog "The sound doesnt seem to be played at all. And since the test is run on a platform which needs extra libraries, the test ends now." + kontext "Mplayer" + if Mplayer.Exists(3) then + ToolsMediaPlayer + endif + printlog "close document" + Call hCloseDocument + goto endsub + else + warnlog "The sound doesnt seem to be played at all, but I will continue the test. The platform was: " + gtSYSName + endif else if timevalue1 <> timevalue2 AND timevalue2 = timevalue3 then Printlog "the stop-button seemed to work. Good." @@ -127,7 +131,7 @@ testcase g_mediaplayer warnlog "Very strange. The first value was: " + timevalue1 + ". Second: " + timevalue2 + ". Third: " + timevalue3 endif endif - '/// Play ///' + printlog "Play" ' Save value timevalue1 = mTimeedit.GetText ' Press 'Play' @@ -141,7 +145,7 @@ testcase g_mediaplayer Printlog "the play-button seemed to work. Good." endif - '/// Pause ///' + printlog "Pause" mPlay.Click sleep 10 mPause.Click @@ -156,19 +160,23 @@ testcase g_mediaplayer Printlog "the pause-button seemed to work. Good." endif - '/// Time ///' - mStop.Click 'to get to the beginning. - sleep 1 'And make sure it's really the beginning. + printlog "Time" + printlog " Click Stop to get to the beginning." + mStop.Click + sleep 1 + printlog "And make sure it's really the beginning." timevalue1 = mTimeedit.GetText if timevalue1 <> "00:00:00 / 00:00:29" then warnlog "Expected the time to go back to 00:00:00, but was " + timevalue1 + " instead." - mStop.Click 'to make another try to get to the beginning again. + printlog "to make another try to get to the beginning again." + mStop.Click ' else printlog "Sound stopped, time-value set to 00:00:00." endif printlog "We press 'Play'" - mPlay.Click 'to get it running + printlog "Click play to get it running" + mPlay.Click sleep 5 timefound = 0 @@ -192,41 +200,34 @@ testcase g_mediaplayer warnlog "Either the time didnt change, or the test-computer is too fast." endif - '-Repeat - 'Plays the file repeatedly. - '/// Loop ///' + printlog "Loop" mLoop.Click - '/// Volume ///' - 'mVolume. 'Click - '-Volume slider - 'Adjusts the volume. + printlog "Volume" - '/// Mute ///' + printlog "Mute" mMute.Click sleep 1 mMute.Click - '-Mute - 'Turns sound off and on. - '/// Time-slider ///' + printlog "Time-slider" ' mTimeslider. 'Click '-Position slider 'Moves to a different position in the file. - '/// Scroll-whatever ///' + printlog "Scroll-whatever" 'mZoomlistbox. '-Zoom 'Adjusts the size of the movie playback. - '/// Apply ///' + printlog "Apply" mInsert.Click sleep 10 - '/// Close the MediaPlayer via Tools - MediaPlayer ///' + printlog "Close the MediaPlayer via Tools - MediaPlayer" ToolsMediaPlayer - '/// Check if there is an object available. ///' + printlog "Check if there is an object available." if (gApplication = "IMPRESS") then kontext "DocumentImpress" else @@ -242,15 +243,15 @@ testcase g_mediaplayer Kontext "TabPositionAndSize" if Width.Exists then Printlog "Position and Size came up, object inserted correctly." - '/// Close dialog TabPositionAndSize with 'OK' ///' + printlog "Close dialog TabPositionAndSize with 'OK'" TabPositionAndSize.OK else Warnlog "Position And Size didn't come up, was there no sound-object inserted?" endif sleep 2 - '/// close document ///' - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument else qaerrorLog "#74350# - Different strings in g_mediaplayer under Italian." endif -endcase +endcase
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/global/g_paneview.inc b/testautomation/graphics/optional/includes/global/g_paneview.inc index a2e7bdb87266..fb3620496759 100644 --- a/testautomation/graphics/optional/includes/global/g_paneview.inc +++ b/testautomation/graphics/optional/includes/global/g_paneview.inc @@ -78,7 +78,7 @@ testcase tiMinimize_Maximize_Docking_SlidePane Sleep 1 Slides.Size 300, 400 Sleep 1 - Slides.Size 150, 250 + Slides.Size 170, 250 Sleep 1 Slides.Size xSize%, ySize% Sleep 1 @@ -451,7 +451,7 @@ testcase tdMinimize_Maximize_Docking_Pagepane Sleep 1 Pagepane.Size 300, 400 Sleep 1 - Pagepane.Size 150, 250 + Pagepane.Size 170, 250 Sleep 1 Pagepane.Size xSize%, ySize% Sleep 1 diff --git a/testautomation/graphics/optional/includes/global/g_shaddow.inc b/testautomation/graphics/optional/includes/global/g_shaddow.inc index 1dfd01f305aa..7732cc5bc7e8 100644 --- a/testautomation/graphics/optional/includes/global/g_shaddow.inc +++ b/testautomation/graphics/optional/includes/global/g_shaddow.inc @@ -54,19 +54,19 @@ testcase tiShaddow dim linewidth as string dim cornerstyletype as string - '/// Set the file-extension we'll be using when opening the saved file ///' + printlog "Set the file-extension we'll be using when opening the saved file " if (gApplication = "IMPRESS") then ExtensionString = "odp" else ExtensionString = "odg" end if - '/// Open application ///' + printlog "Open application " Call hNewDocument Call sSelectEmptyLayout sleep 1 - '/// Import picture ///' + printlog "Import picture " InsertGraphicsFromFile sleep 3 kontext "Active" @@ -81,10 +81,10 @@ testcase tiShaddow Oeffnen.Click printlog "Inserted file" sleep 2 - '/// Select all ///' + printlog "Select all" EditSelectAll sleep 3 - '/// Check values and save them ///' + printlog "Check values and save them" FormatPositionAndSize kontext active.SetPage TabPositionAndSize @@ -92,11 +92,11 @@ testcase tiShaddow ImageWidth = Width.GetText ImageHeight = Height.GetText printlog "Got values from position and size" - '/// Check the "Protect Size"-button. And close dialogue. ///' + printlog "Check the Protect Size-button. And close dialogue. " ProtectSize.Check TabPositionAndSize.Ok - '/// Add Shaddow via Toolbar-Button ///' + printlog "Add Shaddow via Toolbar-Button " Kontext "GraphicObjectbar" if GraphicObjectbar.Exists = FALSE then ViewToolbarsPicture @@ -106,21 +106,21 @@ testcase tiShaddow end if sleep 1 - '/// click button 'Shadow' ///' - Schatten.Click -' '/// Check and save Shaddow-values via context-menu ///' - EditSelectAll - hOpenContextMenu - sleep(2) - if hMenuFindSelect(10142, true, 4) = false then + printlog "click button 'Shadow'" + Schatten.Click + printlog " Check and save Shaddow-values via context-menu " + EditSelectAll + hOpenContextMenu + sleep(2) + if hMenuFindSelect(10142, true, 4) = false then Warnlog "Context-Menu-entry `Area` was not found. Therefore the test ends." Call hCloseDocument Goto Endsub - endif - '/// Select Contextmenu entry "Area" ///' - sleep(2) + endif + printlog " Select Contextmenu entry Area " + sleep(2) kontext "TabArea" - '/// Switch to Shaddow-tabpage, do some changes, save them, close dialogue + printlog "Switch to Shaddow-tabpage, do some changes, save them, close dialogue" Kontext active.SetPage TabSchatten kontext "TabSchatten" @@ -131,20 +131,20 @@ testcase tiShaddow Warnlog "'Use Shadow' doesn't exist or isn't visible." endif - '/// Change Distance and Transparency-values ///' - Entfernung.More ',2 - Transparenz.More ',2 - shadowdistancevalue = Entfernung.GetText - shadowcolorvalue = Farbe.GetSelText - shadowtransparencyvalue = Transparenz.GetText - printlog "Got values from TabArea" - TabSchatten.Ok + printlog "Change Distance and Transparency-values " + Entfernung.More ',2 + Transparenz.More ',2 + shadowdistancevalue = Entfernung.GetText + shadowcolorvalue = Farbe.GetSelText + shadowtransparencyvalue = Transparenz.GetText + printlog "Got values from TabArea" + TabSchatten.Ok - '/// Check if it's the same when going over FormatArea ///' + printlog "Check if it's the same when going over FormatArea " FormatArea sleep 1 kontext "TabArea" - '/// Switch to Shaddow-tabpage, do some changes, save them, close dialogue ///' + printlog "Switch to Shaddow-tabpage, do some changes, save them, close dialogue " Kontext active.SetPage TabSchatten kontext "TabSchatten" @@ -165,23 +165,23 @@ testcase tiShaddow endif TabSchatten.Ok - '/// Add Cornerstyle via FormatLine ///' - FormatLine - Kontext - Messagebox.SetPage TabLinie - kontext "TabLinie" - Stil.Select 2 ' Select Continuously. - linetype = Stil.GetItemText - Farbe.Select 2 ' Select Blue - linecolour = Farbe.GetItemText - Breite.More 3 ' Set Width to 3 - linewidth = Breite.Gettext - CornerStyle.Select 4 ' Select number four: Beveled - cornerstyletype = CornerStyle.GetSelText - printlog "Cornerstyle is: " + CornerStyle.GetSelText '+ cornerstyletype + printlog "Add Cornerstyle via FormatLine " + FormatLine + Kontext + Messagebox.SetPage TabLinie + kontext "TabLinie" + Stil.Select 2 ' Select Continuously. + linetype = Stil.GetItemText + Farbe.Select 2 ' Select Blue + linecolour = Farbe.GetItemText + Breite.More 3 ' Set Width to 3 + linewidth = Breite.Gettext + CornerStyle.Select 4 ' Select number four: Beveled + cornerstyletype = CornerStyle.GetSelText + printlog "Cornerstyle is: " + CornerStyle.GetSelText '+ cornerstyletype TabLinie.ok - '/// Check values via PositionAndSize via the Contextmenu ///' + printlog "Check values via PositionAndSize via the Contextmenu " hOpenContextmenu sleep(2) if hMenuFindSelect(10087, true, 1) = false then @@ -189,35 +189,35 @@ testcase tiShaddow Call hCloseDocument Goto Endsub endif - 'Select "Position and Size" - sleep(2) - Kontext - Active.SetPage TabPositionAndSize - Kontext "TabPositionAndSize" - if ImageWidth <> Width.GetText then warnlog "Position X differs. Should be: " + ImageWidth + " But is: " + Width.GetText - if ImageHeight <> Height.GetText then warnlog "Position Y differs. Should be: " + ImageHeight + " But is: " + Height.GetText + printlog "Select Position and Size" + sleep(2) + Kontext + Active.SetPage TabPositionAndSize + Kontext "TabPositionAndSize" + if ImageWidth <> Width.GetText then warnlog "Position X differs. Should be: " + ImageWidth + " But is: " + Width.GetText + if ImageHeight <> Height.GetText then warnlog "Position Y differs. Should be: " + ImageHeight + " But is: " + Height.GetText TabPositionAndSize.OK - '/// Check Cornerstyle via FormatLine ///' - FormatLine - Kontext - Messagebox.SetPage TabLinie - kontext "TabLinie" - if linetype <> Stil.GetItemText then warnlog "Linetype should be: " + linetype + " But is: " + Stil.GetItemText - if linecolour <> Farbe.GetItemText then warnlog "Linecolour should be: " + linetype + " But is: " + Farbe.GetItemText - if linewidth <> Breite.GetText then warnlog "Linewidth should be: " + linewidth + " But is: " + Breite.GetText - if cornerstyletype <> CornerStyle.GetSelText then warnlog "CornerStyle should be: " + cornerstyletype + " But is: " + CornerStyle.GetSelText 'ItemText - TabLinie.ok - - '/// Check if the Shaddow-button is activated ///' - Kontext "GraphicObjectbar" - if Schatten.GetState(2) <> 1 then - warnlog "Shaddow-button shouldnt have been checked" - endif + printlog "Check Cornerstyle via FormatLine " + FormatLine + Kontext + Messagebox.SetPage TabLinie + kontext "TabLinie" + if linetype <> Stil.GetItemText then warnlog "Linetype should be: " + linetype + " But is: " + Stil.GetItemText + if linecolour <> Farbe.GetItemText then warnlog "Linecolour should be: " + linetype + " But is: " + Farbe.GetItemText + if linewidth <> Breite.GetText then warnlog "Linewidth should be: " + linewidth + " But is: " + Breite.GetText + if cornerstyletype <> CornerStyle.GetSelText then warnlog "CornerStyle should be: " + cornerstyletype + " But is: " + CornerStyle.GetSelText 'ItemText + TabLinie.ok + + printlog "Check if the Shaddow-button is activated " + Kontext "GraphicObjectbar" + if Schatten.GetState(2) <> 1 then + warnlog "Shaddow-button shouldnt have been checked" + endif - '/// Save the file. Then close the office and reload the file ///' + printlog "Save the file. Then close the office and reload the file " sFileName = ( ConvertPath(gOfficePath + "user\work\shaddow-test")) - '/// File-Save As with filter as: "user\temp\shaddow-test" ///' + printlog "File-Save As with filter as: user\temp\shaddow-test " try FileSaveAs Kontext "SpeichernDlg" @@ -233,12 +233,12 @@ testcase tiShaddow warnlog "Error when saving file." endcatch - '/// Close the office-session ///' + printlog "Close the office-session " FileClose Kontext "Messagebox" if Messagebox.Exists(2) then Messagebox.Yes Sleep 3 - '/// Open the saved file ///' + printlog "Open the saved file " try hFileOpen sFileName + "." + ExtensionString Sleep 3 @@ -247,11 +247,11 @@ testcase tiShaddow warnlog "Error when opening file." endcatch - '/// Select all ///' + printlog "Select all " EditSelectAll sleep 2 - '/// Check if the Shaddow-button still is activated ///' + printlog "Check if the Shaddow-button still is activated " kontext "GraphicObjectbar" if schatten.Getstate(2) <> 1 then warnlog "The Shadow-button should be activated" @@ -259,7 +259,7 @@ testcase tiShaddow Printlog "Shaddowbutton activated, good." endif - '/// Check the attributes for the picture ///' + printlog "Check the attributes for the picture " hOpenContextmenu sleep(2) if hMenuFindSelect(10087, true, 1) = false then @@ -267,7 +267,7 @@ testcase tiShaddow Call hCloseDocument Goto Endsub endif - 'Select "Position and Size" + printlog "Position and Size" sleep(2) Kontext Active.SetPage TabPositionAndSize @@ -279,7 +279,7 @@ testcase tiShaddow FormatArea sleep 1 kontext "TabArea" - '/// Switch to Shaddow-tabpage, do some changes, save them, close dialogue ///' + printlog "Switch to Shaddow-tabpage, do some changes, save them, close dialogue " Kontext active.SetPage TabSchatten kontext "TabSchatten" @@ -293,7 +293,7 @@ testcase tiShaddow if shadowcolorvalue <> Farbe.GetSelText then warnlog "Color value changed. Should be: " + shadowcolorvalue + ". But is: " + Farbe.gettext if shadowtransparencyvalue <> Transparenz.GetText then warnlog "Transparency value changed. Should be: " + shadowtransparencyvalue + ". But is: " + Transparenz.gettext - '/// Check Transparency ///' + printlog "Check Transparency" Kontext Active.SetPage TabTransparenz kontext "TabTransparenz" @@ -306,7 +306,7 @@ testcase tiShaddow kontext "TabSchatten" TabSchatten.Ok - '/// Check Cornerstyle via FormatLine ///' + printlog "Check Cornerstyle via FormatLine " FormatLine Kontext Messagebox.SetPage TabLinie @@ -317,7 +317,7 @@ testcase tiShaddow if cornerstyletype <> CornerStyle.GetSelText then warnlog "CornerStyle should be: " + cornerstyletype + " But is: " + CornerStyle.GetSelText 'ItemText TabLinie.ok - '/// If Impress: Save as Powerpoint-file. If Draw: Save as usual Draw-file. ///' + printlog "If Impress: Save as Powerpoint-file. If Draw: Save as usual Draw-file. " if (gApplication = "IMPRESS") then ExtensionString = "ppt" else @@ -344,19 +344,19 @@ testcase tiShaddow 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 + "." + ExtensionString) printlog "File opened: " + sFileName + "." + ExtensionString Sleep 3 - '/// Select all ///' + printlog "Select all" EditSelectAll - '/// Check the attributes for the picture ///' + printlog "Check the attributes for the picture" hOpenContextmenu sleep(2) if hMenuFindSelect(10087, true, 1) = false then @@ -364,7 +364,7 @@ testcase tiShaddow Call hCloseDocument Goto Endsub endif - 'Select "Position and Size" + printlog "Select Position and Size" sleep(2) Kontext Active.SetPage TabPositionAndSize @@ -373,7 +373,7 @@ testcase tiShaddow if ImageHeight <> Height.GetText then warnlog "Position X differs. Should be: " + ImageHeight + " But is: " + Height.GetText TabPositionAndSize.OK - '/// Check if transparency has disappeared and if the cornerstyle has changed ///' + printlog "Check if transparency has disappeared and if the cornerstyle has changed" FormatArea Kontext Messagebox.SetPage TabTransparenz @@ -402,7 +402,7 @@ testcase tiShaddow TabTransparenz.Cancel - '/// Check Cornerstyle via FormatLine ///' + printlog "Check Cornerstyle via FormatLine " FormatLine Kontext Messagebox.SetPage TabLinie @@ -413,7 +413,7 @@ testcase tiShaddow if cornerstyletype <> CornerStyle.GetSelText then warnlog "CornerStyle should be: " + cornerstyletype + " But is: " + CornerStyle.GetSelText 'ItemText TabLinie.ok - '/// Remove the Shaddow, Transparency and Cornerstyle ///' + printlog "Remove the Shaddow, Transparency and Cornerstyle" FormatArea Kontext Messagebox.SetPage TabTransparenz @@ -421,14 +421,14 @@ testcase tiShaddow KeineTransparenz.Check sleep 1 kontext "TabArea" - '/// Switch to Shaddow-tabpage, do some changes, save them, close dialogue ///' + printlog "Switch to Shaddow-tabpage, do some changes, save them, close dialogue" Kontext active.SetPage TabSchatten kontext "TabSchatten" Anzeigen.UnCheck TabSchatten.Ok - '/// If Impress: Save as Powerpoint-file. If Draw: Save as usual Draw-file. ///' + printlog "If Impress: Save as Powerpoint-file. If Draw: Save as usual Draw-file." if (gApplication = "IMPRESS") then ExtensionString = "ppt" else @@ -454,19 +454,19 @@ testcase tiShaddow printlog "Saved as: " + sFileName Sleep 3 - '/// Close the office-session ///' + printlog "Close the office-session" FileClose Kontext "Messagebox" if Messagebox.Exists(2) then Messagebox.Yes Sleep 3 - '/// Open the saved file ///' + printlog "Open the saved file" hFileOpen (sFileName + "." + ExtensionString) printlog "File opened: " + sFileName + "." + ExtensionString Sleep 3 - '/// Select all ///' + printlog "Select all" EditSelectAll - '/// Check the attributes for the picture ///' + printlog "Check the attributes for the picture" hOpenContextmenu sleep(2) if hMenuFindSelect(10087, true, 1) = false then @@ -474,7 +474,7 @@ testcase tiShaddow Call hCloseDocument Goto Endsub endif - 'Select "Position and Size" + printlog "Select Position and Size" sleep(2) Kontext Active.SetPage TabPositionAndSize @@ -483,7 +483,7 @@ testcase tiShaddow if ImageHeight <> Height.GetText then warnlog "Position X differs. Should be: " + ImageHeight + " But is: " + Height.GetText TabPositionAndSize.OK - '/// Check if transparency has disappeared ///' + printlog "Check if transparency has disappeared " FormatArea Kontext Messagebox.SetPage TabTransparenz @@ -495,7 +495,7 @@ testcase tiShaddow end if TabTransparenz.Cancel - '/// Check if the cornerstyle has changed via FormatLine ///' + printlog "Check if the cornerstyle has changed via FormatLine " FormatLine Kontext Messagebox.SetPage TabLinie @@ -506,7 +506,7 @@ testcase tiShaddow if cornerstyletype <> CornerStyle.GetSelText then warnlog "CornerStyle should be: " + cornerstyletype + " But is: " + CornerStyle.GetSelText 'ItemText TabLinie.ok - '/// Close application ///' + printlog "Close application" Call hCloseDocument Printlog "Finished Shaddow-test for " + gApplication diff --git a/testautomation/graphics/optional/includes/global/g_spellcheck.inc b/testautomation/graphics/optional/includes/global/g_spellcheck.inc index 1c82bf3921c3..1684738ded35 100644 --- a/testautomation/graphics/optional/includes/global/g_spellcheck.inc +++ b/testautomation/graphics/optional/includes/global/g_spellcheck.inc @@ -29,113 +29,75 @@ '* '* short description : '* -'******************************************************************* -'* -' #1 tiToolsSpellcheckCorrect -' #1 tiToolsSpellcheckError -' #1 tiToolsSpellcheckCheck -' #1 tToolsSpellcheckAutoSpellcheck -'* '\******************************************************************* -testcase tiToolsSpellcheckCorrect - if iSprache = 48 then - qaerrorlog "This test is not adapted for polish, 48." - got endsub +testcase tiToolsSpellcheckCheck_AlwaysIgnore + + Dim sExt as string + + Dim sWrongWord as String + Dim sRightWord as string + + dim aWords(2) as string + aWords() = getWordsForLanguage() + + sWrongWord = aWords(0) + sRightWord = aWords(1) + + if(sWrongWord = "" OR sRightWord = "") then ' if any word is empty then the test should stop + qaerrorlog "no spellcheck test for the langauges " + iSprache + " available." + goto endsub endif - Dim DieDatei as String - dim lFiles(100) as string - dim i as integer - dim iFiles as integer + delete_word_from_dictionary(sWrongWord,"IgnoreAllList") - lFiles(0)=0 - Printlog "- Checking Dictionary-Files" ' borrowed from w_106.inc - select case iSprache - case 01 : DieDatei = "01-44-hyph.dat" - case else : DieDatei = "" & iSprache & "-hyph.dat" - end select - DieDatei = Convertpath(gNetzOfficePath + "share\dict\" + DieDatei) - if gPlatGroup <> "unx" then - if (Dir(DieDatei) = "") then - if bAsianLan then - printlog "Dictionary not found : " + DieDatei + ", but is AsianLan, so OK :-)" - else - if gNetzInst then - printlog "Dictionary not found : " + DieDatei - else - warnlog "Dictionary not found : " + DieDatei - end if - end if - else - Printlog " Dictionary has been installed : " + DieDatei - end if - end if - iFiles = GetFileList (Convertpath (gNetzOfficePath + "share\dict\"), "*.dat" ,lFiles()) - for i = 1 to iFiles - printlog " " + i + ": " + DateiExtract(lFiles(i)) - next i + if Ucase(gApplication) = "DRAW" then + sExt = ".odg" + else + sExt = ".odp" + endif - Call hNewDocument - ' sleep 2 - ToolsSpellcheck - Kontext "Active" - if Active.Exists(5) then - try - printlog "Message: Finished: Want to continue at the beginning? '" + active.gettext + "'" - Active.No - catch - Warnlog "The Active-dialoge didn't have a No-button, tries with OK instead." - Active.Ok - endcatch + Call hFileOpenLocally (gTesttoolpath + "graphics\required\input\recht_"+iSprache+sExt) + + sleep(1) + + ' Perform the test now: + printlog "Call Tools->Spellcheck" + ToolsSpellcheck + sleep(2) + Kontext "Spellcheck" + printlog "Click button 'Always ignore' on dialog." + IgnoreAll.Click + Sleep 2 + + ToolsOptions + printlog "Select in category 'Languagesettings' entry 'Writing Aids.'" + hToolsOptions ("LANGUAGESETTINGS","WRITINGAIDS") + + fSelectWithString(Benutzerwoerterbuch,"IgnoreAllList") + + Bearbeiten.Click + + Kontext "BenutzerwoerterbuchBearbeiten" + if(Inhalt.getText <> sWrongWord) then + warnlog " added word is not in dictionary: '" + Buch.getSelText + "'" else - Warnlog "No 'Spellcheck finished, do you wish to continue?' message appeared" + printlog " added word is in dictionary: '" + Buch.getSelText + "'" end if sleep 2 - PrintLog "- Spellcheck with correct text" - select case iSprache - case 01 : hTextrahmenErstellen ("This is a text without any error.<Return>",10,10,50,20) - case 33 : hTextrahmenErstellen ("Il nous faut donc un de temps pour examiner avec soin tous les dossiers.<Return>",10,10,70,20) - case 34 : hTextrahmenErstellen ("Este es un chico muy importante.",10,10,50,20) - case 36 : hTextrahmenErstellen ("akit a b�r�s�g vagy a szab�lys�rt�si hat�s�g a eltiltott",10,10,70,20) - case 39 : hTextrahmenErstellen ("La ringraziamo per l'interesse mostrato a collaborare con la firma.<Return>",10,10,70,20) - case 46 : hTextrahmenErstellen ("Det varierar vad som behandlas och ur vilket perspektiv.<Return>",10,10,50,20) - case 49 : hTextrahmenErstellen ("Dies ist ein Text ohne Fehler.<Return>",10,10,50,20) - case 50 : hTextrahmenErstellen ("To je besedilo brez napake.<Return>",10,10,50,20) - case 55 : hTextrahmenErstellen ("Esta poderia ser a resposta para suas preces?<Return>",10,10,50,20) - case else : - if bAsianLan then - printlog "For the language " + iSprache +" nothing is prepared yet, but is AsianLan, so OK :-) will use english instaed" - ' there was smth wrong, try to find out : - kontext - if active.exists then - printlog "ERROR: active: '"+active.gettext+"'" - active.ok - end if - hTextrahmenErstellen ("This is a text without any error.<Return>",10,10,50,20) - else - Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here" - hTextrahmenErstellen ("This is a text without any error.<Return>",10,10,50,20) - end if - end select - ToolsSpellcheck - WaitSlot (2000) - Kontext "Active" - if active.exists(5) then - printlog "Message: spellchecking has finished?: '" + active.gettext + "'" - Active.OK - else - errorLog "Spellcheck started :" - Kontext "Spellcheck" - if Spellcheck.exists then - errorlog " - spellcheck came up and will be closed now" - Spellcheck.Close - else - printlog "spellcheck didn't come up" - end if - end if - WaitSlot (2000) + printlog "Close dialog 'Edit Custom Dictionary'." + BenutzerwoerterbuchBearbeiten.Close + Kontext "ExtrasOptionenDlg" + printlog "Close the Option dialog." + ExtrasOptionenDlg.OK + + printlog "Close document" Call hCloseDocument + + ' remove the word again from the dictionary + delete_word_from_dictionary(sWrongWord,"IgnoreAllList") + + kill (convertPath(gOfficePath+"user/work/"+"recht_"+iSprache+sExt)) endcase 'tiToolsSpellcheckCorrect '------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ @@ -161,7 +123,7 @@ testcase tiToolsSpellcheckError case 39 : FehlerText$ = "Ringrarziamo per l'interessa mostrato a collaborare con la firma." : Fehler$ = "Ringrarziamo" : Sprachenname$ = "Italienisch" case 46 : FehlerText$ = "Detd varierar vad som behandlas och ur vilket perspektiv." : Fehler$ = "Detd" : Sprachenname$ = "Schwedisch" case 49 : FehlerText$ = "Diees ist ein Fehler." : Fehler$ = "Diees" : Sprachenname$ = "Deutsch" - case 50 : FehlerText$ = "Toje napaka, ker manjka presledek." : Fehler$ = "Toje" : Sprachenname$ = "Slovenščina" + case 50 : FehlerText$ = "Toje napaka, ker manjka presledek." : Fehler$ = "Toje" : Sprachenname$ = "Slovenš�?ina" case 55 : FehlerText$ = "Eesta poderia ser a resposta para suas preces?": Fehler$ = "Eesta" : Sprachenname$ = "Portugiesisch" case else : if bAsianLan then @@ -250,180 +212,139 @@ testcase tiToolsSpellcheckError end if end if - printlog "delete textbox" - EditSelectAll - hTypeKeys "<DELETE>" - sleep 1 + printlog "Close document" + Call hCloseDocument - printlog "Create same textbox again (test IGNORE function)." - Printlog "Check function Ignore" - hTextrahmenErstellen (FehlerText$,30,30,80,40) - printlog "All 'Tools->Spellcheck->Check'." - - 'printlog "Setting Text to english" - 'sleep 1 - 'EditSelectAll - 'FormatCharacter - 'sleep 1 - 'Kontext - 'Messagebox.SetPage TabFont - 'Kontext "TabFont" - 'Language.Select 41 - 'TabFont.OK +endcase 'tiToolsSpellcheckCorrect - ToolsSpellcheck - Kontext "Spellcheck" - printlog "press button 'Ignore'" - IgnoreOnce.Click - printlog "spellcheck dialog has to disappear and " - printlog " There has to come up only one active: 'Spellcheck of entire document has been completed [OK]'." - Kontext "Active" - if Active.Exists(5) Then - Printlog " Spellcheck ended because of only 1 defined error. And Ignore worked.'" + active.gettext + "'" - Active.OK +'------------------------------------------------------------------------------- +testcase tiToolsSpellcheckCheck_Change + + Dim sExt as string + Dim sWrongWord as String + Dim sRightWord as string + + dim aWords(2) as string + aWords() = getWordsForLanguage() + + sWrongWord = aWords(0) + sRightWord = aWords(1) + + if(sWrongWord = "" OR sRightWord = "") then ' if any word is empty then the test should stop + qaerrorlog "no spellcheck test for the langauges " + iSprache + " available." + goto endsub + endif + + if Ucase(gApplication) = "DRAW" then + sExt = ".odg" else - Printlog " 'Ignore Once' seems to work correctly." - Kontext "Spellcheck" - Spellcheck.Close - Kontext "Active" - if active.exists(5) then - Printlog " Spellcheck dialog closed'" + active.gettext + "'" - Active.OK - else - Printlog " Spellcheck dialog closed'" - end if - end if + sExt = ".odp" + endif - printlog "Call 'Tools->Spellcheck->Check." + Call hFileOpenLocally (gTesttoolpath + "graphics\required\input\recht_"+iSprache+sExt) + + ' Perform the test now: + printlog "Call Tools->Spellcheck" ToolsSpellcheck + sleep(2) Kontext "Spellcheck" - if Spellcheck.Exists Then - Printlog " Ignore worked" - Spellcheck.Close - Kontext "Active" - if active.exists(5) then - Printlog " " + active.gettext + "'" - Active.OK - else - Printlog " Spellcheck dialog closed'" - end if + printlog "Click button 'Change' on dialog." + Change.Click + sleep(10) + SpellcheckClose.click + + if Ucase(gApplication) = "DRAW" then + Kontext "DocumentDraw" + DocumentDraw.TypeKeys("<TAB>",true) + DocumentDraw.TypeKeys("<SPACE>",true) else - Warnlog " Spellcheck ended even we only ignored the error" - end if + Kontext "DocumentImpress" + DocumentImpress.TypeKeys("<TAB>",true) + DocumentImpress.TypeKeys("<SPACE>",true) + endif - printlog "delete textbox." EditSelectAll - hTypeKeys "<DELETE>" - sleep 1 + EditCopy + + dim s as string + s = getClipBoard() - printlog "create same textbox again (test ALWAYS IGNORE function)." - hTextrahmenErstellen (FehlerText$,30,30,60,40) - - 'printlog "Setting Text to english" - 'sleep 1 - 'EditSelectAll - 'FormatCharacter - 'sleep 1 - 'Kontext - 'Messagebox.SetPage TabFont - 'Kontext "TabFont" - 'Language.Select 41 - 'TabFont.OK - - printlog "Call 'Tools->Spellcheck->Check'." - ToolsSpellcheck - Kontext "Spellcheck" - printlog "click button 'Always Ignore." - IgnoreAll.Click - printlog "spellcheck dialog has to disappear and" - printlog "There has to come up only one active: 'Spellcheck of entire document has been completed [OK]'." - Kontext "Active" - if active.exists(5) then - Printlog " Spellcheck ended because of only 1 defined error. And Ignore worked.'" + active.gettext + "'" - Active.OK + printlog s + + if(Instr(s,sWrongWord) <> 0) then + warnlog "word not changed. '" + s + "' contains still wrong word '" + sWrongWord + "'" else - Printlog " 'Ignore All' seems to work." - Kontext "Spellcheck" - Spellcheck.Close - Kontext "Active" - if active.exists(5) then - Printlog " Spellcheck dialog closed'" + active.gettext + "'" - Active.OK - else - Printlog " Spellcheck dialog closed'" - end if - end if + printlog "word changed." + endif - Printlog "- Delete ignore list" - sleep 1 - printlog "Delete ignore word list." - if (not wIgnorierenlisteLoeschen) then - qaErrorLog "Can't get into Dictionary lists" - goto endsub - end if + if(Instr(s,sRightWord) <> 0) then + printlog "word changed." + else + warnlog "word not changed." + endif + + printlog "Close document" Call hCloseDocument -endcase 'tiToolsSpellcheckError + kill (convertPath(gOfficePath+"user/work/"+"recht_"+iSprache+sExt)) + +endcase 'tiToolsSpellcheckCheck_Change +'------------------------------------------------------------------------------- +testcase tiToolsSpellcheckCheck_ChangeAll -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ -testcase tiToolsSpellcheckCheck - if iSprache = 48 then - qaerrorlog "This test is not adapted for polish, 48." - got endsub - endif - Dim Datei$ - Dim sWord(2) as string - Dim i as integer - Dim j as integer - Dim s as integer - Dim AlleBuecher as integer Dim sExt as string - Dim sWordOne as string - Dim sWordTwo as string - Dim iBooks as integer - Dim bWordFound(2) as boolean - Dim iSuggestions as integer - Dim iWord(2) as integer - Dim bFound as boolean - - Select Case Ucase(gApplication) - case "DRAW" : sExt = ".odg" - case "IMPRESS" : sExt = ".odp" - end select + Dim sRightWord as String + Dim sWrongWord as string + + dim aWords(2) as string + aWords() = getWordsForLanguage() - printlog "Load prepared document containing 4 errors : graphics\\required\\input\\recht_" & iSprache & sExt - if (not bAsianLan) then - printlog "Check if the document is writable." - Call hFileOpen (gTesttoolpath + "graphics\required\input\recht_"+iSprache+sExt) + sWrongWord = aWords(0) + sRightWord = aWords(1) + + if(sWrongWord = "" OR sRightWord = "") then ' if any word is empty then the test should stop + qaerrorlog "no spellcheck test for the langauges " + iSprache + " available." + goto endsub + endif + + 'delete_word_from_dictionary(sWord,"IgnoreListAll") + + if Ucase(gApplication) = "DRAW" then + sExt = ".odg" else - Call hFileOpen (gTesttoolpath + "graphics\required\input\recht_1"+sExt) - end if - if fIsDocumentWritable = false then - printlog "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 - end if - end if - select case iSprache ' sWord(1)=red : sWord(2)=turquoise - case 01 : sWord(1) = "documente" : sWord(2) = "expriss" - case 33 : sWord(1) = "intercu" : sWord(2) = "Lees" - case 34 : sWord(1) = "afekto" : sWord(2) = "fratternal" - case 36 : sWord(1) = "szeerint" : sWord(2) = "tervvezi" - case 39 : sWord(1) = "Millano" : sWord(2) = "tarrget" - case 46 : sWord(1) = "desa" : sWord(2) = "occh" - case 49 : sWord(1) = "Texxt" : sWord(2) = "reichtt" - case 50 : sWord(1) = "Bsedilo" : sWord(2) = "zadosča" - case 55 : sWord(1) = "esktava" : sWord(2) = "noitee" - case else : - if bAsianLan then - sWord(1) = "documente" : sWord(2) = "expriss" - else - Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here and create the file" - end if - end select - sleep 2 + sExt = ".odp" + endif + + Call hFileOpenLocally (gTesttoolpath + "graphics\required\input\recht_"+iSprache+sExt) + + ' Perform the test now: + printlog "Call Tools->Spellcheck" + ToolsSpellcheck + sleep(2) + Kontext "Spellcheck" + printlog "Click button 'Change' on dialog." + ChangeAll.Click + 'TODO: check result beware of issue 110688 + Sleep 2 + + SpellCheckClose.click + + printlog "Close document" + Call hCloseDocument + kill (convertPath(gOfficePath+"user/work/"+"recht_"+iSprache+sExt)) + +endcase 'tiToolsSpellcheckCheck_ChangeAll + +'------------------------------------------------------------------------------- - Printlog "Delete all added words from dictionaries." +function delete_all_added_words(aWords) + + 'this function delete the words in sWords in all user dictionaries + + Dim iBookCounter as integer + Dim iWordCounter as integer + Dim iBooks as integer + + Printlog "Delete the given words from dictionaries." printlog "Call Tools->Options." ToolsOptions printlog "Select in category 'Languagesettings' entry 'Writing Aids.'" @@ -431,487 +352,143 @@ testcase tiToolsSpellcheckCheck sleep 1 Kontext "WRITINGAIDS" sleep 1 - printlog "Click on button 'edit' in section 'User-defined dictionaries.'" - if (fGetIntoDictionary) then - qaErrorLog "wTSC" - goto endsub - end if + printlog "select the first User-defined dictionaries and click EDIT" + Benutzerwoerterbuch.select 1 + Bearbeiten.Click + Kontext "BenutzerwoerterbuchBearbeiten" sleep 1 - printlog "Check every book, if it contains the words that will be added in this test." + printlog "Check every book, if it contains the words." iBooks = Buch.getItemCount - bWordFound(1) = false - bWordFound(2) = false - for i = 1 to iBooks - Buch.select(i) + for iBookCounter = 1 to iBooks + Buch.select(iBookCounter) printlog "Items in Booklist: " & WordList.getItemCount - for j = 1 to 2 - Wort.setText sWord(j) + for iWordCounter = 1 to uBound(aWords) + Wort.setText aWords(iWordCounter) sleep 1 if ((not neu.isEnabled) and Loeschen.isEnabled) then printlog "If it contains the word, press button 'delete'." Loeschen.click - bWordFound(j) = true - printlog "Added word WAS in dictionary: '" + Buch.getSelText + "' - '" + sWord(j) + "'" + printlog "Added word WAS in dictionary: '" + Buch.getSelText + "' - '" + aWords(iWordCounter) + "'" end if - next j - next i - if (bWordFound(1) OR bWordFound(2))then - qaErrorLog "Word was found in dictionary - check why it was there. '" + sWord(1) + "': " + bWordFound(1) + " '" + sWord(2) + "': " + bWordFound(2) - end if + next iWordCounter + next iBookCounter printlog "Close dialog 'Edit Custom Dictionary.'" BenutzerwoerterbuchBearbeiten.Close sleep 1 Kontext "ExtrasOptionenDlg" printlog "Press button 'OK' on dialog 'Writing Aids'." ExtrasOptionenDlg.OK - printlog "Call dialog again and delete all remaining words from dictionary 'IgnoreAllList'." - if (not wIgnorierenlisteLoeschen) then - qaErrorLog "Can't get into Dictionary lists" - goto endsub - end if - - printlog "Test if spellcheck dialog comes up and check/set direction of spellcheck." - printlog "Call 'Tools->Spellcheck->Check'." - ToolsSpellcheck - Kontext "Spellcheck" - WaitSlot (1000) - printlog "If no dictionary for the language is available, a messagebox comes up:" - printlog ". . . 'Error executing the spellcheck.: Language is not supported by spellchecker funtion." - kontext "active" - if active.exists(5) then - warnlog "$Language is not supported by spellchecker funtion: '" + active.gettext + "'" - Active.OK - printlog ". . . exiting testcase." - goto endsub - end if - Kontext "Spellcheck" - printlog "Close dialog 'Spellcheck'." - Spellcheck.Close - Kontext "Active" - if active.exists(5) then - Warnlog " Should not be any message here: " + active.gettext + "'" - Active.OK - else - printlog "Spellcheck ended, dialog closed" - end if - printlog "Select all." - hTypeKeys "<MOD1 A>" - printlog "Check presupposition: 12 Words have to be complained about." - printlog "All 'Tools->Spellcheck->Check'." - ToolsSpellcheck - WaitSlot (2000) - Kontext "Spellcheck" - printlog "Click button 'Ignore' 12 times." - - for i = 1 to 11 - Kontext "Spellcheck" - IgnoreOnce.Click - Kontext "Active" - if active.exists(5) then - warnlog "Presupposition not met: there are less than 12 errors in the document! " + i - Active.OK - printlog "If errors < 12 -> exiting testcase." - goto endsub - end if - next i - Kontext "Spellcheck" - IgnoreOnce.Click - printlog "Spellcheck dialog has to disapear and messagebox with OK has to come up." - Kontext "Active" - if active.exists(5) then - printlog "Active dialog said: " + active.gettext + "'" - Active.OK - end if - Kontext "Spellcheck" - if Spellcheck.Exists(5) then - warnlog "Presupposition not met: there are more than 12 errors in the document!" - Spellcheck.Close - kontext "Active" - if active.exists(5) then - Active.OK - else - printlog "bug fixed #111972# " - end if - printlog "If errors > 12 -> exiting testcase." - goto endsub - else - Kontext "Active" - if active.exists(5) then - warnlog "There was a Message where none was supposed to be: '" + active.gettext + "'" - Active.NO - end if - printlog "Presupposition met: there are 12 errors in the document!" - end if - - printlog "Perform the test now:" - printlog "Call 'Tools->Spellcheck->Check'" - ToolsSpellcheck - WaitSlot (2000) - Kontext "Spellcheck" - Printlog "----------------------------------------------------------------------------" - Printlog "1st Test: - Ignore now" - printlog "1st error: ignore : 1st pink word in 1st Paragraph." - printlog "Backwards: last green word in 3rd Paragraph." - sWordOne = Suggestions.GetSelText - printlog "********* Suggestion word found: '" + sWordOne + "'" - printlog "##### suggestions: "+Suggestions.GetItemCount+"; Language: "+DictionaryLanguage.getSelText '+" ; dictionary: "+woerterbuch.getSelText - if (Suggestions.GetItemCount > 0) then - printlog "----- "+i+": "+Suggestions.GetSelText (1) - end if - printlog "Click button 'Ignore'." - IgnoreOnce.Click - Sleep 2 + +end function 'delete_all_added_words - Printlog "----------------------------------------------------------------------------" - Printlog "2nd Test: - Add" - printlog "2nd error: add : 1st red word in 1st Paragraph -> hasn't to show up anymore from now on." - printlog "Backwards: last turquoise word in 3rd Paragraph -> hasn't to show up anymore from now on." - printlog "Check if word in textfield 'Word' changed." - printlog "(Check if it is the expected next error - you have to look into the source code for the right word!)." - sWordTwo = Suggestions.GetSelText - if (sWordOne = sWordTwo) then - warnlog "Ignore didn't work? Spellcheck didn't go on" - end if - if (sWord(iWord(1)) <> sWordTwo) then - Printlog "The errornous word '" + sWord(iWord(1)) + "' would be replaced with: '" + sWordTwo + "'" - end if - printlog "********* word found: '" + sWordTwo + "'" - printlog "##### suggestions: "+Suggestions.GetItemCount+"; Language: "+DictionaryLanguage.getSelText ' +" ; dictionary: "+woerterbuch.getSelText - if (Suggestions.GetItemCount > 0) then - printlog "----- "+i+": "+Suggestions.GetSelText (1) - end if - Sleep 1 - printlog "Click button 'Add' on dialog '" - AddToDictionary.Click - Sleep 2 - printlog "The menu has: " + MenuGetItemCount + " entries." - hMenuSelectNr(1) 'Default - Kontext "Active" - if Active.Exists(5) Then - Warnlog " - Word could not be added to dictionary: '" + active.getText + "'" - Active.OK - Sleep 1 - end if - printlog "Check in options, if word exists in word list." - printlog "Click button 'Options' on dialog 'Spellcheck'." - Kontext "Spellcheck" - SpellcheckOptions.Click - Kontext "TabLinguistik" - printlog "Click button 'Edit ...' on dialog 'Writing Aids' in section 'User-defined dictionaries'." - if TabLinguistik.exists(5) then - sleep 3 - if (fGetIntoDictionary) then - qaErrorLog "wTSC" - goto endsub - end if - else - qaerrorlog "baeh" - end if - Kontext "BenutzerwoerterbuchBearbeiten" - printlog "Check every book, if it contains the added word." - if not BenutzerwoerterbuchBearbeiten.exists(5) then - sleep 5 - qaerrorlog "baeh" - end if - iBooks = Buch.getItemCount - bWordFound(1) = false - for i = 1 to iBooks - Buch.select(i) - printlog "Book number selected: " & i - Wort.setText sWord(iWord(1)) - sleep 1 - if ((not neu.isEnabled) and Loeschen.isEnabled) then - bWordFound(1) = true - printlog "Added word is in dictionary: '" + Buch.getSelText + "'" - end if - next i - if (not bWordFound(1)) then - warnlog "Word was not added to dictionary" - end if - printlog "Cancel dialog 'Edit Custom Dictionary'." - BenutzerwoerterbuchBearbeiten.Close - Kontext "TabLinguistik" - printlog "Cancel dialog 'Writing Aids'." - TabLinguistik.Close - Kontext "Spellcheck" - - Printlog "----------------------------------------------------------------------------" - Printlog " 3rd Test: - Always Ignore" - printlog "3rd error: always ignore : 1st turquoise word in 1st Paragraph -> hasn't to show up anymore from now on." - printlog "Check if word in textfield 'Word' changed." - printlog "(check if it is the expected next error - you have to look into the source code for the right word!)" - sWordOne = sWordTwo - sWordTwo = Suggestions.GetSelText 'wort.getText - if (sWordOne = sWordTwo) then - warnlog "Add didn't work? Spellcheck didn't go on." - end if - if (sWord(iWord(2)) <> sWordTwo) then - Printlog "The erroneous word '" + sWord(iWord(2)) + "' would be replaced with: '" + sWordTwo + "'" - else - warnlog "ERROR: SAME WORD in the dictionary as in the text??? Must be wrong." - end if - printlog "********* word found: '" + sWordTwo + "'" - printlog "##### suggestions: "+Suggestions.GetItemCount+"; Language: "+DictionaryLanguage.getSelText ' +" ; dictionary: "+DictionaryLanguage.getSelText 'Wort.GetItemCount 'Woerterbuch.GetSelText - if (Suggestions.GetItemCount > 0) then 'Wort.GetItemCount > 0) then - printlog "----- "+i+": "+Suggestions.GetItemText (1) 'Wort.GetItemText (1) - end if - Sleep 1 - printlog "Click button 'Always ignore' on dialog." - IgnoreAll.Click - Sleep 2 - printlog "Check in options, if word exists in word list." - printlog "Click button 'Options' on dialog 'Spellcheck'." - SpellcheckOptions.Click - Kontext "TabLinguistik" - printlog "Click button 'Edit ...' on dialog 'Writing Aids' in section 'User-defined dictionaries." - if TabLinguistik.exists(5) then - sleep 3 'culprint swedish windows; wait until butrton exists? - if (fGetIntoDictionary) then - qaErrorLog "wTSC" - goto endsub - end if - else - qaerrorlog "baeh" - end if - Kontext "BenutzerwoerterbuchBearbeiten" - if not BenutzerwoerterbuchBearbeiten.exists(5) then - sleep 3 - qaerrorlog "baeh" - end if - printlog "Check every book, if it contains the added word." - iBooks = Buch.getItemCount - bWordFound(2) = false - for i = 1 to iBooks - Kontext "BenutzerwoerterbuchBearbeiten" - Buch.select(i) - Inhalt.setText sWord(iWord(2)) 'Wort.setText sWord(iWord(2)) - sleep 1 - if ((not neu.isEnabled) and Loeschen.isEnabled) then - bWordFound(2) = true - printlog " added word is in dictionary: '" + Buch.getSelText + "'" - end if - next i - if (not bWordFound(2)) then - warnlog "Word was not added to dictionary, #ixxxxxx" - end if - printlog "Cancel dialog 'Edit Custom Dictionary'." - BenutzerwoerterbuchBearbeiten.Close - Kontext "TabLinguistik" - printlog "Cancel dialog 'Writing Aids'." - TabLinguistik.Close - kontext "Spellcheck" - - Printlog "----------------------------------------------------------------------------" - Printlog "4th test: - Replace" - printlog "4th error: replace : 1st green word in 1st Paragraph." - printlog "Check if word in textfield 'Word' changed." - printlog "(check if it is the expected next error - you have to look into the source code for the right word!)." - sWordOne = sWordTwo - sWordTwo = Suggestions.GetSelText - if (sWordOne = sWordTwo) then - warnlog "Always ignore didn't work? Spellcheck didn't go on." - end if - printlog "********* word found: '" + sWordTwo + "'" - iSuggestions = Suggestions.GetItemCount - printlog "##### suggestions: " + iSuggestions + "; Language: "+DictionaryLanguage.getSelText '+"; dictionary: "+woerterbuch.getSelText - if (Suggestions.GetItemCount > 0) then - printlog "----- "+i+": "+Suggestions.GetItemText (1) - end if - Sleep 1 - printlog "Click button 'Replace'." - if (iSuggestions > 0) then - Change.click - else - qaerrorlog "Please change the text in the file, so the spellchecker can make a suggestion for the word: '" + sWordTwo + "'" - IgnoreOnce.Click - end if +'------------------------------------------------------------------------------- - Printlog "----------------------------------------------------------------------------" - Printlog "5th Test: - Always Replace" - printlog "5th error: always replace : 1st pink word in 2nd Paragraph -> hasn't to show up anymore from now on." - printlog "backwards: 1st green word in 2nd Paragraph -> hasn't to show up anymore from now on." - printlog "check if word in textfield 'Word' changed." - printlog "(check if it is the expected next error - you have to look into the source code for the right word!)." - sWordOne = sWordTwo - sWordTwo = Suggestions.GetSelText - if (sWordOne = sWordTwo) then - warnlog "Replace didn't work? Spellcheck didn't go on" - end if - printlog "********* word found: '" + sWordTwo + "'" - iSuggestions = Suggestions.GetItemCount - printlog "##### suggestions: " + iSuggestions + "; Language: "+DictionaryLanguage.getSelText ' +" ; dictionary: "+woerterbuch.getSelText - if (Suggestions.GetItemCount > 0) then - printlog "----- "+i+": "+Suggestions.GetItemText (1) - end if - Sleep 1 - printlog "click button 'Always Replace'." - if (iSuggestions > 0) then - ChangeAll.click - else - qaErrorLog "Please change the text in the file, so the spellchecker can make a suggestion for the word: '" + sWordTwo + "'" - IgnoreOnce.Click - end if +function delete_word_from_dictionary(sWord as String, sDictionary as String) - printlog "2 errors are left: 4th word (green) in 2nd and 3rd paragraph." - printlog "backwards: 1st word (pink) in 2nd and 1st paragraph." - Kontext "Spellcheck" - sWordOne = sWordTwo - sWordTwo = Suggestions.GetSelText - if (sWordOne <> sWordTwo) then - printlog sWordTwo - else - warnlog "there is anopther word left, that wasn't expected!. '" + sWordTwo +"'" - end if - printlog "Click button 'Ignore' 2 times." - IgnoreOnce.Click + 'this function delete the words in sWords in all user dictionaries - Kontext "Spellcheck" - sWordOne = sWordTwo - sWordTwo = Suggestions.GetSelText - if (sWordOne <> sWordTwo) then - warnlog "there is anopther word left, that wasn't expected!. '" + sWordTwo +"'" - else - printlog sWordTwo - end if - printlog "Click button 'Ignore' 2 times." - IgnoreOnce.Click - Kontext "Active" - if active.exists(5) then - printlog "Spellcheck works :-) '" + active.gettext + "'" - Active.No - else - warnlog "Spellcheck didn't work :-(! there are still errors in the document." - Kontext "Spellcheck" - Spellcheck.Close - Kontext "Active" - if active.exists(5) then - qaErrorLog " Spellcheck dialog closed'" + active.gettext + "'" - Active.No - end if - end if - sleep 2 + Dim iBookCounter as integer + Dim iWordCounter as integer + Dim iBooks as integer - Printlog "Delete all added words from dictionaries." + Printlog "Delete the given word from dictionaries." printlog "Call Tools->Options." ToolsOptions - printlog "Select in category 'Languagesettings' entry 'Writing Aids'." + printlog "Select in category 'Languagesettings' entry 'Writing Aids.'" hToolsOptions ("LANGUAGESETTINGS","WRITINGAIDS") sleep 1 Kontext "WRITINGAIDS" - printlog "Click on button 'edit' in section 'User-defined dictionaries'." - if (fGetIntoDictionary) then - qaErrorLog "wTSC" - goto endsub - end if + sleep 1 + printlog "select the dictionary and click EDIT" + + fSelectWithString(Benutzerwoerterbuch,sDictionary) + + Bearbeiten.Click + Kontext "BenutzerwoerterbuchBearbeiten" - printlog "Check every book, if it contains the added word." - iBooks = Buch.getItemCount - bWordFound(1) = false - bWordFound(2) = false - for i = 1 to iBooks - Buch.select(i) - for j = 1 to 2 - Wort.setText sWord(j) - sleep 1 - if ((not neu.isEnabled) and Loeschen.isEnabled) then - printlog "If it contains the word, press button 'delete'." - Loeschen.click - bWordFound(j) = true - printlog " added word is in dictionary: '" + Buch.getSelText + "' - '" + sWord(j) + "'" - end if - next j - next i - if ((not bWordFound(1)) AND (not bWordFound(2)))then - warnlog "Word was not found in dictionary. '" + sWord(1) + "': " + bWordFound(1) + " '" + sWord(2) + "': " + bWordFound(2) + + Wort.setText sWord + sleep 1 + if ((not neu.isEnabled) and Loeschen.isEnabled) then + printlog "If it contains the word, press button 'delete'." + Loeschen.click + printlog "Added word WAS in dictionary: '" + Buch.getSelText + "' - '" + sWord + "'" end if - printlog "Close dialog 'Edit Custom Dictionary'." + + printlog "Close dialog 'Edit Custom Dictionary.'" BenutzerwoerterbuchBearbeiten.Close sleep 1 Kontext "ExtrasOptionenDlg" - printlog "press button 'OK' on dialog 'Writing Aids'." + printlog "Press button 'OK' on dialog 'Writing Aids'." ExtrasOptionenDlg.OK - printlog "Call dialog again and delete all remaining words from dictionary 'IgnoreAllList'." - if (not wIgnorierenlisteLoeschen) then - qaErrorLog "Can't get into Dictionary lists" - goto endsub - end if - printlog "Close document" - Call hCloseDocument -endcase 'tiToolsSpellcheckCheck +end function 'delete_word_from_dictionary '------------------------------------------------------------------------------- -testcase tToolsSpellcheckAutoSpellcheck - - QaErrorLog "#i81928# - outcommented tToolsSpellcheckAutoSpellcheck due to bug." - goto endsub - dim i as integer - dim x as integer - dim y as integer - dim q as integer - dim z as integer - dim iResult as long - dim iTemp as long - dim iTemp2 as long - dim sTemp as string - dim sCompare as string - dim iCompare as long - dim iError as long - dim sError as string - - call hNewDocument - - call hTextrahmenErstellen ("Ein Tipp: Schiffahrt schreibt man nun mit 3f Tunfisch Amboss a", 10, 10, 90, 50) - EditSelectAll - setCharacterLanguage(glLocale(4)) - sleep 10 - printlog "## check ENGLISH auto spellchecking" - iError = 0 - ' Get underlined words / wrong recognized words by spellchecker - iResult = sAnalyseContextMenu(11, iError) - sTemp = sLongToBinary(iResult, 11) - sError = sLongToBinary(iError, 11) - ' reference of words, which should be underlined - sCompare = "11011001011" - iCompare = sBinaryToLong(sCompare) - ' compare result with reference -> get the difference - iTemp = not (iResult EQV iCompare) - ' eliminate errors from open bugs -> get the real errors - iTemp2 = iTemp AND NOT iError - if (iTemp2 > 0) then - warnlog "wrong words are not underlined? Should be: " + sCompare - warnlog "Is: " + sTemp - warnlog "Differences: " + sLongToBinary(iTemp, 11) - warnlog "Wrong after merging errors from bugs " + sLongToBinary(iTemp2, 11) - end if +function fSelectWithString(oControl as Object,sText as String) - sleep 1 - ' call hTypeKeys "<F2>" - call hTypeKeys "<mod1 end> <Shift mod1 home>" - setCharacterLanguage(glLocale(6)) - sleep 10 - printlog "## check GERMAN auto spellchecking" - iError = 0 - iResult = sAnalyseContextMenu(11, iError) - sTemp = sLongToBinary(iResult, 11) - sError = sLongToBinary(iError, 11) - sCompare = "00010000000" - iCompare = sBinaryToLong(sCompare) - ' compare result with reference -> get the difference - iTemp = not (iResult EQV iCompare) - ' eliminate errors from open bugs -> get the real errors - iTemp2 = iTemp AND NOT iError - if (iTemp2 > 0) then - warnlog "wrong words are not underlined? Should be: " + sCompare - warnlog "Is: " + sTemp - warnlog "Differences: " + sLongToBinary(iTemp, 11) - warnlog "Wrong after merging errors from bugs " + sLongToBinary(iTemp2, 11) - end if - printlog "-----------------------------------" + dim iCounter as Integer + dim iNumberOfItems as Integer + iNumberOfItems = oControl.getItemCount() + + for iCounter = 1 to iNumberOfItems + oControl.select iCounter + if( Instr(oControl.getSelText,sText) <> 0 ) then ' the correct entry is selected + iCounter = iNumberOfItems ' stop the loop + endif + next - hCloseDocument() -endcase 'tToolsSpellcheckAutoSpellcheck +end function 'fSelectWithString '------------------------------------------------------------------------------- + +function getWordsForLanguage() + + dim sWrongWord as String + dim sRightWord as String + dim aWords(2) as String + + select case iSprache + case 1 : + sWrongWord = "documente" + sRightWord = "document" + case 31 : + sWrongWord = "miejn" + sRightWord = "mijn" + case 33 : + sWrongWord = "projjet" + sRightWord = "projet" + case 34 : + sWrongWord = "lazsos" + sRightWord = "lazos" + case 36 : + sWrongWord = "Bozniai" + sRightWord = "Boszniai" + case 39 : + sWrongWord = "borrdo" + sRightWord = "borro" + case 46 : + sWrongWord = "desa" + sRightWord = "edas" + case 48 : + sWrongWord = "werrsji" + sRightWord = "wersji" + case 49 : + sWrongWord = "Feehlern" + sRightWord = "Fehlern" + case 55 : + sWrongWord = "Elle" + sRightWord = "Elze" + case else : + sWrongWord = "" + sRightWord = "" + end select + + aWords(0) = sWrongWord + aWords(1) = sRightWord + + getWordsForLanguage = aWords + +end function 'getWordsForLanguage diff --git a/testautomation/graphics/optional/includes/global/g_stylist.inc b/testautomation/graphics/optional/includes/global/g_stylist.inc index fab547eb5d3b..71d05f7d704c 100644 --- a/testautomation/graphics/optional/includes/global/g_stylist.inc +++ b/testautomation/graphics/optional/includes/global/g_stylist.inc @@ -38,17 +38,18 @@ testcase tFormatStylistFlyer Dim ySize% printlog " - Format/Stylist : using all possible things to manipulate the flyer" - '/// open application ///' + printlog "open application" Call hNewDocument Kontext "Gestalter" - '/// Check if stylist is there. Expected: not there ///' + printlog "Check if stylist is there. Expected: not there" if Gestalter.NotExists = false Then - qaErrorLog " - Expected Stylist to be closed; But is Open. Check tests." + qaErrorLog "Expected Stylist to be closed; But is Open. Check tests." else if lcase(gPlatform) = "osx" then hTypekeys "<mod1 t>" else - hTypekeys "<F11>" '/// open stylist by pressing key [F11] ///' + printlog "open stylist by pressing key [F11]" + hTypekeys "<F11>" end if sleep 1 end if @@ -57,51 +58,51 @@ testcase tFormatStylistFlyer Warnlog " No stylist popped up using F11; opening now via slotID" FormatStylist end if - '///+ save stylist position and size ///' + printlog "save stylist position and size" xPos% = Gestalter.GetPosX yPos% = Gestalter.GetPosY xSize% = Gestalter.GetSizeX ySize% = Gestalter.GetSizeY - '///+ if Stylist is docked; undock ///' + printlog " if Stylist is docked; undock" if Gestalter.IsDocked then Gestalter.UnDock - printlog " - '///move stylist ///" - '///+ move stylist to 10,10 ///' + printlog " move stylist" + printlog "move stylist to 10,10" Gestalter.Move 10, 10 Sleep 1 - '///+ move stylist to 300,400 ///' + printlog "move stylist to 300,400" Gestalter.Move 300, 400 Sleep 1 - '///+ move stylist to 590,790 ///' + printlog "move stylist to 590,790" Gestalter.Move 590, 790 Sleep 1 - '///+ move stylist back to saved start position ///' + printlog " move stylist back to saved start position" Gestalter.Move xPos%, yPos% Sleep 1 - printlog " - '///size stylist ///" - '///+ change size to 200,200 ///' + printlog "size stylist" + printlog "change size to 200,200" Gestalter.Size 200, 200 Sleep 1 - '///+ change size to 300,400 ///' + printlog "change size to 300,400" Gestalter.Size 300, 400 Sleep 1 - '///+ change size to 150,250 ///' + printlog "change size to 150,250" Gestalter.Size 150, 250 Sleep 1 - '///+ change size back to saved size ///' + printlog "change size back to saved size" Gestalter.Size xSize%, ySize% Sleep 1 - printlog " - Close stylist reopen stylist, check if appearence is same as before" - '/// save stylist position and size ///' + printlog "Close stylist reopen stylist, check if appearence is same as before" + printlog "save stylist position and size" xPos% = Gestalter.GetPosX yPos% = Gestalter.GetPosY xSize% = Gestalter.GetSizeX ySize% = Gestalter.GetSizeY - '/// close stylist Format->Stylist ///' + printlog "close stylist Format->Stylist" FormatStylist Sleep 1 - '/// open stylist Format->Stylist ///' + printlog "open stylist Format->Stylist" FormatStylist sleep (1) if xPos% <> Gestalter.GetPosX then Warnlog "The x-Pos. has changed : Should be -> '"+ xPos% + "' Is -> '"+ Gestalter.GetPosX +"'." @@ -110,29 +111,29 @@ testcase tFormatStylistFlyer if ySize% <> Gestalter.GetSizeY then Warnlog "The y-Size has changed : Should be -> '"+ ySize% + "' Is -> '"+ Gestalter.GetSizeY +"'." printlog " - dock stylist" - '/// dock stylist ///' + printlog "dock stylist" Gestalter.Dock Sleep 1 if (NOT Gestalter.IsDocked) then warnlog " stylist not docked but should" endif - '/// UNdock stylist ///' + printlog "UNdock stylist" if (Gestalter.IsDocked) Then Gestalter.UnDock endif Sleep 1 printlog " - maximize/minimize stylist" - '/// minimize stylist ///' + printlog "minimize stylist" Gestalter.Minimize Sleep 1 - '/// maximize stylist ///' + printlog "maximize stylist" Gestalter.Maximize Sleep 1 if (NOT Gestalter.IsMax) then warnlog " The stylist did not return to maximized state" endif - '/// close stylist ///' + printlog "close stylist" Gestalter.Close Call hCloseDocument @@ -518,8 +519,10 @@ testcase tiFormatStylist goto endsub end select + printlog "Open new doc" Call hNewDocument sleep 2 + printlog "call the navigator" Kontext "Gestalter" if Gestalter.Exists Then Warnlog "- Stylist exists, perhaps not closed last time a Impress doc was open" @@ -529,11 +532,14 @@ testcase tiFormatStylist FormatStylist Kontext "Gestalter" + printlog "opening graphics styles" Grafikvorlagen.Click sleep 1 + printlog "Select number 1" Vorlagenliste.Select Num1 ' num1 sleep 1 Printlog "- open Grafic template Dialogs using the context menue , checking if all resources exist" + printlog "Opening context menu" Vorlagenliste.OpenContextMenu sleep 1 hMenuSelectNr (2) @@ -543,6 +549,7 @@ testcase tiFormatStylist Messagebox.SetPage TabText Kontext "TabText" sleep 1 + printlog "Canceling dialog" TabText.Cancel sleep 1 @@ -550,18 +557,21 @@ testcase tiFormatStylist Kontext "Gestalter" Printlog "- presentation templates" sleep 1 + printlog "presentation styles" Praesentationsvorlagen.Click Vorlagenliste.Select Num2 sleep 1 + printlog "opening context menu" Vorlagenliste.OpenContextMenu sleep 1 + printlog "selecting modify" hMenuSelectNr (1) sleep 1 Kontext if Messagebox.exists (5) then try - ' Messagebox.SetPage TabArea + printlog "Messagebox.SetPage TabArea" Kontext "TabArea" if TabArea.Exists = false then warnlog "Where is TabArea?" @@ -578,86 +588,111 @@ testcase tiFormatStylist Kontext "Gestalter" sleep 1 + printlog "Select number 3" Vorlagenliste.Select Num3 sleep 1 + printlog "opening context menu of number 3" Vorlagenliste.OpenContextMenu sleep 1 hMenuSelectNr (1) sleep 1 + printlog "Check the styles..." call hWalkTheStyles (1,1) Kontext + printlog "setting tabpage indents and spacing" Messagebox.SetPage TabEinzuegeUndAbstaende Kontext "TabEinzuegeUndAbstaende" sleep 1 + printlog "Canceling tabpage" TabEinzuegeUndAbstaende.Cancel sleep 1 Kontext "Gestalter" sleep 1 + printlog "Select number 4" Vorlagenliste.Select Num4 sleep 1 + printlog "opening context menu of number 4" Vorlagenliste.OpenContextMenu sleep 1 hMenuSelectNr (1) sleep 1 Kontext + printlog "setting tabpage TabFont" Messagebox.SetPage TabFont kontext "TabFont" Kontext + printlog "setting tabpage TabFontEffects" Messagebox.SetPage TabFontEffects kontext "TabFontEffects" Kontext + printlog "setting tabpage TabIndents and Spacing" Messagebox.SetPage TabEinzuegeUndAbstaende kontext "TabEinzuegeUndAbstaende" sleep 1 + printlog "canceling TabIndents and Spacing" TabEinzuegeUndAbstaende.Cancel sleep 1 Kontext "Gestalter" sleep 1 + printlog "opening context menu of number 5" Vorlagenliste.Select Num5 sleep 1 + printlog "opening context menu of number 5" Vorlagenliste.OpenContextMenu sleep 1 hMenuSelectNr (1) sleep 1 Kontext + printlog "setting tabpage Tab Font" Messagebox.SetPage TabFont kontext "TabFont" Kontext + printlog "setting tabpage Tab FontEffects" Messagebox.SetPage TabFontEffects kontext "TabFontEffects" Kontext + printlog "setting tabpage TabIndents and Spacing" Messagebox.SetPage TabEinzuegeUndAbstaende kontext "TabEinzuegeUndAbstaende" sleep 1 Kontext + printlog "setting tabpage Tab Bullets" Messagebox.SetPage TabBullet Kontext "TabBullet" sleep 1 Kontext + printlog "setting tabpage Tab Numbering Type" Messagebox.SetPage TabNumerierungsart Kontext "TabNumerierungsart" sleep 1 Kontext + printlog "setting tabpage Tab Graphics" Messagebox.SetPage TabGrafiken Kontext "TabGrafiken" sleep 1 Kontext + printlog "setting tabpage Tab Numbering options" Messagebox.SetPage TabOptionenNumerierung Kontext "TabOptionenNumerierung" sleep 1 + printlog "Canceling..." TabOptionenNumerierung.Cancel sleep 1 endif + kontext "DocumentImpress" + printlog "Closing Stylist" if lcase(gPlatform) = "osx" then hTypekeys "<mod1 t>" else - hTypeKeys "<F11>" + Kontext "Gestalter" + Gestalter.Close end if sleep 1 Kontext "Gestalter" if Gestalter.Exists Then Warnlog "- Stylist could not be closed pressing F11" + printlog "Closing doc." Call hCloseDocument endcase 'tiFormatStylist diff --git a/testautomation/graphics/optional/includes/global/g_tables.inc b/testautomation/graphics/optional/includes/global/g_tables.inc index 410ed8ca0fc6..c3c8f99c551c 100644 --- a/testautomation/graphics/optional/includes/global/g_tables.inc +++ b/testautomation/graphics/optional/includes/global/g_tables.inc @@ -40,14 +40,19 @@ dim iItemIndex AS integer 'Counter for/next testcase tiInsertTableUsingMenu +qaerrorlog "#i116013# No table toolbar when inserting table via insert/table" +goto endsub + printlog "Inserting table into doc using the menu." Call hNewDocument printlog "Switching between Draw/Impress" if ( gApplication = "IMPRESS" ) then + Kontext "Document Impress" DocumentImpress.UseMenu hMenuSelectNr(4) hMenuSelectNr(14) else + Kontext "Document Draw" DocumentDraw.UseMenu hMenuSelectNr(4) hMenuSelectNr(11) @@ -58,6 +63,7 @@ testcase tiInsertTableUsingMenu Kontext "InsertTableImpress" if InsertTableImpress.Exists then printlog "InsertTable Dialog is up." + InsertTableImpress.OK else warnlog "InsertTableDialog did not come up!" endif @@ -123,6 +129,9 @@ endcase 'tiInsertTableUsingMenu testcase tiInsertTableUsingButton +qaerrorlog "#i116013# No table toolbar when inserting table via insert/table" +goto endsub + printlog " Inserting table using the button in standard toolbar." Call hNewDocument printlog "Open New Document." @@ -202,15 +211,20 @@ endcase 'tiInsertTableUsingToolbarbutton '------------------------------------------------------------------------------- testcase tiTableObjectBar +qaerrorlog "#i116013# No table toolbar when inserting table via insert/table" +goto endsub + printlog "Testing TableObjectBar." printlog "Inserting table into doc using the menu." Call hNewDocument printlog "Switching between Draw/Impress" if ( gApplication = "IMPRESS" ) then DocumentImpress.UseMenu + Kontext "Document Impress" hMenuSelectNr(4) hMenuSelectNr(14) else + Kontext "Document Draw" DocumentDraw.UseMenu hMenuSelectNr(4) hMenuSelectNr(11) @@ -240,6 +254,7 @@ testcase tiTableObjectBar printlog "Table bar visible." else warnlog "Table bar is not up!" + ViewToolbarsTable endif printlog "Checking LinienStil." diff --git a/testautomation/graphics/optional/includes/global/g_tools.inc b/testautomation/graphics/optional/includes/global/g_tools.inc index fa3f429bbb3b..e8e918b95cbb 100644 --- a/testautomation/graphics/optional/includes/global/g_tools.inc +++ b/testautomation/graphics/optional/includes/global/g_tools.inc @@ -29,11 +29,6 @@ '* '* short description : will be moved to autocorrection.bas/inc '* -'************************************************************************************** -' #1 tiToolsThesaurus -' #1 tiToolsHyphenation1 -' #1 tiToolsHyphenation2 -' #1 tToolsMacro '\************************************************************************************* ' sFile = gTesttoolpath + "graphics\required\input\silben_"+iSprache+sExt @@ -46,6 +41,7 @@ testcase tiToolsThesaurus Dim sAlternativeText as string Dim sExt as string Dim ZaehlerBedeutung + dim sWorkFile as string 'for normal text, the thesaurus is enabled, 'if the format->character->language of the word has a thesaurus @@ -54,7 +50,7 @@ testcase tiToolsThesaurus 'so especially for asian languages you have to set a default language in the options, 'to be able to use the thesaurus there - fallback to englisch, 'because there is no thesaurus for cjk languages - + 'As long as OOo has no modules for that, disabled if gOOO = True then printlog "No spellchecking in OOo" @@ -63,64 +59,65 @@ testcase tiToolsThesaurus 'First we make sure we test a language where Thesaurus select case iSprache - case 01 : sWord = "Hello" - case 03 : sWord = "Alo" - case 07 : printlog "- No Thesaur for Russian available" - goto endsub - case 30 : Printlog "- No Thesaurus available !" - goto endsub - case 31 : sWord = "Guiten" - case 33 : sWord = "Bonjour" - case 34 : sWord = "Hola" - case 35 : Printlog "- No Thesaurus available !" - goto endsub - case 36 : Printlog "- No Thesaurus available !" - goto endsub - case 37 : Printlog "- No Thesaurus available !" - goto endsub - case 39 : sWord = "Ciao" - case 42 : Printlog "- No Thesaurus available !" - goto endsub - case 45 : sWord = "Hej" - case 46 : sWord = "Välkommen" - case 47 : Printlog "- No Thesaurus available !" - goto endsub - case 48 : Printlog "- No Thesaurus in Polish!" - goto endsub - case 49 : sWord = "Hallo" - case 50 : sWord = "Prosojnica" - case 51 : Printlog "- No Thesaurus available !" - goto endsub - case 55 : Printlog "- No Thesaurus in Brazilian!" - goto endsub - case 90 : Printlog "- No Thesaurus available !" - goto endsub + case 01 : sWord = "Hello" + case 03 : sWord = "Alo" + case 07 : printlog "- No Thesaur for Russian available" + goto endsub + case 30 : Printlog "- No Thesaurus available !" + goto endsub + case 31 : sWord = "Guiten" + case 33 : sWord = "Bonjour" + case 34 : sWord = "Hola" + case 35 : Printlog "- No Thesaurus available !" + goto endsub + case 36 : Printlog "- No Thesaurus available !" + goto endsub + case 37 : Printlog "- No Thesaurus available !" + goto endsub + case 39 : sWord = "Ciao" + case 42 : Printlog "- No Thesaurus available !" + goto endsub + case 45 : sWord = "Hej" + case 46 : sWord = "Välkommen" + case 47 : Printlog "- No Thesaurus available !" + goto endsub + case 48 : Printlog "- No Thesaurus in Polish!" + goto endsub + case 49 : sWord = "Hallo" + case 50 : sWord = "Prosojnica" + case 51 : Printlog "- No Thesaurus available !" + goto endsub + case 55 : Printlog "- No Thesaurus in Brazilian!" + goto endsub + case 90 : Printlog "- No Thesaurus available !" + goto endsub - case else : if bAsianLan then - hSetSpellHypLanguage - sWord = "Hello" - else - Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here" - sWord = "Hello" - endif + case else : if bAsianLan then + hSetSpellHypLanguage + sWord = "Hello" + else + Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here" + sWord = "Hello" + endif end select - + PrintLog "Thesaurus with 1 word: " + sWord - if( Ucase(gApplication) = "DRAW" ) then + if( gApplication = "DRAW" ) then sExt = ".odg" - elseif( Ucase(gApplication) = "IMPRESS" ) then + elseif( gApplication = "IMPRESS" ) then sExt = ".odp" endif - Call hFileOpen (gTesttoolpath + "graphics\required\input\recht_" + iSprache + sExt) - Call sMakeReadOnlyDocumentEditable() + sWorkFile = gTesttoolPath & "graphics\required\input\recht_" & iSprache & sExt + + Call hFileOpenLocally( sWorkFile ) Call hTextrahmenErstellen (sWord,20,20,50,30) sleep 1 printlog "select the word" hTypeKeys "<Home><SHIFT END>" - + try ExtrasThesaurusDraw catch @@ -154,8 +151,7 @@ testcase tiToolsThesaurus endif if ( ReplaceWith.getText() <> sAlternativeText ) then - warnlog "the text is no transfered to the ReplaceWith field. " +_ - "ReplaceWith = " + ReplaceWith.getText() + ", Alternative = " + sAlternativeText + warnlog "the text is no transfered to the ReplaceWith field. " + "ReplaceWith = " + ReplaceWith.getText() + ", Alternative = " + sAlternativeText else printlog "the text is transfered to the ReplaceWith field." endif @@ -165,9 +161,9 @@ testcase tiToolsThesaurus endif Thesaurus.OK - if(Ucase(gApplication) = "DRAW") then + if(gApplication = "DRAW") then Kontext "Draw" - elseif(Ucase(gApplication) = "IMPRESS") then + elseif(gApplication = "IMPRESS") then Kontext "Impress" else ' fallback warnlog "gApplication is wrong" @@ -186,10 +182,10 @@ testcase tiToolsThesaurus else warnlog "thesaurus didn't come up." end if - + Call hCloseDocument -endcase +endcase 'tiToolsThesaurus '------------------------------------------------------------------------------- testcase tiToolsThesaurusWithoutText @@ -210,9 +206,9 @@ testcase tiToolsThesaurusWithoutText endif Call hCloseDocument - -endcase + +endcase 'tiToolsThesaurusWithoutText '------------------------------------------------------------------------------- testcase tiToolsThesaurusContextMenu @@ -236,46 +232,46 @@ testcase tiToolsThesaurusContextMenu 'First we make sure we test a language where Thesaurus select case iSprache - case 01 : sWord = "Hello" - case 03 : sWord = "Alo" - case 07 : printlog "- No Thesaur for Russian available" - goto endsub - case 30 : Printlog "- No Thesaurus available !" - goto endsub - case 31 : sWord = "Guiten" - case 33 : sWord = "Bonjour" - case 34 : sWord = "Hola" - case 35 : Printlog "- No Thesaurus available !" - goto endsub - case 36 : Printlog "- No Thesaurus available !" - goto endsub - case 37 : Printlog "- No Thesaurus available !" - goto endsub - case 39 : sWord = "Ciao" - case 42 : Printlog "- No Thesaurus available !" - goto endsub - case 45 : sWord = "Hej" - case 46 : sWord = "Välkommen" - case 47 : Printlog "- No Thesaurus available !" - goto endsub - case 48 : Printlog "- No Thesaurus in Polish!" - goto endsub - case 49 : sWord = "Hallo" - case 50 : sWord = "Prosojnica" - case 51 : Printlog "- No Thesaurus available !" - goto endsub - case 55 : Printlog "- No Thesaurus in Brazilian!" - goto endsub - case 90 : Printlog "- No Thesaurus available !" - goto endsub + case 01 : sWord = "Hello" + case 03 : sWord = "Alo" + case 07 : printlog "- No Thesaur for Russian available" + goto endsub + case 30 : Printlog "- No Thesaurus available !" + goto endsub + case 31 : sWord = "Guiten" + case 33 : sWord = "Bonjour" + case 34 : sWord = "Hola" + case 35 : Printlog "- No Thesaurus available !" + goto endsub + case 36 : Printlog "- No Thesaurus available !" + goto endsub + case 37 : Printlog "- No Thesaurus available !" + goto endsub + case 39 : sWord = "Ciao" + case 42 : Printlog "- No Thesaurus available !" + goto endsub + case 45 : sWord = "Hej" + case 46 : sWord = "Välkommen" + case 47 : Printlog "- No Thesaurus available !" + goto endsub + case 48 : Printlog "- No Thesaurus in Polish!" + goto endsub + case 49 : sWord = "Hallo" + case 50 : sWord = "Prosojnica" + case 51 : Printlog "- No Thesaurus available !" + goto endsub + case 55 : Printlog "- No Thesaurus in Brazilian!" + goto endsub + case 90 : Printlog "- No Thesaurus available !" + goto endsub - case else : if bAsianLan then - hSetSpellHypLanguage - sWord = "Hello" - else - Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here" - sWord = "Hello" - endif + case else : if bAsianLan then + hSetSpellHypLanguage + sWord = "Hello" + else + Warnlog "For the language " + iSprache +" nothing is prepared yet: insert text here" + sWord = "Hello" + endif end select PrintLog "Thesaurus with 1 word: " + sWord @@ -286,7 +282,7 @@ testcase tiToolsThesaurusContextMenu printlog "select the word" hTypeKeys "<Home><SHIFT END>" - + hOpenContextMenu hMenuSelectNr(14) ' the synonyms @@ -308,28 +304,31 @@ testcase tiToolsThesaurusContextMenu call hCloseDocument -endcase +endcase 'tiToolsThesaurusContextMenu '------------------------------------------------------------------------------- testcase tiToolsHyphenation1 printlog " - Hyphenation without any text" - Call hNewDocument '/// New impress document ///' + printlog "New impress document " + Call hNewDocument sleep 3 - ToolsLanguageHyphenationDraw '/// Try with empty document ///' + ToolsLanguageHyphenationDraw Kontext "Hyphenation" + printlog "Try with empty document" if Hyphenation.Exists(1) = True Then - Warnlog " - Dialog ist da" - Hyphenation.Cancel + Warnlog " - Dialog ist da" + Hyphenation.Cancel else - Printlog " - Hyphenation activated" + Printlog " - Hyphenation activated" end if ' Kontext "DocumentImpress" printlog " - Hyphenation with text, but without any possibility to break words" select case iSprache - case 01 : hTextrahmenErstellen ("This ist a text with no split words",10,10,40,40) '/// Create text without a pssibility to split words///' + case 01 : hTextrahmenErstellen ("This ist a text with no split words",10,10,40,40) case 03 : hTextrahmenErstellen ("Compare a tradu" + Chr(231) + Chr(227) + "o com o original",10,10,40,40) case 07 : qaerrorlog "- No Hypenation for Russian available" - Call hCloseDocument '/// Close document ///' + printlog "Close document" + Call hCloseDocument goto endsub case 31 : hTextrahmenErstellen ("Het is mijn bedoeling om voor en hulpmiddel.",10,10,40,40) case 33 : hTextrahmenErstellen ("Merci beaucoup pout votre candidature du 13/11/97.",10,10,40,40) @@ -340,7 +339,7 @@ testcase tiToolsHyphenation1 case 46 : hTextrahmenErstellen ("Detta är en text utan delade ord",10,10,40,40) case 48 : hTextrahmenErstellen (" Jeoli jednak zechcesz",10,10,40,40) case 49 : hTextrahmenErstellen ("Dies ist ein Text ohne eine Moeglichkeit Woerter zu trennen",10,10,40,40) - case 50 : hTextrahmenErstellen ("Zato ves čas iščemo nove člane: sodelujte",10,10,40,40) + case 50 : hTextrahmenErstellen ("Zato ves �?as iš�?emo nove �?lane: sodelujte",10,10,40,40) case 55 : hTextrahmenErstellen ("a Sun tentou adquirir a Apple",10,10,40,40) case else : if bAsianLan then printlog "For the language " + iSprache +" nothing is prepared yet, but is AsianLan, so OK :-)" @@ -351,7 +350,7 @@ testcase tiToolsHyphenation1 endif end select hTypeKeys "<Home>" - ToolsLanguageHyphenationDraw '/// Try ///' + ToolsLanguageHyphenationDraw Kontext "Hyphenation" if Hyphenation.Exists =True Then Warnlog "Dialog exists" @@ -360,32 +359,32 @@ testcase tiToolsHyphenation1 Kontext "Active" if Active.Exists then Active.OK end if - - Call hCloseDocument '/// Close document ///' + printlog "Close document " + Call hCloseDocument endcase 'tiToolsHyphenation1 '------------------------------------------------------------------------------- testcase tiToolsHyphenation2 - dim iWaitIndex as integer - dim sExt as string - Dim i : Dim DasWort2 : Dim DasWort3 : Dim DasWort4 : Dim DasWort5 : Dim DasWort6 : Dim DasWort7 - Dim DasWort as string - dim sDraw as string - dim sFile as string - PrintLog "- Tools/Hyphenation2" - Select Case Ucase(gApplication) - case "DRAW" : sExt = ".odg" - case "IMPRESS" : sExt = ".odp" - end select + dim iWaitIndex as integer + dim sExt as string + Dim i : Dim DasWort2 : Dim DasWort3 : Dim DasWort4 : Dim DasWort5 : Dim DasWort6 : Dim DasWort7 + Dim DasWort as string + dim sDraw as string + dim sFile as string + PrintLog "- Tools/Hyphenation2" + Select Case gApplication + case "DRAW" : sExt = ".odg" + case "IMPRESS" : sExt = ".odp" + end select - if ((not bAsianLan) AND (iSprache <> 07)) then - sFile = gTesttoolpath + "graphics\required\input\silben_"+iSprache+sExt - Call hFileOpen (sFile) - endif + if ((not bAsianLan) AND (iSprache <> 07)) then + sFile = gTesttoolpath + "graphics\required\input\silben_"+iSprache+sExt + Call hFileOpenLocally( sFile ) + endif - select case iSprache '/// Open prepared document ///' + select case iSprache case 01 :DasWort = "ation" : DasWort2 = "tion" : DasWort3 = "ion" : DasWort4 = "on" '+Chr(34) case 07 : qaerrorlog "- No Hypenation for Russian available" goto endsub @@ -402,6 +401,7 @@ testcase tiToolsHyphenation2 case else : if bAsianLan then printlog "For the language " + iSprache +" nothing is prepared yet, but is AsianLan, so OK :-)" printlog " :-) will use English instead" + printlog "Open prepared document" Call hFileOpen (gTesttoolpath + "graphics\required\input\silben_"+"1"+sExt) DasWort = "ation" : DasWort2 = "tion" : DasWort3 = "ion" : DasWort4 = "on" '+Chr(34) else @@ -410,66 +410,78 @@ testcase tiToolsHyphenation2 endif end select - Call sMakeReadOnlyDocumentEditable - - printlog " - Test hyphenation" - EditSelectAll '/// Press CTRL + A to select all ///' - '/// press return to go into the edit mode ///' + printlog "Test hyphenation" +printlog "Press CTRL + A to select all" + EditSelectAll + printlog "press return to go into the edit mode" hTypeKeys "<Return>" sleep 1 ' WA for draw, or smth else: get text part before hyphenation: if iSprache = "1" OR bAsianLan = TRUE then - hTypeKeys "<MOD1 END><HOME><MOD1 SHIFT RIGHT RIGHT>" '/// Select part of text and compare it with original text at this place ///' + printlog "Select part of text and compare it with original text at this place" + hTypeKeys "<MOD1 END><HOME><MOD1 SHIFT RIGHT RIGHT>" else hTypeKeys "<MOD1 END><HOME><MOD1 SHIFT RIGHT>" endif EditCopy sDraw = GetClipboardText() - EditSelectAll '/// Select whole text ///' - ToolsLanguageHyphenationDraw '/// Run Hyphenation ///' + printlog "Select whole text" + EditSelectAll + printlog "Run Hyphenation" + ToolsLanguageHyphenationDraw gMouseClick 50,50 - hTypeKeys "<MOD1 END><HOME><MOD1 SHIFT RIGHT>" '/// Select part of text and compare it with original text at this place ///' + printlog "Select part of text and compare it with original text at this place" + hTypeKeys "<MOD1 END><HOME><MOD1 SHIFT RIGHT>" sleep 3 EditCopy -printlog GetClipboardText + + printlog GetClipboardText select case GetClipboardText - case DasWort : printlog " - Hyphenation worked" - case DasWort2 : printlog " - Hyphenation worked" - case DasWort3 : printlog " - Hyphenation worked" - case DasWort4 : printlog " - Hyphenation worked" - case else : warnlog " - Hyphenation didnt work" + case DasWort : printlog " - Hyphenation worked" + case DasWort2 : printlog " - Hyphenation worked" + case DasWort3 : printlog " - Hyphenation worked" + case DasWort4 : printlog " - Hyphenation worked" + case else : warnlog " - Hyphenation didnt work" end select if GetClipboardText <> sDraw then - Printlog " - WA draw hyphenation did work :-)" + Printlog " - WA draw hyphenation did work :-)" else - Warnlog " - Hyphenation did not work" - Printlog "Expected: '"+DasWort+"'; or something different than: '"+sDraw+"'; But what we got was: '"+GetClipboardText+"'" + Warnlog " - Hyphenation did not work" + Printlog "Expected: '"+DasWort+"'; or something different than: '"+sDraw+"'; But what we got was: '"+GetClipboardText+"'" end if sleep 1 - Call hCloseDocument '/// Close document ///' + printlog "Close document" + Call hCloseDocument endcase 'tiToolsHyphenation2 '------------------------------------------------------------------------------- testcase tToolsMacro +qaerrorlog( "#i116017# - [Automation]: TypeKeys executes wrong commands" ) + goto endsub + + Dim i as integer Dim j as integer Dim Zaehler as integer Dim ZaehlerListe as integer + printlog "New document" Call hNewDocument ToolsMacro Kontext "Makro" - '/// to get the count of all macros, the list needs to get elapsed-all ///' + printlog "to get the count of all macros, the list needs to get elapsed-all" for j = 1 to 2 Zaehler=MakroAus.GetItemCount MakroAus.typeKeys "<end>" for i = 1 to Zaehler - MakroAus.typeKeys "<+><up>" + MakroAus.typeKeys "<+>" + sleep 1 + MakroAus.typeKeys "<up>" next i next j Zaehler=MakroAus.GetItemCount @@ -578,5 +590,5 @@ testcase tToolsMacro 'TODO: organizer testing! Call hCloseDocument Call hCloseDocument - + endcase 'tToolsMacro diff --git a/testautomation/graphics/optional/includes/global/g_zoom.inc b/testautomation/graphics/optional/includes/global/g_zoom.inc index c82b6743966a..90741015aafd 100644 --- a/testautomation/graphics/optional/includes/global/g_zoom.inc +++ b/testautomation/graphics/optional/includes/global/g_zoom.inc @@ -49,20 +49,22 @@ testcase tViewZoom Datei$ = ConvertPath (gOfficePath + "user\work\test." & ExtensionString) Printlog "- View-Zoom testing" - if dir(Datei$) <> "" then app.Kill(Datei$) ' to avoid the anoying overwrite warnlog :-) - Call hNewDocument '/// new document ///' + printlog "to avoid the anoying overwrite warnlog :-)" + if dir(Datei$) <> "" then app.Kill(Datei$) + printlog "new document" +Call hNewDocument ViewZoom Kontext "Massstab" - Vergroesserung100.Check '/// set zoom to 50% ///' + Vergroesserung100.Check Massstab.OK - '/// create a number of rectangles with different color properties ///' + printlog "create a number of rectangles with different color properties" Kontext "SD_Farbleiste" sleep 1 if SD_Farbleiste.Exists then Printlog "- Color toolbar will be disabled now" ViewToolbarsColorBar end if - '/// All rectangles are created with same dimensions but using different zoom settings ///' + printlog "All rectangles are created with same dimensions but using different zoom settings" For Zaehler = 1 to 9 Position1 = 5 * Zaehler - 3 Position2 = 105 - 5 * Zaehler @@ -77,9 +79,11 @@ testcase tViewZoom gMouseClick 50,0 Next Zaehler sleep 2 - hFileSaveAs (Datei$) '/// save document ///' + printlog "save document" + hFileSaveAs (Datei$) sleep 3 - for Zaehler = 1 to 6 '/// changing zoom settings and checking functionality with controlling the color of the selected rectangle ///' + printlog "changing zoom settings and checking functionality with controlling the color of the selected rectangle" + for Zaehler = 1 to 6 ViewZoom Kontext "Massstab" VergroesserungStufenlos.check @@ -103,18 +107,14 @@ testcase tViewZoom Case 6: VergroesserungStufenlos.check Stufenlos.Settext "200" - 'Case 2: Vergroesserung50.check - 'Case 3: Vergroesserung75.check - 'Case 4: Vergroesserung100.check - 'Case 5: Vergroesserung150.check - 'Case 6: Vergroesserung200.check End Select Massstab.OK sleep 1 Kontext "DocumentImpress" - gMouseClick 15,15 'hier soll die Maus ein Rechteck treffen; - 'die Farbe des Rechtecks sagt uns dann, ob - FormatArea 'richtig vergroessert oder verkleinert wurde. + printlog "Mouseclick should hit a rectangle. Color tells us then if it was zoomed correctly." + gMouseClick 15,15 + + FormatArea sleep 1 Kontext Active.SetPage TabFarben @@ -128,6 +128,6 @@ testcase tViewZoom 'Optimal.push 'Seitenbreite.push sleep 2 - - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument endcase diff --git a/testautomation/graphics/optional/includes/global/id_001.inc b/testautomation/graphics/optional/includes/global/id_001.inc deleted file mode 100644 index 15a99c0d3f23..000000000000 --- a/testautomation/graphics/optional/includes/global/id_001.inc +++ /dev/null @@ -1,725 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\********************************************************************************** - - -testcase tiFileSaveAs - - dim sFileName as string ' test document & new created doc - ' dim sFormula as string ' container for formula to create document with - dim sTemp as string - dim sFilter (50) as string - dim i as integer - dim x as integer - dim y as integer - dim Exlist(100) as string ' files to be deleted - dim sFile as string ' filename to export - dim sPath as string ' filename to export - - if (gApplication = "IMPRESS") then - ExtensionString = "odp" - else - ExtensionString = "odg" - end if - - sFilter (0) = 0 ' initalize ;-)... - - sFileName = "graphics\required\input\tbo_alf_." + ExtensionString ' this is the file with all features - sFile = "isas_" ' this is the filename of the export files - sPath = ConvertPath ( gOfficePath + "user/work/graphics/required/"+gApplication+"\"+ gPlatform) ' this is the export path - if dir (sPath) = "" then - app.mkdir (sPath) - end if - - if gSamePC = TRUE then ' delete export directory - GetFileList ( sPath, sFile+"*", Exlist() ) - if KillFileList ( Exlist() ) <> TRUE then - Warnlog "Couldn't delete all Files in Output-Export-Directory, the followings are still there:" - for i=1 to ListCount ( Exlist() ) - printlog " <> " + Exlist(i) - next i - end if - end if - - Call hFileOpen ( ConvertPath(gTesttoolPath + sFileName) ) - WaitSlot (3000) - - - ' to use the helper fileSaveAs functions i get alll available filters... - FileSaveAs - WaitSlot (2000) - Kontext "SpeichernDlg" - for i = 0 to 5 - if i=0 then x = Dateityp.GetItemCount - if (i) then ' set border, whenm start from beginning/end - y = i ' set filter from beginning - else - y = x-3 ' set filter from end - end if - ListAppend(sFilter(), Dateityp.GetItemText (y)) - next i - SpeichernDlg.Cancel - y = ListCount(sFilter()) - - if gtSYSName = "Linux" then y=y-1 - '#i45961# - last part of filter-list deactivated due to BUG - FHA - 'TODO: JSI->FHA please verify if this special handling needed after the issue has been fixed. - - for i = 1 to y - sFileName = sPath + sFile + (i) - hFileSaveAsWithFilter (sFileName, sFilter(i), TRUE ) - kontext - if messagebox.exists then - messagebox.Yes ' to go on .... - end if - printlog " saved with filter ("+i+"/"+y+"): "+ sFilter(i) - next i - ' TODO TBO: small check, if correct filter was used! - WaitSlot (3000) - fileclose - WaitSlot (3000) - kontext "Messagebox" - if Messagebox.exists then - printlog "Messagebox about informationloss... :-) that's OK: 'Text in the messagebox: "+Messagebox.GetText+"'" - Messagebox.YES - end if - - '----------------------------------------------------------------- - hNewDocument - - - sFilter (0) = 0 - sFileName = sPath - GetFileList ( sFileName, sFile + "*", sFilter() ) - - ' call hNewDocument - x = ListCount ( sFilter() ) - for i = 1 to x - printlog "("+i+"/"+x+"): "+sFilter(i) - hFileOpen ( sFilter(i) ) - WaitSlot (3000) - If hIsNamedDocLoaded (sFilter(i)) Then - printlog " used filter: " + hGetUsedFilter() - else - sTemp = left(right(sFilter(i),2),1) - if ( (sTemp = "t") OR (sTemp = "o") ) then - printlog "document is --- TEMPLATE?! --- " - else - qaErrorlog "#116563# document didn't get loaded " - end if - end if - hCloseDocument - WaitSlot (2000) - next i - ' Call hCloseDocument -endcase - -testcase tiFileReload - Dim DokumentPfad$ - Dim Datei$ - - if (gApplication = "IMPRESS") then - ExtensionString = "odp" - else - ExtensionString = "odg" - end if - - Datei$= (ConvertPath (gOfficePath + "user/work/graphics/required/version1." + ExtensionString)) - - if app.dir(ConvertPath (gOfficePath + "user/work/graphics/required/")) = "" then - app.mkdir (ConvertPath (gOfficePath + "user/work/graphics/required/")) - end if - Call hNewDocument - WaitSlot (2000) - Call hFileSaveAsKill (Datei$) - WaitSlot (2000) - Call hCloseDocument - - Call hFileOpen (Datei$) - WaitSlot (2000) - call hTBOtypeInDoc - WaitSlot (2000) - FileReload - WaitSlot (2000) - Kontext "Messagebox" - sleep 2 - Messagebox.No - WaitSlot (2000) - - FileReload - WaitSlot (2000) - Kontext "Messagebox" - sleep 2 - Messagebox.Yes - WaitSlot (1000) - - Call hCloseDocument - if Dir (Datei$) <> "" AND gSamePC = TRUE then kill Datei$ -endcase - -testcase tiFileVersion - Dim DokumentPfad$ - Dim Datei$ - - if (gApplication = "IMPRESS") then - ExtensionString = "odp" - else - ExtensionString = "odg" - end if - - Datei$= (ConvertPath (gOfficePath + "user/work/graphics/required/erwin." + ExtensionString)) - 'if dir (ConvertPath (gOfficePath + "user/work/graphics/required/")) = "" then - if dir (Datei$) = "" then app.mkdir (ConvertPath (gOfficePath + "user/work/graphics/required/")) - Call hNewDocument - WaitSlot (1000) - Call hFileSaveAsKill (Datei$) - WaitSlot (1000) - Call hCloseDocument - - Call hFileOpen (Datei$) - WaitSlot (1000) - call hTBOtypeInDoc - WaitSlot (1000) - try - FileVersions - catch - Warnlog "- File / Versions not accessible!" - goto endsub - endcatch - - Kontext "Versionen" - Call DialogTest ( Versionen ) - Speichern.Click - Kontext "VersionskommentarEingeben" - Call DialogTest ( VersionskommentarEingeben ) - VersionskommentarEingeben.Cancel - Kontext "Versionen" - Versionen.Close - Call hCloseDocument - ' if Dir (Datei$) <> "" AND gSamePC = TRUE then kill Datei$ -endcase - -testcase tiFilePassword - goto endsub - Dim DokumentPfad$ - Dim Datei$ - dim sFileName as string ' test document & new created doc - ' dim sFormula as string ' container for formula to create document with - dim e as string - dim sTemp as string - dim sFilter (50) as string - dim i as integer - dim x as integer - dim y as integer - dim Exlist(100) as string ' files to be deleted - dim sFileIn as string ' filename to import - dim sFile as string ' filename to export - dim sPath as string ' and path to export - - if (gApplication = "IMPRESS") then - ExtensionString = "odp" - else - ExtensionString = "odg" - end if - - sFile = "isp__" ' this is the filename of the export files - sPath = ConvertPath ( gOfficePath + "user/work/graphics/required/"+gApplication+"\"+ gPlatform+"\") ' this is the export path - mkdir (sPath) - if dir (sPath) = "" then app.mkdir (sPath) - sFileIn = (sPath + sFile + "." + ExtensionString) - if gSamePC = TRUE then ' delete export directory - GetFileList ( sPath, sFile+"*", Exlist() ) - if KillFileList ( Exlist() ) <> TRUE then - Warnlog "Couldnt delete all Files in Output-Export-Directory, the followings are still there:" - for i=1 to ListCount ( Exlist() ) - printlog " <> " + Exlist(i) - next i - end if - end if - - Call hNewDocument - WaitSlot (1000) - FileSaveAs - Kontext "SpeichernDlg" - Datei$ = ConvertPath ( sFileIn ) - printlog " will use the file: "+Datei$ - if Dir (Datei$) <> "" then - kill Datei$ - end if - Passwort.Check - Dateiname.SetText Datei$ - Speichern.Click - WaitSlot (2000) - Kontext "Passwort" - PasswortName.SetText "12345" - PasswortBestaetigen.Settext "54321" - Passwort.OK - WaitSlot (2000) - Kontext "Messagebox" - if Messagebox.Exists(1) then - Messagebox.OK - else - Warnlog "- Wrong password not recognized" - end if - Kontext "Passwort" - PasswortName.SetText "12345" - PasswortBestaetigen.SetText "12345" - Passwort.OK - sleep 2 - FileClose - sleep 2 - - FileOpen - Kontext "OeffnenDlg" - WaitSlot (2000) - Dateiname.SetText Datei$ - Oeffnen.Click - WaitSlot (2000) - Kontext "PasswordFileOpen" - PasswortName.SetText "34567" - try - PasswordFileOpen.OK - catch - Printlog "- Wrong password not accepted" - endcatch - Kontext - if Not Messagebox.Exists(1) then - Warnlog "Wrong password while loading not recognized" - else - Messagebox.OK - printlog "Wrong password on loading ok - recogniced" - end if - WaitSlot (3000) - Kontext "PasswordFileOpen" - PasswortName.SetText "12345" - PasswordFileOpen.OK - WaitSlot (5000) - FileSaveAs - Kontext "SpeichernDlg" - Dateiname.SetText Datei$ - if (Passwort.IsChecked <> TRUE) then - Warnlog "Password has to be checked! :-(" - end if - Speichern.Click - WaitSlot (1000) - Kontext "Messagebox" - if Messagebox.Exists(5) then - Messagebox.Yes - end if - Kontext "Passwort" - if (Passwort.Exists(5) = FALSE)then - Warnlog "- Password dialog Didn't pop up after pressing save" - else - Kontext "Passwort" - WaitSlot (1000) - PasswortName.SetText "a12345" - PasswortBestaetigen.SetText "a12345" - Passwort.OK - WaitSlot (1000) - FileClose - WaitSlot (1000) - end if - FileOpen - WaitSlot (2000) - Kontext "OeffnenDlg" - Dateiname.SetText Datei$ - Oeffnen.Click - Kontext "PasswordFileOpen" - WaitSlot (1000) - PasswortName.SetText "a12345" - PasswordFileOpen.OK - WaitSlot (5000) - FileSaveAs - Kontext "SpeichernDlg" - Dateiname.SetText Datei$ - if (Passwort.IsChecked <> TRUE) then - Warnlog "Password has to be checked! :-(" - end if - Passwort.UnCheck - Speichern.Click - Kontext "Messagebox" - if Messagebox.Exists(5) then Messagebox.Yes - Kontext "Passwort" - if (Passwort.Exists(5))then - Warnlog "- Password dialog didn't pop up after pressing save" - Kontext "Passwort" - password.cancel - FileClose - else - hCloseDocument - end if -endcase - -testcase tiFileTemplates - Call hNewDocument - - FileTemplatesOrganize - Kontext "DVVerwalten" - WaitSlot (1000) - Call DialogTest (DVVerwalten) - sleep 1 - PopuplisteLinks.Select 2 - WaitSlot (1000) - PopuplisteRechts.Select 2 - WaitSlot (1000) - WelcheDatei.Click - WaitSlot (1000) - Kontext "Oeffnendlg" - Call DialogTest (OeffnenDlg) - sleep 1 - OeffnenDlg.Cancel - WaitSlot (2000) - Kontext "DVVerwalten" - DVVerwalten.Close - - if gtSYSName = "Solaris x86" then - qaErrorLog "#i62423# - FileTemplatesAddressBookSource outcommented under x86. - FHA" - else - FileTemplatesAddressBookSource - Printlog "- AddressBookAssignment" - kontext "AddressBookSource" - Call DialogTest (AddressBookSource) - Administrate.Click - kontext "AddressSourceAutopilot" - AddressSourceAutopilot.Cancel - kontext "AddressBookSource" - AddressBookSource.Cancel - end if - - FileTemplatesSave - Printlog "- Save template" - WaitSlot (1000) - Kontext "Dokumentvorlagen" - sleep 1 - Call DialogTest (Dokumentvorlagen) - WaitSlot (1000) - Verwalten.Click - WaitSlot (2000) - Kontext "DVVerwalten" - Call DialogTest (DVVerwalten) - WaitSlot (3000) - DVVerwalten.Close - WaitSlot (1000) - Kontext "Dokumentvorlagen" - sleep 1 - Dokumentvorlagen.Cancel - WaitSlot (1000) - - try - FileTemplatesEdit - Printlog "- Edit template" - WaitSlot (1000) - Kontext "OeffnenDlg" - sleep 1 - Call DialogTest (OeffnenDlg) - WaitSlot (1000) - OeffnenDlg.Cancel - catch - Warnlog "- There are problems with File-Template-Save" - endcatch - WaitSlot (1000) - Call hCloseDocument -endcase - - -'----------------------------------------------------------- -'******************* M A T H dito ************************* -'----------------------------------------------------------- - - -testcase tmFileNewFromTemplate - Call hNewDocument - FileNewFromTemplate - WaitSlot (5000) - Kontext "TemplateAndDocuments" - if TemplateAndDocuments.NotExists then - Warnlog "Dialog Templates and Documents are not up!" - goto endsub - end if - Call DialogTest (TemplateAndDocuments) - WaitSlot (5000) - try - TemplateAndDocuments.Cancel - catch - endcatch - WaitSlot (5000) - Call hCloseDocument -endcase - -testcase tmFileOpen - call hNewDocument - FileOpen - Kontext "OeffnenDlg" - UebergeordneterOrdner.Click - Standard.Click - NurLesen.check - Call DialogTest ( OeffnenDlg ) - OeffnenDlg.Cancel - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tmFileClose - printlog "- File Close" - hNewDocument ' just for the records: I open ONE document - call hTBOtypeInDoc - WaitSlot (2000) - FileClose - Kontext ' Expecting "Modified, do you want to close?" - if active.exists (5) then - printlog " Ok, active came up: " + active.gettext - Active.Cancel ' No, not this time - else - warnlog "active missing (1)" - end if - WaitSlot (2000) - - FileClose - Kontext - Active.Yes ' but now - records: this document is closed - WaitSlot (2000) - - Kontext "SpeichernDlg" - Call DialogTest ( SpeichernDlg ) - SpeichernDlg.Cancel - WaitSlot (2000) - - FileClose ' now the office gets closed! (if there were no modifications!) - Kontext - Active.No - WaitSlot (2000) -endcase -'----------------------------------------------------------- -testcase tmFileSave - hNewDocument - call hTBOtypeInDoc - - FileSave - WaitSlot (2000) - Kontext "SpeichernDlg" - UebergeordneterOrdner.click - Standard.Click - Call DialogTest (SpeichernDlg) - Kontext "SpeichernDlg" - Standard.Click - SpeichernDlg.Cancel - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tmFileSaveAs - - hNewDocument - WaitSlot (2000) - call hTBOtypeInDoc - - FileSaveAs - WaitSlot (2000) - Kontext "SpeichernDlg" - if (SpeichernDlg.exists (5) = FALSE) then - warnlog "FileSaveAs dialog is not visible" - end if - WaitSlot (2000) - Passwort.check - Passwort.uncheck - UebergeordneterOrdner.click - Standard.Click - - NeuerOrdner.click - kontext "NeuerOrdner" - neuerordner.cancel - Kontext "SpeichernDlg" - - Call DialogTest (SpeichernDlg) - - Kontext "SpeichernDlg" - SpeichernDlg.Cancel - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tmFileSaveAll - printlog "- File SaveAll" - - hNewDocument - call hTBOtypeInDoc - - Printlog " open 2. window" - hNewDocument - call hTBOtypeInDoc - - Printlog " call save all" - FileSaveAll - Printlog " cancel 1. save" - Kontext "SpeichernDlg" - SpeichernDlg.Cancel - - Printlog " cancel 2. save" - WaitSlot (2000) - Kontext "SpeichernDlg" - SpeichernDlg.Cancel - WaitSlot (2000) - - try - Kontext "SpeichernDlg" - SpeichernDlg.Cancel - printlog "smth had been typed in the starting window (just a hint ;-) )" - catch - printlog "--------- no other window wants to get saved. :-)" - endcatch - - WaitSlot (2000) - Printlog " hCloseDocument both" - Call hCloseDocument - sleep 2 - Printlog " first closed" - Call hCloseDocument - WaitSlot (2000) - Printlog " second closed" - WaitSlot (5000) -endcase - -testcase tmFileProperties - printlog "- File Properties" - - Call hNewDocument - FileProperties - - Kontext - active.SetPage TabDokument - Kontext "TabDokument" - Call DialogTest ( TabDokument ) - - Kontext - active.SetPage TabDokumentInfo - Kontext "TabDokumentInfo" - Call DialogTest ( TabDokumentInfo ) - - 'Deactivating this part because of #i95523#: - 'Kontext - 'active.SetPage TabBenutzer - 'Kontext "TabBenutzer" - 'Call DialogTest ( TabBenutzer ) - 'Infofelder.Click - ' Kontext "InfonamenBearbeiten" - ' Call DialogTest (InfonamenBearbeiten) - 'InfonamenBearbeiten.Cancel - - Kontext - active.SetPage TabInternet - Kontext "TabInternet" - Call DialogTest (TabInternet) - TabInternet.Cancel - - Call hCloseDocument -endcase - -testcase tmFilePrinterSetting - printlog "- File Printersettings" - Call hNewDocument - WaitSlot (3000) - FilePrintersettings - kontext - if active.exists(5) then - active.ok - qaerrorlog "There is no printer available - please install one on your system!" - end if - WaitSlot (2000) - Kontext "DruckerEinrichten" - Call DialogTest (DruckerEinrichten) - sleep 2 - DruckerEinrichten.Cancel - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tdFileExport - goto endsub - dim x as integer - Call hNewDocument - WaitSlot (3000) - FileExport - Kontext "ExportierenDlg" - Call DialogTest ( ExportierenDlg ) - UebergeordneterOrdner.Click - Kontext "SpeichernDlg" - x=Dateityp.getitemcount - if x <> 18 then warnlog "the number of filters is not 18, it is: " + x - SpeichernDlg.Cancel - WaitSlot (2000) - Call hCloseDocument - WaitSlot (2000) -endcase - -testcase tmFileExit - goto endsub - printlog "- File Close" - Call hNewDocument - WaitSlot (2000) - try - FileExit "SynchronMode", TRUE - WaitSlot (2000) - Kontext - WaitSlot (2000) - Kontext "MessageBox" - if MessageBox.Exists(1) then ' this is the messagebox from the first window! - Printlog MessageBox.GetText - try - MessageBox.OK - catch - MessageBox.No - endcatch - end if - Kontext "MessageBox" - if MessageBox.Exists(1) then - Warnlog "MsgBox popped up and there were no changes in the document" - Printlog MessageBox.GetText - try - MessageBox.OK - catch - MessageBox.No - endcatch - end if - catch - printlog "this exit is wanted :-)" - endcatch - try - WaitSlot (20000) - call hStartTheOffice ' from master.inc - catch - printlog "catch AGAIN" - endcatch - Kontext "SD_Praesentation" - if SD_Praesentation.exists (2) then - ViewToolbarsPresentation - end if -endcase diff --git a/testautomation/graphics/optional/includes/global/id_002.inc b/testautomation/graphics/optional/includes/global/id_002.inc deleted file mode 100644 index c199ab998524..000000000000 --- a/testautomation/graphics/optional/includes/global/id_002.inc +++ /dev/null @@ -1,440 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\********************************************************************************** - -testcase tiEditUndoRedo - - hNewDocument - call hTBOtypeInDoc - - EditUndo - WaitSlot (2000) - EditRedo - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tiEditRepeat - goto endsub 'Quaste, ask FHA - Call hNewDocument - - gMouseClick 50,50 - Call hRechteckErstellen ( 30, 10, 70, 30 ) - WaitSlot (1000) - Call hRechteckErstellen ( 20, 20, 60, 40 ) - WaitSlot (1000) - Call hRechteckErstellen ( 80, 50, 40, 20 ) - WaitSlot (1000) - ContextArrangeBringBackward - WaitSlot (2000) - try - EditRepeat - catch - Warnlog " Menu entry is disabled #i26129#" - endcatch - - Call hCloseDocument -endcase - -testcase tiEditCutPasteCopySelectall - Call hNewDocument - - call hTBOtypeInDoc - - EditCut - WaitSlot (2000) - EditPaste - WaitSlot (2000) - EditCopy - WaitSlot (2000) - EditPaste - WaitSlot (2000) - EditSelectAll - WaitSlot (2000) - EditCut - WaitSlot (2000) - EditPaste - WaitSlot (2000) - EditDeleteContents - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tiEditPasteSpecial - Call hNewDocument - - SetClipboard "This is a Text in the Clipboard" - - EditPasteSpecial - WaitSlot (1000) - Kontext "InhaltEinfuegen" - DialogTest ( InhaltEinfuegen ) - - InhaltEinfuegen.Cancel - WaitSlot (1000) - Call hCloseDocument -endcase - -testcase tiEditSearchAndReplace - Call hNewDocument - - try - EditSearchAndReplace - WaitSlot (1000) - Kontext "FindAndReplace" - DialogTest ( FindAndReplace ) - - More.Click - SimilaritySearch.Check ' culprint for errors if not resetted ! - WaitSlot (1000) - SimilaritySearchFor.Click - Kontext "Aehnlichkeitssuche" - DialogTest (Aehnlichkeitssuche ) - Aehnlichkeitssuche.Cancel - Kontext "FindAndReplace" - SimilaritySearch.UnCheck - More.Click - FindAndReplace.Close - catch - Warnlog "EditSearchAndReplace caused an error" - endcatch - Call hCloseDocument -endcase - -testcase tiEditDuplicate - Call hNewDocument - call hTBOtypeInDoc - EditSelectAll - EditDuplicate - - Kontext "Duplizieren" - Call DialogTest ( Duplizieren ) - Duplizieren.Cancel - - Call hCloseDocument -endcase - -testcase tEditPoints - Call hNewDocument - call hTBOtypeInDoc - FormatEditPoints - EditGluePoints - Call hCloseDocument -endcase - -testcase tiEditFields - Call hNewDocument - WaitSlot (2000) - InsertFieldsDateFix - WaitSlot (1000) - gMouseDoubleClick 10,10 - - hTypeKeys "<ESCAPE>" - hTypeKeys "<Tab>" ' With a Tab catches we always the Object - hTypeKeys "<F2>" ' Here we enter Edit-Mode and therefore also the right place - hTypeKeys "<Home>" ' Here we enter Edit-Mode and therefore also the right place - - try - EditFieldsDraw - Kontext "FeldbefehlBearbeitenDraw" - Call DialogTest ( FeldbefehlBearbeitenDraw ) - FeldbefehlBearbeitenDraw.Close - catch - Warnlog "- Slot could not be accessed" - endcatch - - Call hCloseDocument -endcase - -testcase tdEditDeleteSlide - Call hNewDocument - InsertSlide - WaitSlot (2000) - hTypekeys "<Pagedown>" - WaitSlot (2000) - Kontext "Navigator" - sleep (2) - if Navigator.exists then - printlog "Navigator: open :-)" - else - printlog "Navigator: NOT available :-( Will be opened now!" - ViewNavigator - end if - WaitSlot (2000) - Kontext "NavigatorDraw" - if Liste.GetItemCount<>2 Then - Warnlog "- No slide inserted" - Kontext "Navigator" - Navigator.Close - Call hCloseDocument - goto endsub - else - Liste.Select 2 - Kontext "Navigator" - Navigator.Close - end if - WaitSlot (2000) - EditDeleteSlide - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tiEditLinks - Call hNewDocument - - InsertGraphicsFromFile - Kontext "GrafikEinfuegenDlg" - try - if Link.Exists then - Link.Check - else - Warnlog "- Link in Insert graphic is not working" - end if - Dateiname.settext Convertpath (gTesttoolPath + "global\input\graf_inp\stabler.tif") - Oeffnen.Click - Kontext "Messagebox" - if Messagebox.Exists=True Then - Warnlog Messagebox.GetText - Messagebox.Ok - end if - InsertGraphicsFromFile - Kontext "GrafikEinfuegenDlg" - Link.Check - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - Oeffnen.Click - - kontext "Messagebox" - if Messagebox.Exists( 2 ) then - Warnlog Messagebox.GetText - Messagebox.OK - sleep 1 - end if - catch - Warnlog "Insert graphic caused errors" - endcatch - - WaitSlot (2000) - try - EditLinksDraw - WaitSlot (2000) - Kontext "VerknuepfungenBearbeiten" - Call DialogTest ( VerknuepfungenBearbeiten ) - VerknuepfungenBearbeiten.Close - WaitSlot (1000) - catch - Warnlog "- EditLinks could not be executed, could be the graphic was not imported" - endcatch - - Call hCloseDocument -endcase - -testcase tiEditImageMap - Call hNewDocument - - EditImageMap - - Kontext "ImageMapEditor" - if ImageMapEditor.Exists( 5 ) then - printlog "- ImageMap exists" - DialogTest ( ImageMapEditor ) - try - ImageMapEditor.Close - Printlog "ImageMap closed using the close button" - catch - EditImageMap - Printlog "ImageMap closed using menue 'edit-imagemap'" - endcatch - else - warnlog "ImageMap didn't come up!" - end if - Call hCloseDocument -endcase - -testcase tiEditObjectProperties - dim i as integer - - Call hNewDocument - - InsertFloatingFrame - WaitSlot (2000) - - Kontext "TabEigenschaften" - FrameName.SetText "Hello" - Inhalt.SetText ConvertPath ( gTesttoolpath + "global\input\graf_inp\desp.bmp" ) - WaitSlot (2000) - TabEigenschaften.OK - WaitSlot (2000) - gMouseDoubleClick 1,1 - - hTypekeys "<tab>" - - kontext - WaitSlot (2000) - EditObjectProperties - WaitSlot (1000) - Kontext "TabEigenschaften" - DialogTest ( TabEigenschaften ) - Oeffnen.Click - Kontext "OeffnenDlg" - Call DialogTest ( OeffnenDlg ) - OeffnenDlg.Cancel - Kontext "TabEigenschaften" - TabEigenschaften.Cancel - - Call hCloseDocument -endcase - -testcase tiEditObjectEdit - dim i as integer - Call hNewDocument - - InsertObjectOLEObject - WaitSlot (1000) - Kontext "OLEObjektEinfuegen" - ObjektTyp.Select 1 - OLEObjektEinfuegen.OK - WaitSlot (1000) - - gMouseClick 20,1 - - hTypekeys "<tab>" - - EditObjectEdit - ' try EditObjectEdit again, to see, if it is in edit mode ! - WaitSlot (2000) - try - ContextNameObject - warnlog " Couldn't get into edit mode!" - catch - printlog "Reached edit mode - ok :-)" - gMouseClick 20,1 - endcatch - - EditSelectAll - - EditObjectSaveCopyAs - Kontext "SpeichernDlg" - Call DialogTest ( SpeichernDlg ) - SpeichernDlg.Cancel - WaitSlot (2000) - Kontext "Active" - if Active.Exists(2) then Active.No - Call hCloseDocument -endcase - -testcase tiEditPlugIn - Call hNewDocument - - InsertObjectPlugin - Kontext "PlugInEinfuegen" - ' DialogTest ( PlugInEinfuegen) - Durchsuchen.click - Kontext "OeffnenDlg" - ' Call DialogTest ( OeffnenDlg ) - if OeffnenDlg.exists (5) then - OeffnenDlg.Cancel - else - warnlog "Open file dialog didn't come up" - end if - WaitSlot (5000) - Kontext "PlugInEinfuegen" - if PlugInEinfuegen.exists then - DateiUrl.SetText (ConvertPath ( gTesttoolpath + "graphics\required\input\sample.mov" )) - - Optionen.SetText "Fiddler's Green" - Optionen.TypeKeys "<HOME>" - Optionen.TypeKeys "<SHIFT><END>" - Optionen.TypeKeys "<delete>" - PlugInEinfuegen.Ok - else - warnlog "Insert plugin isn't visible" - end if - WaitSlot (5000) - kontext "Messagebox" - if Messagebox.exists (5) then - warnlog "Messagebox: " + Messagebox.gettext - Messagebox.ok - end if - EditPlugIn - printlog "Editplugin works!" - - Call hCloseDocument -endcase - -testcase tiEditHyperlink - hNewDocument - InsertHyperlink - - kontext "HyperlinkDialog" - if ( HyperlinkDialog.exists( 2 ) ) then - Kontext "Hyperlink" - Auswahl.MouseDown 50, 5 - Auswahl.MouseUp 50, 5 - Auswahl.typekeys "<PAGEDOWN><PAGEUP>" - Auswahl.typekeys "<TAB>" - sleep( 1 ) - Kontext "TabHyperlinkInternet" - - 'Workaround to get rid of a Focusing-problem... - NameText.Typekeys "alal <RETURN>" - NameText.Typekeys "<MOD1 A><DELETE>" - TabHyperlinkInternet.Typekeys "<TAB>", 6 - TabHyperlinkInternet.Typekeys "<LEFT>", 3 - 'End of workaround... - - Internet.Check 'Just to make sure the radio-button is addressable. - ZielUrl.Settext "http://www.liegerad-fahrer.de" - - Uebernehmen.Click() - - kontext "HyperlinkDialog" - HyperlinkDialog.Close() - - hTypeKeys "<TAB><F2>" - EditSelectAll - try - EditHyperlinkDraw - Kontext "HyperlinkDialog" - if ( HyperlinkDialog.Exists( 1 ) ) then - HyperlinkDialog.Close() - else - Warnlog "- Hyperlinkdialog not up" - end if - catch - Warnlog "- Not able to edit Hyperlink!" - endcatch - else - warnlog( "Failed to open <HyperlinkDialog>" ) - endif - - Call hCloseDocument -endcase diff --git a/testautomation/graphics/optional/includes/global/id_003.inc b/testautomation/graphics/optional/includes/global/id_003.inc deleted file mode 100644 index 4ada1beaaea4..000000000000 --- a/testautomation/graphics/optional/includes/global/id_003.inc +++ /dev/null @@ -1,264 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\********************************************************************************** - -testcase tiViewNavigator - Call hNewDocument - - Kontext "NavigatorDraw" - if Not NavigatorDraw.Exists Then - ViewNavigator - end if - Kontext "NavigatorDraw" - Call DialogTest ( NavigatorDraw ) - - try - Kontext "Navigator" - Navigator.Close - catch - Errorlog " Navigator wasn't closed, second try with Menu" - ViewNavigator - endcatch - Call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tiViewZoom - Call hNewDocument - UseBindings - ViewZoom - Kontext "Massstab" - DialogTest ( Massstab ) - Massstab.Cancel - Call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tiViewToolbar - Call hNewDocument - - ViewToolbarsThreeDSettings - WaitSlot (1000) - ViewToolbarsThreeDSettings - WaitSlot (1000) - - ViewToolbarsAlign - WaitSlot (1000) - ViewToolbarsAlign - WaitSlot (1000) - - ViewToolbarsTools - WaitSlot (1000) - ViewToolbarsTools - WaitSlot (1000) - - ViewToolbarsBezier - WaitSlot (1000) - ViewToolbarsBezier - WaitSlot (1000) - - ViewToolbarsFontwork - WaitSlot (1000) - ViewToolbarsFontwork - WaitSlot (1000) - - ' if gApplication = "IMPRESS" then - ' ViewToolbarsPresentation ' only in impress, not draw - ' ViewToolbarsPresentation - ' endif - - ViewToolbarsFormControls - WaitSlot (1000) - ViewToolbarsFormControls - WaitSlot (1000) - - '----------------- - ViewToolbarsFormDesign - WaitSlot (1000) - ViewToolbarsFormDesign - WaitSlot (1000) - - ViewToolbarsFormNavigation - WaitSlot (1000) - ViewToolbarsFormNavigation - WaitSlot (1000) - - ViewToolbarsGluepoints - WaitSlot (1000) - ViewToolbarsGluepoints - WaitSlot (1000) - ViewToolbarsInsert - WaitSlot (1000) - ViewToolbarsInsert - WaitSlot (1000) - - ViewToolbarsGraphic - WaitSlot (1000) - ViewToolbarsGraphic - WaitSlot (1000) - - ViewToolbarsMediaPlayback - WaitSlot (1000) - ViewToolbarsMediaPlayback - WaitSlot (1000) - - ViewToolbarsOptionbar - WaitSlot (1000) - ViewToolbarsOptionbar - WaitSlot (1000) - - ViewToolbarsPicture - WaitSlot (1000) - ViewToolbarsPicture - WaitSlot (1000) - - ViewToolbarsStandard - WaitSlot (1000) - ViewToolbarsStandard - WaitSlot (1000) - - ViewToolbarsStandardView - WaitSlot (1000) - ViewToolbarsStandardView - WaitSlot (1000) - - ViewToolbarsHyperlinkbar - WaitSlot (1000) - ViewToolbarsHyperlinkbar - WaitSlot (1000) - - ViewToolbarsColorBar - WaitSlot (1000) - ViewToolbarsColorBar - WaitSlot (1000) - - ViewToolbarsCustomize - WaitSlot (1000) - Kontext - try - Messagebox.SetPage TabCustomizeMenu ' 1 ------------------ - catch - warnlog "couldn't switch to tabpage 'Menus'" - endcatch - Kontext "TabCustomizeMenu" - if TabCustomizeMenu.exists(5) then - Call DialogTest ( TabCustomizeMenu ) - Menu.typeKeys("<down>") - Entries.typeKeys("<down>") - sleep 2 - BtnNew.Click - sleep 1 - Kontext "MenuOrganiser" - Call DialogTest ( MenuOrganiser ) - MenuOrganiser.cancel - sleep 1 - Kontext "TabCustomizeMenu" - TabCustomizeMenu.Close - end if - sleep (1) - - Call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tiViewDisplayQuality - Call hNewDocument - - Call hRechteckErstellen 20,20,40,40 - - try - ViewQualityBlackWhite - Printlog "- Quality set to black and white" - catch - Warnlog "- Slot could not be accessed" - endcatch - WaitSlot (1000) - try - ViewQualityGreyscale - Printlog "- View quality set to greyscale" - catch - Warnlog "- View quality greyscale could not be accessed" - endcatch - WaitSlot (1000) - try - ViewQualityColour - Printlog "- View quality set to colour" - catch - Warnlog "- View quality colour could not be accessed" - endcatch - Call hClosedocument -endcase - -'------------------------------------------------------------------------- - -testcase tiViewLayer - Call hNewDocument - - ViewLayer - WaitSlot (1000) - ViewLayer - Call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tViewGrid - Call hNewDocument - - ViewGridVisible - ViewGridUse - ViewGridFront - ViewGridVisible - ViewGridUse - ViewGridFront - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tViewSnapLines - Call hNewDocument - - ViewSnapLinesVisible - ViewSnapLinesUse - ViewSnapLinesFront - ViewSnapLinesVisible - ViewSnapLinesUse - ViewSnapLinesFront - WaitSlot (1000) - Call hCloseDocument -endcase - diff --git a/testautomation/graphics/optional/includes/global/id_004.inc b/testautomation/graphics/optional/includes/global/id_004.inc deleted file mode 100644 index 2e1aa6db3cd1..000000000000 --- a/testautomation/graphics/optional/includes/global/id_004.inc +++ /dev/null @@ -1,370 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\********************************************************************************** - - -testcase tiInsertSlide - - Call hNewDocument - InsertSlide - WaitSlot (2000) - hTypekeys "<Pagedown>" - WaitSlot (2000) 'sleep 2 - Call hCloseDocument -endcase - -testcase tiInsertDuplicateSlide - Call hNewDocument - Call hRechteckErstellen ( 30, 40, 40, 50 ) - InsertDuplicateSlide - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tiInsertField - Call hNewDocument - - InsertFieldsTimeFix - WaitSlot (1000) - printlog "OK Time Fix" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsDateFix - WaitSlot (1000) - printlog "OK Date Fix" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsTimeVariable - WaitSlot (1000) - printlog "OK Time Variabel" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsDateVariable - WaitSlot (1000) - printlog "OK Date Variabel" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsAuthorDraw - WaitSlot (1000) - printlog "OK Author" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsPageNumberDraw - WaitSlot (1000) - printlog "OK Page number" - EditSelectAll - hTypekeys "<Delete>" - sleep 1 - - InsertFieldsFileName - WaitSlot (1000) 'sleep 1 - printlog "OK File name" - EditSelectAll - hTypekeys "<Delete>" - sleep 2 - Call hCloseDocument -endcase - -testcase tiInsertSpecialCharacter - Call hNewDocument - - hTextrahmenErstellen ("This is a testtext",30,40,60,50) - sleep 2 - InsertSpecialCharacterDraw - - Kontext "Sonderzeichen" - if ( Sonderzeichen.exists( 2 ) ) then - Call DialogTest (Sonderzeichen) - hCloseDialog( Sonderzeichen, "Cancel" ) - else - warnlog( "<Special Characters> dialog not open" ) - endif - Call hCloseDocument -endcase - -testcase tiInsertHyperlink - - Call hNewDocument - InsertHyperlink - - kontext "HyperlinkDialog" - if ( HyperlinkDialog.exists( 2 ) ) then - - Kontext "TabHyperlinkInternet" - Auswahl.MouseDown 50, 5 - Auswahl.MouseUp 50, 5 - Auswahl.typekeys "<PAGEDOWN><PAGEUP>" - Auswahl.typekeys "<TAB>" - - 'Workaround to get rid of a Focusing-problem... - NameText.Typekeys "alal <RETURN>" - NameText.Typekeys "<MOD1 A><DELETE>" - TabHyperlinkInternet.Typekeys "<TAB>", 6 - TabHyperlinkInternet.Typekeys "<LEFT>", 3 - 'End of workaround... - - Internet.Check - ZielUrl.SetText( "http://www.nowhere.com" ) - Uebernehmen.Click() - - kontext "HyperlinkDialog" - HyperlinkDialog.Close() - - else - warnlog "Failed to open <HyperlinkDialog>" - end if - Call hCloseDocument -endcase - -testcase tiInsertGraphic - Call hNewDocument - InsertGraphicsFromFile - WaitSlot (2000) ' - try - Kontext "GrafikEinfuegenDlg" - if Link.exists then - Link.Check - else - Warnlog "Linking grafik doesn't work :-(" - end if - if Preview.exists then - Preview.Check - else - Warnlog "Preview of graphic doesn't work :-(" - end if - DialogTest (GrafikEinfuegenDlg) - - Dateiname.settext Convertpath (gTesttoolPath + "global\input\graf_inp\stabler.tif") - Oeffnen.click - catch - Warnlog "Insert graphic doesn't work :-(" - endcatch - - Call hCloseDocument -endcase - -testcase tiInsertObjectSound - goto endsub ' disabled for final, because always wrong (TZ 01/2002) - 'TODO: TBO: enhance! - Call hNewDocument - try - InsertObjectSound - WaitSlot (1000) - Kontext "OeffnenDlg" - ' Call Dialogtest (OeffnenDlg) ' just be sure to check one pth and one open dialog : TZ 28.11.201 - - OeffnenDlg.Cancel - catch - printlog "'Insert -> Object -> Sound' not available. TestDevelopmentInProgress (TDIP) ;-)" - endcatch - Call hCloseDocument -endcase - -testcase tiInsertObjectVideo - goto endsub - 'TODO: TBO: enhance! - Call hNewDocument - try - InsertObjectVideo - Kontext "OeffnenDlg" - ' Call Dialogtest (OeffnenDlg) - WaitSlot (1000) - OeffnenDlg.Cancel - catch - printlog "'Insert -> Object -> Video' not available. (TDIP) ;-)" - endcatch - Call hCloseDocument -endcase - -testcase tiInsertChart - Call hNewDocument - InsertChart - - Kontext "Messagebox" - if ( Messagebox.Exists( 2 ) ) then - Warnlog Messagebox.GetText - hCloseDialog( Messagebox, "OK" ) - end if - gMouseClick 1,1 - sleep 2 - Call hCloseDocument -endcase - -testcase tiInsertObjectOLEObjects - hNewDocument - InsertObjectOLEObject - Kontext "OLEObjektEinfuegen" - ' Call Dialogtest ( OLEObjektEinfuegen ) - ' NeuErstellen.Check ' is default value - Call DialogTest (OLEObjektEinfuegen, 1) - AusDateiErstellen.Check - Call DialogTest (OLEObjektEinfuegen, 2) - Durchsuchen.click - Kontext "OeffnenDlG" - OeffnenDLG.Cancel - Kontext "OLEObjektEinfuegen" - OLEObjektEinfuegen.Cancel - sleep 1 - Call hCloseDocument -endcase - -testcase tiInsertSpreadsheet - if gtSYSName = "Linux" then - printlog "Linux = wont test tiInsertSpreadsheet" - goto endsub - endif - - Call hNewDocument - WaitSlot (2000) - InsertSpreadsheetDraw - WaitSlot (2000) - Kontext "Messagebox" - if Messagebox.Exists (5) then - Warnlog Messagebox.GetText - hCloseDialog( Messagebox, "ok" ) - end if - gMouseClick 1,1 - sleep 1 - hTypekeys "<Tab><Delete>" - sleep 2 - Call hCloseDocument -endcase - -testcase tiInsertFormula - Call hNewDocument - InsertObjectFormulaDraw - - Kontext "Messagebox" - if ( Messagebox.Exists( 2 ) ) then - Warnlog Messagebox.GetText - hCloseDialog( Messagebox, "ok" ) - end if - gMouseClick 1,1 - sleep 1 - hTypekeys "<Tab><Delete>" - Call hCloseDocument -endcase - -testcase tiInsertFloatingFrame - Call hNewDocument - InsertFloatingFrame - WaitSlot (2000) - Kontext "TabEigenschaften" - Dialogtest (TabEigenschaften) - Oeffnen.Click - Kontext "OeffnenDlg" - hCloseDialog( OeffnenDlg, "Cancel" ) - Kontext "TabEigenschaften" - TabEigenschaften.Cancel - Call hCloseDocument -endcase - -testcase tiInsertFile - Call hNewDocument - WaitSlot (1000) - InsertFileDraw - WaitSlot (1000) - Kontext "OeffnenDLG" - ' Call Dialogtest ( OeffnenDLG ) - OeffnenDLG.Cancel - Call hCloseDocument -endcase - -testcase tiInsertPlugin - call hNewDocument - InsertObjectPlugIn - Kontext "PluginEinfuegen" - if PluginEinfuegen.exists (5) then - call Dialogtest (PluginEinfuegen) - Durchsuchen.Click - sleep 1 - Kontext "Messagebox" - if Messagebox.Exists (5) Then - Warnlog Messagebox.GetText - Messagebox.OK - else - printlog "No Messagebox :-)" - end if - Kontext "OeffnenDlG" - if OeffnenDlG.exists (5) then - OeffnenDLG.Cancel - end if - Kontext "PluginEinfuegen" - if PluginEinfuegen.exists (5) then PluginEinfuegen.Cancel - else - warnlog "Insert Plugin does not work :-(" - end if - Call hCloseDocument -endcase - -testcase tiInsertScan - goto endsub - Call hNewDocument - InsertScanRequest ' as long as there is no scanner available, nothing happens - WaitSlot (1000) - InsertScanSelectSource - WaitSlot (1000) - printlog "Not testable, not translatable, just callable, because of systemdialog :-(" - Call hCloseDocument -endcase - -testcase tiInsertSnappointLine - Call hNewDocument - InsertSnapPointLine - Kontext "NeuesFangobjekt" - DialogTest ( NeuesFangobjekt ) - NeuesFangobjekt.Cancel - sleep 2 - Call hCloseDocument -endcase - -testcase tdInsertLayer - Call hNewDocument - WaitSlot (1000) - ViewLayer - InsertLayer - Kontext "EbeneEinfuegenDlg" - DialogTest ( EbeneEinfuegenDlg ) - EbeneEinfuegenDlg.Cancel - Call hCloseDocument -endcase - diff --git a/testautomation/graphics/optional/includes/global/id_005.inc b/testautomation/graphics/optional/includes/global/id_005.inc deleted file mode 100644 index 4aefb701a861..000000000000 --- a/testautomation/graphics/optional/includes/global/id_005.inc +++ /dev/null @@ -1,808 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'*********************************************************************************** -' #1 tiFormatDefault -' #1 tiFormatLine -' #1 tdFormatArea -' #1 tiFormatText -' #1 tiFormatPositionAndSize -' #1 tiFormatCharacter -' #1 tiFormatControlForm -' #1 tiFormatDimensions -' #1 tiFormatConnector -' #1 tiFormat3D_Effects -' #1 tiFormatNumberingBullets -' #1 tiFormatCaseCharacter -' #1 tiFormatParagraph -' #1 tiFormatPage -' #1 tiFormatStylesAndFormatting -' #1 tiFormatStylesSlideDesign -' #1 tiFormatFontwork -' #1 tiFormatGroup -' #1 hWalkTheStyles -'\********************************************************************************** - -testcase tiFormatDefault - - Call hNewDocument - gMouseClick 50,50 - Call hRechteckErstellen ( 10, 10, 20, 40 ) - FormatStandardDraw - Call hCloseDocument -endcase - -testcase tiFormatLine - hNewDocument - gMouseClick 50,50 - Call hRechteckErstellen ( 10, 10, 20, 40 ) - FormatLine - Kontext - Messagebox.SetPage TabLinie - kontext "TabLinie" - Call DialogTest ( TabLinie ) - - Kontext - Messagebox.SetPage TabLinienstile - kontext "TabLinienstile" - Call DialogTest ( TabLinienstile ) - Hinzufuegen.click - Kontext "NameDLG" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabLinienstile" - Aendern.Click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - kontext "TabLinienstile" - Loeschen.Click - Kontext "Messagebox" - Messagebox.no - - kontext "TabLinienstile" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - kontext "TabLinienstile" - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDLG.Cancel - Kontext - Messagebox.SetPage TabLinienenden - kontext "TabLinienenden" - Call DialogTest ( TabLinienenden ) - Hinzufuegen.Click - Kontext "NameDLG" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabLinienenden" - Aendern.Click - Kontext "Messagebox" - try - Messagebox.OK - catch - 'print "TabLinienenden" - endcatch - - kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabLinienenden" - Loeschen.Click - Kontext "Messagebox" - Messagebox.no - - kontext "TabLinienenden" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - kontext "TabLinienenden" - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDlg.Cancel - kontext "TabLinienenden" - TabLinienenden.cancel - Call hCloseDocument -endcase - -testcase tdFormatArea - Call hNewDocument - gMouseClick 50,50 - Call hRechteckErstellen (15,15,65,65) - gMouseClick 30,30 - FormatArea - WaitSlot (1000) - Kontext - Messagebox.SetPage TabArea - Kontext "TabArea" - Call DialogTest ( TabArea ) - Kontext - Messagebox.SetPage TabSchatten - kontext "TabSchatten" - Anzeigen.Check - Call DialogTest ( TabSchatten ) - Kontext - Messagebox.SetPage TabFarben - kontext "TabFarben" - Farbe.select 1 - Farbmodell.Select 1 - Call DialogTest ( TabFarben,1 ) - Farbmodell.Select 2 - Call DialogTest ( TabFarben,2 ) - - Hinzufuegen.click - Kontext "Messagebox" - Messagebox.OK - kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - kontext "TabFarben" - Loeschen.click - Kontext "Messagebox" - Messagebox.no - - kontext "TabFarben" - sleep 1 - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDlg.Cancel - sleep 1 - - kontext "TabFarben" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - Kontext "TabFarben" - - Kontext - Messagebox.SetPage TabFarbverlaeufe - kontext "TabFarbverlaeufe" - Call DialogTest ( TabFarbverlaeufe ) - - Hinzufuegen.click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabFarbverlaeufe" - Aendern.Click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabFarbverlaeufe" - loeschen.click - try - kontext "Messagebox" - Messagebox.no - catch - warnlog "nobody cares about deleting a gradient :-(" - endcatch - - kontext "TabFarbverlaeufe" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - kontext "TabFarbverlaeufe" - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDLG.Cancel - - Kontext - Messagebox.SetPage TabSchraffuren - kontext "TabSchraffuren" - Call DialogTest ( TabSchraffuren) - - Hinzufuegen.click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabSchraffuren" - Aendern.Click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.Cancel - - kontext "TabSchraffuren" - Loeschen.click - kontext "Messagebox" - Messagebox.no - - kontext "TabSchraffuren" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - kontext "TabSchraffuren" - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDLG.Cancel - - Kontext - Messagebox.SetPage TabBitmap - kontext "TabBitmap" - Call DialogTest ( TabBitmap ) - zurueck.click - sleep 1 - hinzufuegen.click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.cancel - - kontext "TabBitmap" - try - Aendern.Click - Kontext "NameDlg" - Call DialogTest ( NameDlg ) - NameDlg.cancel - catch - WarnLog "Control is disabled - modify bitmap" - endcatch - kontext "TabBitmap" - Import.Click - try - Kontext "GrafikEinfuegenDlg" - Call DialogTest ( GrafikEinfuegenDlg ) - Kontext "GrafikEinfuegenDlg" - GrafikEinfuegenDlg.Cancel - catch - Warnlog "Insert graphic does not work" - endcatch - - kontext "TabBitmap" - loeschen.click - kontext "Messagebox" - Messagebox.no - - kontext "TabBitmap" - Oeffnen.click - Kontext "OeffnenDLG" - call Dialogtest (OeffnenDLG) - OeffnenDLG.Cancel - kontext "TabBitmap" - Speichern.click - Kontext "SpeichernDLG" - call Dialogtest (SpeichernDLG) - SpeichernDLG.Cancel - kontext "TabBitmap" - TabBitmap.Cancel - Call hCloseDocument -endcase - -testcase tiFormatText - Call hNewDocument - FormatTextDraw - Kontext - Messagebox.SetPage TabText - Kontext "TabText" - DialogTest ( TabText ) - Kontext - Messagebox.SetPage TabLauftext - Kontext "TabLauftext" - DialogTest ( TabLauftext ) - TabLauftext.Cancel - Call hCloseDocument -endcase - -testcase tiFormatPositionAndSize - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - ContextPositionAndSize - Kontext - Messagebox.setpage TabPositionAndSize - Kontext "TabPositionAndSize" - call Dialogtest ( TabPositionAndSize ) - kontext "PositionPosition" - PositionPosition.TypeKeys ("<right>", 2) - kontext "SizePosition" - SizePosition.TypeKeys ("<down>", 2) - Kontext - Messagebox.setPage TabDrehung - Kontext "TabDrehung" - call Dialogtest ( TabDrehung ) - Kontext - Messagebox.setpage TabSchraegstellen - Kontext "TabSchraegstellen" - call Dialogtest ( TabSchraegstellen ) - TabSchraegstellen.cancel - Call hCloseDocument -endcase - -testcase tiFormatCharacter - Call hNewDocument - FormatCharacter - WaitSlot (1000) - Kontext - Messagebox.SetPage TabFont - kontext "TabFont" - sleep 1 - Call DialogTest ( TabFont ) - Kontext - Messagebox.SetPage TabFontEffects - kontext "TabFontEffects" - sleep 1 - Call DialogTest ( TabFontEffects ) - sleep 1 - Kontext - Messagebox.SetPage TabFontPosition - Kontext "TabFontPosition" - sleep 1 - Call DialogTest ( TabFontPosition ) - sleep 2 - TabFontPosition.Cancel - Call hCloseDocument -endcase - -testcase tiFormatControlForm - - printlog "testcase: check if controls are available" - - printlog "open new document" - Call hNewDocument - - 'click in the document to get the focus into the document - if ( UCase(gApplication) = "DRAW" ) then - Kontext "DocumentDraw" - DocumentDraw.MouseDown(50,50) - DocumentDraw.MouseUp(50,50) - else 'Impress - Kontext "DocumentImpress" - DocumentImpress.MouseDown(50,50) - DocumentImpress.MouseUp(50,50) - endif - - printlog "open the form controls toolbar" - call hToolbarSelect("FormControls",true) - - kontext "FormControls" - printlog "insert a PushButton" - Pushbutton.Click - Sleep 1 - gMouseMove (50, 20,70, 40) - - printlog "open the control properties dialog" - FormatControl - - Kontext "ControlPropertiesDialog" - WaitSlot (1000) - printlog "close the control properties dialog" - ControlPropertiesDialog.Close - - printlog "open the form properties dialog" - FormatForm - Kontext "ControlPropertiesDialog" - WaitSlot (1000) - printlog "close the form properties dialog" - ControlPropertiesDialog.Close - - printlog "close the form control toolbar" - call hToolbarSelect("FormControls",false) - - printlog "close application" - Call hCloseDocument - -endcase - -testcase tiFormatDimensions - Call hNewDocument - FormatDimensioning - Kontext "Bemassung" - DialogTest ( Bemassung ) - Bemassung.Cancel - Call hCloseDocument -endcase - -testcase tiFormatConnector - Call hNewDocument - FormatConnector - Kontext "Verbinder" - DialogTest ( Verbinder ) - Verbinder.Cancel - Call hCloseDocument -endcase - -testcase tiFormat3D_Effects - Call hNewDocument - Format3D_Effects - Kontext "Drei_D_Effekte" - Call DialogTest ( Drei_D_Effekte,1 ) - Geometrie.Click - Call DialogTest ( Drei_D_Effekte,2 ) - Darstellung.Click - Call DialogTest ( Drei_D_Effekte,3 ) - Beleuchtung.Click - Call DialogTest ( Drei_D_Effekte,4 ) - Texturen.Click - Call DialogTest ( Drei_D_Effekte,5 ) - Material.Click - Call DialogTest ( Drei_D_Effekte,6 ) - Kontext "Drei_D_Effekte" - Drei_D_Effekte.Close - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatNumberingBullets - Call hNewDocument - WaitSlot (2000) - FormatNumberingBulletsDraw - WaitSlot (2000) - Kontext - Messagebox.SetPage TabBullet - Kontext "TabBullet" - Call DialogTest ( TabBullet ) - Kontext - Messagebox.SetPage TabNumerierungsart - Kontext "TabNumerierungsart" - Call DialogTest ( TabNumerierungsart ) - Kontext - Messagebox.SetPage TabGrafiken - Kontext "TabGrafiken" - Call DialogTest ( TabGrafiken ) - Kontext - Messagebox.SetPage TabPositionNumerierung - Kontext "TabPositionNumerierung" - Call DialogTest ( TabPositionNumerierung ) - Kontext - Messagebox.SetPage TabOptionenNumerierung - Kontext "TabOptionenNumerierung" - Call DialogTest ( TabOptionenNumerierung ) - Numerierung.Select 9 ' last one always ? -> graphics - TabOptionenNumerierung.MouseDown 50,60 - TabOptionenNumerierung.MouseUp 50,60 - Auswahl.TypeKeys "<SPACE>" - hMenuSelectNr (1) - sleep 3 - Kontext "OeffnenDlg" - OeffnenDlg.Cancel - sleep 1 - sleep 1 - Kontext - Messagebox.SetPage TabOptionenNumerierung - Kontext "TabOptionenNumerierung" - sleep 1 - try - Auswahl.TypeKeys "<SPACE>" - hMenuSelectNr (2) - hMenuSelectNr (3) - Sleep 2 - catch - warnlog "couldn't do something :-) (1)" - Exceptlog - Call hMenuClose - endcatch - TabOptionenNumerierung.Cancel - sleep 1 - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatCaseCharacter - Call hNewDocument - Call hTextrahmenErstellen ("testit",20,20,50,30) - sleep 1 - hTypeKeys "<left>" - - FormatChangeCaseUpper - WaitSlot (1000) - FormatChangeCaseLower - WaitSlot (2000) - if bAsianLan then - if not gAsianSup then - qaerrorlog "This is an asian language-office, but asian support was disabled in a previous test?" - end if - try - FormatChangeCaseHalfWidth - catch - Warnlog "Format / Change Case / Half Width does not work." - endcatch - WaitSlot (1000) - try - FormatChangeCaseFullWidth - catch - Warnlog "Format / Change Case / Full Width does not work!" - endcatch - sleep 1 - try - FormatChangeCaseHiragana - catch - Warnlog "Format / Change Case / Hiragana does not work." - endcatch - sleep 1 - try - FormatChangeCaseKatagana - catch - Warnlog "Format / Change Case / Katagana does not work." - endcatch - end if - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatParagraph - Call hNewDocument - FormatParagraph - Kontext - Messagebox.SetPage TabEinzuegeUndAbstaende - kontext "TabEinzuegeUndAbstaende" - Call DialogTest ( TabEinzuegeUndAbstaende ) - Kontext - Messagebox.SetPage TabAusrichtungAbsatz - Kontext "TabAusrichtungAbsatz" - Call DialogTest ( TabAusrichtungAbsatz ) - Kontext - Messagebox.SetPage TabTabulator - kontext "TabTabulator" - Call DialogTest ( TabTabulator ) - TabTabulator.Cancel - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatPage - Call hNewDocument - FormatSlideDraw - kontext - if Messagebox.exists (5) then - Messagebox.SetPage TabSeite - Kontext "TabSeite" - if TabSeite.exists (5) then - Call Dialogtest (TabSeite) - else - warnlog "nope :-(1" - endif - sleep 1 - kontext - Messagebox.SetPage TabArea - sleep 1 - kontext - if messagebox.GetRT = 304 then - printlog "active about pagesize != printersettings, will say NO: " + Messagebox.GetText - try - Messagebox.No - catch - warnlog messagebox.getText - Messagebox.ok ' should be Error loading BASIC of document ##? - kontext - if messagebox.GetRT = 304 then - try - warnlog messagebox.getText - Messagebox.ok - catch - printlog "not expected state." - endcatch - endif - endcatch - endif - sleep 1 - kontext - Messagebox.SetPage TabArea - Kontext "TabArea" - if TabArea.exists (5) then - Call Dialogtest (TabArea) - endif - sleep 1 - TabArea.Cancel - else - warnlog "FormatPage doesn't come up with dialog :-(" - endif - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatStylesAndFormatting - Dim sTemp as String - dim sSettings(20,3) ' Control_name; control_type; value - dim i as integer - dim abctemp - - Call hNewDocument - sleep 5 - - hTextrahmenErstellen ("I love Wednesdays...",20,20,80,40) - sleep 1 - printlog "Checking if TextObjectBar is up" - Kontext "TextObjectbar" - if TextObjectbar.Exists Then - printlog "TextObjectbar.Exists = " + TextObjectbar.Exists - else - ViewToolbarsTextFormatting - endif - FormatStylist - WaitSlot (1000) - Kontext "Stylist" - if (Stylist.NotExists) then - qaErrorLog "There is no stylist open, trying again now" - FormatStylist - end if - WaitSlot (1000) - Vorlagenliste.TypeKeys "<End>" - Vorlagenliste.TypeKeys "<Up>" - Vorlagenliste.TypeKeys "<Up>" - sleep 1 - Vorlagenliste.OpenContextMenu - sleep 1 - hMenuSelectNr (1) - sleep 1 - - Kontext - if Messagebox.exists (5) then - try - Messagebox.SetPage TabVerwalten - Kontext "TabVerwalten" - TabVerwalten.TypeKeys "<TAB>" - VorlagenName.setText("1Test") - sTemp = VorlagenName.getText - VerknuepftMit.getSelText - Bereich.getSelText - TabVerwalten.OK - catch - warnlog "Under Gnome we have a focus problem here." - endcatch - end if - sleep 1 - Kontext "Stylist" - Vorlagenliste.TypeKeys "<Home>" 'to go to the style we've created ourselves. - sleep 1 - Vorlagenliste.OpenContextMenu - sleep 1 - hMenuSelectNr (2) 'modify... - sleep 1 - Kontext - if Messagebox.exists (5) then - try - Messagebox.SetPage TabVerwalten - Kontext "TabVerwalten" - VorlagenName.setText("2Test") - TabVerwalten.OK - catch - warnlog "Under Gnome we have a focus problem here." - endcatch - end if - - sleep 3 - Kontext "Stylist" - Vorlagenliste.TypeKeys "<Home>" 'to go to the style we've created ourselves. - sleep 1 - try - Vorlagenliste.TypeKeys "<Delete>" 'To delete the style. - Kontext "Active" 'do you really wish to delete? - Active.YES - sleep 2 - catch - Warnlog "Couldnt delete the new Style, or maybe wrong position?" - endcatch - Kontext "Stylist" - if (Stylist.NotExists) then - ErrorLog "There was no Stylist open, should be." - else - 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." - endif - endif - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatFontwork - Call hNewDocument - Call hTextrahmenErstellen ("Flightplanning via www.aua.com is hard!",20,20,50,30) - sleep 1 - FormatFontwork - Kontext "FontWork" - if FontWork.exists (5) then - DialogTest ( FontWork ) - sleep 1 - FontWork.Close - else - warnlog "FontWork didn't came up :-(" - endif - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatGroup - Call hNewDocument - hRechteckErstellen ( 10, 10, 20, 20 ) - hRechteckErstellen ( 30, 30, 40, 40 ) - EditSelectAll - FormatGroupDraw - WaitSlot (1000) - FormatEditGroupDraw - WaitSlot (1000) - FormatExitGroupDraw - WaitSlot (1000) - FormatUngroupDraw - WaitSlot (1000) - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- - -testcase tiFormatStylesSlideDesign - ' create recktanglr; click outside ? - Call hNewDocument - WaitSlot (3000) - FormatModifyLayout ' is OK : Format->Styles->Slide Design; 27064; SID_PRESENTATION_LAYOUT - WaitSlot (1000) - Kontext "Seitenvorlage" - Call DialogTest ( Seitenvorlage ) - HintergrundseiteAustauschen.check - DeleteUnusedBackgrounds.check - Laden.Click - kontext "Neu" - Zusaetze.click - sleep 1 - kontext "Neu" - try - Vorschau.check - catch - printlog "Preview wasn't checkable :-( hopfully now:" - Zusaetze.click - sleep 1 - Vorschau.check - printlog "... OK :-)" - endcatch - Neu.cancel - Kontext "Seitenvorlage" - Seitenvorlage.Cancel - sleep 2 - Call hCloseDocument -endcase - -'--------------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/global/id_006.inc b/testautomation/graphics/optional/includes/global/id_006.inc deleted file mode 100644 index bcbfa3d7c24b..000000000000 --- a/testautomation/graphics/optional/includes/global/id_006.inc +++ /dev/null @@ -1,362 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'*********************************************************************************** -' #1 tiToolsSpellchecking -' #1 tiToolsSpellcheckingAutomatic -' #1 tiToolsThesaurus -' #1 tiToolsHyphenation -' #1 tiToolsAutoCorrect -' #1 tChineseTranslation -' #1 tiToolsMacro -' #1 tiToolsGallery -' #1 tiToolsEyedropper -' #1 tiToolsOptions -'\********************************************************************************** - - -testcase tiToolsSpellchecking - - if not gOOO then ' Spellcheck doesn't work in OOo builds. - Call hNewDocument - WaitSlot (2000) 'sleep 2 - call hSetSpellHypLanguage - Call hTextrahmenErstellen ("Whaaaat", 10, 10, 30, 40) - sleep 1 - ToolsSpellCheck - WaitSlot (1000) 'sleep 1 - Kontext "MessageBox" - if MessageBox.exists(2) then - qaerrorlog "Messagebox : " + MessageBox.gettext() + " appear." - qaerrorlog "Maybe no spellchecking for this languages is available." - MessageBox.OK - else - Kontext "Rechtschreibung" - if Rechtschreibung.exists then - Call DialogTest ( Rechtschreibung ) - Rechtschreibung.Close - else - warnlog " Spellcheck dialog didn't came up :-(" - end if - end if - sleep 1 - Kontext "Messagebox" - if Messagebox.exists (5) then - warnlog "Shouldn't be any messagebox after pressing close in spellchecker" - Messagebox.OK - sleep (2) - Kontext - end if - Call hCloseDocument - else goto endsub - endif -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsSpellcheckingAutomatic - Call hNewDocument - ToolsSpellcheckAutoSpellcheck - Call hTextrahmenErstellen ("What", 10, 10, 30, 40) - sleep 2 - ToolsSpellcheckAutoSpellcheck - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsThesaurus - if not gOOO then ' Thesaurus doesn't work in OOo builds. - - dim sFileName as String - - call hSetSpellHypLanguage - if (gApplication = "IMPRESS") then - sFileName = (ConvertPath (gTesttoolPath + "graphics\required\input\engtext.odp")) - else - sFileName = (ConvertPath (gTesttoolPath + "graphics\required\input\engtext.odg")) - end if - if FileExists ( sFileName ) = FALSE then - warnlog "The language-file was not found or accessible! The test ends." - goto endsub - end if - Call hFileOpen (sFileName) - sleep (2) - - hTypeKeys "<TAB><RETURN>" - hTypeKeys "<END><SHIFT HOME>" - - ' Call hTextrahmenErstellen ("SimpleTest" + "<Mod1 Shift left>", 10, 10, 30, 40) - try - ExtrasThesaurusDraw - Kontext "Thesaurus" - Call DialogTest ( Thesaurus ) - Sprache.Click - Kontext "SpracheAuswaehlen" - Call DialogTest ( SpracheAuswaehlen ) - SpracheAuswaehlen.cancel - Kontext "Thesaurus" - Nachschlagen.Click - kontext - if Messagebox.exists (5) then - printlog "Messagebox: word not in thesaurus: '"+Messagebox.gettext+"'" - Messagebox.ok - end if - sleep 1 - Kontext "Thesaurus" - Thesaurus.Cancel - catch - warnlog "Thesaurus didn't work :-(" - endcatch - sleep 1 - Call hCloseDocument - else goto endsub - endif -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsHyphenation - Call hNewDocument - ToolsLanguageHyphenationDraw - WaitSlot (2000) 'sleep 2 - ToolsLanguageHyphenationDraw - Call hCloseDocument -endcase - -testcase tiToolsAutoCorrect - dim iLanguage as integer ' for resetting the language - Call hNewDocument - WaitSlot (1000) 'sleep 1 - ToolsAutocorrect - WaitSlot (2000) 'sleep 1 - Kontext - Messagebox.SetPage TabErsetzung - Kontext "TabErsetzung" - Call DialogTest ( TabErsetzung ) - iLanguage = WelcheSprache.GetSelIndex - WelcheSprache.Select 1 ' select language with empty list - Kuerzel.SetText "a" - ErsetzenDurch.SetText "b" - Neu.Click - sleep 1 - Loeschen.Click - sleep 1 - try - Loeschen.Click - catch - printlog "ok was CRASH before" '# - endcatch - WelcheSprache.select (iLanguage) - Kontext - Messagebox.SetPage TabAusnahmen - Kontext "TabAusnahmen" - Call DialogTest ( TabAusnahmen ) - Abkuerzungen.settext "Lala" - AbkuerzungenNeu.click - AbkuerzungenLoeschen.click - Woerter.settext "LALA" - WoerterAutomatisch.Check - WoerterNeu.click - WoerterLoeschen.click - WoerterAutomatisch.UnCheck - Kontext - Messagebox.SetPage TabOptionen - Kontext "TabOptionen" - Call DialogTest ( TabOptionen ) - Kontext - Messagebox.SetPage TabLocalizedOptions - Kontext "TabLocalizedOptions" ' 1a - SingleQuotesReplace.Check - SingleQuotesStart.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 1 ) - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 1b - SingleQuotesEnd.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 2 ) - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 1s - SingleQuotesDefault.Click - - Kontext "TabLocalizedOptions" ' 2a - DoubleQuotesStart.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 3 ) - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 2b - DoubleQuotesEnd.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 4 ) - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 2s - DoubleQuotesDefault.Click - SingleQuotesReplace.UnCheck - TabLocalizedOptions.cancel - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tChineseTranslation - - qaerrorlog( "#i89634# - Chinese Translation dialog does not close" ) - goto endsub - - dim sFileName as string - dim bSavedAsianSupport as boolean - - if uCase(gApplication) = "IMPRESS" then - sFileName = "graphics\required\input\tchinese.odp" - else - sFileName = "graphics\required\input\tchinese.odg" - end if - - Call hNewDocument - WaitSlot (2000) 'sleep 1 - bSavedAsianSupport = ActiveDeactivateAsianSupport(TRUE) - Call hFileOpen ( ConvertPath(gTesttoolPath + sFileName) ) - sleep (2) - Kontext "Standardbar" - if Bearbeiten.GetState(2) <> 1 then - Bearbeiten.Click '0 = not pressed. 1 = pressed. - Kontext - if Active.Exists(1) then - Active.Yes - else - warnlog "No messagebox after making document editable? - Test canceled here" - goto endsub - end if - end if - if uCase(gApplication) = "IMPRESS" then - Kontext "DocumentImpress" - else - Kontext "DocumentDraw" - end if - EditSelectAll - hTypeKeys "<RETURN>" - hTypeKeys "<MOD1 HOME><RIGHT><RIGHT><SHIFT RIGHT RIGHT>" - ToolsChineseTranslation - WaitSlot (2000) 'sleep 1 - kontext "ChineseTranslation" - Call DialogTest ( ChineseTranslation ) - EditTerms.Click - kontext "ChineseDictionary" - Call DialogTest ( ChineseDictionary ) - ChineseDictionary.Ok - kontext "ChineseTranslation" - ChineseTranslation.OK - kontext - if Messagebox.exists (5) then - printlog "Messagebox: "+Messagebox.gettext+"'" - Messagebox.ok - end if - ActiveDeactivateAsianSupport(bSavedAsianSupport) - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsMacro - Call hNewDocument - WaitSlot (2000) 'sleep 2 - ToolsMacro - Kontext "Makro" - Call DialogTest ( Makro ) - Verwalten.Click - - Kontext - Messagebox.SetPage TabModule - Kontext "TabModule" - Call DialogTest ( TabModule ) - - Kontext - Messagebox.SetPage TabBibliotheken - Kontext "TabBibliotheken" - Call DialogTest ( TabBibliotheken ) - Hinzufuegen.Click - Kontext "Messagebox" - if Messagebox.Exists (5) then - if Messagebox.GetRT = 304 then - Warnlog Messagebox.Gettext - Messagebox.Ok - end if - end if - Kontext "OeffnenDlg" - OeffnenDlg.Cancel - Kontext "TabBibliotheken" - Neu.Click - kontext "NeueBibliothek" - sleep 1 'Bibliotheksname - NeueBibliothek.cancel - Kontext "TabBibliotheken" - TabBibliotheken.Close - - Kontext "Makro" - Makro.Cancel - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsGallery - Call hNewDocument - ToolsGallery - WaitSlot (2000) 'sleep 1 - ToolsGallery - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsEyedropper - Call hNewDocument - ToolsEyedropper - Kontext "Pipette" - Call DialogTest (Pipette) - Pipette.Close - sleep 1 - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -testcase tiToolsOptions - Call hNewDocument - ToolsOptions - WaitSlot (2000) 'sleep 1 - kontext "OptionenDlg" - OptionenDlg.Close - Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/global/id_007.inc b/testautomation/graphics/optional/includes/global/id_007.inc deleted file mode 100644 index bbc870953f3a..000000000000 --- a/testautomation/graphics/optional/includes/global/id_007.inc +++ /dev/null @@ -1,426 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'*********************************************************************************** -' #1 tdModifyFlipVertikal -' #1 tdModifyFlipHorizontal -' #1 tdContextConvertIntoCurve -' #1 tdContextConvertIntoPolygon -' #1 tdContextConvertIntoContour -' #1 tdContextConvertInto3D -' #1 tdContextConvertIntoRotationObject -' #1 tdContextConvertIntoBitmap -' #1 tdContextConvertIntoMetaFile -' #1 tdModifyArrange -' #1 tdModifyArrangeObjects -' #1 tdModifyAlignment -' #1 tdContextDistribution -' #1 tdContextDescriptionObject -' #1 tdContextNameObject -' #1 tdModifyConnectBreak -' #1 tdModifyShapes -' #1 tdModifyCombineSplit -'\********************************************************************************** - -testcase tdModifyFlipVertikal - - Call hNewDocument ' imp: contextmenue same SID! - sleep 1 - Call hRechteckErstellen ( 10, 10, 20, 40 ) - try - ContextFlipVerticalDraw - Printlog "- Flip-vertical is working" - catch - Warnlog "- Flip-Vertical does not work" - endcatch - sleep 1 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyFlipHorizontal - Call hNewDocument ' imp: contextmenue same SID! - WaitSlot (1000) - Call hRechteckErstellen ( 10, 10, 20, 40 ) - try - ContextFlipHorizontalDraw - Printlog "- Flip-horizontal is working" - catch - Warnlog "- Flip-horizontal does not work" - endcatch - sleep 1 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoCurve - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - ContextConvertIntoCurve - WaitSlot (2000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoPolygon - dim iWaitIndex as integer - Call hNewDocument ' imp: contextmenue same SID! - InsertGraphicsFromFile - Kontext "GrafikEinfuegenDlg" - iWaitIndex = 0 - do while NOT GrafikEinfuegenDlg.Exists AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if NOT GrafikEinfuegenDlg.Exists AND iWaitIndex = 10 then - warnlog "Dialogue Insert Graphics didnt work. Ending testcase." - Call hCloseDocument - goto endsub - end if - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") - Oeffnen.Click - sleep 3 - ContextConvertIntoPolygon - Kontext "InPolygonUmwandeln" - Call DialogTest (InPolygonUmwandeln) - LoecherFuellen.Check - Farbanzahl.More - Punktreduktion.More - Kachelgroesse.More - Vorschau.Click - sleep 10 - InPolygonUmwandeln.Cancel - sleep (2) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoContour - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - ContextConvertIntoContour - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertInto3D - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - ContextConvertInto3D - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoRotationObject - Call hNewDocument - WaitSlot (1000) - Call hRechteckErstellen (20,20,50,50) - sleep 2 - ContextConvertInto3DRotationObject - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoBitmap - Call hNewDocument - WaitSlot (3000) - InsertGraphicsFromFile - WaitSlot (3000) - Kontext "GrafikEinfuegenDlg" - sleep 2 - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\columbia.dxf") - sleep 2 - Oeffnen.Click - sleep 2 - try - ContextConvertIntoBitmap - Printlog "- Convert into bitmap is working" - catch - Warnlog "- Convert into bitmap does not work" - endcatch - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextConvertIntoMetaFile - Call hNewDocument - WaitSlot (3000) - InsertGraphicsFromFile - WaitSlot (1000) - kontext "Messagebox" - if Messagebox.Exists (5) Then Messagebox.OK - sleep 1 - Kontext "GrafikEinfuegenDlg" - sleep 2 - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - sleep 2 - Preview.Click - sleep 3 - Oeffnen.Click - sleep 5 - try - ContextConvertIntoMetafile - Printlog "- convert into meta file does work" - catch - Warnlog "- convert into meta file does not work" - endcatch - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyArrange - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - hTypeKeys("<escape>") - Call hRechteckErstellen ( 30, 30, 50, 60 ) - FormatArrangeBringToFront - WaitSlot (1000) - ContextArrangeBringForward - WaitSlot (1000) - ContextArrangeBringBackward - WaitSlot (1000) - FormatArrangeSendToBack - WaitSlot (1000) - EditSelectAll - ContextArrangeReverse - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyArrangeObjects - Call hNewDocument - WaitSlot (1000) - Call hRechteckErstellen ( 20, 20, 30, 50 ) - hTypeKeys("<escape>") - Call hRechteckErstellen ( 30,30,50,50 ) - ContextArrangeInFrontOfObject - gMouseClick 11,11 - ContextArrangeBehindObject - gMouseClick 45,45 - sleep 1 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyAlignment - Call hNewDocument - WaitSlot (1000) - Call hRechteckErstellen ( 20, 20, 30, 50 ) - ContextAlignmentLeft - WaitSlot (1000) - ContextAlignmentCentered - WaitSlot (1000) - ContextAlignmentRight - WaitSlot (1000) - ContextAlignmentTop - WaitSlot (1000) - ContextAlignmentBottom - WaitSlot (1000) - ContextAlignmentCenter - WaitSlot (1000) - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextDistribution - Call hNewDocument - WaitSlot (3000) - Call hRechteckErstellen (20,20,30,30) - Call hRechteckErstellen (40,40,50,50) - Call hRechteckErstellen (60,60,70,70) - sleep 1 - EditSelectAll - sleep 1 - ContextDistribution - Kontext "VerteilenDlg" - sleep 1 - Call DialogTest (VerteilenDlg) - sleep 1 - Links.Check - MitteHorizontal.Check - AbstandHorizontal.Check - Rechts.Check - KeineHorizontal.Check - Oben.Check - MitteVertikal.Check - AbstandVertikal.Check - Unten.Check - KeineVertikal.Check - VerteilenDlg.Cancel - sleep 2 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextDescriptionObject - Call hNewDocument - WaitSlot (1000) - Call hRechteckErstellen ( 10, 10, 20, 40 ) - ContextDescriptionObject - Kontext "DescriptionObject" - Call DialogTest (DescriptionObject) - DescriptionObject.Cancel - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdContextNameObject - Call hNewDocument - WaitSlot (1000) - Call hRechteckErstellen ( 20, 20, 30, 50 ) - hTypeKeys("<escape>") - Call hRechteckErstellen ( 30, 40, 50, 60 ) - sleep 1 - gMouseMove 1,1,95,95 - sleep 1 - FormatGroupGroup - WaitSlot (1000) - ContextNameObject - Kontext "NameDlgObject" - Call DialogTest (NameDlgObject) - NameDlgObject.Cancel - FormatUngroupDraw - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyConnectBreak - Call hNewDocument - sleep 1 - Call hRechteckErstellen (10,10,30,30) - Call hRechteckErstellen (35,35,50,50) - sleep 1 - EditSelectAll - ContextConnect - sleep 1 - try - ContextBreak - catch - Warnlog "- Modify-Break does not work" - endcatch - sleep 1 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyShapes - Call hNewDocument - sleep 1 - gMouseClick 50,50 - Call hRechteckErstellen (30,30,50,50) - Call hRechteckErstellen (60,60,80,80) - sleep 1 - EditSelectAll - sleep 1 - try - ModifyShapesMerge ' 1 - WaitSlot (1000) 'sleep 1 - Printlog "- Modify-Shape merge is working" - catch - Warnlog "- Modify-shape merge is not working" - endcatch - EditSelectAll - sleep 1 - hTypeKeys "<DELETE>" - sleep 1 - Call hRechteckErstellen (30,30,50,50) - Call hRechteckErstellen (60,60,80,80) - sleep 1 - EditSelectAll - sleep 1 - try - ModifyShapesSubstract ' 2 - Printlog "- Modify-shape-substract is working" - catch - Warnlog "- Modify-shape substract is not working" - endcatch - sleep 1 - EditSelectAll - sleep 1 - hTypeKeys "<DELETE>" - sleep 1 - Call hRechteckErstellen (30,30,50,50) - sleep 1 - Call hRechteckErstellen (60,60,80,80) - sleep 1 - EditSelectall - sleep 1 - try - ModifyShapesIntersect ' 3 - Printlog "- Modify-shape intersect is working" - catch - Warnlog "- Modify-Shape intersect is not working" - endcatch - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ - -testcase tdModifyCombineSplit - Call hNewDocument - sleep 1 - Call hRechteckErstellen (30,30,50,50) - Call hRechteckErstellen (60,60,80,80) - sleep 1 - EditSelectAll - sleep 1 - try - ContextCombine - Printlog "- Modify combine is working" - ContextSplit - Printlog "- Modify-split is working" - catch - Warnlog "- Modify-combine and split are not working" - endcatch - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------ diff --git a/testautomation/graphics/optional/includes/global/id_008.inc b/testautomation/graphics/optional/includes/global/id_008.inc deleted file mode 100644 index 654cae0f00df..000000000000 --- a/testautomation/graphics/optional/includes/global/id_008.inc +++ /dev/null @@ -1,71 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'****************************************************************** -' #1 tiWindowNewWindow -' #1 tidWindow123 'wrn:2 -'\***************************************************************** - -testcase tiWindowNewWindow - - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - WindowNewWindow - WaitSlot (2000) - Call hCloseDocument -endcase - -testcase tidWindow123 - goto endsub '' testing TBO: 29.03.2002 - dim iMenues as integer - Call hNewDocument - Call hRechteckErstellen ( 10, 10, 20, 40 ) - - Kontext "DocumentImpress" - DocumentImpress.UseMenu - iMenues = MenuGetItemCount - warnlog "---- Number of Main menus: " & iMenues - MenuSelect(Menugetitemid(8)) - sleep 1 - iMenues = MenuGetItemCount - printlog "---- Number of Main menus: " & iMenues - ' MenuSelect(Menugetitemid(14)) - sleep 1 - i=1 - printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - i=2 - printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - warnlog "Dynamic entries not accessible ? :-(((((" - ' i=3 - ' printlog "count: " + i + "; of submenue: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - Call hCloseDocument -endcase - diff --git a/testautomation/graphics/optional/includes/global/id_009.inc b/testautomation/graphics/optional/includes/global/id_009.inc deleted file mode 100644 index 7096a1a860a9..000000000000 --- a/testautomation/graphics/optional/includes/global/id_009.inc +++ /dev/null @@ -1,243 +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 : wolfram.garten@oracle.com -'* -'* short description : Testcases to test the Help-Menu. -'* -'*********************************************************************************** -' #1 tmHelpHelpAgent -' #1 tmHelpTips -' #1 tmHelpExtendedTips -' #1 tmHelpAboutStarOffice -' #1 tmHelpContents -' #1 tCheckIfTheHelpExists -'\********************************************************************************** -' -testcase tmHelpHelpAgent - - Call hNewDocument - - hTBOtypeInDoc - - HelpHelpAgent ' it's just a switch - sleep 2 - HelpHelpAgent - - Call hCloseDocument -endcase - -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... - -testcase tmHelpTips - Call hNewDocument - hTBOtypeInDoc - - HelpTips - Sleep 2 - HelpTips - - Call hCloseDocument -endcase - -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... - -testcase tmHelpExtendedTips - Call hNewDocument - hTBOtypeInDoc - - HelpEntendedHelp - Sleep (2) - HelpEntendedHelp - - Call hCloseDocument -endcase - -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... - -testcase tmHelpAboutStarOffice - Call hNewDocument - hTBOtypeInDoc - - HelpAboutStarOffice - Kontext "UeberStarMath" - DialogTest (UeberStarMath) - UeberStarMath.OK - - Call hCloseDocument -endcase - -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... - -testcase tmHelpContents - goto endsub '"#i84486# - tmHelpContents outcommented due to crash." - dim i as integer - - Call hNewDocument - HelpContents - sleep(8) - kontext "StarOfficeHelp" - if Not StarOfficeHelp.Exists then - Warnlog "Help is not up!" - else - Printlog "HelpAbout: '" + HelpAbout.GetItemCount +"'" - '################ left half ################ - TabControl.SetPage ContentPage - Printlog "SearchContent: '" + SearchContent.GetItemCount + "'" - TabControl.SetPage IndexPage - Printlog "SearchIndex: '" + SearchIndex.GetItemCount + "'" - sleep 5 - DisplayIndex.Click - sleep 5 - TabControl.SetPage FindPage - Printlog "SearchFind: '" + SearchFind.GetItemCount + "'" - if SearchFind.GetSelText = "" then - if FindButton.IsEnabled then - warnlog " The Find-Button should have been inactive, but was active." - endif - else - warnlog " The Search-Text-Field shouldn't contain any text. But contained: " + SearchFind.GetSelText - endif - SearchFind.SetText "Doobbidedooo" - FindButton.Click - kontext - if (active.exists (2) )then - Printlog "active came up: '" + active.gettext + "'" - active.ok - endif - kontext "StarOfficeHelp" - FindFullWords.Check - FindInHeadingsOnly.Check - Printlog "Result: '" + Result.GetItemCount + "'" - DisplayFind.Click - TabControl.SetPage BookmarksPage - Printlog "Bookmarks: '" + Bookmarks.GetItemCount + "'" - DisplayBookmarks.Click - '################ right half ################ - '################ toolbar ################ - Kontext "TB_Help" - Index.Click - sleep 1 - Index.Click - sleep 1 - GoToStart.Click - sleep 1 - Backward.Click - sleep 1 - Forward.Click - sleep 1 - PrintButton.Click - sleep (1) - - kontext "Active" - if Active.Exists( 2 ) then - qaerrorlog "No default printer defined: " & Active.GetText - Active.Ok - end if - - kontext "Printing" - if Printing.Exists( 2 ) then - Printing.cancel - else - warnlog "the Print-Dialogue didnt appear." - end if - Kontext "TB_Help" - sleep 1 - SetBookmarks.Click - sleep 1 - Kontext "AddBookmark" - Printlog "Bookmarkname: '" + Bookmarkname.GetText + "'" - AddBookmark.Cancel - sleep 1 - '################ help display ################ - kontext "HelpContent" - HelpContent.OpenContextMenu - - sleep 1 - Printlog " i: " + hMenuItemGetCount - hMenuClose() - '################ right scroolbar ################ - kontext "HelpContent" - if HelpContentUP.IsVisible then - HelpContentUP.Click - sleep 1 - endif - if HelpContentNAVIGATION.IsVisible then - HelpContentNAVIGATION.Click - sleep 1 - endif - kontext "NavigationsFenster" - NavigationsFenster.Close - sleep 1 - kontext "HelpContent" - if HelpContentDOWN.IsVisible then - HelpContentDOWN.Click - sleep 1 - endif - kontext "StarOfficeHelp" - Printlog "trying to close the help now" - try - StarOfficeHelp.TypeKeys "<Mod1 F4>" ' strg F4 supported since bug #103586# - catch - Warnlog "failed to close the help window :-(" - endcatch - kontext "StarOfficeHelp" - if StarOfficeHelp.Exists then - warnlog "Help still up!" - endif - endif - Call hCloseDocument -endcase - -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... - -testcase tCheckIfTheHelpExists - Call hNewDocument - HelpContents - kontext "HelpContent" - sleep (5) - HelpContent.TypeKeys "<MOD1 A>" - sleep (1) - HelpContent.TypeKeys "<MOD1 C>" - if GetClipBoard = "" then - Warnlog " No content in the Help-Content -view." - else - Printlog " The Help-Content -view contained content. Good." - endif - kontext "StarOfficeHelp" - try - StarOfficeHelp.TypeKeys "<MOD1 F4>" - catch - Warnlog " Failed to close the help window :-(" - endcatch - kontext "StarOfficeHelp" - if StarOfficeHelp.Exists then - warnlog "Help was still visible!" - endif - hTypeKeys "." - Call hCloseDocument -endcase 'tCheckIfTheHelpExists diff --git a/testautomation/graphics/optional/includes/global/id_011.inc b/testautomation/graphics/optional/includes/global/id_011.inc deleted file mode 100644 index b1880d0982e8..000000000000 --- a/testautomation/graphics/optional/includes/global/id_011.inc +++ /dev/null @@ -1,995 +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 : wolfram.garten@oracle.com -'* -'* short description : -'* -'\****************************************************************************** - -testcase tiTextToolbar - - Dim iWaitIndex as integer - Dim Zufall as integer - Dim i as integer - - Call hNewDocument - - hTextrahmenErstellen ("This is a Text, which will be formatted in several ways", 20,20,40,80) - sleep 2 - EditSelectAll - sleep 2 - Kontext "TextObjectbar" - if TextObjectbar.Exists <> TRUE then 'isVisible - ViewToolbarsTextFormatting - endif - WaitSlot (3000) 'sleep (3) - Kontext "TextObjectbar" - Printlog "- choose random font" - randomize - Zufall=((2*Rnd)+1) ' wird nicht auf den verfuegbaren bereich getreckt :-( TODO TBO! - Schriftart.GetItemcount - Schriftart.GetSelText - Schriftart.Select (Zufall) - Printlog Schriftart.GetSelText + " chosen" - - Kontext "TextObjectbar" - sleep 2 - Printlog "- Change size of font" - Schriftgroesse.Select (Zufall) - Printlog Schriftgroesse.GetSelText + " chosen" - - Kontext "TextObjectbar" - Printlog "- Font attribute bold" - Fett.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Font attribute cursive" - Kursiv.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Font attribute cursiv" - Unterstrichen.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- font attribute color" - sleep 3 - FontColorGraphics.TearOff - Kontext "TB_Farbe" - TB_Farbe.Move 20, 20 - Sleep 2 - TB_Farbe.MouseDoubleClick 50, 50 - Sleep 2 - TB_Farbe.Close - - Kontext "TextObjectbar" - Printlog "- Allign text left" - Linksbuendig.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Allign text centered" - Zentriert.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- align text to right" - Rechtsbuendig.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Justified" - Blocksatz.Click - sleep 2 - - Kontext "TextObjectbar" - if TextObjectbar.isEnabled <> TRUE then - warnlog "Couldn't access TextObjectbar - known bug with bars - FHA" - ViewToolbarsTextFormatting - endif - WaitSlot (2000) 'sleep 2 - Printlog "- Raising Font spacing" - - kontext "TextObjectbar" - sleep 1 - iWaitIndex = 0 - do while NOT TextObjectbar.isEnabled AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if NOT TextObjectbar.isEnabled AND iWaitIndex = 10 then - warnlog "Dialogue TextObjectbar didnt work. Ending testcase." - Call hCloseDocument - goto endsub - endif - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemCheck (13) - sleep 2 - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemCheck (14) - sleep 2 - ZeilenabstandErhoehen.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Decrease Spacing" - ZeilenabstandVerringern.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Numbering and Bullets" - sleep 2 - BulletsOnOff.Click - sleep 2 - BulletsOnOff.Click - - Kontext "TextObjectBar" - Printlog "- Increase Font /Reduce Font" - sleep 2 - printlog "Click on Increase Font" - IncreaseFont.Click - sleep 2 - printlog "Click on Reduce Font" - ReduceFont.Click - - Kontext "TextObjectbar" - Printlog "- Text direction from left to right" - sleep 2 - Printlog "- click button 'Text direction from left to right - try - TextdirectionLeftToRight.Click - printlog "hor does work :-)" - if (NOT gAsianSup) then - warnlog " this doesn't have to work if asian lang support is disabled :-)" - endif - catch - if (gAsianSup) then - warnlog "hor does NOT work :-(" - endif - endcatch - Printlog "- click button 'Text direction from top to bottom" - try - TextdirectionTopToBottom.Click - printlog "ver does work :-)" - if (gAsianSup = FALSE) then - warnlog " this doesnt have to work if asian lang support is disabled :-)" - endif - catch - if (gAsianSup = TRUE) then - warnlog "ver does NOT work :-( , AsianLanguage support is enabled !" - endif - endcatch - - Printlog "- open character dialog" - Kontext "TextObjectbar" - sleep 2 - Zeichenformat.Click - sleep 2 - - Kontext - Active.SetPage TabFont - - Kontext "TabFont" - sleep 2 - if TabFont.Exists Then - TabFont.Cancel - Printlog "- Tabfont exists" - else - Warnlog "- No dialog exists " - endif - - Kontext "TextObjectbar" - sleep 2 - Printlog "- call properties for paragraph using text object toolbar" - Absatzformat.Click - sleep 2 - - Kontext - Active.SetPage TabTabulator - - Kontext "TabTabulator" - if TabTabulator.Exists Then - Printlog "- TabTabulator exists" - TabTabulator.Cancel - else - Warnlog "- TabTabulator does not exist" - endif - - if ( gApplication = "IMPRESS" ) then ' IMPRESS only - - Kontext "TextObjectbar" - OutlineBullet.Click - kontext - if active.exists (5) then - messagebox.SetPage TabOptionenNumerierung - - kontext "TabOptionenNumerierung" - if (TabOptionenNumerierung.exists (5) ) then - Printlog "Numbering/Bullets window came up :-)" - TabOptionenNumerierung.cancel - else - warnlog "no Numbering/Bullets window came up :-(" - endif - else - warnlog "no Numbering/Bullets window came up :-( 2" - endif - - Printlog "-change order of outline points" - sleep 3 - ViewWorkspaceOutlineView - WaitSlot (2000) 'sleep (3) - - Kontext "DocumentImpressOutlineView" - sleep 1 - DocumentImpressOutlineView.TypeKeys "Bla bla bla <RETURN><TAB>bla bla bla bla bla <MOD1 SHIFT LEFT>" - sleep 1 - - Kontext "TextObjectbar" - HierachieRunter.Click - sleep 1 - Printlog "- Move back down" - HierachieHoch.Click - sleep 1 - HierachieHoch.Click - sleep 1 - Printlog "- Move paragraph up" - AbsatzHoch.Click - sleep 1 - Printlog "- move paragraph back down and switch to drawing view" - AbsatzRunter.Click - sleep 1 - - Kontext "Vorschau" - if Vorschau.Exists then - printlog "- - - - preview window is open, hope there is no problem" - ' Vorschau.Close - endif - - else ' DRAW only - Kontext "TextObjectbar" - Printlog "- Double" - LineSpacing2.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- 1.5 lines" - LineSpacing15.Click - sleep 2 - - Kontext "TextObjectbar" - Printlog "- Single" - LineSpacing1.Click - sleep 2 - endif - - iWaitIndex = 0 - - Kontext "TextObjectbar" - do while TextObjectbar.isEnabled = FALSE AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if TextObjectbar.isEnabled = FALSE AND iWaitIndex = 10 then - warnlog "Dialogue TextObjectbar didnt work. Ending testcase." - Call hCloseDocument - goto endsub - endif - sleep 2 - - Kontext "TextObjectbar" - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (13) - sleep 2 - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (14) - sleep 2 - ViewToolbarsTextFormatting - WaitSlot (2000) 'sleep 1 - if ( gApplication = "IMPRESS" ) then - Kontext "DocumentImpressOutlineView" - DocumentImpressOutlineView.TypeKeys "<ESCAPE>" - hUseAsyncSlot( "EditSelectAll" ) - DocumentImpressOutlineView.TypeKeys "<DELETE>" - sleep (3) - ViewWorkspaceDrawingView - - Kontext "DocumentImpress" - WaitSlot (2000) 'sleep 1 - DocumentImpress.TypeKeys "<ESCAPE>" - hUseAsyncSlot( "EditSelectAll" ) - DocumentImpress.TypeKeys "<DELETE>" - else - Kontext "DocumentDraw" - DocumentDraw.TypeKeys "<ESCAPE>" - hUseAsyncSlot( "EditSelectAll" ) - DocumentDraw.TypeKeys "<DELETE>" - endif - Printlog "Test ended." - - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' - -testcase tiDrawObjectBar - Dim a as string - Dim Zaehler as integer - Dim i as integer - Dim x as integer - - Call hNewDocument - - Call hRechteckErstellen (20,20,70,70) - sleep 1 - '--------------------------- format line ------------------------ - Printlog "- call format line using graphic object toolbar" - Kontext "DrawingObjectbar" - if DrawingObjectbar.Exists = FALSE then - ViewToolbarsGraphic - endif - if DrawingObjectbar.Exists = FALSE then - warnlog "Drawing-Objectbar should have been opened, but wasnt" - ViewToolbarsGraphic - endif - - sleep 3 - Linie.Click - sleep 2 - Kontext - Active.SetPage TabLinie - Kontext "TabLinie" - if TabLinie.Exists Then - TabLinie.Cancel - Printlog "- TabLinie exists " - else - Warnlog "- TabLinie does not exist" - endif - - '--------------------------- Linienendenstil -------------------- - Printlog "- Style of line ends" - Kontext "DrawingObjectbar" - sleep 1 - Linienendenstil.TearOff - sleep 2 - Kontext "Linienenden" - if Linienenden.Exists Then - Printlog "- dialog exists" - Linienenden.Close - else - Warnlog "- Arrowheads does not exist" - endif - - '--------------------------- Linienstil ------------------------- - Printlog "- choose style of lines using graphic object toolbar" - - Kontext "DrawingObjectbar" - sleep 1 - Linienstil.Select 2 - Printlog Linienstil.GetSelText + " chosen" - Linienstil.Select Linienstil.GetItemCount - Printlog Linienstil.GetSelText + " chosen" - sleep 2 - - '--------------------------- Linienbreite------------------------ - Printlog "- check style of lines using graphic object toolbar" - Kontext "DrawingObjectbar" - sleep 1 - a = Linienbreite.GetText - SetClipboard a - sleep 1 - Linienbreite.SetText "0,5" - sleep 2 - if Linienbreite.GetText = a Then - Warnlog "- changes in edit field did not happen; is: '"+Linienbreite.GetText+"', should be : '"+"0,5"+"'" - else - Printlog "- Width of lines changed" - endif - - '--------------------------- Linienfarbe ------------------------ - Printlog "- change line color" - Kontext "DrawingObjectbar" - sleep 1 - Zaehler = Linienfarbe.GetItemCount - randomize - i = Int(Zaehler*Rnd+1) - Linienfarbe.Select i - Printlog Linienfarbe.GetSelText + " chosen" - - '--------------------------- Flaechenformatierung --------------- - Printlog "- Call Format area using graphic object toolbar" - Kontext "DrawingObjectbar" - sleep 1 - try - Flaeche.Click - catch - printlog "clicking on area took ages :-(" - endcatch - sleep 5 - Kontext - Active.SetPage TabArea - Kontext "TabArea" - if TabArea.Exists Then - Printlog "- TabArea exists " - TabArea.Cancel - else - Warnlog "- TabArea does not exist" - endif - - '--- - sleep 1 - Kontext "DrawingObjectbar" - sleep 1 - x = AreaStyle.GetItemCount - i = 1 - for i = i to x - AreaStyle.Select i - Printlog "Area Style: (" + i + "/" + x + ") - " + AreaStyle.GetSelText - sleep 1 - if AreaStyle.GetSelIndex > 1 then - Printlog " Area Filling " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetItemCount - if (i <> 1) AND (AreaFilling.GetItemCount <> 0) then - if (AreaFilling.GetSelIndex = 0) AND (AreaFilling.GetItemCount > 0) then - printlog "default item is 0 => means nothing; NO BUG! 100909" - endif - AreaFilling.Select (AreaFilling.GetItemCount) - Printlog " Selected: " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetSelText - endif - endif - next i - - '---------------------------- Schatten -------------------------- - Printlog "- Assign shadow using graphic object toolbar" - Kontext "DrawingObjectbar" - sleep 1 - Schatten.Click - sleep 1 - Printlog "- shadow assigned" - - '---------------------------- Praesentationsflyer --------------- - if ( gApplication = "IMPRESS" ) then ' IMPRESS only - Printlog "- Call presentation flyer" - Kontext "CommonTaskbar" ' first check , if presentation flyer is up! if not -> make it up :-) - if CommonTaskbar.Exists Then - printlog "- flyer is already visible :-)" - else - printlog "- flyer wasn't visible :-( -will be now!" - Kontext "DrawingObjectbar" - sleep 1 - ViewToolbarsPresentation ' put it up again! - endif - endif - if ((UCase(gApplication)) = "IMPRESS") then ' IMPRESS only - Kontext "DrawingObjectbar" - if DrawingObjectbar.isVisible = FALSE then - ViewToolbarsGraphic - endif - endif - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' - -testcase tiGraphicsObjectBar - dim i as integer - Call hNewDocument - - hGrafikeinfuegen ConvertPath (gTesttoolPath & "global\input\graf_inp\desp.bmp") - sleep 1 - Kontext "GraphicObjectbar" - if ( NOT GraphicObjectbar.Exists() ) then - ViewToolbarsPicture - endif - sleep 1 - Filter.TearOff - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "invert" - Invert.Click - sleep 3 - Printlog "smooth" - Smooth.Click - sleep 3 - Printlog "sharpen" - Sharpen.Click - sleep 3 - Printlog "remove noise" - Remove.Click - sleep 3 - Printlog "solarization" - Solarization.Click - sleep 3 - Kontext "Solarization" - if Solarization.exists (5) then - sleep 1 - Call Dialogtest ( Solarization ) - sleep 1 - Value.More - Value.Less - Invert.Check - Solarization.OK - else - warnlog "solarization didn't came up :-(" - endif - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "aging" - Aging.Click - Kontext "Aging" - sleep 1 - Call Dialogtest ( Aging ) - AgingDegree.More - AgingDegree.Less - sleep 1 - Aging.OK - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "poster" - Posterize.Click - sleep 1 - Kontext "Posterize" - sleep 1 - Call Dialogtest ( Posterize ) - PosterColors.More - PosterColors.Less - sleep 1 - Posterize.OK - sleep 2 - kontext "GraphicFilterBar" - sleep 1 - Printlog "pop" - Art.Click - sleep 3 - Printlog "charcoal" - CharcoalSketch.Click - sleep 3 - Printlog "relief" - Relief.Click - Kontext "Relief" - sleep 1 - Call Dialogtest ( Relief ) - LightSource.TypeKeys "<left><up>" - Relief.OK - sleep 3 - Kontext "GraphicFilterBar" - Printlog "mos" - Mosaic.Click - sleep 1 - Kontext "Mosaic" - sleep 1 - Call Dialogtest ( Mosaic ) - Width.More - Width.Less - Height.More - Height.Less - EnhanceEdges.Check - Mosaic.OK - sleep 3 - Kontext "GraphicFilterBar" - GraphicFilterBar.Close - - Kontext "GraphicObjectbar" - if GraphicObjectbar.Exists = FALSE then - ViewToolbarsPicture - endif - sleep 1 - for i = 1 to Grafikmodus.GetItemCount - Grafikmodus.select i - sleep 1 - next i - - ColorSettings.Click - Kontext "ColorBar" - - try - Rotanteil.More - Rotanteil.Less - catch - warnlog "not working from testtool redvalue "+ rotanteil.GetRT - endcatch - try - Gruenanteil.More - Gruenanteil.Less - catch - warnlog "not working from testtool Greenvalue." - endcatch - try - Blauanteil.More - Blauanteil.Less - catch - warnlog "not working from testtool Bluevalue." - endcatch - try - Helligkeit.More - Helligkeit.Less - catch - warnlog "not working from testtool Brightness." - endcatch - try - Kontrast.More - Kontrast.Less - catch - warnlog "not working from testtool Contrast." - endcatch - try - Gamma.More - Gamma.Less - catch - warnlog "not working from testtool Gamma." - endcatch - - ColorBar.Close - Kontext "GraphicObjectbar" - - try - Transparenz.More - Transparenz.Less - catch - warnlog "Not working from testtool Transparency." - endcatch - - Crop.click - FormatCropPicture - - kontext "TabZuschneiden" - GroesseBeibehalten.Check - MassstabBeibehalten.Check - Links.More - Links.Less - Rechts.More - Rechts.Less - Oben.More - Oben.Less - Unten.More - Unten.Less - MassstabBreite.More - MassstabBreite.Less - MassstabHoehe.More - MassstabHoehe.Less - GroesseBreite.More - GroesseBreite.Less - GroesseHoehe.More - GroesseHoehe.Less - Originalgroesse.Click - TabZuschneiden.Cancel - - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' - -testcase tiGluepointToolbar - Call hNewDocument - - Call hRechteckErstellen 20,20,40,40 - Call hRechteckErstellen 60,60,80,80 - sleep 2 - ViewToolbarsOptionbar - sleep 2 - - Kontext "Optionsbar" - if Optionsbar.Exists = False Then - ViewToolbarsOptionbar - Kontext "Optionsbar" - if Optionsbar.Exists = False Then - warnlog "Can't open Optionsbar." - endif - endif - sleep 2 - Kontext "Toolbar" - sleep 1 - Verbinder.Click - gMouseMove 30,30,70,70 - sleep 3 - Kontext "Toolbar" - GluePoints.Click - sleep 1 - Kontext "Gluepointsobjectbar" - if Gluepointsobjectbar.Exists = False Then - ViewToolbarsGluepoints - endif - sleep 3 - '-------------------------------------- Klebepunkt einfuegen ---- - try - PunkteEinfuegen.Click - sleep 2 - gMouseClick 25,30 - sleep 1 - gMouseclick 25,30 - Printlog "- insert gluepoint works" - catch - Warnlog "- gluepoint could not be insert. Following errors might have their reason here" - endcatch - sleep 3 - Kontext "Gluepointsobjectbar" - - '-------------------------------------- Links ------------------- - try - Links.Click - Printlog "- gluepoint left works" - catch - Warnlog "- gluepoint left does not work" - endcatch - sleep 1 - '-------------------------------------- Rechts ------------------ - try - Rechts.Click - Printlog "- gluepoint right works" - catch - Warnlog "- gluepoint right does not work" - endcatch - sleep 1 - '-------------------------------------- Oben -------------------- - try - Oben.Click - Printlog "- gluepoint top works" - catch - Warnlog "- gluepoint top does not work" - endcatch - sleep 1 - '-------------------------------------- Unten ------------------- - try - Unten.Click - Printlog "- gluepoint bottom works" - catch - Warnlog "- gluepoint bottom does not work" - endcatch - sleep 1 - '---------------------- Position an Objekt anpassen ------------- - try - PositionAnObjektAnpassen.Click - Printlog "- align position to object works" - gMouseClick 25,30 ' if you don't click onto an existing point, the state changes back :-[ - catch - Warnlog "- align position to object does not work" - endcatch - Kontext "Gluepointsobjectbar" - sleep 1 - '------------------------------------- Horizontal links --------- - if PositionAnObjektAnpassen.exists then - printlog "PositionAnObjektAnpassen = Exists" - endif - if PositionAnObjektAnpassen.GetState(2) <> 0 then - PositionAnObjektAnpassen.Click ' make unpressed! - endif - '0 = not pressed. 1 = pressed. - sleep 2 - try - Kontext "Gluepointsobjectbar" - HorizontalLinks.Click - Printlog "- align horizontal left works" - catch - Warnlog "- align horizontal left does not work" - PositionAnObjektAnpassen.Click ' that's the middle button, it has to be UP/not activated! - for i = 1 to Gluepointsobjectbar.GetItemCount - if (Gluepointsobjectbar.GetState ( i, 0 ) <> 0 ) then ' is no seperator - printlog "----------------------------------------------------------------------" - printlog "helpid : " + Gluepointsobjectbar.Getstate ( i, 0 ) + " number in row: " + i - printlog "itemtype: " + Gluepointsobjectbar.GetState ( i, 1 ) - printlog "state : " + Gluepointsobjectbar.GetState ( i, 2 ) - printlog "----------------------------------------------------------------------" - endif - next i - endcatch - sleep 2 - '------------------------------------- Horizontal rechts -------- - try - HorizontalRechts.Click - Printlog "- Align horizontal right does work" - catch - Warnlog "- Align horizontal right does notwork" - endcatch - sleep 1 - '------------------------------------- Horizontal zentriert ----- - try - HorizontalZentriert.Click - Printlog "- align horizontal center does work" - catch - Warnlog "- align horizontal center does work" - endcatch - sleep 1 - '------------------------------------- Vertikal oben ------------ - try - VertikalOben.Click - sleep 1 - Printlog "- Align vertical top does work" - catch - Warnlog "- Align vertical top does not work" - endcatch - '------------------------------------- Vertikal unten ----------- - try - VertikalUnten.Click - sleep 1 - printlog "- Align vertical bottom does work" - catch - Warnlog "- Align vertical bottom does not work" - endcatch - '------------------------------------- Vertikal zentriert ------- - try - VertikalZentriert.Click - sleep 1 - Printlog "- Align vertical center does work" - catch - Warnlog "- Align vertical center does not work" - endcatch - - Printlog "- End of testing gluepoints" - - ViewToolbarsOptionbar - sleep 2 - Kontext "Optionsbar" - if Optionsbar.Exists Then - warnlog "Couldnt close Optionsbar." - endif - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' - -testcase tdBezierToolbar - Call hNewDocument - - Call hRechteckErstellen ( 10, 10, 30, 40 ) - sleep (1) - - Call hOpenContextMenu - sleep (1) - - Call hOpenContextMenu - sleep (2) - - Kontext "Bezierobjectbar" - if Bezierobjectbar.Exists <> TRUE then - ViewToolbarsBezier - Sleep (2) - if Bezierobjectbar.Exists <> TRUE then - warnlog "Bezierobjectbar did not show up. Check why." - endif - endif - - '----------------------------------- Punkte verschieben ------------------------------------ - - Kontext "Bezierobjectbar" - if Bezierobjectbar.Exists <> TRUE then - ViewToolbarsBezier - Sleep 2 - endif - if Bezierobjectbar.Exists <> TRUE then - Warnlog "The Bezier-Objectbar should have been opened, but wasnt." - ViewToolbarsBezier - Sleep 2 - endif - - Kontext "Bezierobjectbar" - sleep 1 - Printlog "- Move points" - Verschieben.Click - sleep 2 - - hTypeKeys "<MOD1 TAB>" - - Printlog "- Insert points" - Kontext "Bezierobjectbar" - Einfuegen.Click - sleep 2 - Bezierobjectbar.Move 20, 20 - sleep (1) - Printlog "- Delete points" - - gMouseMove 25,25,45,45 - - - sleep 2 - Kontext "Bezierobjectbar" - sleep 2 - Printlog "- Convert into curve" - InKurve.Click - sleep 2 - Printlog "- Place edge point" - Ecke.Click - sleep 2 - Printlog "- Smooth transition" - Glatt.Click - sleep 2 - Printlog "- Symetric transition" - Symmetrisch.Click - sleep 2 - - Kontext "Bezierobjectbar" - PunkteReduzieren.Click - sleep 2 - - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 SHIFT SPACE>" - - Kontext "Bezierobjectbar" - try - Auftrennen.Click - catch - Warnlog "- 'Break' could not be executed" - endcatch - sleep 2 - - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 A>" - - Printlog "- Close bezier" - Kontext "Bezierobjectbar" - try - Schliessen.Click - catch - InKurve.Click - sleep 2 - try - Schliessen.Click - catch - warnlog "Couldn't push button :-( can't reproduce it now, mostly seen on linux, if i loop this test, it happens only 1/5 of the time ... :-)" - endcatch - endcatch - sleep 2 - - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 A>" - - Kontext "Bezierobjectbar" - Printlog "- Break curve" - try - Loeschen.Click - sleep 2 - catch - warnlog "Delete didn't work... why?" - endcatch - - Kontext "Toolbar" - sleep 2 - Toolbar.OpenContextMenu ' Enable forms button in menuebar - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (7) - sleep 2 - Call hCloseDocument -endcase - -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' diff --git a/testautomation/graphics/optional/includes/impress/i_animation.inc b/testautomation/graphics/optional/includes/impress/i_animation.inc index 8ee7777e5994..ac1c07ed817e 100644 --- a/testautomation/graphics/optional/includes/impress/i_animation.inc +++ b/testautomation/graphics/optional/includes/impress/i_animation.inc @@ -37,151 +37,178 @@ ' Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\grafix3.ras") testcase tExtrasAnimation + + Dim i + Dim Zaehler + Dim ZaehlerAnpassung + + Printlog "- Tools/Animation" - Dim i - Call hNewDocument - Call sSelectEmptyLayout '/// New impress document ///' - sleep 2 - InsertGraphicsFromFile '/// insert graphic file (sample.bmp) ///' - sleep 1 - Kontext "GrafikEinfuegenDlg" - sleep 2 + printlog "New impress document " + Call hNewDocument + Call sSelectEmptyLayout + sleep 2 + printlog "insert graphic file (sample.bmp) " + InsertGraphicsFromFile + sleep 1 + Kontext "GrafikEinfuegenDlg" + sleep 2 Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") sleep 2 Oeffnen.Click sleep 2 - Kontext "DocumentImpress" - DocumentImpress.MouseDoubleClick 90,90 '/// Deselect graphic ///' - sleep 1 - InsertGraphicsFromFile - sleep 2 - Kontext "GrafikEinfuegenDlg" - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\grafix3.ras") - sleep 2 - Oeffnen.Click - sleep 2 - Opl_SD_EffekteZulassen - Kontext "Animation" - - for i=1 to 10 - BildAufnehmen.Click '/// add selected picture 10 times into the animation ///' - next i - sleep 1 - if AnzahlBilder.GetText <> "10" Then '/// compare frame number in animation dialog ///' - WarnLog " - Adding graphics did not work" - else - PrintLog " Pictures added" - end if - - if AlleAufnehmen.IsEnabled Then WarnLog " - Add all should not be enabled, there is only 1 graphic selected" '/// test if Add all is eneabled (shouldn't be because of only 1 object selected) ///' - Kontext "DocumentImpress" - EditSelectAll '/// Select both pictures ///' - - Kontext "Animation" - - for i=1 to 5 - AlleAufnehmen.Click '/// Add all (5 times) ///' - next i - sleep 1 - if AnzahlBilder.GetText <> "20" Then '/// check if number of frames is now 20 ///' - WarnLog " - Adding pics did not work" - else - PrintLog " All pics added" - end if - - ErstesBild.Click '/// Click First Picture ///' - - if AnzahlBilder.GetText <> "1" Then '/// Control if we are at frame 1 ///' - WarnLog " - Jump back to start did not work" - else - PrintLog " Jumped back to first picture" - end if - - LetztesBild.Click '/// Go to last picture ///' - - if AnzahlBilder.GetText <> "20" Then '/// Control frame number ///' - WarnLog " - Jump to end did not work" - else - PrintLog " Jump to end did work" - end if - - Abspielen.Click '/// Play animation ///' - sleep 3 - Kontext "DocumentImpress" - EditSelectAll '/// Select all in document ///' - DocumentImpress.TypeKeys "<DELETE>" '/// Delete content ///' - - Kontext "Animation" - Erstellen.Click '/// /Create animation //' - sleep 10 - - Kontext "DocumentImpress" - try - EditCopy '/// Try to copy ccreated animation into clipboard ///' - PrintLog " animation created" - catch - WarnLog " - Animation not created" - endcatch - - Kontext "Animation" - - if AnimationsgruppeGruppenobjekt.IsChecked=True Then - try - AnzeigedauerProBild.SetText "1" '/// Try setting duration per frame ///' - WarnLog " - Edit field should be disabled" - catch - PrintLog " Edit field not enabled because groupobject status is = " + AnimationsgruppeGruppenobjekt.IsChecked - endcatch - end if - - - AnimationsgruppeBitmapobjekt.Check '/// check animation group object ///' - - AnzeigedauerProBild.SetText "3" '/// Set duration per frame to 3///' - SetClipboard AnzeigedauerProBild.GetText - AnzeigedauerProBild.More '/// Raise value for duration ///' - if AnzeigedauerProBild.GetText <> GetClipboardText Then - PrintLog " Time per pic could be edited" - else - WarnLog " - Time per pic could be edited" - end if - - Dim Zaehler - Zaehler = AnzahlDurchlaeufe.GetItemCount - for i=1 to Zaehler '/// Change number of plays ///' - AnzahlDurchlaeufe.Select i - next i - PrintLog " Number of loops checked" - - - Dim ZaehlerAnpassung - ZaehlerAnpassung=Anpassung.GetItemCount '/// change ZaehlerAnpassung ///' - for i=1 to ZaehlerAnpassung - Anpassung.Select i - next i - PrintLog " Loop count changed" - - BildLoeschen.Click '/// Delete 1 frame ///' - if AnzahlBilder = "20" Then - WarnLog " - Delete pictures from animation did not work" - else - PrintLog " Picture No20 deleted" - end if - - AlleLoeschen.Click '/// Delete all frames ///' - Kontext "Active" - Active.Yes - sleep 3 - - Kontext "Animation" - if Abspielen.IsEnabled=true Then - WarnLog " - Not all pics could be deleted" - else - PrintLog " all pics deleted" - end if - sleep 2 - Animation.Close - sleep 2 - Call hCloseDocument '/// close document///' + Kontext "DocumentImpress" + printlog "Deselect graphic " + DocumentImpress.MouseDoubleClick 90,90 + sleep 1 + InsertGraphicsFromFile + sleep 2 + Kontext "GrafikEinfuegenDlg" + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\grafix3.ras") + sleep 2 + Oeffnen.Click + sleep 2 + Opl_SD_EffekteZulassen + Kontext "Animation" + + printlog "add selected picture 10 times into the animation " + for i=1 to 10 + BildAufnehmen.Click + next i + sleep 1 + printlog "compare frame number in animation dialog " + if AnzahlBilder.GetText <> "10" Then + WarnLog " - Adding graphics did not work" + else + printlog "Pictures added" + end if + + printlog "test if Add all is eneabled (shouldn't be because of only 1 object selected) " + if AlleAufnehmen.IsEnabled Then WarnLog " - Add all should not be enabled, there is only 1 graphic selected" + Kontext "DocumentImpress" + printlog "Select both pictures " + EditSelectAll + Kontext "Animation" + printlog "Add all (5 times) " + for i=1 to 5 + AlleAufnehmen.Click + next i + sleep 1 + printlog "check if number of frames is now 20 " + if AnzahlBilder.GetText <> "20" Then + WarnLog " - Adding pics did not work" + else + printlog "All pics added" + end if + + printlog "Click First Picture " + ErstesBild.Click + + printlog "Control if we are at frame 1 " + if AnzahlBilder.GetText <> "1" Then + WarnLog " - Jump back to start did not work" + else + printlog "Jumped back to first picture" + end if + + printlog "Go to last picture " + LetztesBild.Click + + printlog "Control frame number " + if AnzahlBilder.GetText <> "20" Then + WarnLog " - Jump to end did not work" + else + printlog "Jump to end did work" + end if + + printlog "Play animation " + Abspielen.Click + sleep 3 + Kontext "DocumentImpress" + printlog "Select all in document " + EditSelectAll + printlog "Delete content " + DocumentImpress.TypeKeys "<DELETE>" + + Kontext "Animation" + printlog "Create animation" + Erstellen.Click + sleep 10 + + Kontext "DocumentImpress" + try + printlog "Try to copy ccreated animation into clipboard " + EditCopy + printlog "animation created" + catch + WarnLog " - Animation not created" + endcatch + + Kontext "Animation" + + if AnimationsgruppeGruppenobjekt.IsChecked=True Then + try + printlog "Try setting duration per frame " + AnzeigedauerProBild.SetText "1" + WarnLog " - Edit field should be disabled" + catch + printlog "Edit field not enabled because groupobject status is = " + AnimationsgruppeGruppenobjekt.IsChecked + endcatch + end if + + + printlog "check animation group object " + AnimationsgruppeBitmapobjekt.Check + + printlog "Set duration per frame to 3" + AnzeigedauerProBild.SetText "3" + SetClipboard AnzeigedauerProBild.GetText + printlog "Raise value for duration " + AnzeigedauerProBild.More + if AnzeigedauerProBild.GetText <> GetClipboardText Then + printlog "Time per pic could be edited" + else + WarnLog " - Time per pic could be edited" + end if + + Zaehler = AnzahlDurchlaeufe.GetItemCount + printlog "Change number of plays " + for i=1 to Zaehler + AnzahlDurchlaeufe.Select i + next i + printlog "Number of loops checked" + + printlog "change ZaehlerAnpassung " + ZaehlerAnpassung=Anpassung.GetItemCount + for i=1 to ZaehlerAnpassung + Anpassung.Select i + next i + printlog "Loop count changed" + + printlog "Delete 1 frame " + BildLoeschen.Click + if AnzahlBilder = "20" Then + WarnLog " - Delete pictures from animation did not work" + else + printlog "Picture No20 deleted" + end if + + printlog "Delete all frames " + AlleLoeschen.Click + Kontext "Active" + Active.Yes + sleep 3 + + Kontext "Animation" + if Abspielen.IsEnabled=true Then + WarnLog " - Not all pics could be deleted" + else + printlog "all pics deleted" + end if + sleep 2 + Animation.Close + sleep 2 + printlog "close document" + Call hCloseDocument endcase diff --git a/testautomation/graphics/optional/includes/impress/i_headerfooter.inc b/testautomation/graphics/optional/includes/impress/i_headerfooter.inc index 3e4c54551525..d69a6762f886 100644 --- a/testautomation/graphics/optional/includes/impress/i_headerfooter.inc +++ b/testautomation/graphics/optional/includes/impress/i_headerfooter.inc @@ -30,35 +30,31 @@ '* short description : Tests the header-footer-function in Impress '* '******************************************************************* -'* -' #1 tiHeaderFooterSlide -' #1 tiHeaderFooterNotesHandout -'* -'\******************************************************************* -dim numbervalue1 as integer -dim value2 as String -dim value3 as String +testcase tiHeaderFooterSlide -'------------------------------------------------------------------------------ + dim numbervalue1 as integer + dim value2 as String + dim value3 as String -testcase tiHeaderFooterSlide - '/// This part checks the first Tabpage of the Header and Footer Dialog - - Call hNewDocument '/// Open New document + printlog "This part checks the first Tabpage of the Header and Footer Dialog" + + printlog "Open New document" + Call hNewDocument kontext "drawimpress" try - ViewHeaderAndFooter '/// View - Header And Footer + printlog "View - Header And Footer" + ViewHeaderAndFooter sleep(1) catch - warnlog " Could'nt open ViewHeaderAndFooter!" '/// Warnlog for not opening dialog + warnlog " Could'nt open ViewHeaderAndFooter!" endcatch printlog " Testing TabHeaderFooterSlide." kontext "TabHeaderFooterSlide" - '/// Check Date And Time on first tab - if DateTime.Exists = TRUE AND DateTimeFixed.isVisible = TRUE then '/// Testing date and time checkbox + printlog "Testing date and time checkbox" + if DateTime.Exists = TRUE AND DateTimeFixed.isVisible = TRUE then DateTime.UnCheck sleep(1) DateTime.Check @@ -74,7 +70,7 @@ testcase tiHeaderFooterSlide warnlog "DateTime does not exist or is not visible." endif - '/// Checking if DateTime checkbox setting is remembered... + printlog "Checking if DateTime checkbox setting is remembered..." DateTime.Uncheck printlog " Date Time is unchecked now." Apply.Click @@ -87,7 +83,7 @@ testcase tiHeaderFooterSlide endif DateTime.Check - '/// Check DateTimeFixed can be checked/unchecked + printlog "Check DateTimeFixed can be checked/unchecked" if DateTimeFixed.Exists = TRUE AND DateTimeFixed.isVisible = TRUE then DateTimeFixed.Check sleep(1) @@ -102,7 +98,7 @@ testcase tiHeaderFooterSlide warnlog " DateTimeFixed doesnt exist or is not visible!" endif - '/// Can text be inserted in the "fixed"-field? + printlog "Can text be inserted in the fixed-field?" if DateTimeFixedText.exists = TRUE AND DateTimeFixedText.isVisible = TRUE then DateTimeFixedText.settext "lalala" @@ -116,7 +112,7 @@ testcase tiHeaderFooterSlide warnlog " DateTimeFixedText doesnt exist or is not visible!" endif - '/// Checking if DateTimeFixed and Text setting is remembered... + printlog "Checking if DateTimeFixed and Text setting is remembered..." DateTime.Check DateTimeFixed.Check DateTimeFixedText.settext "lalala" @@ -130,7 +126,7 @@ testcase tiHeaderFooterSlide endif DateTimeFixedText.settext "" - '/// Can I change to "Variable" and check it? + printlog "Can I change to Variable and check it?" if DateTimeVariable.exists = TRUE AND DateTimeVariable.isVisible = TRUE then DateTimeVariable.Check sleep(1) @@ -145,7 +141,7 @@ testcase tiHeaderFooterSlide warnlog " DateTimeVariable doesnt exist or is not visible!" endif - '/// Is the Variable setting saved? + printlog "Is the Variable setting saved?" Apply.Click ViewHeaderAndFooter if DateTimeVariable.isChecked then @@ -154,24 +150,30 @@ testcase tiHeaderFooterSlide warnlog " Variable setting does not get saved!" endif - '/// Checking DateTimeFormat box + printlog "Checking DateTimeFormat box" if DateTimeFormat.exists = TRUE AND DateTimeFormat.isVisible = TRUE then - numbervalue1 = DateTimeFormat.getitemcount '/// Get the number of choices + printlog "Get the number of choices" + numbervalue1 = DateTimeFormat.getitemcount printlog " DateTimeFormat equals: " + numbervalue1 - value2 = DateTimeFormat.getseltext '/// Get the text for the choosen entry + printlog "Get the text for the choosen entry" + value2 = DateTimeFormat.getseltext printlog " Tries to get ", numbervalue1 & "." - DateTimeFormat.select ( numbervalue1 - 1 ) '/// Select the last entry - value3 = DateTimeFormat.getseltext '/// Get the text for the last entry + printlog "Select the last entry" + DateTimeFormat.select ( numbervalue1 - 1 ) + printlog "Get the text for the last entry" + value3 = DateTimeFormat.getseltext printlog " DateTimeFormat is: " + value3 - if value2 = value3 then - errorlog " More options for Date should exist!" '/// Check if the first and last are the same. - DateTimeFormat.select value2 '/// Choose the original state + if value2 = value3 then + printlog "Check if the first and last are the same." + errorlog " More options for Date should exist!" + printlog "Choose the original state" + DateTimeFormat.select value2 else printlog " DateTimeFormat box works." endif - '/// Checking if settings of DateTimeFormat box get saved + printlog "Checking if settings of DateTimeFormat box get saved" Apply. Click ViewHeaderAndFooter if DateTimeFormat.GetSelText = value3 then @@ -184,23 +186,30 @@ testcase tiHeaderFooterSlide warnlog " DateTimeFormat doesnt exist or is not visible." endif - '/// Checking DateTimeLanguage box + printlog "Checking DateTimeLanguage box" if DateTimeLanguage.exists = TRUE AND DateTimeLanguage.isVisible = TRUE then - numbervalue1 = DateTimeLanguage.GetItemCount '/// Get the number of choices - DateTimeFormat.select 1 '/// Choose the first entry - value2 = DateTimeLanguage.GetSelText '/// Get the text for the choosen entry - DateTimeLanguage.select ( numbervalue1 - 1 ) '/// Select the last entry - value3 = DateTimeLanguage.GetSelText '/// Get the text for the last entry + printlog "Get the number of choices " + numbervalue1 = DateTimeLanguage.GetItemCount + printlog "Choose the first entry " + DateTimeFormat.select 1 + printlog "Get the text for the choosen entry " + value2 = DateTimeLanguage.GetSelText + printlog "Select the last entry " + DateTimeLanguage.select ( numbervalue1 - 1 ) + printlog "Get the text for the last entry " + value3 = DateTimeLanguage.GetSelText if value2 = value3 then - errorlog " More options for Date should exist!" '/// Check if the first and last aare the same. - DateTimeLanguage.select value2 '/// Choose the original state + errorlog " More options for Date should exist!" + printlog "Check if the first and last are the same. " + printlog "Choose the original state " + DateTimeLanguage.select value2 value3 = DateTimeLanguage.GetSelText else printlog " DateTimeLanguage box works." endif - '/// Checking if language settings get saved + printlog "Checking if language settings get saved" Apply.Click ViewHeaderAndFooter if DateTimeLanguage.GetSelText = value3 then @@ -213,7 +222,7 @@ testcase tiHeaderFooterSlide warnlog " DateTime doesnt exist or is not visible!" endif - '/// Checking Footer checkbox + printlog "Checking Footer checkbox " if Footer.exists = TRUE AND Footer.isVisible = TRUE then Footer.Check sleep(1) @@ -228,7 +237,7 @@ testcase tiHeaderFooterSlide warnlog " Footer checkbox doesnt exist or is not visible!" endif - '/// Checking if Footer setting gest saved + printlog "Checking if Footer setting gest saved" Footer.Uncheck Apply.Click ViewHeaderAndFooter @@ -239,7 +248,7 @@ testcase tiHeaderFooterSlide endif Footer.Check - '/// Checking if text can be inserted in FooterFixedText + printlog "Checking if text can be inserted in FooterFixedText " if FooterFixedText.exists = TRUE AND FooterFixedText.isVisible = TRUE then FooterFixedText.SetText "lalala" @@ -253,7 +262,7 @@ testcase tiHeaderFooterSlide warnlog " Footer doesnt exist or is not visible!" endif - '/// Checking if Footer text gets saved. + printlog "Checking if Footer text gets saved." Apply.Click ViewHeaderAndFooter @@ -265,7 +274,7 @@ testcase tiHeaderFooterSlide endif FooterFixedText.SetText "" - '/// Checking Slidenumber checkbox + printlog "Checking Slidenumber checkbox" if Donotshowonfirstslide.exists = TRUE AND Donotshowonfirstslide.isVisible = TRUE then Slidenumber.Check sleep(1) @@ -279,7 +288,7 @@ testcase tiHeaderFooterSlide warnlog " Do not show on first slide doesnt exist or is not visible!" endif - '/// Checking if Slidenumber gets saved. + printlog "Checking if Slidenumber gets saved." Apply.Click ViewHeaderAndFooter @@ -289,7 +298,7 @@ testcase tiHeaderFooterSlide warnlog " Slidenumber setting is not remembered!" endif - '/// Checking "Do not show on first slide" checkbox + printlog "Checking Do not show on first slide checkbox" if Donotshowonfirstslide.exists = TRUE AND Donotshowonfirstslide.isVisible = TRUE then Donotshowonfirstslide.UnCheck sleep(1) @@ -303,7 +312,7 @@ testcase tiHeaderFooterSlide warnlog " Do not show on first slide doesnt exist or is not visible!" endif - '/// Checking if Do not show on first slide is saved. + printlog "Checking if Do not show on first slide is saved." Apply.Click ViewHeaderAndFooter @@ -313,34 +322,41 @@ testcase tiHeaderFooterSlide warnlog " Do not show on first slide setting is not saved!" endif - '/// Closing dialog with cancel + printlog "Closing dialog with cancel" sleep 1 TabHeaderFooterSlide.Cancel sleep 1 kontext "drawimpress" sleep 1 - '/// Close document + printlog "Close document" Call hCloseDocument -endcase +endcase 'tiHeaderFooterSlide '---------------------------------------------------------------------------- testcase tiHeaderFooterNotesHandout - '/// This part checks the second Tabpage of the Header and Footer Dialog for notes and handout - Call hNewDocument '/// Open New document + dim numbervalue1 as integer + dim value2 as String + dim value3 as String + + printlog "This part checks the second Tabpage of the Header and Footer Dialog for notes and handout" + + printlog "Open New document " + Call hNewDocument kontext "drawimpress" try - ViewHeaderAndFooter '/// View - Header And Footer + printlog "View - Header And Footer " + ViewHeaderAndFooter sleep(1) catch - warnlog " Could'nt open ViewHeaderAndFooter!" '/// Warnlog for not opening dialog + printlog "Warnlog for not opening dialog" + warnlog " Could'nt open ViewHeaderAndFooter!" endcatch 'goto endcase kontext " TabHeaderFooterSlide" - '/// Change tabpage to HeaderFooterNotesHandout printlog " Testing TabHeaderFooterNotesHandout." sleep 2 kontext @@ -348,7 +364,7 @@ testcase tiHeaderFooterNotesHandout sleep 2 kontext "TabHeaderFooterNotesHandout" - '/// Checking Header checkbox + printlog "Checking Header checkbox " if Header.exists = TRUE AND Header.isVisible = TRUE then Header.UnCheck sleep(1) @@ -365,7 +381,7 @@ testcase tiHeaderFooterNotesHandout warnlog " Header doesnt exist or is not visible!" endif - '/// Checking if Header setting is saved. + printlog "Checking if Header setting is saved." Header.Uncheck ApplyToAll.Click ViewHeaderAndFooter @@ -380,7 +396,7 @@ testcase tiHeaderFooterNotesHandout Header.Check endif - '/// Checking if header text can be inserted + printlog "Checking if header text can be inserted" if HeaderFixedText.exists = TRUE AND HeaderFixedText.isVisible = TRUE then HeaderFixedText.settext "lalala" sleep(1) @@ -394,7 +410,7 @@ testcase tiHeaderFooterNotesHandout warnlog " HeaderFixedText doesnt exist or is not visible!" endif - '/// Checking if text is saved. + printlog "Checking if text is saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -407,7 +423,7 @@ testcase tiHeaderFooterNotesHandout endif HeaderFixedText.SetText "" - '/// Checking Date And Time checkbox + printlog "Checking Date And Time checkbox" if DateTime.exists = TRUE AND DateTime.isVisible = TRUE then DateTime.UnCheck sleep(1) @@ -424,7 +440,7 @@ testcase tiHeaderFooterNotesHandout warnlog " DateTime doesnt exist or is not visible!" endif - '/// Checking if Date and Time setting is saved. + printlog "Checking if Date and Time setting is saved." DateTime.Uncheck ApplyToAll.Click ViewHeaderAndFooter @@ -439,7 +455,7 @@ testcase tiHeaderFooterNotesHandout endif DateTime.Check - '/// Check DateTimeFixed can be checked/unchecked + printlog "Check DateTimeFixed can be checked/unchecked " if DateTimeFixed.exists = TRUE AND DateTimeFixed.isVisible = TRUE then if DateTimeFixed.isChecked then @@ -464,7 +480,7 @@ testcase tiHeaderFooterNotesHandout warnlog " DateTimeFixed doesnt exist or is not visible!" endif - '/// Can text be inserted in the "fixed"-field? + printlog "Can text be inserted in the fixed-field? " if DateTimeFixedText.exists = TRUE AND DateTimeFixedText.isVisible = TRUE then DateTimeFixedText.settext "lalala" @@ -474,7 +490,7 @@ testcase tiHeaderFooterNotesHandout printlog " DateTimeFixedText works." endif - '/// Checking if DateTimeFixedText gets saved. + printlog "Checking if DateTimeFixedText gets saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -491,7 +507,7 @@ testcase tiHeaderFooterNotesHandout warnlog "DateTimeFixedText doesnt exist or is not visible" endif - '/// Can it be changed to "Variable" and checked? + printlog "Can it be changed to Variable and checked? " if DateTimeVariable.exists = TRUE AND DateTimeVariable.isVisible = TRUE then DateTimeVariable.Check sleep(1) @@ -502,7 +518,7 @@ testcase tiHeaderFooterNotesHandout warnlog " Something wrong with the DateTimeVariable-checkbox or DateTimeFormat is checked!" endif - '/// Checking if DateTimeVariable setting gets saved. + printlog "Checking if DateTimeVariable setting gets saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -519,25 +535,31 @@ testcase tiHeaderFooterNotesHandout warnlog " DateTimeVariable doesnt exist or is not visible" endif - '/// Checking format dropdown box - numbervalue1 = DateTimeFormat.getitemcount '/// Get the number of choices + printlog "Checking format dropdown box" + printlog "Get the number of choices " + numbervalue1 = DateTimeFormat.getitemcount printlog " DateTimeFormat equals: " + numbervalue1 - value2 = DateTimeFormat.getseltext '/// Get the text for the choosen entry + printlog "Get the text for the choosen entry " + value2 = DateTimeFormat.getseltext printlog " Tries to get ", numbervalue1 if DateTimeFormat.exists = TRUE AND DateTimeFormat.isVisible = TRUE then - DateTimeFormat.select ( numbervalue1 - 1 ) '/// Select the last entry - value3 = DateTimeFormat.getseltext '/// Get the text for the last entry + printlog "Select the last entry " + DateTimeFormat.select ( numbervalue1 - 1 ) + printlog "Get the text for the last entry " + value3 = DateTimeFormat.getseltext printlog " DateTimeFormat is: " + value3 - if value2 = value3 then - errorlog " More options for Date should exist." '/// Check if the first and last are the same. - DateTimeFormat.select value2 '/// Choose the original state + if value2 = value3 then + printlog "Check if the first and last are the same. " + errorlog " More options for Date should exist." + printlog "Choose the original state " + DateTimeFormat.select value2 else printlog " DateTimeFormat works." endif - '/// Checking if DateTimeFormat setting gets saved. + printlog "Checking if DateTimeFormat setting gets saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -555,19 +577,25 @@ testcase tiHeaderFooterNotesHandout endif if DateTimeLanguage.exists = TRUE AND DateTimeLanguage.isVisible = TRUE then - numbervalue1 = DateTimeLanguage.getitemcount '/// Get the number of choices - DateTimeFormat.select 1 '/// Choose the first entry - value2 = DateTimeLanguage.getseltext '/// Get the text for the choosen entry - DateTimeLanguage.select ( numbervalue1 - 1 ) '/// Select the last entry - value3 = DateTimeLanguage.getseltext '/// Get the text for the last entry + printlog "Get the number of choices " + numbervalue1 = DateTimeLanguage.getitemcount + printlog "Choose the first entry " + DateTimeFormat.select 1 + printlog "Get the text for the choosen entry " + value2 = DateTimeLanguage.getseltext + printlog "Select the last entry " + DateTimeLanguage.select ( numbervalue1 - 1 ) + printlog "Get the text for the last entry" + value3 = DateTimeLanguage.getseltext - if value2 = value3 then - errorlog " More options for Date should exist!" '/// Check if the first and last are the same. + if value2 = value3 then + printlog "Check if the first and last are the same. " + errorlog " More options for Date should exist!" else printlog " Footer works." endif - '/// Checking if DateTimeLanguage setting gets saved. + printlog "Checking if DateTimeLanguage setting gets saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -583,7 +611,7 @@ testcase tiHeaderFooterNotesHandout warnlog " DateTimeLanguage does not exist!" endif - '/// Checking Footer checkbox. + printlog "Checking Footer checkbox. " if Footer.exists = TRUE AND Footer.isVisible = TRUE then Footer.UnCheck sleep(1) @@ -597,7 +625,7 @@ testcase tiHeaderFooterNotesHandout Footer.Check endif - '///Check if Footer setting is saved. + printlog "Check if Footer setting is saved." Footer.Uncheck ApplyToAll.Click ViewHeaderAndFooter @@ -611,10 +639,8 @@ testcase tiHeaderFooterNotesHandout printlog " Footer is not checked." endif Footer.Check - - - '/// Checking if Footer text can be inserted + printlog "Checking if Footer text can be inserted" if FooterFixedText.exists = TRUE AND FooterFixedText.isVisible = TRUE then FooterFixedText.SetText "lalala" sleep(1) @@ -629,7 +655,7 @@ testcase tiHeaderFooterNotesHandout warnlog " FooterFixedText does not exists!" endif - '///Checking if Footer text is saved. + printlog "Checking if Footer text is saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -642,7 +668,7 @@ testcase tiHeaderFooterNotesHandout printlog " FooterFixedText gets saved." endif - '/// Checking Slidenumber checkbox + printlog "Checking Slidenumber checkbox" if Slidenumber.exists = TRUE AND Slidenumber.isVisible = TRUE then Slidenumber.UnCheck sleep(1) @@ -653,7 +679,7 @@ testcase tiHeaderFooterNotesHandout Slidenumber.Check endif - '/// Checking if Slidenumber setting is saved. + printlog "Checking if Slidenumber setting is saved." ApplyToAll.Click ViewHeaderAndFooter kontext @@ -670,16 +696,16 @@ testcase tiHeaderFooterNotesHandout warnlog " Slidenumber does'nt exist or is not visible!" endif - '/// Close dialog with cancel + printlog "Close dialog with cancel" sleep 1 TabHeaderFooterNotesHandout.Cancel sleep 1 kontext "drawimpress" sleep 1 - '/// Close document + printlog "Close document " Call hCloseDocument -endcase +endcase 'tiHeaderFooterNotesHandout -'------------------------------------------------------------------------------- +'-------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_pengine.inc b/testautomation/graphics/optional/includes/impress/i_pengine.inc index 4f19f254b055..2374ff28f572 100644 --- a/testautomation/graphics/optional/includes/impress/i_pengine.inc +++ b/testautomation/graphics/optional/includes/impress/i_pengine.inc @@ -36,26 +36,24 @@ '\******************************************************************* testcase tiPenginefast -' dim i,t,q as integer -' dim e as string - dim sFileName as string + ' dim i,t,q as integer + ' dim e as string + dim sFileName as string -'/// the Presentation-Engine consists of showing the presentation, with all it's effects. ///' - -'/// Create a new presentation. ///' + printlog "the Presentation-Engine consists of showing the presentation, with all it's effects." + printlog "Create a new presentation." Call hNewDocument sleep 1 + printlog "Open the test-file." + Call hDateiOeffnen (gTesttoolpath + "graphics\required\input\allshapes.odp") - '/// Open the test-file. ///' - Call hDateiOeffnen (gTesttoolpath + "graphics\required\input\allshapes.odp") 'effects.odp") - - '/// Start the slideshow. ///' + printlog "Start the slideshow." CALL hTypeKeys "<F5>" sleep (5) kontext "DocumentPresentation" DocumentPresentation.TypeKeys "<SPACE>" - '/// Wait for the presentation to reach a certain moment. ///' + printlog "Wait for the presentation to reach a certain moment." sleep (10) DocumentPresentation.TypeKeys "<SPACE>" sleep (7) @@ -63,7 +61,7 @@ testcase tiPenginefast sleep (7) DocumentPresentation.TypeKeys "<SPACE>" sleep (7) - '/// Press "Space" again, to continue with slide two. ///' + printlog "Press "Space" again, to continue with slide two." DocumentPresentation.TypeKeys "<SPACE>" sleep (7) DocumentPresentation.TypeKeys "<SPACE>" @@ -72,19 +70,18 @@ testcase tiPenginefast sleep (7) DocumentPresentation.TypeKeys "<SPACE>" sleep (7) - '/// And press "Space" again, to exit the presentation-mode. ///' + printlog "And press "Space" again, to exit the presentation-mode." DocumentPresentation.TypeKeys "<SPACE>" - FileClose Call hNewDocument sleep 1 - '/// Open the test-file. ///' + printlog "Open the test-file." Call hDateiOeffnen (gTesttoolpath + "graphics\required\input\effects.odp") - '/// Start the slideshow. ///' + printlog "Start the slideshow." CALL hTypeKeys "<F5>" sleep (200) - '/// Press "Space" again, to continue with slide two. ///' + printlog "Press Space again, to continue with slide two." kontext "DocumentPresentation" DocumentPresentation.TypeKeys "<SPACE>" sleep (40) @@ -126,93 +123,93 @@ testcase tiPenginefast kontext "DocumentImpress" end if -'/// Insert a new slide. ///' -' InsertSlide -' sleep 2 -' hTypekeys "<Pagedown>" -' sleep 2 - -'/// Menu: Slideshow: Check every menu-item. ///' - -'Exists: -' #1 tSlideShowSlideShow -' #1 tSlideShowRehearseTimings -' #1 tSlideShowSlideShowSettings -' #1 tSlideShowCustomSlideShow -' #1 tSlideShowSlideTransition -' #1 tSlideShowShowHideSlide - -' Slideshow menu 1 - Slide show -' Slideshow menu 2 - Slide show settings -' Slideshow menu 3 - Rehearse timings -' Slideshow menu 4 - Interaction -' Slideshow menu 6 - Slide Transition -' Slideshow menu 7 - Show / Hide slide -' Slideshow menu 8 - Custom Slide show - - -'Printlog " Here starts the test " - -'Presentation - Start / Stop. Different ways to do it. -'Presentation - Effects. -'LeftWindow - -'/// Slideshow Settings: Range: test all three alternatives. ///' -'/// Test if the Slideshow-types (Default, Window, Auto) works. ///' -'/// Check if the checkboxes works. ///' -'/// Close dialogue. ///' -'/// Add an object. ///' -'/// Custom Animation: Add an Animation to the object. ///' -'/// Run the slideshow. ///' - -'/// Change to the next effect and continue through every animation in ///' -'/// Entrance, Emphasis, Exit and Motion Paths. ///' -'/// While testing - test the speed-choices for every kind of animation. ///' -'/// Check if the "Change" and "Remove"-buttons. ///' -'/// Check the Start, "Direction" and "Speed" variables. ///' -'/// Add two effects to one object and change the order. ///' -'/// Try the Play and "Slide Show"-button. ///' -'/// Try the Automatic preview-button. ///' - -'/// Slidetransition. ///' -'/// Go through every kind of effect, speed, and sound. ///' -'/// Check loop until next sound. ///' -'/// Check the Advance slide with mouseclick-function. ///' -'/// Check the "Apply to all slides", "Play", and "Slide Show"-buttons. ///' -'/// Check Automatic preview. ///' - -'/// Some effects doesnt have a right / left orientation. Test these. ///' -'/// Possibility: check random effects and see if something hangs. ///' - -'/// Load/Save-test: Does the settings last? ///' - -'/// Are two different objects dependant or independent from each other? ///' - -'/// Close Application ///' + printlog "Insert a new slide." + ' InsertSlide + ' sleep 2 + ' hTypekeys "<Pagedown>" + ' sleep 2 + + printlog "Menu: Slideshow: Check every menu-item." + + 'Exists: + ' #1 tSlideShowSlideShow + ' #1 tSlideShowRehearseTimings + ' #1 tSlideShowSlideShowSettings + ' #1 tSlideShowCustomSlideShow + ' #1 tSlideShowSlideTransition + ' #1 tSlideShowShowHideSlide + + ' Slideshow menu 1 - Slide show + ' Slideshow menu 2 - Slide show settings + ' Slideshow menu 3 - Rehearse timings + ' Slideshow menu 4 - Interaction + ' Slideshow menu 6 - Slide Transition + ' Slideshow menu 7 - Show / Hide slide + ' Slideshow menu 8 - Custom Slide show + + + 'Printlog " Here starts the test " + + 'Presentation - Start / Stop. Different ways to do it. + 'Presentation - Effects. + 'LeftWindow + + printlog "Slideshow Settings: Range: test all three alternatives." + printlog "Test if the Slideshow-types (Default, Window, Auto) works." + printlog "Check if the checkboxes works." + printlog "Close dialogue." + printlog "Add an object." + printlog "Custom Animation: Add an Animation to the object." + printlog "Run the slideshow." + + printlog "Change to the next effect and continue through every animation in" + printlog "Entrance, Emphasis, Exit and Motion Paths." + printlog "While testing - test the speed-choices for every kind of animation." + printlog "Check if the "Change" and "Remove"-buttons." + printlog "Check the Start, "Direction" and "Speed" variables." + printlog "Add two effects to one object and change the order." + printlog "Try the Play and "Slide Show"-button." + printlog "Try the Automatic preview-button." + + printlog "Slidetransition." + printlog "Go through every kind of effect, speed, and sound." + printlog "Check loop until next sound." + printlog "Check the Advance slide with mouseclick-function." + printlog "Check the "Apply to all slides", "Play", and "Slide Show"-buttons." + printlog "Check Automatic preview." + + printlog "Some effects doesnt have a right / left orientation. Test these." + printlog "Possibility: check random effects and see if something hangs." + + printlog "Load/Save-test: Does the settings last?" + + printlog "Are two different objects dependant or independent from each other?" + + printlog "Close Application" Call hCloseDocument Printlog "Finished Optional-test for Presentation-Engine" -endcase +endcase 'tiPenginefast +'------------------------------------------------------------------------------- testcase tSlideShowInteraction - Dim Datei$ - Dim i as integer - Dim Zaehler as integer - dim b115364 as boolean + Dim Datei$ + Dim i as integer + Dim Zaehler as integer + dim b115364 as boolean - Datei$ =ConvertPath (gOfficePath + "user\work\interac.sxi") + Datei$ =ConvertPath (gOfficePath + "user\work\interac.sxi") -' '/// save file as presentation with name '"user\\work\\diashow.sxi")' ///' +' printlog "save file as presentation with name '"user\\work\\diashow.sxi")'" ' hFileSaveAsWithFilterKill ( sFile , gImpressFilter, FALSE ) ' Printlog "saved presetation: '" + sFile + "'" - '/// open application ///' + printlog "open application" Call hNewDocument sleep 5 - setStartCurrentPage(FALSE) '/// Set "start with current page to OFF ///' + setStartCurrentPage(FALSE) printlog "Set "start with current page to OFF" - '/// call 'Insert->Slide' three times and name the slides 2, 3, 4 and create a rectangle on it ///' - '///+ we now have 4 slides ?! :-) ///' + printlog "call 'Insert->Slide' three times and name the slides 2, 3, 4 and create a rectangle on it " for i = 2 to 4 InsertSlide sleep 2 @@ -222,7 +219,7 @@ testcase tSlideShowInteraction sleep 2 next i - '/// check state of navigator ! expected: closed -> open navigator ///' + printlog "check state of navigator ! expected: closed -> open navigator" Kontext "Navigator" if Navigator.exists then warnlog "Navigator: already open :-(" @@ -232,194 +229,194 @@ testcase tSlideShowInteraction endif sleep 3 - '/// Slide Show->Interaction ///' - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - if AktionBeiMausklick.GetItemCount = 13 Then - Printlog "- List is complete" - else - Warnlog "- Number of possible actions is wrong. It should be: 13, but it is: " + AktionBeiMausklick.GetItemCount - end if - sleep 1 - - AktionBeiMausklick.Select 1 'Keine Aktion bei Mausclick - Printlog (AktionBeiMausklick.GetSelText + " chosen") - If Durchsuchen.IsVisible then Warnlog "- Control should be invisible because AktionBeiMausklick = " + AktionBeiMausKlick.GetSelText - sleep 1 - - Kontext "TabInteraktion" - AktionBeiMausklick.Select 2 'Sprung zur vorhergehenden Seite - Printlog (AktionBeiMausklick.GetSelText + " chosen") - if Durchsuchen.IsVisible Then Warnlog "- Control should be invisible, beacause Action = " + AktionBeiMausKlick.GetSelText - TabInteraktion.OK - sleep 2 - Kontext "DocumentImpress" - gMouseClick 90,90 - sleep 1 - gMouseClick 50,50 + printlog "Slide Show->Interaction" + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + if AktionBeiMausklick.GetItemCount = 13 Then + Printlog "- List is complete" + else + Warnlog "- Number of possible actions is wrong. It should be: 13, but it is: " + AktionBeiMausklick.GetItemCount + end if + sleep 1 + + AktionBeiMausklick.Select 1 'Keine Aktion bei Mausclick + Printlog (AktionBeiMausklick.GetSelText + " chosen") + If Durchsuchen.IsVisible then Warnlog "- Control should be invisible because AktionBeiMausklick = " + AktionBeiMausKlick.GetSelText + sleep 1 + + Kontext "TabInteraktion" + AktionBeiMausklick.Select 2 'Sprung zur vorhergehenden Seite + Printlog (AktionBeiMausklick.GetSelText + " chosen") + if Durchsuchen.IsVisible Then Warnlog "- Control should be invisible, beacause Action = " + AktionBeiMausKlick.GetSelText + TabInteraktion.OK + sleep 2 + Kontext "DocumentImpress" + gMouseClick 90,90 + sleep 1 + gMouseClick 50,50 sleep 2 - Kontext "NavigatorDraw" - sleep 2 - if Not Liste.GetSelIndex = 3 Then - Warnlog "- jumped to wrong slide" - else - Printlog "- jumped to correct slide" - end if - sleep 1 + Kontext "NavigatorDraw" + sleep 2 + if Not Liste.GetSelIndex = 3 Then + Warnlog "- jumped to wrong slide" + else + Printlog "- jumped to correct slide" + end if + sleep 1 - Kontext "DocumentImpress" - EditSelectAll - sleep 1 + Kontext "DocumentImpress" + EditSelectAll + sleep 1 - SlideShowInteraction - sleep 2 - Kontext "TabInteraktion" - AktionBeiMausklick.select 3 'Sprung zur naechsten Seite - Printlog (AktionBeiMausKlick.GetSelText + " chosen") - TabInteraktion.OK - sleep 1 + SlideShowInteraction + sleep 2 + Kontext "TabInteraktion" + AktionBeiMausklick.select 3 'Sprung zur naechsten Seite + Printlog (AktionBeiMausKlick.GetSelText + " chosen") + TabInteraktion.OK + sleep 1 Kontext "DocumentImpress" gMouseClick 90,90 sleep 2 gMouseClick 50,50 Kontext "NavigatorDraw" - if Liste.GetSelIndex <> 4 Then - Warnlog "- Jumped to wrong slide" - else - Printlog " Jumped to correct slide" - end if - sleep 1 - kontext "DocumentImpress" - EditSelectAll - sleep 1 - - SlideShowInteraction - sleep 1 - Kontext "TabInteraktion" - AktionBeiMausklick.select 4 'Sprung zur ersten Seite - Printlog AktionBeiMausKlick.GetSelText - sleep 1 - TabInteraktion.OK - sleep 1 - Kontext "DocumentImpress" - gMouseClick 90,90 - gMouseClick 50,50 - Kontext "NavigatorDraw" - if Liste.GetSelIndex <> 1 Then Warnlog "- jumped to wrong slide" - Letzte.Click 'Liste.Select 4 - Kontext "DocumentImpress" - EditSelectAll - sleep 2 + if Liste.GetSelIndex <> 4 Then + Warnlog "- Jumped to wrong slide" + else + Printlog " Jumped to correct slide" + end if + sleep 1 + kontext "DocumentImpress" + EditSelectAll + sleep 1 + + SlideShowInteraction + sleep 1 + Kontext "TabInteraktion" + AktionBeiMausklick.select 4 'Sprung zur ersten Seite + Printlog AktionBeiMausKlick.GetSelText + sleep 1 + TabInteraktion.OK + sleep 1 + Kontext "DocumentImpress" + gMouseClick 90,90 + gMouseClick 50,50 + Kontext "NavigatorDraw" + if Liste.GetSelIndex <> 1 Then Warnlog "- jumped to wrong slide" + Letzte.Click 'Liste.Select 4 + Kontext "DocumentImpress" + EditSelectAll + sleep 2 try SlideShowInteraction catch warnlog "SlideshowInteraction diasabled :-(" endcatch - Kontext "TabInteraktion" - AktionBeiMausklick.select 5 'Sprung zur letzten Seite - printlog AktionBeiMausKlick.GetSelText - TabInteraktion.OK - sleep 1 - Kontext "NavigatorDraw" - if Not Liste.GetSelIndex = 1 Then Warnlog "- jumped to wrong slide" + Kontext "TabInteraktion" + AktionBeiMausklick.select 5 'Sprung zur letzten Seite + printlog AktionBeiMausKlick.GetSelText + TabInteraktion.OK + sleep 1 + Kontext "NavigatorDraw" + if Not Liste.GetSelIndex = 1 Then Warnlog "- jumped to wrong slide" - kontext "DocumentImpress" - Call hRechteckErstellen 20,20,50,50 - sleep 1 - EditSelectAll - sleep 1 + kontext "DocumentImpress" + Call hRechteckErstellen 20,20,50,50 + sleep 1 + EditSelectAll + sleep 1 try FormatGroupGroup catch warnlog "GROUP?" endcatch - sleep 1 - - SlideShowInteraction - Kontext "TabInteraktion" - AktionBeiMausklick.select 6 'Sprung zu Seite oder Objekt - printlog AktionBeiMausKlick.GetSelText - sleep 2 - if Not ListeSprungZuSeiteObjekt.IsVisible Then Warnlog " list seems to be invisible" - Seite.SetText S2 - Suchen.Click - if ListeSprungZuSeiteObjekt.GetSelIndex <> 3 Then Warnlog " Search does not work" - printlog ListeSprungZuSeiteObjekt.GetSelIndex - TabInteraktion.OK - sleep 1 + sleep 1 - Kontext "DocumentImpress" - gMouseClick 90,90 - gMouseClick 25,25, - sleep 2 - Kontext "NavigatorDraw" - if Liste.GetSelIndex <> 2 Then Warnlog "- Jumped to wrong destination" - printlog Liste.GetSelIndex - Liste.Select 4 - Kontext "DocumentImpress" - EditSelectAll - sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + AktionBeiMausklick.select 6 'Sprung zu Seite oder Objekt + printlog AktionBeiMausKlick.GetSelText + sleep 2 + if Not ListeSprungZuSeiteObjekt.IsVisible Then Warnlog " list seems to be invisible" + Seite.SetText S2 + Suchen.Click + if ListeSprungZuSeiteObjekt.GetSelIndex <> 3 Then Warnlog " Search does not work" + printlog ListeSprungZuSeiteObjekt.GetSelIndex + TabInteraktion.OK + sleep 1 - Kontext "DocumentImpress" - EditSelectAll + Kontext "DocumentImpress" + gMouseClick 90,90 + gMouseClick 25,25, + sleep 2 + Kontext "NavigatorDraw" + if Liste.GetSelIndex <> 2 Then Warnlog "- Jumped to wrong destination" + printlog Liste.GetSelIndex + Liste.Select 4 + Kontext "DocumentImpress" + EditSelectAll + sleep 1 + + Kontext "DocumentImpress" + EditSelectAll + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + AktionBeiMausKlick.Select 7 'Sprung zu Dokument + Printlog AktionBeiMausKlick.GetSelText + " chosen" + try + Durchsuchen.Click sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - AktionBeiMausKlick.Select 7 'Sprung zu Dokument - Printlog AktionBeiMausKlick.GetSelText + " chosen" - try - Durchsuchen.Click - sleep 1 - Kontext "OeffnenDlg" - sleep 1 - Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\recht_49.sxi") - Oeffnen.Click - sleep 10 - ' 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 - catch - Warnlog "- Search button could not be accessed" - endcatch - sleep 1 - Kontext "TabInteraktion" - sleep 1 - TabInteraktion.OK - sleep 3 - Kontext "DocumentImpress" - DocumentImpress.MouseDown 90,90 - DocumentImpress.MouseUp 90,90 - sleep 2 - Kontext "DocumentImpress" - DocumentImpress.Mousedown 30,30 - kontext - b115364 = false - if messagebox.exists then - printlog "baeh: '" + messagebox.gettext + "'" - try - messagebox.ok ' was default in so7 - catch - warnlog "behaviour changed #115364# mother document gets closed :-(" - if fileExists(ConvertPath (gOfficePath + "user\work\bug115364.sxi")) then - kill ConvertPath (gOfficePath + "user\work\bug115364.sxi") - endif - messagebox.yes ' don't save changes, before going on! - b115364 = true - kontext "SpeichernDlg" - Dateiname.setText ConvertPath (gOfficePath + "user\work\bug115364.sxi") - Speichern.click - sleep 10 - endcatch + Kontext "OeffnenDlg" + sleep 1 + Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\recht_49.sxi") + Oeffnen.Click + sleep 10 + ' 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 + catch + Warnlog "- Search button could not be accessed" + endcatch + sleep 1 + Kontext "TabInteraktion" + sleep 1 + TabInteraktion.OK + sleep 3 + Kontext "DocumentImpress" + DocumentImpress.MouseDown 90,90 + DocumentImpress.MouseUp 90,90 + sleep 2 + Kontext "DocumentImpress" + DocumentImpress.Mousedown 30,30 + kontext + b115364 = false + if messagebox.exists then + printlog "baeh: '" + messagebox.gettext + "'" + try + messagebox.ok ' was default in so7 + catch + warnlog "behaviour changed #115364# mother document gets closed :-(" + if fileExists(ConvertPath (gOfficePath + "user\work\bug115364.sxi")) then + kill ConvertPath (gOfficePath + "user\work\bug115364.sxi") + endif + messagebox.yes ' don't save changes, before going on! + b115364 = true + kontext "SpeichernDlg" + Dateiname.setText ConvertPath (gOfficePath + "user\work\bug115364.sxi") + Speichern.click + sleep 10 + endcatch else printlog "OK :-)" endif @@ -444,207 +441,207 @@ testcase tSlideShowInteraction endif sleep 5 - Kontext "NavigatorDraw" - sleep 1 - Naechste.click + Kontext "NavigatorDraw" + sleep 1 + Naechste.click - Kontext "DocumentImpress" - EditSelectAll - sleep 1 - - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - AktionBeiMausKlick.Select 9 - Printlog AktionBeiMausKlick.GetSelText + " chosen" - sleep 1 - Tabinteraktion.OK - sleep 2 + Kontext "DocumentImpress" + EditSelectAll + sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - if not AktionBeiMausKlick.GetSelIndex = 9 Then Warnlog "- Not the right action chosen" - sleep 1 - AktionBeiMausKlick.Select 9 'Klang abspielen - Printlog AktionBeiMausKlick.GetSelText + "- chosen" - sleep 1 - Tabinteraktion.OK - sleep 2 - Kontext "NavigatorDraw" - sleep 1 - Liste.Select 2 - Kontext "DocumentImpress" - EditSelectAll - sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - Durchsuchen.Click - sleep 1 - Kontext "OeffnenDlg" - sleep 1 - Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\blip.wav") - sleep 1 - Oeffnen.Click - sleep 1 - Kontext "Active" - if Active.Exists Then - Warnlog Active.GetText + " Gallery might be empty" - Active.OK - sleep 1 - Kontext "OeffnenDlg" - OeffnenDlg.Cancel - sleep 1 - end if - Kontext "TabInteraktion" - SetClipboard Klangwahl.GetText - TabInteraktion.OK - sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - if Klangwahl.GetText <> GetClipboardText then Warnlog "- Not the right sound chosen" - TabInteraktion.OK - sleep 1 - InsertGraphicsFromFile - sleep 1 - Kontext "GrafikeinfuegenDlg" - sleep 1 - if Verknuepfen.IsChecked then Verknuepfen.UnCheck - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") - Oeffnen.Click - sleep 3 - Kontext "NavigatorDraw" - sleep 1 - Liste.Select 4 - sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - AktionBeiMausKlick.Select 11 'Objektaktion ausfuehren - Printlog AktionBeiMausKlick.GetSelText + " chosen" - sleep 1 - Zaehler=Effekt.GetItemCount - for i=1 to Zaehler - Effekt.Select i - Printlog Effekt.GetSelText + " chosen" - if i=1 Then - if Langsam.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" - if Mittel.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" - if Schnell.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" - end if - sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + AktionBeiMausKlick.Select 9 + Printlog AktionBeiMausKlick.GetSelText + " chosen" + sleep 1 + Tabinteraktion.OK + sleep 2 - TabInteraktion.OK - sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - next i - TabInteraktion.OK - sleep 1 - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - AktionBeiMausKlick.Select 10 'Objekt ausblenden - Printlog AktionBeiMausKlick.GetSelText + " chosen" - ListeObjektAktion.Select 1 - sleep 1 - TabInteraktion.OK - sleep 1 - gMouseClick 90,90 - sleep 1 - gMouseClick 55,55 - sleep 1 - Kontext "DocumentImage" - - SlideShowInteraction - Kontext "TabInteraktion" - sleep 1 - AktionBeiMausKlick.Select 13 'Makro - Printlog AktionBeiMausKlick.GetSelText + " chosen" - sleep 2 - Durchsuchen.Click - sleep 5 - Kontext "Makro" - sleep 5 - Makro.Cancel - sleep 2 - Kontext "TabInteraktion" - sleep 1 - TabInteraktion.OK - sleep 3 - - SlideShowInteraction - Kontext "TabInteraktion" - sleep 2 - if not AktionBeiMausKlick.GetSelIndex = 12 Then Warnlog "- Wrong action used" - sleep 1 - AktionBeiMausKlick.Select 14 'Praesentation beenden - Printlog AktionBeiMausKlick.GetSelText - Tabinteraktion.OK - sleep 1 - - SlideShowPresentationSettings - Kontext "Bildschirmpraesentation" - if not Fenster.IsChecked Then Fenster.Check - BildschirmPraesentation.OK - sleep 2 - Kontext "DocumentImpress" - DocumentImpress.TypeKeys "<MOD1 F2>" - sleep 5 - Kontext "DocumentPresentation" - sleep 2 - DocumentPresentation.MouseDown 50,50 - DocumentPresentation.MouseUp 50,50 - sleep 5 - try - Kontext "DocumentImpress" - EditSelectAll - Printlog "- Slideshow ended at right point" - catch - Warnlog "- Program is still in slideshow mode" - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<ESCAPE>" - endcatch + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + if not AktionBeiMausKlick.GetSelIndex = 9 Then Warnlog "- Not the right action chosen" + sleep 1 + AktionBeiMausKlick.Select 9 'Klang abspielen + Printlog AktionBeiMausKlick.GetSelText + "- chosen" + sleep 1 + Tabinteraktion.OK + sleep 2 + Kontext "NavigatorDraw" + sleep 1 + Liste.Select 2 + Kontext "DocumentImpress" + EditSelectAll + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + Durchsuchen.Click + sleep 1 + Kontext "OeffnenDlg" + sleep 1 + Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\blip.wav") + sleep 1 + Oeffnen.Click + sleep 1 + Kontext "Active" + if Active.Exists Then + Warnlog Active.GetText + " Gallery might be empty" + Active.OK + sleep 1 + Kontext "OeffnenDlg" + OeffnenDlg.Cancel + sleep 1 + end if + Kontext "TabInteraktion" + SetClipboard Klangwahl.GetText + TabInteraktion.OK + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + if Klangwahl.GetText <> GetClipboardText then Warnlog "- Not the right sound chosen" + TabInteraktion.OK + sleep 1 + InsertGraphicsFromFile + sleep 1 + Kontext "GrafikeinfuegenDlg" + sleep 1 + if Verknuepfen.IsChecked then Verknuepfen.UnCheck + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") + Oeffnen.Click + sleep 3 + Kontext "NavigatorDraw" + sleep 1 + Liste.Select 4 + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + AktionBeiMausKlick.Select 11 'Objektaktion ausfuehren + Printlog AktionBeiMausKlick.GetSelText + " chosen" + sleep 1 + Zaehler=Effekt.GetItemCount + for i=1 to Zaehler + Effekt.Select i + Printlog Effekt.GetSelText + " chosen" + if i=1 Then + if Langsam.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" + if Mittel.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" + if Schnell.IsEnabled Then Warnlog "- Control should not be enabled, because no effect chosen" + end if + sleep 1 - Kontext "DocumentImpress" - DocumentImpress.TypeKeys "<SHIFT MOD1 F5>" - sleep 3 - setStartCurrentPage(TRUE) '/// Set "start with current page to ON = Default ///' - Call hCloseDocument -endcase + TabInteraktion.OK + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + next i + TabInteraktion.OK + sleep 1 + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + AktionBeiMausKlick.Select 10 'Objekt ausblenden + Printlog AktionBeiMausKlick.GetSelText + " chosen" + ListeObjektAktion.Select 1 + sleep 1 + TabInteraktion.OK + sleep 1 + gMouseClick 90,90 + sleep 1 + gMouseClick 55,55 + sleep 1 + Kontext "DocumentImage" -' Slideshow menu 5 - Custom Animation + SlideShowInteraction + Kontext "TabInteraktion" + sleep 1 + AktionBeiMausKlick.Select 13 'Makro + Printlog AktionBeiMausKlick.GetSelText + " chosen" + sleep 2 + Durchsuchen.Click + sleep 5 + Kontext "Makro" + sleep 5 + Makro.Cancel + sleep 2 + Kontext "TabInteraktion" + sleep 1 + TabInteraktion.OK + sleep 3 + + SlideShowInteraction + Kontext "TabInteraktion" + sleep 2 + if not AktionBeiMausKlick.GetSelIndex = 12 Then Warnlog "- Wrong action used" + sleep 1 + AktionBeiMausKlick.Select 14 'Praesentation beenden + Printlog AktionBeiMausKlick.GetSelText + Tabinteraktion.OK + sleep 1 + + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + if not Fenster.IsChecked Then Fenster.Check + BildschirmPraesentation.OK + sleep 2 + Kontext "DocumentImpress" + DocumentImpress.TypeKeys "<MOD1 F2>" + sleep 5 + Kontext "DocumentPresentation" + sleep 2 + DocumentPresentation.MouseDown 50,50 + DocumentPresentation.MouseUp 50,50 + sleep 5 + try + Kontext "DocumentImpress" + EditSelectAll + Printlog "- Slideshow ended at right point" + catch + Warnlog "- Program is still in slideshow mode" + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<ESCAPE>" + endcatch + + Kontext "DocumentImpress" + DocumentImpress.TypeKeys "<SHIFT MOD1 F5>" + sleep 3 + setStartCurrentPage(TRUE) printlog "Set "start with current page to ON = Default" + Call hCloseDocument +endcase 'tSlideShowInteraction + +'------------------------------------------------------------------------------- testcase tSlideShowCustomAnimation dim bError as boolean - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 10, 10, 20, 40 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then DialogTest(TabEntrance) - '/// select in the listbox 'Effects' the second entry ///' + printlog "select in the listbox 'Effects' the second entry" Effects.select(2) Speed.getItemCount AutomaticPreview.unCheck sleep 1 AutomaticPreview.Check kontext - '/// Switch to TabPage: Emphasis ///' + printlog "Switch to TabPage: Emphasis" active.setPage(TabEmphasis) kontext "TabEmphasis" if TabEmphasis.exists(5) then @@ -654,7 +651,7 @@ testcase tSlideShowCustomAnimation warnlog "Impress:Tasks Pane:Custom Animation:TabEmphasis tabPage doesn't work." endif kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" if TabExit.exists(5) then @@ -664,7 +661,7 @@ testcase tSlideShowCustomAnimation warnlog "Impress:Tasks Pane:Custom Animation:TabExit tabPage doesn't work." endif kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" if TabMotionPaths.exists(5) then @@ -674,7 +671,7 @@ testcase tSlideShowCustomAnimation bError = true warnlog "Impress:Tasks Pane:Custom Animation:TabMotionPaths tabPage doesn't work." endif - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabMotionPaths.OK bError = false else @@ -683,11 +680,11 @@ testcase tSlideShowCustomAnimation endif Kontext "Tasks" if (NOT bError) then - '/// click button 'Change...' ///' + printlog "click button 'Change...'" EffectChange.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if (NOT TabEntrance.exists(5)) then @@ -699,14 +696,14 @@ testcase tSlideShowCustomAnimation if EffectProperty.isEnabled then EffectProperty.getItemCount endif - '/// CLick on button '...' (Options) ///' + printlog "CLick on button '...' (Options)" EffectOptions.click kontext "TabEffect" if TabEffect.exists(5) then dialogTest(TabEffect) Sound.getItemCount AfterAnimation.getItemCount - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext active.setPage TabTiming kontext "TabTiming" @@ -723,7 +720,7 @@ testcase tSlideShowCustomAnimation else warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: Timing TabPage didn't work." endif - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext active.setPage TabTextAnimation kontext "TabTextAnimation" @@ -753,10 +750,9 @@ testcase tSlideShowCustomAnimation endif kontext "Tasks" EffectAutomaticPreview.isChecked - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.click endif - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase - +endcase
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_pengine1.inc b/testautomation/graphics/optional/includes/impress/i_pengine1.inc index 44f531c47fcd..ff4d2a035ef0 100644 --- a/testautomation/graphics/optional/includes/impress/i_pengine1.inc +++ b/testautomation/graphics/optional/includes/impress/i_pengine1.inc @@ -30,20 +30,9 @@ '* short description : Tests the Engine for Presentation '* '******************************************************************* -'* -' #1 tiPengineTabEntrance -' #1 tiPengineTabEmphasis -' #1 tiPengineTabExit -' #1 tiPengineTabMotionPaths -' #1 tiPengineSlideTransition -' #1 tiPengineTabpageEntrance2 -' #1 tiPengineTabPageEmphasis2 -' #1 tiPengineTabPageExit2 -' #1 tiPengineTabPageMotionPaths2 -'* -'\******************************************************************* testcase tiPengineTabEntrance + dim bError as boolean dim e as integer dim d as integer @@ -62,19 +51,19 @@ testcase tiPengineTabEntrance dim UsedEffect as string dim NewEffect as string -'/// open application ///' -Call hNewDocument -'/// create textbox with text ///' -Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) -'/// Slide Show->Custom Animation... ///' -SlideShowCustomAnimation - Kontext "Tasks" - '/// click button 'Add...' ///' - EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' - kontext + printlog "open application" + Call hNewDocument + printlog "create textbox with text" + Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) + printlog "Slide Show->Custom Animation..." + SlideShowCustomAnimation + Kontext "Tasks" + printlog "click button 'Add...'" + EffectAdd.click + printlog "Dialog 'Custom Animation' comes up" + kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then @@ -183,7 +172,8 @@ SlideShowCustomAnimation Printlog "Presentation didn't end. Error?" endif kontext "TabEntrance" - Effects.TypeKeys "<DOWN>", e '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e p = Effects.GetSelIndex If p = d Then e = i Next e @@ -206,12 +196,12 @@ SlideShowCustomAnimation Next o kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -223,15 +213,16 @@ SlideShowCustomAnimation endif kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabEntrance -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------ +'------------------------------------------------------------------------------- testcase tiPengineTabEmphasis + dim bError as boolean dim e as integer dim d as integer @@ -250,19 +241,19 @@ testcase tiPengineTabEmphasis dim UsedEffect as string dim NewEffect as string - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Emphasis ///' + printlog "Switch to TabPage: Emphasis" kontext active.setPage(TabEmphasis) kontext "TabEmphasis" @@ -347,11 +338,12 @@ testcase tiPengineTabEmphasis else Printlog "Presentation didn't end. Error?" endif - '/// Switch to TabPage: Emphasis ///' + printlog "Switch to TabPage: Emphasis" kontext active.setPage(TabEmphasis) kontext "TabEmphasis" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e + 1 p = Effects.GetSelIndex If p = d Then e = i Next e @@ -375,12 +367,12 @@ testcase tiPengineTabEmphasis endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -388,15 +380,16 @@ testcase tiPengineTabEmphasis bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabEmphasis -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------ +'------------------------------------------------------------------------------- testcase tiPengineTabExit + dim bError as boolean dim e as integer dim d as integer @@ -415,19 +408,19 @@ testcase tiPengineTabExit dim UsedEffect as string dim NewEffect as string - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" if TabExit.exists(5) then @@ -509,10 +502,11 @@ testcase tiPengineTabExit Printlog "Presentation didn't end. Error?" endif kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e + 1 p = Effects.GetSelIndex If p = d Then e = i 'p > 2 AND Next e @@ -529,12 +523,12 @@ testcase tiPengineTabExit endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -542,15 +536,17 @@ testcase tiPengineTabExit bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------ +endcase 'tiPengineTabExit + +'------------------------------------------------------------------------------- testcase tiPengineTabMotionPaths + dim bError as boolean dim e as integer dim d as integer @@ -569,19 +565,19 @@ testcase tiPengineTabMotionPaths dim UsedEffect as string dim NewEffect as string - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" if TabMotionPaths.exists(5) then @@ -671,10 +667,11 @@ testcase tiPengineTabMotionPaths Printlog "Presentation didn't end. Error?" endif kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + Effects.TypeKeys "<DOWN>", e + 1 + printlog "Select the next entry" ' if p = 2 then Effects.TypeKeys "<DOWN>" p = Effects.GetSelIndex If p = d Then e = i 'p > 2 AND @@ -691,12 +688,12 @@ testcase tiPengineTabMotionPaths endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -704,15 +701,16 @@ testcase tiPengineTabMotionPaths bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabMotionPaths '-------------------------------------------------------------------------------------------------------------------------------------------------- testcase tiPengineSlideTransition + dim a as integer dim b as integer dim i as integer @@ -720,31 +718,31 @@ testcase tiPengineSlideTransition dim iCount as integer dim Soundposition as integer - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) sleep 1 - '/// Insert a second slide ///' + printlog "Insert a second slide" InsertSlide sleep 2 - hTypekeys "<Pagedown>" + hTypeKeys "<Pagedown>" sleep 2 - '/// create textframe with quotes; Simple: 39; Double: 34; ///' + printlog "create textframe with quotes; Simple: 39; Double: 34;" hTextrahmenErstellen ( "Hallo",20,20,60,30) - '/// Insert a third slide ///' + printlog "Insert a third slide" InsertSlide sleep 2 hTypekeys "<Pagedown>" sleep 2 - '/// Slide Show->Slide Transition ///' + printlog "Slide Show->Slide Transition" SlideShowSlideTransition sleep 2 - '/// The 'Slide Transition' in the right 'Tasks' Pane has to come up ///' + printlog "The 'Slide Transition' in the right 'Tasks' Pane has to come up" Kontext "Tasks" - '/// Select every entry in the Listbox 'Apply to Selected Slides' ///' - '/// Then select the next Speed for Transition and retest all the effects ///' - '/// Redo until all effects has been tested with all speeds ///' + printlog "Select every entry in the Listbox 'Apply to Selected Slides'" + printlog "Then select the next Speed for Transition and retest all the effects" + printlog "Redo until all effects has been tested with all speeds" lala = TransitionApplyToSelectedSlide.GetItemCount Printlog "Count of effects : " + TransitionApplyToSelectedSlide.GetItemCount Printlog "Count of Speeds : " + TransitionSpeed.GetItemCount @@ -759,7 +757,7 @@ testcase tiPengineSlideTransition Next iCount Next b Printlog "Count of Sounds : " + TransitionSound.GetItemCount - '/// One Entry of the Listbox 'Sound' is 'Other sound...', select it ///' + printlog "One Entry of the Listbox 'Sound' is 'Other sound...', select it" ' iCount = TransitionSound.GetItemCount TransitionSound.TypeKeys "<HOME>" i = 0 @@ -770,11 +768,11 @@ testcase tiPengineSlideTransition Soundposition = TransitionSound.GetSelIndex kontext "OeffnenDlg" if (OeffnenDlg.Exists (5)) then - '/// Read all entries in Listbox 'File type' ///' + printlog "Read all entries in Listbox 'File type'" for i = 1 to Dateityp.getItemCount printlog "" + i + ":" + Dateityp.getItemText(i) next i - '/// cancel dialog 'Open' ///' + printlog "cancel dialog 'Open'" sleep 1 OeffnenDlg.cancel kontext "Tasks" @@ -792,21 +790,21 @@ testcase tiPengineSlideTransition sleep 5 kontext "Tasks" - '/// check checkbox 'Automatically after' ///' + printlog "check checkbox 'Automatically after'" TransitionAutomaticallyAfter.Check sleep 5 - '/// press key 'Page Up' in box ///' + printlog "press key 'Page Up' in box" TransitionAutomaticallyAfterTime.TypeKeys "<PageUp>" sleep 5 - '/// check the standard checkbox 'On mouse click' ///' + printlog "check the standard checkbox 'On mouse click'" TransitionOnMouseClick.Check sleep 5 - '/// press button 'Apply to All Slides' ///' + printlog "press button 'Apply to All Slides'" TransitionApplyToAllSlides.Click sleep 5 - '/// press button 'Play' ///' + printlog "press button 'Play'" TransitionPlay.Click - '/// press button 'Slide Show' ///' + printlog "press button 'Slide Show'" sleep (10) TransitionSlideShow.Click sleep (3) @@ -827,17 +825,17 @@ testcase tiPengineSlideTransition endif kontext "Tasks" - '/// uncheck and check Checkbox 'Automatic Preview' ///' - '/// default is checked ///' + printlog "uncheck and check Checkbox 'Automatic Preview'" + printlog "default is checked" if (NOT TransitionAutomaticPreview.IsChecked) then warnlog "Impress:Tasks Pane:Slide Transition: Automatic preview has to be checked by default, wasn't!" endif TransitionAutomaticPreview.UnCheck sleep 1 TransitionAutomaticPreview.Check - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineSlideTransition 'testcase ' Two different objects for two different effects. Does it work? @@ -849,9 +847,10 @@ endcase ' Save file, close, open again and see if everything is as it were. (Random effects) 'Endcase -'######################################################################## +'------------------------------------------------------------------------------- testcase tiPengineTabpageEntrance2 + dim bError as boolean dim e as integer dim d as integer @@ -868,21 +867,21 @@ testcase tiPengineTabpageEntrance2 dim StartName1 as string dim PropertyName1 as string -'/// open application ///' -Call hNewDocument -'/// create textbox with text ///' -Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) -'/// Slide Show->Custom Animation... ///' -SlideShowCustomAnimation - Kontext "Tasks" - '/// Uncheck AutomaticPreview ///' - EffectAutomaticPreview.UnCheck - '/// click button 'Add...' ///' - EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' - kontext + printlog "open application" + Call hNewDocument + printlog "create textbox with text" + Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) + printlog "Slide Show->Custom Animation..." + SlideShowCustomAnimation + Kontext "Tasks" + printlog "Uncheck AutomaticPreview" + EffectAutomaticPreview.UnCheck + printlog "click button 'Add...'" + EffectAdd.click + printlog "Dialog 'Custom Animation' comes up" + kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then @@ -927,7 +926,8 @@ SlideShowCustomAnimation Printlog "Presentation didn't end. Error?" endif kontext "TabEntrance" - Effects.TypeKeys "<DOWN>", e '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e p = Effects.GetSelIndex If p = d Then e = i Next e @@ -945,12 +945,12 @@ SlideShowCustomAnimation Next o kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -962,15 +962,16 @@ SlideShowCustomAnimation endif kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabpageEntrance2 '------------------------------------------------------------------------------------------------------------------------------------------------------ testcase tiPengineTabPageEmphasis2 + dim bError as boolean dim e as integer dim d as integer @@ -987,21 +988,21 @@ testcase tiPengineTabPageEmphasis2 dim StartName1 as string dim PropertyName1 as string -'/// open application ///' -Call hNewDocument -'/// create textbox with text ///' -Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) -'/// Slide Show->Custom Animation... ///' -SlideShowCustomAnimation + printlog "open application" + Call hNewDocument + printlog "create textbox with text" + Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) + printlog "Slide Show->Custom Animation..." + SlideShowCustomAnimation Kontext "Tasks" - '/// Uncheck AutomaticPreview ///' + printlog "Uncheck AutomaticPreview" EffectAutomaticPreview.UnCheck - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Emphasis ///' + printlog "Switch to TabPage: Emphasis" kontext active.setPage(TabEmphasis) kontext "TabEmphasis" @@ -1049,7 +1050,8 @@ SlideShowCustomAnimation active.setPage(TabEmphasis) Printlog "Testing effects in - TabEmphasis" kontext "TabEmphasis" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e + 1 p = Effects.GetSelIndex If p = d Then e = i 'p > 2 AND Next e @@ -1074,12 +1076,12 @@ SlideShowCustomAnimation endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -1087,15 +1089,16 @@ SlideShowCustomAnimation bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabPageEmphasis2 '------------------------------------------------------------------------------------ testcase tiPengineTabPageExit2 + dim bError as boolean dim e as integer dim d as integer @@ -1112,21 +1115,21 @@ testcase tiPengineTabPageExit2 dim StartName1 as string dim PropertyName1 as string -'/// open application ///' +printlog "open application" Call hNewDocument -'/// create textbox with text ///' +printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) -'/// Slide Show->Custom Animation... ///' +printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// Uncheck AutomaticPreview ///' + printlog "Uncheck AutomaticPreview" EffectAutomaticPreview.UnCheck - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" if TabExit.exists(5) then @@ -1178,15 +1181,16 @@ SlideShowCustomAnimation Printlog "Presentation didn't end. Error?" endif kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e + 1 p = Effects.GetSelIndex If p = d Then e = i 'p > 2 AND Next e kontext - '/// Switch to TabPage: Exit ///' + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" e = 0 @@ -1208,12 +1212,12 @@ SlideShowCustomAnimation endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -1221,15 +1225,16 @@ SlideShowCustomAnimation bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiPengineTabPageExit2 '-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- testcase tiPengineTabPageMotionPaths2 + dim bError as boolean dim e as integer dim d as integer @@ -1246,21 +1251,21 @@ testcase tiPengineTabPageMotionPaths2 dim StartName1 as string dim PropertyName1 as string - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation Kontext "Tasks" - '/// Uncheck AutomaticPreview ///' + printlog "Uncheck AutomaticPreview" EffectAutomaticPreview.UnCheck - '/// click button 'Add...' ///' + printlog "click button 'Add...'" EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" if TabMotionPaths.exists(5) then @@ -1302,15 +1307,16 @@ testcase tiPengineTabPageMotionPaths2 Printlog "Presentation didn't end. Error?" endif kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" - Effects.TypeKeys "<DOWN>", e + 1 '/// Select the next entry ///' + printlog "Select the next entry" + Effects.TypeKeys "<DOWN>", e + 1 p = Effects.GetSelIndex If p = d Then e = i 'p > 2 AND Next e kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" @@ -1332,12 +1338,12 @@ testcase tiPengineTabPageMotionPaths2 warnlog "Impress:Tasks Pane:Custom Animation:TabMotionPaths tabPage doesn't work." endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -1345,12 +1351,10 @@ testcase tiPengineTabPageMotionPaths2 bError = false kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase - -'-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - +endcase 'tiPengineTabPageMotionPaths2 +'--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_pengine2.inc b/testautomation/graphics/optional/includes/impress/i_pengine2.inc index f1fa908cf7b7..56d15f6eee37 100644 --- a/testautomation/graphics/optional/includes/impress/i_pengine2.inc +++ b/testautomation/graphics/optional/includes/impress/i_pengine2.inc @@ -30,48 +30,41 @@ '* short description : Tests the Presentation-Engines effects '* '******************************************************************* -'* -' #1 tiPengineAnimationEffectsPreview -' #1 tiPengineAnimationEffectsOptions -' #1 tiPengineAllShapesAndEffects -' #1 tiPengine2ObjectsGetsEffects -'* -'\******************************************************************* testcase tiPengineAnimationEffectsPreview dim bError as boolean - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create textbox with text ///' + printlog "create textbox with text" Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) - '/// Slide Show->Custom Animation... ///' + printlog "Slide Show->Custom Animation..." SlideShowCustomAnimation - Kontext "Tasks" - '/// click button 'Add...' ///' - EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' - kontext - '/// Switch to TabPage: Entrance ///' - active.setPage(TabEntrance) - kontext "TabEntrance" - if TabEntrance.exists(5) then - DialogTest(TabEntrance) - TestAnimations - '/// Switch to TabPage: Emphasis ///' - kontext - active.setPage(TabEmphasis) - kontext "TabEmphasis" - if TabEmphasis.exists(5) then - DialogTest(TabEmphasis) - TestAnimations - else - bError = true - warnlog "Impress:Tasks Pane:Custom Animation:TabEmphasis tabPage doesn't work." - endif - kontext - - '/// Switch to TabPage: Exit ///' + Kontext "Tasks" + printlog "click button 'Add...'" + EffectAdd.click + printlog "Dialog 'Custom Animation' comes up" + kontext + printlog "Switch to TabPage: Entrance" + active.setPage(TabEntrance) + kontext "TabEntrance" + if TabEntrance.exists(5) then + DialogTest(TabEntrance) + TestAnimations + printlog "Switch to TabPage: Emphasis" + kontext + active.setPage(TabEmphasis) + kontext "TabEmphasis" + if TabEmphasis.exists(5) then + DialogTest(TabEmphasis) + TestAnimations + else + bError = true + warnlog "Impress:Tasks Pane:Custom Animation:TabEmphasis tabPage doesn't work." + endif + kontext + + printlog "Switch to TabPage: Exit" active.setPage(TabExit) kontext "TabExit" if TabExit.exists(5) then @@ -83,7 +76,7 @@ testcase tiPengineAnimationEffectsPreview endif kontext - '/// Switch to TabPage: Motion Paths ///' + printlog "Switch to TabPage: Motion Paths" active.setPage(TabMotionPaths) kontext "TabMotionPaths" if TabMotionPaths.exists(5) then @@ -95,12 +88,12 @@ testcase tiPengineAnimationEffectsPreview endif kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if TabEntrance.exists(5) then Effects.Select 4 - '/// Close dialog 'Custom Animation' with 'OK' ///' + printlog "Close dialog 'Custom Animation' with 'OK'" TabEntrance.OK else warnlog "Error when switching Tab" @@ -112,12 +105,12 @@ testcase tiPengineAnimationEffectsPreview endif Kontext "Tasks" if (NOT bError) then - '/// click button 'Change...' ///' + printlog "click button 'Change...'" EffectChange.click - '/// Dialog 'Custom Animation' comes up ///' + printlog "Dialog 'Custom Animation' comes up" kontext - '/// Switch to TabPage: Entrance ///' + printlog "Switch to TabPage: Entrance" active.setPage(TabEntrance) kontext "TabEntrance" if (NOT TabEntrance.exists(5)) then @@ -129,7 +122,7 @@ testcase tiPengineAnimationEffectsPreview if EffectProperty.IsVisible then EffectProperty.GetItemCount endif - '/// CLick on button '...' (Options) ///' + printlog "CLick on button '...' (Options)" EffectOptions.Click kontext "TabEffect" if TabEffect.Exists(5) then @@ -137,7 +130,7 @@ testcase tiPengineAnimationEffectsPreview Sound.GetItemCount AfterAnimation.GetItemCount - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext Active.SetPage TabTiming kontext "TabTiming" @@ -155,7 +148,7 @@ testcase tiPengineAnimationEffectsPreview warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: Timing TabPage didn't work." endif - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext active.setPage TabTextAnimation kontext "TabTextAnimation" @@ -193,17 +186,18 @@ testcase tiPengineAnimationEffectsPreview sleep (2) kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click endif sleep (2) - '/// close application ///' + printlog "close application" Call hCloseDocument endcase 'tiPengineAnimationEffectsPreview '------------------------------------------------------------------------------ testcase tiPengineAnimationEffectsOptions + dim bError as boolean dim e as integer dim d as integer @@ -222,28 +216,28 @@ testcase tiPengineAnimationEffectsOptions dim StartName1 as string dim PropertyName1 as string -'/// open application ///' -Call hNewDocument -'/// create textbox with text ///' -Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) -'/// Slide Show->Custom Animation... ///' -SlideShowCustomAnimation - '/// Dialog 'Custom Animation' comes up ///' - Kontext "Tasks" - '/// Click button 'Add...' to add an effect to the text ///' - EffectAdd.click - kontext - '/// Switch to TabPage: Entrance ///' - active.setPage(TabEntrance) - kontext "TabEntrance" - if TabEntrance.exists(5) then + printlog "open application" + Call hNewDocument + printlog "create textbox with text" + Call hTextrahmenErstellen ("Test text to test text effects", 35, 35, 70, 70 ) + printlog "Slide Show->Custom Animation..." + SlideShowCustomAnimation + printlog "Dialog 'Custom Animation' comes up" + Kontext "Tasks" + printlog "Click button 'Add...' to add an effect to the text" + EffectAdd.click + kontext + printlog "Switch to TabPage: Entrance" + active.setPage(TabEntrance) + kontext "TabEntrance" + if TabEntrance.exists(5) then AutomaticPreview.UnCheck Printlog "Testing effects in - TabEntrance" i = Effects.GetItemCount p = 7555 Effects.TypeKeys "<HOME DOWN>" Randomize - '/// Choose ten random effects, and test them. ///' + printlog "Choose ten random effects, and test them." For e = 1 to 10 randomize for y = 1 to 1 @@ -270,7 +264,7 @@ SlideShowCustomAnimation Warnlog "Something wrong when exiting Impress:Tasks Pane:Custom Animation: ... (options)" endif kontext "TabEntrance" - '/// Select the next entry ///' + printlog "Select the next entry" Effects.TypeKeys "<DOWN>", e p = Effects.GetSelIndex If p = d Then e = i @@ -300,27 +294,28 @@ SlideShowCustomAnimation endif kontext "Tasks" EffectAutomaticPreview.Check - '/// click button 'Remove' ///' + printlog "click button 'Remove'" EffectRemove.Click - '/// close application ///' + printlog "close application" Call hCloseDocument endcase 'tiPengineAnimationEffectsOptions -'------------------------------------------------------------------------------------------------------------------------------------------------------ +'------------------------------------------------------------------------------- testcase tiPengineAllShapesAndEffects - dim sFileName as string -'/// the Presentation-Engine consists of showing the presentation, with all it's effects. ///' + dim sFileName as string - '/// Create a new presentation. ///' + printlog "the Presentation-Engine consists of showing the presentation, with all it's effects." + + printlog "Create a new presentation." Call hNewDocument Sleep (1) - '/// Open the test-file. ///' + printlog "Open the test-file." Call hFileOpen (gTesttoolpath + "graphics\required\input\allshapes2.odp") 'effects.odp") - '/// Start the slideshow. ///' + printlog "Start the slideshow." Call hTypeKeys "<F5>" sleep (10) kontext "DocumentPresentation" @@ -339,14 +334,14 @@ testcase tiPengineAllShapesAndEffects Call hCloseDocument sleep (1) - '/// Open the test-file. ///' + printlog "Open the test-file." Call hFileOpen (gTesttoolpath + "graphics\required\input\effects.odp") Sleep (10) - '/// Start the slideshow. ///' + printlog "Start the slideshow." CALL hTypeKeys "<F5>" Sleep (10) - '/// Press "Space" again, to continue with slide two. ///' + printlog "Press Space again, to continue with slide two." kontext "DocumentPresentation" while DocumentPresentation.exists() DocumentPresentation.TypeKeys "<SPACE>" @@ -362,14 +357,15 @@ testcase tiPengineAllShapesAndEffects kontext "DocumentImpress" end if -'/// Close Application ///' +printlog "Close Application" Call hCloseDocument Printlog "Finished Optional-test for Presentation-Engine" endcase 'tiPengineAllShapesAndEffects -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- +'------------------------------------------------------------------------------- testcase tiPengine2ObjectsGetsEffects + dim i as integer dim t as integer dim q as integer @@ -385,7 +381,6 @@ testcase tiPengine2ObjectsGetsEffects kontext "Toolbar" sleep (1) - printlog "insert a Smiley." printlog "From the toolbar: Insert three objects:" printlog "insert a Smiley." kontext "Toolbar" @@ -469,9 +464,7 @@ testcase tiPengine2ObjectsGetsEffects warnlog "Error when switching Tab" end if Kontext "Tasks" - printlog "Effect no 3" - printlog "Insert new slide" InsertSlide Printlog "Inserted new Slide" @@ -507,7 +500,6 @@ testcase tiPengine2ObjectsGetsEffects Kontext "Tasks" printlog "Effect no 4" - printlog "Click button 'Add...'" EffectAdd.click printlog "Dialog 'Custom Animation' comes up" @@ -570,16 +562,19 @@ testcase tiPengine2ObjectsGetsEffects Printlog "Finished Optional-test for Presentation-Engine" endcase 'tiPengine2ObjectsGetsEffects -'------------------------------------------------------------------------------------------------------------------------------------------------------ +'------------------------------------------------------------------------------- Function TestAnimations - '/// select in the listbox 'Effects' the second entry///' + + printlog "Function: TestAnimations: select in the listbox 'Effects' the second entry" + Dim i as Integer Dim s as Integer Dim q as Integer Dim e as Integer Dim o as Integer Dim p as Integer + i = Effects.GetItemCount s = Speed.GetItemCount AutomaticPreview.Check @@ -588,7 +583,7 @@ Function TestAnimations If e <> p Then if AutomaticPreview.isChecked = TRUE then sleep 1 Printlog "Effect has position Nr: " + Effects.GetSelIndex + ". Name of effect: " + Effects.GetSelText - '/// Select the next entry ///' + printlog "Select the next entry" Effects.TypeKeys "<DOWN>" p = Effects.GetSelIndex Else @@ -606,4 +601,4 @@ Function TestAnimations sleep 1 AutomaticPreview.Check Kontext -end Function +end Function
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_slidecopy.inc b/testautomation/graphics/optional/includes/impress/i_slidecopy.inc index 92283b35a369..4de5505fe0a1 100644 --- a/testautomation/graphics/optional/includes/impress/i_slidecopy.inc +++ b/testautomation/graphics/optional/includes/impress/i_slidecopy.inc @@ -51,6 +51,7 @@ testcase tiSlideCopyNewPresentation sleep 1 try Verbinder.TearOff + printlog "Tearing off Connector bar.." catch warnlog "bug for GH from FHA; .tearoff doesnt tell success" endcatch @@ -93,19 +94,21 @@ testcase tiSlideCopyNewPresentation sleep 2 try StarShapes.TearOff + printlog "Tearing off StarShapes Bar..." catch warnlog( "<StarShapes.TearOff> failed" ) goto endsub endcatch kontext "StarShapes" + sleep 2 if ( StarShapes.exists( 2 ) ) then StarShapesDoorplate.click else warnlog( "<StarShapesDoorplate> could not be clicked" ) endif - sleep (3) + sleep (5) gMouseDown (40,40) gMouseMove (40,40,60,60) gMouseUp (60,60) @@ -169,7 +172,7 @@ testcase tiSlideCopyNewPresentation kontext "DocumentImpress" hMouseClick DocumentImpress, 90, 90 '---------------------------------------------------------------------------3 - '/// Copy the slide to the clipboard ///' + printlog "Copy the slide to the clipboard" kontext "Slides" SlidesControl.TypeKeys "<PAGEUP>" sleep (1) @@ -182,16 +185,16 @@ testcase tiSlideCopyNewPresentation Call hCloseDocument Goto Endsub endif - '/// Close the presentation-window ///' + printlog "Close the presentation-window" Call hCloseDocument - '/// Open a new presentation ///' + printlog "Open a new presentation" Call hNewDocument - '/// Paste the slide from the clipboard ///' + printlog "Paste the slide from the clipboard!" kontext "Slides" hUseAsyncSlot( "EditPaste" ) - '/// Delete the first slide ///' + printlog "Delete the first slide" hUseAsyncSlot( "EditDeleteSlide" ) - '/// Check if all three objects exists, and has the right values ///' + printlog "Check if all three objects exists, and has the right values" kontext "DocumentImpress" hTypeKeys "<ESCAPE>" hTypeKeys "<TAB>", 1 'Select the first object. @@ -263,7 +266,7 @@ testcase tiSlideCopyNewPresentation Warnlog "Wrong object or object-name! The name found was: " + value13 endif - '/// Close the bars we opened before. ///' + printlog "Close the bars we opened before." kontext "Connectorsbar" if Connectorsbar.Exists then Connectorsbar.Close kontext "SymbolShapes" @@ -271,7 +274,7 @@ testcase tiSlideCopyNewPresentation kontext "StarShapes" if StarShapes.Exists then StarShapes.Close - '/// Close Presentation. End testcase ///' + printlog "Close Presentation. End testcase" Call hCloseDocument endcase 'tiSlideCopyNewPresentation @@ -531,17 +534,17 @@ testcase tiSlideCopyPasteSpecial Dim value1 as string Dim value2 as string Dim value3 as string - '/// Copies slide, and pastes it with "Paste Special", ///' - '/// just to see if the office can handle it ///' - '/// Make new presentation ///' + printlog "Copies slide, and pastes it with Paste Special" + printlog "just to see if the office can handle it" + printlog "Make new presentation" Call hNewDocument - '/// Insert three objects: Connector, Door-plate, and Smiley ///' + printlog "Insert three objects: Connector, Door-plate, and Smiley" - '1 Insert Connector. + printlog "Insert Connector" kontext "Toolbar" sleep 1 try - Verbinder.TearOff ' insert connector + Verbinder.TearOff catch warnlog "bug for GH from FHA; .tearoff doesnt tell success" endcatch @@ -556,11 +559,11 @@ testcase tiSlideCopyPasteSpecial kontext "DocumentImpress" hMouseClick DocumentImpress, 90, 90 - '2 Insert Door-plate. + printlog "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 @@ -575,11 +578,11 @@ testcase tiSlideCopyPasteSpecial 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 @@ -591,7 +594,7 @@ testcase tiSlideCopyPasteSpecial gMouseMove (70,70,89,89) gMouseUp (89,89) - '/// Copy the slide to the clipboard ///' + printlog "Copy the slide to the clipboard" kontext "Slides" SlidesControl.TypeKeys "<PAGEUP>" SlidesControl.TypeKeys "<SHIFT F10>" @@ -603,12 +606,12 @@ testcase tiSlideCopyPasteSpecial Goto Endsub endif - '/// Try to paste special. And check that the office still stays alive ///' + printlog "Try to paste special. And check that the office still stays alive" EditPasteSpecial kontext "InhaltEinfuegen" InhaltEinfuegen.OK - '/// Close the bars we opened before. ///' + printlog "Close the bars we opened before" kontext "Connectorsbar" if Connectorsbar.Exists then Connectorsbar.Close kontext "SymbolShapes" @@ -618,12 +621,13 @@ testcase tiSlideCopyPasteSpecial sleep 1 kontext "DocumentImpress" - '/// Close Presentation. End testcase ///' + printlog "Close Presentation. End testcase" Call hCloseDocument endcase 'tiSlideCopyPasteSpecial '----------------------------------------------------------------------- + testcase tiSlideCopyInSlideSorter qaerrorlog "#i58418#: Pasting in slide sorter sets slide to wrong position" goto endsub @@ -631,10 +635,10 @@ testcase tiSlideCopyInSlideSorter Dim value1 as string Dim value2 as string Dim value3 as string - '/// Copies slides within the slidesorter, and makes sure they are pasted on the correct position ///' - '/// Make new presentation ///' + printlog "Copies slides within the slidesorter, and makes sure they are pasted on the correct position" + printlog "Make new presentation" Call hNewDocument - '/// Insert an object: Connector, on the first slide ///' + printlog "Insert an object: Connector, on the first slide" kontext "Toolbar" sleep 1 try @@ -653,12 +657,9 @@ testcase tiSlideCopyInSlideSorter gMouseMove (10,10,30,30) gMouseUp (30,30) Printlog " Inserted a Connector-object." - 'Rename object hTypeKeys "<ESCAPE>" hTypeKeys "<TAB>", 1 DocumentImpress.TypeKeys "<SHIFT F10>" - - 'Rename if hMenuFindSelect(27027, true, 14) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -668,15 +669,14 @@ testcase tiSlideCopyInSlideSorter NameField.SetText "First" NameDlgObject.OK sleep 1 - Printlog " Renamed a the object to 'First'" + Printlog "Renamed a the object to 'First'" sleep 3 - '/// Rename slide to "1" ///' + printlog "Rename slide to 1" kontext "Slides" SlidesControl.TypeKeys "<PAGEUP>" SlidesControl.TypeKeys "<SHIFT F10>" sleep 3 - 'Rename if hMenuFindSelect(27268, true, 2) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -687,25 +687,24 @@ testcase tiSlideCopyInSlideSorter NameField.SetText "1" NameDlgPage.OK sleep 1 - Printlog " Renamed the Slide to '1'" + Printlog "Renamed the Slide to '1'" kontext "DocumentImpress" hMouseClick DocumentImpress, 90, 90 sleep 3 - '/// Insert a new slide ///' + printlog "Insert a new slide" kontext "Slides" SlidesControl.TypeKeys "<TAB><PAGEDOWN>" SlidesControl.OpenContextMenu sleep 3 - 'Insert slide if hMenuFindSelect(27014, true, 1) = false then Warnlog "Context-Menu-entry `Insert slide` was not found. Therefore the test ends." Call hCloseDocument Goto Endsub endif - Printlog " Inserted a new slide." - '/// Insert an object: Door-plate, on the second slide ///' + Printlog "Inserted a new slide." + printlog "Insert an object: Door-plate, on the second slide" kontext "Toolbar" sleep 1 try @@ -721,13 +720,10 @@ testcase tiSlideCopyInSlideSorter gMouseDown (40,40) gMouseMove (40,40,60,60) gMouseUp (60,60) - Printlog " Inserted a Door-Plate-object." - + Printlog "Inserted a Door-Plate-object." hTypeKeys "<ESCAPE>" hTypeKeys "<TAB>", 2 hTypeKeys "<SHIFT F10>" - - ' Rename if hMenuFindSelect(27027, true, 15) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -738,16 +734,15 @@ testcase tiSlideCopyInSlideSorter NameField.SetText "Second" NameDlgObject.OK sleep 1 - Printlog " Renamed a the object to 'Second'" + Printlog "Renamed a the object to 'Second'" kontext "DocumentImpress" hMouseClick DocumentImpress, 90, 90 sleep 2 - '/// Rename slide to "2" ///' + printlog "Rename slide to 2" kontext "Slides" SlidesControl.OpenContextMenu sleep 3 - ' Rename if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -759,20 +754,18 @@ testcase tiSlideCopyInSlideSorter sleep 1 Printlog " Renamed the slide '2'" - '/// Insert a new slide ///' + printlog "Insert a new slide" kontext "Slides" Slidescontrol.TypeKeys "<PAGEDOWN>", 2 Slidescontrol.TypeKeys "<SHIFT F10>" sleep 3 - 'Insert slide if hMenuFindSelect(27014, true, 1) = false then Warnlog "Context-Menu-entry `Insert slide` was not found. Therefore the test ends." Call hCloseDocument Goto Endsub endif - Printlog " Inserted a new slide." - - '/// Insert an object: Smiley, on the second slide ///' + Printlog "Inserted a new slide." + printlog "Insert an object: Smiley, on the second slide" kontext "Toolbar" sleep 1 try @@ -788,13 +781,9 @@ testcase tiSlideCopyInSlideSorter gMouseMove (70,70,89,89) gMouseUp (89,89) Printlog " Inserted a Smiley-object." - - 'Rename object hTypeKeys "<ESCAPE>" hTypeKeys "<TAB>", 2 hTypeKeys "<SHIFT F10>" - - 'Choose rename. if hMenuFindSelect(27027, true, 15) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -804,13 +793,11 @@ testcase tiSlideCopyInSlideSorter NameField.SetText "Third" NameDlgObject.OK Printlog " Renamed a the object to 'Third'" - - '/// Rename slide to "3" ///' + printlog "Rename slide to 3" kontext "Slides" Slidescontrol.TypeKeys "<PAGEDOWN>", 2 SlidesControl.OpenContextMenu sleep 3 - ' Rename if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -823,7 +810,7 @@ testcase tiSlideCopyInSlideSorter sleep 1 Printlog " Renamed the slide '3'" - '/// Close the bars we opened before. ///' + printlog "Close the bars we opened before." kontext "Connectorsbar" if Connectorsbar.Exists then Connectorsbar.Close kontext "SymbolShapes" @@ -831,47 +818,46 @@ testcase tiSlideCopyInSlideSorter kontext "StarShapes" if StarShapes.Exists then StarShapes.Close - '/// Change to Slidesorter ///' + printlog "Change to Slidesorter" kontext "DocumentImpress" ViewSlideSorter - '/// Now we have changed view to the slidesorter ///' + printlog "Now we have changed view to the slidesorter" kontext "Slides" - Printlog " Changed view to 'SlideSorter'" - '/// Make sure the last slide is selcted ///' + Printlog "Changed view to 'SlideSorter'" + printlog "Make sure the last slide is selcted" SlidesControl.TypeKeys "<TAB>" SlidesControl.TypeKeys "<PAGEDOWN>", 3 - '/// Cut the last slide ///' + printlog "Cut the last slide" SlidesControl.TypeKeys "<MOD1 X>" - '/// Make sure the first slide is selected ///' + printlog "Make sure the first slide is selected" SlidesControl.TypeKeys "<TAB>" SlidesControl.TypeKeys "<PAGEUP>", 2 sleep 1 - '/// Paste the Slide ///' + printlog "Paste the Slide" kontext "Slides" SlidesControl.TypeKeys "<MOD1 V>" - '/// choose "Before" as specification for where + printlog "choose Before as specification for where" Kontext "InsertPaste" if InsertPaste.Exists(3) then Before.Check InsertPaste.OK Printlog " Pasted slide 'Before'" else - warnlog " Problem when copying/pasting slide." + warnlog "Problem when copying/pasting slide." endif - '/// Check where the slide ended up ///' + printlog "Check where the slide ended up" kontext "Slides" SlidesControl.TypeKeys "<TAB>" SlidesControl.TypeKeys "<PAGEUP>", 3 'to get to the first slide SlidesControl.TypeKeys "<SHIFT F10>" sleep 3 - ' Rename if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -888,12 +874,14 @@ testcase tiSlideCopyInSlideSorter sleep 1 kontext "Slides" - '/// Choose the slide in the middle (named "1") ///' + printlog "Choose the slide in the middle (named 1)" SlidesControl.TypeKeys "<TAB>" - SlidesControl.TypeKeys "<PAGEDOWN>", 3 'to get to the last slide - SlidesControl.TypeKeys "<PAGEUP>" 'to go back one step + printlog "to get to the last slide" + SlidesControl.TypeKeys "<PAGEDOWN>", 3 + printlog "to go back one step" + SlidesControl.TypeKeys "<PAGEUP>" SlidesControl.OpenContextMenu (true) - ' Check the name of that slide (via Rename) + printlog "Check the name of that slide (via Rename)" if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -910,7 +898,7 @@ testcase tiSlideCopyInSlideSorter sleep 1 kontext "Slides" - '/// Cut the slide ///' + printlog "Cut the slide" SlidesControl.TypeKeys "<SHIFT F10>" sleep 3 if hMenuFindSelect(5710, true, 10) = false then @@ -919,18 +907,18 @@ testcase tiSlideCopyInSlideSorter Goto Endsub endif - '/// Make sure we have selected the last slide ///' + printlog "Make sure we have selected the last slide" SlidesControl.TypeKeys "<TAB>" SlidesControl.TypeKeys "<PAGEDOWN>", 2 - '/// Place the mousepointer to the left of the first slide ///' + printlog "Place the mousepointer to the left of the first slide" sleep 1 kontext "Slides" SlidesControl.MouseMove 2, 3 SlidesControl.OpenContextMenu true sleep 3 - '/// Paste the Slide ///' + printlog "Paste the Slide" if hMenuFindSelect(5712, true, 12) = false then Warnlog "Context-Menu-entry `Paste` were not found. Therefore the test ends." Call hCloseDocument @@ -938,7 +926,7 @@ testcase tiSlideCopyInSlideSorter endif sleep 1 - '/// Choose "After" as specification for where ///' + printlog "Choose After as specification for where" Kontext "InsertPaste" if InsertPaste.Exists(3) then After.Check @@ -948,13 +936,15 @@ testcase tiSlideCopyInSlideSorter warnlog " Problem when copying/pasting slide." endif - '/// Check where the slide ended up. Should have showed up at the last position ///' + printlog "Check where the slide ended up. Should have showed up at the last position" kontext "Slides" SlidesControl.TypeKeys "<TAB>" - SlidesControl.TypeKeys "<PAGEDOWN>", 3 'to get to the last slide - SlidesControl.TypeKeys "<SHIFT F10>" '= open context menu + printlog "to get to the last slide" + SlidesControl.TypeKeys "<PAGEDOWN>", 3 + printlog "open context menu" + SlidesControl.TypeKeys "<SHIFT F10>" sleep 3 - ' Rename + printlog "Rename" if hMenuFindSelect(27268, true, 3) = false then Warnlog "Context-Menu-entry `Rename` was not found. Therefore the test ends." Call hCloseDocument @@ -970,10 +960,8 @@ testcase tiSlideCopyInSlideSorter NameDlgPage.OK sleep 1 - '/// Close Presentation. End testcase ///' + printlog "Close Presentation. End testcase" Call hCloseDocument endcase 'tiSlideCopyInSlideSorter '------------------------------------------------------------------------ - -'TODO FHA - Check the objects after pasting them. diff --git a/testautomation/graphics/optional/includes/impress/i_slidelayer.inc b/testautomation/graphics/optional/includes/impress/i_slidelayer.inc index 441e0a323099..508394144663 100644 --- a/testautomation/graphics/optional/includes/impress/i_slidelayer.inc +++ b/testautomation/graphics/optional/includes/impress/i_slidelayer.inc @@ -30,75 +30,69 @@ '* short description : '* '********************************************************************* -' #1 tiInsertExpandSlide -' #1 tiInsertSummarySlide -' #1 tiFormatSeitenlayout -' #1 t114174 -' #1 t111862 -'\******************************************************************** ' Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") -' Inhalt.SetText ConvertPath (gTesttoolPath + "graphics\required\input\leer.sxd") '/// auto.sdd choosen ///' +' Inhalt.SetText ConvertPath (gTesttoolPath + "graphics\required\input\leer.sxd") '------------------------------------------------------------------------------- testcase tiInsertExpandSlide - - dim i,x as integer - dim sTemp as string - dim b116350 as boolean - - '/// open application ///' - Call hNewDocument - Call sSelectEmptyLayout - '/// create presupposition /// - '///+ View->Master View->Outline View ///' - ViewWorkspaceOutlineView - Sleep 1 - Kontext "DocumentImpressOutlineView" - '///+ create a slide with some levels...and some more slides with just one level... ///' - '///+ it should look like this: ///' - '///+-------------------------------------------------- ///' - '///+ Slide 1///' - '///+ - A ///' - '///+ - - B///' - '///+ - - - C///' - '///+ - - - - D///' - '///+ - - - - - - F///' - '///+ - B///' - '///+ - C///' - '///+ - D///' - '///+ Slide 2 ///' - '///+ Slide 3 ///' - '///+ Slide 4 ///' - '///+ Slide 5 ///' - '///+-------------------------------------------------- ///' - DocumentImpressOutlineView.TypeKeys "Slide 1" - for i = 1 to 6 - DocumentImpressOutlineView.TypeKeys "<return><tab>" - DocumentImpressOutlineView.TypeKeys chr(64+i) - next i - DocumentImpressOutlineView.TypeKeys "<return>" - DocumentImpressOutlineView.TypeKeys ("<shift tab>",5) - for i = 1 to 3 - DocumentImpressOutlineView.TypeKeys chr(65+i) - DocumentImpressOutlineView.TypeKeys "<return>" - next i - DocumentImpressOutlineView.TypeKeys ("<shift tab>") - for i = 2 to 5 - DocumentImpressOutlineView.TypeKeys "Slide " + i - DocumentImpressOutlineView.TypeKeys "<return>" - next i - DocumentImpressOutlineView.TypeKeys "<backspace>" - '///+ View->Master View->Drawing View ///' - ViewWorkspaceDrawingView - Sleep 1 - '///+ there have to be 5 slides now ///' - fGetSlideCount (5) - '/// goto the first slide ///' - hTypeKeys "<home>" - '///<b> Insert->Expand Slide </b>///' - InsertExpandSlide + dim i,x as integer + dim sTemp as string + dim b116350 as boolean + + printlog "open application " + Call hNewDocument + Call sSelectEmptyLayout + printlog "create presupposition" + printlog "View->Master View->Outline View " + ViewWorkspaceOutlineView + Sleep 1 + Kontext "DocumentImpressOutlineView" + 'create a slide with some levels...and some more slides with just one level... " + 'it should look like this: " + '-------------------------------------------------- " + 'Slide 1" + ' - A " + '- - B" + ' - - - C" + ' - - - - D" + ' - - - - - - F" + ' - B" + ' - C" + ' - D" + ' Slide 2 " + ' Slide 3 " + ' Slide 4 " + ' Slide 5 " + '-------------------------------------------------- " + DocumentImpressOutlineView.TypeKeys "Slide 1" + for i = 1 to 6 + DocumentImpressOutlineView.TypeKeys "<return><tab>" + DocumentImpressOutlineView.TypeKeys chr(64+i) + next i + DocumentImpressOutlineView.TypeKeys "<return>" + DocumentImpressOutlineView.TypeKeys ("<shift tab>",5) + for i = 1 to 3 + DocumentImpressOutlineView.TypeKeys chr(65+i) + DocumentImpressOutlineView.TypeKeys "<return>" + next i + DocumentImpressOutlineView.TypeKeys ("<shift tab>") + for i = 2 to 5 + DocumentImpressOutlineView.TypeKeys "Slide " + i + DocumentImpressOutlineView.TypeKeys "<return>" + next i + DocumentImpressOutlineView.TypeKeys "<backspace>" + printlog " View->Master View->Drawing View " + ViewWorkspaceDrawingView + Sleep 1 + printlog "there have to be 5 slides now " + fGetSlideCount (5) + + printlog "goto the first slide " + hTypeKeys "<home>" + printlog "Insert->Expand Slide" + InsertExpandSlide ' usually the content of the new pages is the same as the curren, there is a slide created for every part in the first outline level (gliederungsebene) Sleep 1 if (8 = fGetSlideCount (8)) then @@ -106,7 +100,7 @@ testcase tiInsertExpandSlide else warnLog "Bug with Insert Expand Slide" endif - '///+ check slide content ///' + printlog " check slide content " hTypeKeys ("<TAB><F2>" EditSelectAll EditCopy @@ -142,9 +136,9 @@ testcase tiInsertExpandSlide next i hTypeKeys "<escape><home>" - '///<b> Insert->Expand Slide </b>///' + printlog "Insert->Expand Slide" InsertExpandSlide - '/// And since the Second slide now should be named "B", we check that first ///' + printlog "And since the Second slide now should be named B, we check that first " hTypeKeys ("<TAB><F2>") EditSelectAll try @@ -190,7 +184,7 @@ testcase tiInsertExpandSlide EditSelectAll next i - '/// close application ///' + printlog "close application " Call hCloseDocument endcase 'tiInsertExpandSlide @@ -285,23 +279,29 @@ testcase tiFormatSeitenlayout qaerrorlog "outcommented due to bug" goto endsub - Printlog "Format/Page Layout" - Call hNewDocument '/// new impress document ///' - - FormatPage '/// format page ///' + Printlog "Format/Page Layout" + printlog "new impress document " + Call hNewDocument + + printlog "format page " + FormatPage Kontext "Tasks" sleep 5 - SetClipboard LayoutsPreview.GetText '/// get page name ///' - SeitenName.SetText "Test" '/// change page name ///' + printlog "get page name " + SetClipboard LayoutsPreview.GetText + printlog "change page name " + SeitenName.SetText "Test" sleep 1 - if Hintergrund.IsChecked=False Then '/// check background ///' + printlog "check background " + if Hintergrund.IsChecked=False Then Hintergrund.Check else Hintergrund.UnCheck if Hintergrund.IsChecked=False Then PrintLog " Background is deactivated" end if - - if ObjekteAufDemHintergrund.IsChecked = True Then '/// change status of objects on background ///' + + printlog "change status of objects on background " + if ObjekteAufDemHintergrund.IsChecked = True Then PrintLog " Object on background is activated" ObjekteAufDemHintergrund.UnCheck if ObjekteAufDemHintergrund.IsChecked = False Then PrintLog " Objects on background are deactivated" @@ -309,9 +309,11 @@ testcase tiFormatSeitenlayout ObjekteAufDemHintegrund.Check PrintLog " Object on background is activated" end if - Seitenlayout.OK '/// close dialog ///' + printlog "close dialog " + Seitenlayout.OK sleep 1 - FormatPage '/// reopen dialog ///' + printlog "reopen dialog " + FormatPage Kontext "LayoutsPreview" sleep 2 if GetClipboardText <> SeitenName.GetText Then @@ -320,7 +322,8 @@ testcase tiFormatSeitenlayout WarnLog " Page name is not correct" end if sleep 2 - LayoutsPreview.TypeKeys "<TAB>" '/// assign different page layout ///' + printlog "assign different page layout " + LayoutsPreview.TypeKeys "<TAB>" LayoutsPreview.TypeKeys "<DOWN>" ,2 LayoutsPreview.TypeKeys "<Return>" sleep 2 @@ -338,7 +341,8 @@ testcase tiFormatSeitenlayout sleep 3 DocumentImpress.MouseDoubleClick 25,60 sleep 3 - Kontext "GrafikEinfuegenDlg" '/// check in document if layout has changed ///' + printlog "check in document if layout has changed " + Kontext "GrafikEinfuegenDlg" sleep 2 if GrafikEinfuegenDlg.exists (5) then try @@ -361,13 +365,14 @@ testcase tiFormatSeitenlayout endif sleep 3 Kontext "DocumentImpress" - Call hCloseDocument '/// close document ///' + printlog "close document " + Call hCloseDocument endcase 'tiFormatSeitenlayout '------------------------------------------------------------------------------ testcase t114174 - '/// resulting from regression in #111862# ///' + printlog "resulting from regression in #111862# " dim sReference(2) as string dim sText(2) as string dim i as integer @@ -385,10 +390,10 @@ testcase t114174 sReference(1) = "Koelle" sReference(2) = "Alaaf!" - '/// open application ///' + printlog "open application " Call hNewDocument - '/// Format->Modify Layout ///' + printlog "Format->Modify Layout " FormatPage Kontext "Tasks" LayoutsPreview.TypeKeys "<TAB>" @@ -414,7 +419,7 @@ testcase t114174 endif next i - '/// deselect all by typing key 'ESCAPE' again ///' + printlog "deselect all by typing key 'ESCAPE' again " hTypeKeys("<Escape>") hFileSaveAsKill(sFile) @@ -477,10 +482,10 @@ testcase t111862 sReference(1) = "Koelle" sReference(2) = "Alaaf!" - '/// open application ///' + printlog "open application " Call hNewDocument - '/// Format->Modify Layout ///' + printlog "Format->Modify Layout " Formatpage Kontext "Tasks" LayoutsPreview.TypeKeys "<TAB>" @@ -519,4 +524,4 @@ testcase t111862 hCloseDocument() endcase 't111862 -'------------------------------------------------------------------------------ +'------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow.inc b/testautomation/graphics/optional/includes/impress/i_slideshow.inc index d313f444994b..da96b13cc47d 100644 --- a/testautomation/graphics/optional/includes/impress/i_slideshow.inc +++ b/testautomation/graphics/optional/includes/impress/i_slideshow.inc @@ -29,38 +29,30 @@ '* '* short description : '* -'******************************************************************* -'* -' #1 tSlideShowSlideShow -' #1 tSlideShowRehearseTimings -' #1 tSlideShowSlideShowSettings -' #1 tSlideShowCustomSlideShow -' #1 tSlideShowSlideTransition -' #1 tSlideShowShowHideSlide -'* '\****************************************************************** + testcase tSlideShowSlideShow dim bLoaded as boolean dim i as integer + dim testfile as string + dim localtestfile as string - '/// open file 'graphics\\input\\diashow.odp' ///' - hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") + printlog "open file 'graphics\input\diashow.odp' " + testfile = ( gTesttoolPath + "graphics\required\input\diashow.odp" ) + hFileOpenLocally( testfile ) sleep 30 - printlog "check if the document is writable" - sMakeReadOnlyDocumentEditable - bLoaded = false Kontext "Navigator" if Navigator.Exists then Navigator.Close - '/// Deactivate "Start with current page" in ToolsOptions ///' + printlog "Deactivate Start with current page in ToolsOptions " setStartCurrentPage(FALSE) try - '/// SlideShow->Slide Show Settings... ///' + printlog "SlideShow->Slide Show Settings... " SlideShowPresentationSettings bLoaded = true catch @@ -69,17 +61,17 @@ testcase tSlideShowSlideShow if bLoaded then Kontext "Bildschirmpraesentation" - '/// check Radio button 'Type': 'Window' ///' + printlog "check Radio button 'Type': 'Window' " Fenster.Check - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK sleep 3 - '/// start the slideshow with 'Slide Show->Slide Show' ///' + printlog "start the slideshow with 'Slide Show->Slide Show' " SlideShowSlideshow sleep 3 Kontext "DocumentPresentation" sleep 5 - '/// end the presentation by typing [ESCAPE] ///' + printlog "end the presentation by typing [ESCAPE] " DocumentPresentation.TypeKeys "<ESCAPE>" sleep 3 try @@ -91,7 +83,7 @@ testcase tSlideShowSlideShow sleep 3 endcatch - '/// start the slideshow with 'Slide Show->Slide Show' ///' + printlog "start the slideshow with 'Slide Show->Slide Show' " SlideShowSlideshow Kontext "DocumentPresentation" Printlog "- Check if slideshow runs" @@ -102,14 +94,14 @@ testcase tSlideShowSlideShow Warnlog "Presentation is not running !" endcatch sleep 5 - '/// type the key [SHIFT + F5] to open the navigator ///' + printlog "type the key [SHIFT + F5] to open the navigator " DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" Kontext "NavigatorDraw" sleep 1 - '/// check in list, if the page changed ///' + printlog "check in list, if the page changed " if Liste.GetSelIndex <> 2 Then Warnlog "- pagedown not working: '" + Liste.GetSelText+"'" Kontext "DocumentPresentation" - '/// press key [cursor right] 3 times ///' + printlog "press key [cursor right] 3 times " for i = 1 to 3 sleep 3 DocumentPresentation.TypeKeys "<right>" @@ -132,29 +124,38 @@ testcase tSlideShowSlideShow warnlog "Document didn't get loaded" endif Kontext "DocumentImpress" - '/// Close the Navigator ///' + printlog " Close the Navigator " DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" - '/// Set "Start with current page" back to default = on, in ToolsOptions ///' + printlog "Set Start with current page back to default = on, in ToolsOptions " setStartCurrentPage(TRUE) - '/// close the application ///' - Call hCloseDocument - + printlog "close the application " + Call hCloseDocument + localtestfile = hFileGetLocalPath( gTesttoolPath + "diashow.odp" ) + printlog localtestfile + if (FileExists (localtestfile)) then + app.kill (localtestfile) + printlog "Deleting used file." + else + warnlog "File is missing." + endif endcase 'tSlideShowSlideShow '------------------------------------------------------------------------------- testcase tSlideShowRehearseTimings + qaerrorlog "#i64783# - tSlideShowRehearseTimings outcommented due to bug" goto endsub + dim bLoaded as boolean dim i as integer - '/// open file 'graphics\\input\\diashow.odp' ///' + printlog "open file 'graphics\input\diashow.odp' " hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") sleep 10 - ' check if the document is writable + printlog "check if the document is writable" if fIsDocumentWritable = false then - ' make the document writable and check if it's succesfull + printlog "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 @@ -164,7 +165,7 @@ testcase tSlideShowRehearseTimings if Navigator.Exists then Navigator.Close bLoaded = false try - '/// SlideShow->Slide Show Settings... ///' + printlog "SlideShow->Slide Show Settings... " SlideShowPresentationSettings bLoaded = true catch @@ -172,12 +173,12 @@ testcase tSlideShowRehearseTimings endcatch if bLoaded then Kontext "Bildschirmpraesentation" - '/// check Radio button 'Type': 'Window' ///' + printlog "check Radio button 'Type': 'Window' " Fenster.Check - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK sleep 3 - '/// start the slideshow with 'Slide Show->Rehearse Timings' ///' + printlog "start the slideshow with 'Slide Show->Rehearse Timings' " SlideShowRehearseTimings Kontext "DocumentPresentation" if DocumentPresentation.Exists then @@ -185,7 +186,7 @@ testcase tSlideShowRehearseTimings else warnlog "bah" endif - '/// press key [return] 5 times ///' + printlog "press key [return] 5 times " for i = 1 to 5 sleep 5 DocumentPresentation.TypeKeys "<return>" @@ -205,15 +206,15 @@ testcase tSlideShowRehearseTimings warnlog "Documnet didn't get loaded" endif - '/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog " close navigator ! " Navigator.Close else printlog "Navigator: NOT available" endif - '/// close the application ///' + printlog "close the application " Call hCloseDocument endcase 'tSlideShowRehearseTimings @@ -227,6 +228,8 @@ testcase tSlideShowSlideShowSettings dim sTemp as string dim saSlideNames(4) as string dim bCurrentPage as boolean + dim sTestfile as string + dim sLocaltestfile as string S1 = glLocale (2) + " 1" S2 = glLocale (2) + " 2" @@ -241,65 +244,64 @@ testcase tSlideShowSlideShowSettings ' the state of the navigator in the normal view is not affected ' the navigator that is open in normal view, is not visible in windows presenattions - '/// open application ///' + printlog "open application " Call hNewDocument -'/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close QaErrorLog "Navigator was open. Check earlier tests. Now closed." else printlog "Navigator: NOT available. Good." endif - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" - '/// check checkbox in section 'Range' - 'From: ///' + printlog "check checkbox in section 'Range' - 'From: " AbDia.Check - '/// get count of slides from listbox 'From:' ///' + printlog "get count of slides from listbox 'From:' " x = AbDiaName.GetItemCount - '/// check if count in listbox 'from' is '0' ///' + printlog "check if count in listbox 'from' is '0' " if (x = 1) Then Printlog " - Slide count in the list: '" + x + "'" else Warnlog " - unexpected slide count; should be '1'; is '" + x + "'" end if - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK - '/// Insert->Slide... ///' + printlog "Insert->Slide... " InsertSlide sleep 2 hTypekeys "<Pagedown>" sleep 2 - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" - Printlog "'///<b> check if count in listbox 'from' increased </b>///'" + Printlog "check if count in listbox 'from' increased" i = AbDiaName.GetItemCount if ((i -1) = x) Then Printlog " - Slide appears in the list; count : '" + i + "'" else Warnlog " - Slide not added; is '" + i + "' should: '" + x + "'" end if - '/// close dialog 'Slide Show' with CANCEL ///' + printlog "close dialog 'Slide Show' with CANCEL " Bildschirmpraesentation.Cancel - '/// close application ///' + printlog "close application " Call hCloseDocument sleep 5 - bLoaded = false - '/// open file 'graphics\\input\\diashow.odp' (Slide Show with 4 Slides) ///' - hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") + bLoaded = false + printlog "open file 'graphics\input\diashow.odp' (Slide Show with 4 Slides) " + sTestfile = ( gTesttoolPath + "graphics\required\input\diashow.odp" ) + hFileOpenLocally( sTestfile ) sleep 10 - printlog "check if the document is writable" - sMakeReadOnlyDocumentEditable try Kontext "DocumentImpress" - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " Printlog "'--------------------------------------------------------------------------" SlideShowPresentationSettings bLoaded = true @@ -317,19 +319,19 @@ testcase tSlideShowSlideShowSettings if (NavigatorSichtbar.IsChecked) then Warnlog "'Navigator visible' is checked :-(" endif - '///<b> check checkbox 'All Slides' </b>///' + printlog "check checkbox 'All Slides'" AlleDias.Check - '///<b> check checkbox 'Window' </b>///' + printlog "check checkbox 'Window" Fenster.Check - '///<b> check checkbox 'Navigator visible' </b>///' - NavigatorSichtbar.Check '-------------------------------------------------------------------------- - '/// close dialog 'Slide Show' with OK ///' + printlog "check checkbox 'Navigator visible" + NavigatorSichtbar.Check + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK - '/// start the slideshow with 'Slide Show->Slide Show' ///' + printlog "start the slideshow with 'Slide Show->Slide Show' " SlideShowSlideshow Printlog "'---------------------------- START P -- All -- Window -- Navigator -------------------------" sleep 5 - '/// check state of navigator ! expected: open ///' + printlog " check state of navigator ! expected: open " Kontext "Navigator" if Navigator.exists then Printlog "Navigator: open :-)" @@ -341,7 +343,7 @@ testcase tSlideShowSlideShowSettings sleep 1 Kontext "DocumentPresentation" try - '/// press pagedown ///' + printlog "press pagedown " DocumentPresentation.TypeKeys "<pagedown>" catch Warnlog "presentation is not running !" @@ -351,8 +353,8 @@ testcase tSlideShowSlideShowSettings if Liste.GetSelIndex <> 2 Then warnlog "Wrong slide." endif - '/// press the key [Page Down] 3 times ///' - '///+ check in Navigator list, if the slide is number: (times key pressed) ///' + printlog "press the key [Page Down] 3 times " + printlog "check in Navigator list, if the slide is number: (times key pressed) " for i = 2 to 4 Kontext "Navigator" if Navigator.exists then @@ -367,7 +369,7 @@ testcase tSlideShowSlideShowSettings DocumentPresentation.TypeKeys "<pagedown>" next i sleep (2) - '/// press the key [Page Down] to exit presentation ///' + printlog "press the key [Page Down] to exit presentation " DocumentPresentation.TypeKeys "<pagedown>" sleep (5) try @@ -378,20 +380,20 @@ testcase tSlideShowSlideShowSettings DocumentPresentation.TypeKeys "<ESCAPE>" endcatch sleep 2 - '/// check state of navigator ! expected: open ///' + printlog " check state of navigator ! expected: open " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close else printlog "Navigator: NOT available" endif - Printlog "'--------------------------------------------------------------------------" + Printlog "'---------------------------------------------------------------" Kontext "DocumentPresentation" - '/// type the key [MOD1 SHIFT F5] to open the navigator ///' '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator " hTypeKeys "<MOD1 SHIFT F5>" - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" if (AlleDias.IsChecked = FALSE) then @@ -406,59 +408,59 @@ testcase tSlideShowSlideShowSettings if (DiawechselAufHintergrund.IsChecked = FALSE) then Warnlog "'Change slides by clicking on background' is not checked :-(" endif - '///<b> check checkbox in section 'Range' - 'From: </b>///' + printlog "check checkbox in section 'Range' - 'From:" AbDia.Check - '/// select the 3rd item from the top from listbox 'From:' -> 2 slides to go ///' + printlog "select the 3rd item from the top from listbox 'From:' -> 2 slides to go " AbDiaName.Select 3 sTemp = AbDiaName.GetSelText Printlog " - From '" + sTemp + "' will be shown" - '///<b> check checkbox 'Default' </b>///' + printlog "check checkbox 'Default'" Standard.Check - '/// UNcheck checkbox 'Navigator visible'///' + printlog "UNcheck checkbox 'Navigator visible'" NavigatorSichtbar.UnCheck - '/// UNcheck checkbox 'Change slides by clicking on background'///' + printlog "UNcheck checkbox 'Change slides by clicking on background'" DiawechselAufHintergrund.UnCheck - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK sleep 3 Kontext "DocumentPresentation" - '/// start the slideshow with 'Slide Show->Slide Show' ///' + printlog "start the slideshow with 'Slide Show->Slide Show' " SlideShowSlideshow Printlog "'---------------------------- START P -- From -- Default -- Click on Bg -----------------------" sleep 5 - '/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close Warnlog "Navigator: closed" else Printlog "Navigator: NOT available. Good." endif sleep 1 - '/// type the key [MOD1 SHIFT F5] to open the navigator ///' '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator " Kontext "DocumentPresentation" DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" sleep 3 - '/// check in Navigator list, if the page is THREE! ///' + printlog "check in Navigator list, if the page is THREE! " fGetSlideName(S3) - '/// click right mouse button ///' + printlog "click right mouse button " sleep 5 DocumentPresentation.MouseDown 50,50 DocumentPresentation.MouseUp 50,50 - '/// check in Navigator list, if the page is still THREE. If so, change slide with PageDown ///' + printlog "check in Navigator list, if the page is still THREE. If so, change slide with PageDown " if (fGetSlideName(S3) <> S3) then Warnlog "'Change slides by clicking on background' disable did not work :-(" else DocumentPresentation.TypeKeys "<PAGEDOWN>" endif - '/// check in Navigator list, if the page is FOUR ///' + printlog "check in Navigator list, if the page is FOUR " fGetSlideName(S4) sleep 5 - '/// press the key [Page Down] ///' + printlog "press the key [Page Down] " DocumentPresentation.TypeKeys "<pagedown>" sleep 5 - '/// press the key [Space] to exit presentation ///' + printlog "press the key [Space] to exit presentation " DocumentPresentation.TypeKeys "<Space>" sleep 10 try @@ -470,10 +472,10 @@ testcase tSlideShowSlideShowSettings DocumentPresentation.TypeKeys "<ESCAPE>" Warnlog " - Program was still in slideshow mode - ended now ?" endcatch - '/// check state of navigator ! expected: open ///' + printlog " check state of navigator ! expected: open " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close printlog "Navigator: closed" else @@ -481,7 +483,7 @@ testcase tSlideShowSlideShowSettings endif Printlog "'--------------------------------------------------------------------------" - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" if (AbDia.IsChecked = FALSE) then @@ -496,33 +498,33 @@ testcase tSlideShowSlideShowSettings if (DiawechselAufHintergrund.IsChecked) then Warnlog "'Change slides by clicking in background' is checked :-(" endif - '/// check checkbox 'All Slides' ///' + printlog "check checkbox 'All Slides' " AlleDias.Check - '///<b> check check box 'Auto' -> implies looping of slideshow in fullscreen mode </b>///' + printlog "check check box 'Auto' -> implies looping of slideshow in fullscreen mode" Auto.Check - '/// set duration of pause to '00:00:05' ///' + printlog "set duration of pause to '00:00:05' " Zeit.SetText "00:00:05" - '/// check check box 'Show logo' ///' + printlog "check check box 'Show logo' " LogoAnzeigen.Check - '/// check checkbox 'Change slides by clicking on background'///' + printlog "check checkbox 'Change slides by clicking on background'" DiawechselAufHintergrund.Check - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK - '/// start the slideshow with 'Slide Show->Slide Show' ///' + printlog "start the slideshow with 'Slide Show->Slide Show' " SlideShowSlideshow Printlog "'---------------------------- START P -- All -- Auto -- :05 -- Logo -----------------------------" sleep 3 Kontext "DocumentPresentation" - '/// type the key [MOD1 SHIFT F5] to open the navigator ///' '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator " DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" - '/// press the key [Space] 4 times ///' - '///+ check in Navigator list, if the slide is number: [(times key pressed) -1 ] ///' + printlog "press the key [Space] 4 times " + printlog "check in Navigator list, if the slide is number: [(times key pressed) -1 ] " for i = 1 to 4 fGetSlideName(saSlideNames(i)) DocumentPresentation.TypeKeys "<Space>" sleep 5 next i - '/// wait until autopause ended (5 secs) ///' + printlog "wait until autopause ended (5 secs) " sleep 10 if (fGetSlideName(saSlideNames(1)) = saSlideNames(1)) then Printlog " - Enless loop works" @@ -530,7 +532,7 @@ testcase tSlideShowSlideShowSettings Warnlog " Enless loop does NOT work" end if sleep 2 - '/// type key [excape] to exit presentation ///' + printlog "type key [excape] to exit presentation " Kontext "DocumentPresentation" DocumentPresentation.TypeKeys "<ESCAPE>" sleep 5 @@ -544,7 +546,7 @@ testcase tSlideShowSlideShowSettings DocumentImpress.TypeKeys "<ESCAPE>" sleep 5 endcatch - '/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then Navigator.Close @@ -555,56 +557,56 @@ testcase tSlideShowSlideShowSettings Printlog "'--------------------------------------------------------------------------" Kontext "DocumentImpress" - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "BildschirmPraesentation" - '/// check checkbox 'default' ///' + printlog "check checkbox 'default' " Standard.Check - '///<b> check checkbox 'Change slides maually' </b>///' - ' to check this i need an automatic transition somewhere in the presentation !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + printlog "check checkbox 'Change slides maually'" + ' to check this i need an automatic transition somewhere in the presentation ! DiawechselManuel.Check - '///<b> check checkbox 'Mouse pointer as pen' </b>///' + printlog "check checkbox 'Mouse pointer as pen'" MauszeigerAlsStift.Check - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " BildschirmPraesentation.Ok sleep 1 - '/// goto the first slide by typing [strg home] ///' + printlog "goto the first slide by typing [strg home] " hTypeKeys "<mod1 home>" - '///+ - SlideShow->SlideTransition ///' + printlog "SlideShow->SlideTransition " SlideShowSlideTransition Kontext "Tasks" - '///+ - click button 'Extras' ///' + printlog "click button 'Extras' " sleep 1 - '///+ - + click button 'Automatic Transition' ///' + printlog "click button 'Automatic Transition' " TransitionAutomaticallyAfter.Check 'click - '///+ - + + Set Time to '00:00:01' ///' + printlog " Set Time to '00:00:01' " TransitionAutomaticallyAfterTime.SetText "2" - '///+ - click button 'Assign' ///' + printlog " click button 'Assign' " TransitionApplyToAllSlides.Click - '///+ - close dialog 'Slide Transition' ///' + printlog "close dialog 'Slide Transition' " sleep 3 - '/// start the slideshow with keys [STRG F2] ///' + printlog "start the slideshow with keys [STRG F2] " Kontext "DocumentImpress" DocumentImpress.TypeKeys "<MOD1 F2>" Printlog "'---------------------------- START P -- Default -- Manuel ------------------------------" - '/// wait 10 seconds (to get the dia changed automatical has not to happen !) ///' + printlog "wait 10 seconds (to get the dia changed automatical has not to happen !) " sleep 10 Kontext "DocumentPresentation" - '/// type the key [MOD1 SHIFT F5] to open the navigator ///' '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator " DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" - '/// press key [cursor right] 3 times ///' + printlog "press key [cursor right] 3 times " for i = 1 to 4 sleep 5 fGetSlideName(saSlideNames(i)) - '///+ use the left mouse button, to use the pen drawing function ///' + printlog "use the left mouse button, to use the pen drawing function " DocumentPresentation.MouseDown (10, 10) DocumentPresentation.MouseMove (10, 90) DocumentPresentation.MouseUp (10, 90) DocumentPresentation.TypeKeys "<right>" next i - '/// press the key [Page Down] to exit presentation ///' + printlog "press the key [Page Down] to exit presentation " sleep (2) DocumentPresentation.TypeKeys "<pagedown>" sleep (2) @@ -615,10 +617,10 @@ testcase tSlideShowSlideShowSettings Printlog "- Slideshow ended at the right time" endif sleep 2 - '/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close warnlog "Navigator: closed" else @@ -627,50 +629,50 @@ testcase tSlideShowSlideShowSettings Printlog "'--------------------------------------------------------------------------" Kontext "DocumentImpress" - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "BildschirmPraesentation" - '/// check checkbox 'default' ///' + printlog "check checkbox 'default' " Standard.Check - '///<b> UNcheck checkbox 'Change slides manually' </b>///' + printlog "UNcheck checkbox 'Change slides manually'" DiawechselManuel.UNCheck - '/// UNcheck checkbox 'Mouse pointer as pen' ///' + printlog "UNcheck checkbox 'Mouse pointer as pen' " MauszeigerAlsStift.UNCheck - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " BildschirmPraesentation.Ok sleep 1 - '/// goto the first slide by typing [strg home] ///' + printlog "goto the first slide by typing [strg home] " hTypeKeys "<MOD1 HOME>" - '/// Set all slides to 'wait 10 seconds' to get the slide changed automatically ///' - '///+ - SlideShow->SlideTransition ///' + printlog "Set all slides to 'wait 10 seconds' to get the slide changed automatically " + printlog "SlideShow->SlideTransition " SlideShowSlideTransition Kontext "Tasks" - '///+ - click button 'Extras' ///' + printlog "click button 'Extras' " sleep 1 - '///+ - + click button 'Automatic Transition' ///' + printlog "click button 'Automatic Transition' " TransitionAutomaticallyAfter.Check 'click - '///+ - + + Set Time to '10sec' ///' + printlog "Set Time to '10sec' " TransitionAutomaticallyAfterTime.SetText "10" - '///+ - click button 'Apply to all Slides' ///' + printlog "click button 'Apply to all Slides' " TransitionApplyToAllSlides.Click - '///+ - close dialog 'Slide Transition' ///' + printlog "close dialog 'Slide Transition' " sleep (1) - '/// start the slideshow with keys [STRG F2] ///' + printlog "start the slideshow with keys [STRG F2] " Kontext "DocumentImpress" DocumentImpress.TypeKeys "<MOD1 F2>" Printlog "'---------------------------- START P -- Default -- Automatic -----------------------------" - '/// Wait 6 seconds to see if the Automatic Transition changes the slide. ///' + printlog "Wait 6 seconds to see if the Automatic Transition changes the slide. " sleep 6 Kontext "DocumentPresentation" - '/// type the key [MOD1 SHIFT F5] to open the navigator ///' '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator " DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" - '/// press key [cursor right] 3 times ///' + printlog "press key [cursor right] 3 times " for i = 2 to 4 sleep (5) fGetSlideName(saSlideNames(i)) DocumentPresentation.TypeKeys "<right>" next i - '/// press the key [Page Down] to exit presentation ///' + printlog "press the key [Page Down] to exit presentation " sleep (2) DocumentPresentation.TypeKeys "<PAGEDOWN>" sleep (2) @@ -681,20 +683,28 @@ testcase tSlideShowSlideShowSettings Printlog "- Slideshow ended at the right time" endif sleep 2 - '/// check state of navigator ! expected: closed ///' + printlog " check state of navigator ! expected: closed " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close endif else warnlog "document didn't get loaded" endif - '/// Set "Start with current page" back to default = on, in ToolsOptions ///' + printlog "Set Start with current page back to default = on, in ToolsOptions " setStartCurrentPage(TRUE) - '/// Close the document ///' + printlog "Close the document " call hCloseDocument - + sLocaltestfile = hFileGetLocalPath( gTesttoolPath + "diashow.odp" ) + printlog sLocaltestfile + if (FileExists (sLocaltestfile)) then + app.kill (sLocaltestfile) + printlog "Deleting used file." + else + warnlog "File is missing." + endif + endcase 'tSlideShowSlideShowSettings '------------------------------------------------------------------------------- @@ -706,110 +716,110 @@ testcase tSlideShowCustomSlideShow dim sTemp as string Seite = s1 - '/// open application ///' + printlog "open application " Call hNewDocument Kontext "Navigator" if Navigator.Exists then Navigator.Close - '/// Deactivate "Start with current page" in ToolsOptions ///' + printlog "Deactivate Start with current page in ToolsOptions " setStartCurrentPage(FALSE) - '/// create a rectangle ///' + printlog "create a rectangle " hRechteckErstellen 30,30,60,60 - '/// do 2 times : ///' + printlog "do 2 times : " for i = 1 to 2 - '///+ Insert->Slide... ///' + printlog "Insert->Slide... " InsertSlide sleep 2 hTypekeys "<Pagedown>" sleep 2 - '///+ create a rectangle ///' + printlog "create a rectangle " hRechteckErstellen 30,30,70,70 next i - '/// Slide Show -> Slide Show Settings ///' + printlog "Slide Show -> Slide Show Settings " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" if (Fenster.IsChecked = False) Then Fenster.Check - '/// close dialog 'Slide Show' with OK ///' + printlog "close dialog 'Slide Show' with OK " Bildschirmpraesentation.OK - '/// Slide Show -> Custom Slide Show... ///' + printlog "Slide Show -> Custom Slide Show... " SlideShowCustomSlideshow Kontext "IndividuellePraesentation" - '///<b> click button 'New...' </b>///' + printlog "click button 'New...' " Neu.Click Kontext "IndividuellePraesentationDefinieren" - '/// type something in 'Name' ///' + printlog "type something in 'Name' " PraesentationName.SetText "Individually 1" - '/// select the first entry in the list 'Existing Slides' ///' + printlog "select the first entry in the list 'Existing Slides' " SeitenPraesentation.Select 1 - '/// click button '>>' ///' + printlog "click button '>>' " Hinzufuegen.Click i = SelectedSlides.GetItemCount if (i <> 1) Then Warnlog "- Number of slides 'Selected Slides' is not correct. It should be = '1', but it is = '" + i + "'" endif - '/// close dialog 'Define Custom Slide Show' with OK ///' + printlog "close dialog 'Define Custom Slide Show' with OK " IndividuellePraesentationDefinieren.OK Kontext "IndividuellePraesentation" - '///<b> click button 'Edit...' </b>///' + printlog "click button 'Edit...'" Bearbeiten.Click Kontext "IndividuellePraesentationDefinieren" - '/// select an entry in the list 'Selected Slides' ///' + printlog "select an entry in the list 'Selected Slides' " SelectedSlides.TypeKeys "<pagedown>" - '/// click button '<<' ///' + printlog "click button '<<' " Entfernen.Click i = SelectedSlides.GetItemCount if (i <> 0) Then Warnlog " Removing slides from list 'Selected Slides' does not work It should be = '1', but it is = '" + i + "'" endif - '/// select the first entry in the list 'Existing Slides' ///' + printlog "select the first entry in the list 'Existing Slides' " SeitenPraesentation.Select 1 - '/// click button '>>' ///' + printlog "click button '>>' " Hinzufuegen.Click - '/// close dialog 'Define Custom Slide Show' with OK ///' + printlog "close dialog 'Define Custom Slide Show' with OK " IndividuellePraesentationDefinieren.OK Kontext "IndividuellePraesentation" - '///<b> check checkbox 'Use Custom Slide Show' </b>///' '------------------------------------------------------- + printlog "check checkbox 'Use Custom Slide Show'" IndividuellePraesentationBenutzen.Check - '///<b> click button 'Start...' </b>///' + printlog "click button 'Start..." Starten.Click sleep 2 Kontext "DocumentPresentation" - '/// press key [space] 2 times ///' + printlog "press key [space] 2 times " DocumentPresentation.TypeKeys "<space>" sleep 2 DocumentPresentation.TypeKeys "<space>" sleep 5 try Kontext "IndividuellePraesentation" - '/// close dialog 'Custom Slide Shows' with button 'Close' ///' + printlog "close dialog 'Custom Slide Shows' with button 'Close' " IndividuellePraesentation.Close catch Warnlog "- Slideshow did not end after slide 1" DocumentPresentation.TypeKeys "<space>" sleep 2 endcatch - '/// Slide Show -> Custom Slide Show... ///' + printlog "Slide Show -> Custom Slide Show... " SlideShowCustomSlideshow Kontext "IndividuellePraesentation" - '/// click button 'Edit...' ///' + printlog "click button 'Edit...' " Bearbeiten.Click Kontext "IndividuellePraesentationDefinieren" - '/// select 1st entry in the list 'Selected Slides' ///' + printlog "select 1st entry in the list 'Selected Slides' " SelectedSlides.Select 1 - '/// click button '<<' ///' + printlog "click button '<<' " Entfernen.Click i = SelectedSlides.GetItemCount if (i <> 0) Then Warnlog "- Add and remove slides does not work properly. It should be '0', but it is = '"+i+"'" endif - '/// select the first entry in the list 'Existing Slides' ///' + printlog "select the first entry in the list 'Existing Slides' " SeitenPraesentation.Select 1 - '/// click button '>>' 4 times ///' + printlog "click button '>>' 4 times " for i =1 to 4 Hinzufuegen.Click next i @@ -820,16 +830,16 @@ testcase tSlideShowCustomSlideShow Warnlog "- Wrong slide added to individual slideshow. Instead of '" + Seite + "', '" + sTemp + "' was added" endif next i - '/// close dialog 'Define Custom Slide Show' with OK ///' + printlog "close dialog 'Define Custom Slide Show' with OK " IndividuellePraesentationDefinieren.OK sleep 1 Kontext "IndividuellePraesentation" - '///<b> UNcheck checkbox 'Use Custom Slide Show' </b>///' + printlog "UNcheck checkbox 'Use Custom Slide Show'" IndividuellePraesentationBenutzen.UnCheck - '/// click button 'Start...' ///' - Starten.Click '---------------------------- START P ---------------------------------------------- - '/// press key [space] 4 times ///' + printlog "click button 'Start...' " + Starten.Click + printlog "press key [space] 4 times " kontext "DocumentPresentation" for i = 1 to 4 sleep 3 @@ -837,19 +847,19 @@ testcase tSlideShowCustomSlideShow next i sleep 10 kontext "IndividuellePraesentation" - '/// close dialog 'Custom Slide Shows' with button 'Close' ///' + printlog "close dialog 'Custom Slide Shows' with button 'Close' " if IndividuellePraesentation.exists then IndividuellePraesentation.Close else Warnlog "'IndividuellePraesentation' was closed :-(" end if - '/// Set "Start with current page" back to default = on, in ToolsOptions ///' + printlog "Set Start with current page back to default = on, in ToolsOptions " setStartCurrentPage(TRUE) - '/// close the application ///' + printlog "close the application " Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog "close navigator ! " Navigator.Close else printlog "Navigator: NOT available" @@ -871,33 +881,33 @@ testcase tSlideShowSlideTransition sFile = ConvertPath (gOfficePath + "user\work\diashow") -' '/// open application ///' + printlog "open application " call hNewDocument - '/// close the navigator///' + printlog "close the navigator" Kontext "Navigator" if Navigator.Exists then Navigator.Close WaitSlot (3000) - '/// create 3 slides with a rectangle ///' + printlog "create 3 slides with a rectangle " hRechteckErstellen (30,30,60,60) for i = 1 to 2 - '///+ - Insert->Slide ///' + printlog " Insert->Slide " WaitSlot (1000) InsertSlide WaitSlot (2000) hTypekeys "<Pagedown>" WaitSlot (2000) - '///+ - insert rectangle///' + printlog " insert rectangle" hRechteckErstellen (30,30,60,60) next i Printlog "created 3 slides" - '/// for all 3 slides do: ///' + printlog "for all 3 slides do: " for i = 1 to 3 - '///+ - open navigator with shortcutkey [MOD1 SHIFT F5] ///' + printlog "open navigator with shortcutkey [MOD1 SHIFT F5] " hTypeKeys "<MOD1 SHIFT F5>" Sleep (3) Kontext "NavigatorDraw" - '///+ - select the next slide in the list ///' + printlog "select the next slide in the list " if Liste.GetItemCount < 3 then warnlog "We have " + Liste.GetItemCount + " entries in the Navigator." hTypeKeys "<MOD1 SHIFT F5>" @@ -905,21 +915,21 @@ testcase tSlideShowSlideTransition Kontext "NavigatorDraw" end if Liste.Select i - '///+ - press key [return] ///' + printlog "press key [return] " Liste.TypeKeys "<return>" Kontext "Navigator" - '///+ - close Navigator ///' + printlog "close Navigator " Navigator.Close - '///+ - SlideShow->SlideTransition ///' + printlog " SlideShow->SlideTransition " SlideShowSlideTransition Kontext "Tasks" '"SlideTransition"' "OL_DIA_Diawechsel" 'OL_DIA_Diawechsel TransitionAutomaticPreview.UnCheck - '///+ - click button 'Effects' ///' + printlog "click button 'Effects' " TransitionApplyToSelectedSlide.typekeys "<pagedown>" Sleep (1) - '///+ - in the listbox 'speed' select the i. one from the top ///' + printlog "in the listbox 'speed' select the i. one from the top " TransitionSpeed.Select i - '///+ - Select an effect-group from the listbox ///' + printlog "Select an effect-group from the listbox " TransitionApplyToSelectedSlide.typekeys "<home>" for q= 1 to (i+2) Sleep (2) @@ -927,12 +937,13 @@ testcase tSlideShowSlideTransition Sleep (2) next q sEffect(i) = TransitionApplyToSelectedSlide.GetSelText - '///+ - click button 'Extras' ///' + printlog "click button 'Extras' " Sleep (2) + printlog "click button 'Automatic Transition' " select case i - case 1: '///+ - + click button 'Automatic Transition' ///' + case 1: TransitionAutomaticallyAfter.Check - '///+ - + + Set Time to '00:00:01' OR ///' + printlog " Set Time to '00:00:01' OR " TransitionAutomaticallyAfterTime.ToMin 'SetText "1" '"00:00:01" TransitionAutomaticallyAfterTime.More TransitionApplyToSelectedSlide.typekeys "<DOWN>" @@ -940,8 +951,8 @@ testcase tSlideShowSlideTransition TransitionAutomaticallyAfter.Check Tasks.TypeKeys "<TAB><TAB><TAB>" TimerValue = TransitionAutomaticallyAfterTime.GetText - printlog " TimerValue is now: " + TimerValue - case else: '///+ - + click button 'SemiAutomatic Transition' OR ///' + printlog "TimerValue is now: " + TimerValue + case else: printlog "click button 'SemiAutomatic Transition' OR " TransitionOnMouseClick.Check end select Sleep (3) @@ -950,26 +961,26 @@ testcase tSlideShowSlideTransition Kontext "DocumentImpress" Sleep (3) - '/// SlideShow->Slide Show Settings... ///' + printlog "SlideShow->Slide Show Settings... " SlideShowPresentationSettings Kontext "Bildschirmpraesentation" WaitSlot (2000) - '/// check Radio button 'Type': 'Window' ///' + printlog "check Radio button 'Type': 'Window' " Fenster.Check - '/// close dialog 'Slide Show' ///' + printlog "close dialog 'Slide Show' " Bildschirmpraesentation.OK WaitSlot (5000) Kontext "DocumentImpress" - Printlog "'/// SlideShow->Slide Show ///'" + Printlog "printlog SlideShow->Slide Show" SlideShowSlideshow - '/// wait 10 sec ///' - sleep (10) 'WaitSlot (10000) + printlog "wait 10 sec " + sleep (10) Kontext "DocumentPresentation" - '/// type key [ESCAPE] ///' + printlog "type key [ESCAPE] " DocumentPresentation.TypeKeys "<ESCAPE>" WaitSlot (3000) try - '/// type key [F11] to open the stylist (to check ending of presenation) ///' + printlog "type key [F11] to open the stylist (to check ending of presenation) " if lcase(gPlatform) = "osx" then hTypekeys "<mod1 t>" else @@ -978,7 +989,7 @@ testcase tSlideShowSlideTransition Sleep (3) Kontext "Gestalter" Sleep (3) - '/// close Stylist ///' + printlog "close Stylist " Gestalter.Close Printlog "- Slideshow worked" catch @@ -988,34 +999,33 @@ testcase tSlideShowSlideTransition Sleep (2) endcatch - '/// close the navigator///' + printlog "close the navigator" Kontext "Navigator" if Navigator.Exists then Navigator.Close - Printlog "'///+ check the settings in SlideView in the Dia object bar ///'" + Printlog "check the settings in SlideView in the Dia object bar " for i = 1 to 3 Printlog " --------------------- " + i + " ---------------------------" - '///+ - open navigator with shortcutkey [MOD1 SHIFT F5] ///' + printlog " open navigator with shortcutkey [MOD1 SHIFT F5] " hTypeKeys "<MOD1 SHIFT F5>" sleep (3) Kontext "NavigatorDraw" - '///+ - select the next slide in the list ///' + printlog " select the next slide in the list " Liste.Select i - '///+ - press key [return] ///' + printlog " press key [return] " Liste.TypeKeys "<return>" Kontext "Navigator" - '///+ - close Navigator ///' + printlog " close Navigator " Navigator.Close - '///+ - View->Master View->Slides View ///' -' ViewWorkspaceSlidesView + printlog " View->Master View->Slides View " Sleep (2) - Kontext "Tasks" 'SlideViewObjectbar" - '///+ - check 'speed' ///' + Kontext "Tasks" + printlog " check 'speed' " if Tasks.Exists = TRUE AND Tasks.IsVisible = TRUE then x = TransitionSpeed.GetSelIndex 'TransitionSpeed if (x <> i) then Warnlog "Speed changed :-( is: '" + x + "' should be: '" + i + "'" end if - '///+ - check 'Transition' ///' + printlog " check 'Transition' " x = TransitionApplyToSelectedSlide.GetSelIndex 'Diawechsel.GetSelIndex if (x <> (i+3)) then Warnlog "Transition changed :-( is: '" + x + "' should be: '" + (i+3) + "'" @@ -1025,65 +1035,64 @@ testcase tSlideShowSlideTransition end if end if - '///+ - check 'effect group' ///' + printlog " check 'effect group' " sTemp = TransitionApplyToSelectedSlide.GetSelText x = inStr (sTemp,sEffect(i)) Printlog " Effect tried :-) '" + x + "'" if (x < 1) then printlog "the string '" + sTemp + "' should contain the words(s): '" + sEffect(i) + "'" end if -' ViewWorkspaceDrawingView else warnlog " SlideViewObjectbar doesnt exists or isnt visible" end if next i - '/// save file as presentation with name '"user\\work\\diashow")' ///' + printlog "save file as presentation with name 'user\work\diashow)' " hFileSaveAsWithFilterKill ((sFile + ".odp") , "impress8" ) Printlog " saved presentation: '" + sFile + "'" '." + gImpressFilter + " - '/// close application///' + printlog "close application" hCloseDocument () WaitSlot (10000) - '/// load file again ///' + printlog "load file again " hFileOpen (sFile + ".odp") WaitSlot (5000) - Printlog " '/// check setings for every slide in the transition dialog ///'" - '///+ for all 3 slides do: ///' + Printlog "check setings for every slide in the transition dialog " + printlog " for all 3 slides do: " for i = 1 to 3 - Printlog " --------------------- " + i + " ---------------------------" - '///+ - open navigator with shortcutkey [MOD1 SHIFT F5] ///' - hTypeKeys "<MOD1 SHIFT F5>" - Sleep (3) - Kontext "NavigatorDraw" - '///+ - select the next slide in the list ///' - Liste.Select i - '///+ - press key [return] ///' - Liste.TypeKeys "<return>" - Kontext "Navigator" - '///+ - close Navigator ///' - Navigator.Close - '///+ - select the grafik with the key [TAB] ///' - hTypeKeys ("<tab>") - '///+ - SlideShow->SlideTransition ///' - SlideShowSlideTransition + Printlog " --------------------- " + i + " ---------------------------" + printlog " open navigator with shortcutkey [MOD1 SHIFT F5] " + hTypeKeys "<MOD1 SHIFT F5>" + Sleep (3) + Kontext "NavigatorDraw" + printlog " select the next slide in the list " + Liste.Select i + printlog " press key [return] " + Liste.TypeKeys "<return>" + Kontext "Navigator" + printlog " close Navigator " + Navigator.Close + printlog " select the grafik with the key [TAB] " + hTypeKeys ("<tab>") + printlog " SlideShow->SlideTransition " + SlideShowSlideTransition Kontext "Tasks" Sleep (1) - '///+ - check 'speed' ///' + printlog " check 'speed' " x = TransitionSpeed.GetSelIndex if (x <> i) then Warnlog " Speed changed :-( is: '" + x + "' should: '" + i + "'" end if - '///+ - check 'effect group' ///' + printlog " check 'effect group' " x = TransitionApplyToSelectedSlide.GetSelIndex if (x <> (i+3)) then Warnlog " Effect changed :-( is: '" + x + "' should: '" + (i+3) + "'" end if sleep (1) select case i - case 1: '///+ - click button 'Automatic Transition' ///' + case 1: printlog " click button 'Automatic Transition' " if (TransitionAutomaticallyAfter.IsEnabled) then - '///+ - + + Check Time '1' OR ///' + printlog " Check Time '1' OR " sTemp = TransitionAutomaticallyAfterTime.GetText if (sTemp <> TimerValue) then Warnlog " Time is different :-( is: '" + sTemp + "' should be: '" + TimerValue + "'" '"00:00:01" @@ -1092,27 +1101,27 @@ testcase tSlideShowSlideTransition Warnlog " button 'Automatic Transition' not pressed ?" end if case 2: if (TransitionAutomaticallyAfter.IsChecked <> FALSE) then - '///+ - + check button 'SemiAutomatic Transition' OR ///' + printlog " check button 'SemiAutomatic Transition' OR " Warnlog " button 'Automatic Transition' is pressed ?" end if case 3: if (TransitionAutomaticallyAfter.IsChecked <> FALSE) then - '///+ - + click button 'Manual Transition' ///' + printlog "click button 'Manual Transition' " Warnlog " button 'Automatic Transition' is pressed ?" end if end select Sleep (3) next i TransitionAutomaticPreview.Check - '/// Set "Start with current page" back to default = on, in ToolsOptions ///' + printlog "Set Start with current page back to default = on, in ToolsOptions " setStartCurrentPage(TRUE) Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog " close navigator ! " Navigator.Close else printlog "Navigator: NOT available" end if - '/// Close the document ///' + printlog "Close the document " call hCloseDocument endcase 'tSlideShowSlideTransition @@ -1132,7 +1141,7 @@ testcase tSlideShowShowHideSlide saSlideNames(3) = S3 saSlideNames(4) = S4 - printlog "Open file 'graphics\\input\\diashow.odp' (Slide Show with 4 Slides)" + printlog "Open file 'graphics\input\diashow.odp' (Slide Show with 4 Slides)" hFileOpen ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") sleep (10) printlog "check if the document is writable" @@ -1182,7 +1191,7 @@ testcase tSlideShowShowHideSlide SlideShowSlideshow sleep (1) kontext "DocumentPresentation" - printlog "type the key [MOD1 SHIFT F5] to open the navigator" '-------------------------------------------------------------------------- + printlog "type the key [MOD1 SHIFT F5] to open the navigator" DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" sleep (1) kontext "NavigatorDraw" @@ -1233,4 +1242,4 @@ testcase tSlideShowShowHideSlide endcase 'tSlideShowShowHideSlide -'------------------------------------------------------------------------------ +'------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow2.inc b/testautomation/graphics/optional/includes/impress/i_slideshow2.inc index 4de68a260db9..6274a5e7238f 100644 --- a/testautomation/graphics/optional/includes/impress/i_slideshow2.inc +++ b/testautomation/graphics/optional/includes/impress/i_slideshow2.inc @@ -30,33 +30,29 @@ '* short description : '* '******************************************************************* -'* -' #1 tPraesentationAnimation -' #1 tPraesentationEffekt -' #1 tSlideShowInteraction -' #1 tAendernObjektBenennen -' #1 tSlideshowBackgroundAllSlides -' #1 tSlideshowBackgroundSelectedSlide -'* -'\****************************************************************** testcase tPraesentationAnimation + Dim i - Printlog "- Slideshow/Animation" + Printlog "- Slideshow/Animation" + printlog "new document " Call hNewDocument - Call sSelectEmptyLayout '/// new document ///' - sleep 2 - InsertGraphicsFromFile '/// insert graphic ///' - Kontext "OeffnenDlg" - Dateiname.SetText ConvertPath (gTesttoolPath + "global/input/graf_inp/desp.bmp") - sleep 2 - Oeffnen.Click - sleep 2 + Call sSelectEmptyLayout + sleep 2 + printlog "insert graphic" + InsertGraphicsFromFile + Kontext "OeffnenDlg" + Dateiname.SetText ConvertPath (gTesttoolPath + "global/input/graf_inp/desp.bmp") + sleep 2 + Oeffnen.Click + sleep 2 - gMouseClick 90,90 '/// deselect graphic ///' + printlog "deselect graphic" + gMouseClick 90,90 - InsertGraphicsFromFile '/// insert 2nd graphic ///' + printlog "insert 2nd graphic" + InsertGraphicsFromFile Kontext "OeffnenDlg" Dateiname.SetText ConvertPath (gTesttoolPath + "global/input/graf_inp/borabora.jpg") sleep 2 @@ -65,15 +61,18 @@ testcase tPraesentationAnimation Call hTypekeys "<TAB>" - Opl_SD_EffekteZulassen '/// open animation dialogue ///' + printlog "open animation dialogue" + Opl_SD_EffekteZulassen Kontext "Animation" for i=1 to 10 - BildAufnehmen.Click '/// add graphic 10 times ///' + printlog "add graphic 10 times" + BildAufnehmen.Click next i sleep 1 - if AnzahlBilder.GetText <> "10" Then '/// get number of frames (should be 10) ///' + printlog "get number of frames (should be 10) " + if AnzahlBilder.GetText <> "10" Then WarnLog " - Adding pictures did not work" else PrintLog " Pictures added" @@ -81,52 +80,63 @@ testcase tPraesentationAnimation if AlleAufnehmen.IsEnabled Then WarnLog " - Add all should not be enabled because only 1 object is selected" - Kontext "DocumentImpress" - EditSelectAll '/// select both graphics in document ///' + Kontext "DocumentImpress" + printlog "select both graphics in document " + EditSelectAll - Kontext "Animation" + Kontext "Animation" + printlog "add them 5 times (10 frames)" for i=1 to 5 - printlog i - AlleAufnehmen.Click '/// add them 5 times (10 frames) ///' + printlog i + AlleAufnehmen.Click next i sleep 1 - if AnzahlBilder.GetText <> "20" Then '/// compare total numbers of frame ///' + printlog "compare total numbers of frame" + if AnzahlBilder.GetText <> "20" Then WarnLog " - Adding pics does not work" else PrintLog " all pics added" end if - ErstesBild.Click '/// jump to 1st frame ///' + printlog "jump to 1st frame" + ErstesBild.Click - if AnzahlBilder.GetText <> "1" Then '/// get number index of selected frame ///' + printlog "get number index of selected frame" + if AnzahlBilder.GetText <> "1" Then WarnLog " - Jump back to beginning does not work" else PrintLog " Jump back to beginning works" end if - LetztesBild.Click '/// jump to last frame ///' + printlog "jump to last frame" + LetztesBild.Click - if AnzahlBilder.GetText <> "20" Then '/// control number index of selected frame ///' + printlog "control number index of selected frame" + if AnzahlBilder.GetText <> "20" Then WarnLog " - Jump to end does not work" else PrintLog " Jumped to end" end if sleep 1 - Abspielen.Click '/// play animation ///' + printlog "play animation" + Abspielen.Click sleep 10 Kontext "DocumentImpress" - EditSelectAll '/// delete graphics in document ///' + printlog "delete graphics in document " + EditSelectAll DocumentImpress.TypeKeys "<DELETE>" sleep 2 Kontext "Animation" - Erstellen.Click '/// create animation ///' + printlog "create animation" + Erstellen.Click sleep 10 Kontext "DocumentImpress" try - EditCopy '/// try to copy created animation to make sure it is created ///' + printlog "try to copy created animation to make sure it is created" + EditCopy PrintLog " Animation created" catch WarnLog " - Animation not created" @@ -134,7 +144,8 @@ testcase tPraesentationAnimation Kontext "Animation" - if AnimationsgruppeGruppenobjekt.IsChecked = True Then '/// set duration time of frames ///' + printlog "set duration time of frames" + if AnimationsgruppeGruppenobjekt.IsChecked = True Then try AnzeigedauerProBild.SetText "1" WarnLog " - Control should be disabled" @@ -143,11 +154,14 @@ testcase tPraesentationAnimation endcatch end if - AnimationsgruppeBitmapobjekt.Check '/// check group object ///' + printlog "check group object" + AnimationsgruppeBitmapobjekt.Check - AnzeigedauerProBild.SetText "3" '/// set frame visibility time to 3 ///' + printlog "set frame visibility time to 3" + AnzeigedauerProBild.SetText "3" SetClipboard AnzeigedauerProBild.GetText - AnzeigedauerProBild.More '/// raise value for frame time ///' + printlog "raise value for frame time" + AnzeigedauerProBild.More if AnzeigedauerProBild.GetText<> GetClipboardText Then PrintLog " Duration per frame works" else @@ -155,7 +169,8 @@ testcase tPraesentationAnimation end if Dim Zaehler - Zaehler = AnzahlDurchlaeufe.GetItemCount '/// test different settings for pass amount ///' + printlog "test different settings for pass amount" + Zaehler = AnzahlDurchlaeufe.GetItemCount for i=1 to Zaehler AnzahlDurchlaeufe.Select i next i @@ -167,36 +182,43 @@ testcase tPraesentationAnimation Anpassung.Select i next i - BildLoeschen.Click '/// delete 1 frame ///' + printlog "delete 1 frame" + BildLoeschen.Click if AnzahlBilder = "20" Then WarnLog " - Deleting pictures does not work" else PrintLog " Picture No.20 deleted" end if - AlleLoeschen.Click '/// delete all frames ///' + printlog "delete all frames" + AlleLoeschen.Click Kontext "Active" Active.Yes sleep 3 Kontext "Animation" - if Abspielen.IsEnabled = true Then '/// check if play button is still active ///' + printlog "check if play button is still active" + if Abspielen.IsEnabled = true Then WarnLog " - Not all pics are deleted" else PrintLog " All pics deleted" end if sleep 2 - Animation.Close '/// close animation flyer ///' + printlog "close animation flyer" + Animation.Close sleep 2 - Call hCloseDocument '/// close document ///' -endcase + printlog "close document " + Call hCloseDocument +endcase 'tPraesentationAnimation '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- testcase tPraesentationEffekt + qaerrorlog "Test not yet ready." goto endsub - Printlog "- Slideshow/Effect" + + Dim i Dim j Dim k @@ -208,11 +230,14 @@ testcase tPraesentationEffekt Dim ZaehlerText Dim ZaehlerTon Dim Zufall - Call hNewDocument '/// new document ///' - '/// check state of navigator ! expected: closed ///' + + Printlog "- Slideshow/Effect" + printlog "new document " + Call hNewDocument + printlog " check state of navigator ! expected: closed" Kontext "Navigator" if Navigator.exists then - '///+ close navigator ! ///' + printlog " close navigator !" Navigator.Close Warnlog "Navigator was open. Check earlier tests. Now closed." else @@ -221,17 +246,22 @@ testcase tPraesentationEffekt sleep 2 kontext "DocumentImpress" gMouseClick 50,50 - hRechteckErstellen (20,20,50,50) '/// create rectangle ///' + printlog "create rectangle" + hRechteckErstellen (20,20,50,50) sleep 3 Kontext "Effekt" Printlog " - Test effects" - gMouseClick 90,90 '/// deselect rectangle ///' + printlog "deselect rectangle" + gMouseClick 90,90 sleep 1 - DocumentImpress.TypeKeys "<TAB>" '/// select rectangle ///' + printlog "select rectangle " + DocumentImpress.TypeKeys "<TAB>" sleep 1 - DocumentImpress.TypeKeys "<F2>" '/// go into text edit mode (F2) ///' + printlog "go into text edit mode (F2)" + DocumentImpress.TypeKeys "<F2>" sleep 1 - DocumentImpress.TypeKeys "test text to test text effects" '/// type text into the rectangle ///' + printlog "type text into the rectangle" + DocumentImpress.TypeKeys "test text to test text effects" sleep 1 DocumentImpress.TypeKeys "<ESCAPE>" sleep 2 @@ -242,7 +272,8 @@ testcase tPraesentationEffekt sleep 3 Effekte.Click Zaehler=Effekteliste.GetItemCount - for i=2 to Zaehler '/// Start from the second entry since the first one is "No effect" ///' + printlog "Start from the second entry since the first one is No effect" + for i=2 to Zaehler Effekteliste.Select i SetClipboard Effekteliste.GetSelText Effekt.TypeKeys "<TAB>" @@ -398,7 +429,7 @@ testcase tPraesentationEffekt Effekt.Close sleep 1 Call hCloseDocument -endcase +endcase 'tPraesentationEffekt '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- @@ -410,14 +441,15 @@ testcase tSlideShowInteraction Datei$ = ConvertPath (gOfficePath + "user\work\interac.odp") - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout sleep 5 - setStartCurrentPage(TRUE) '/// Set "start with current page to ON ///' + printlog "Set start with current page to ON" + setStartCurrentPage(TRUE) - '/// call 'Insert->Slide' three times and name the slides 2, 3, 4 and create a rectangl� on it ///' - '///+ we now have 4 slides ?! :-) ///' + printlog "call 'Insert->Slide' three times and name the slides 2, 3, 4 and create a rectangle on it " + printlog "we now have 4 slides" Kontext "DocumentImpress" for i = 2 to 4 InsertSlide @@ -430,7 +462,7 @@ testcase tSlideShowInteraction sleep 2 next i - '/// check state of navigator ! expected: closed -> open navigator ///' + printlog " check state of navigator ! expected: closed -> open navigator" Kontext "Navigator" if Navigator.exists then qaerrorlog "Navigator: already open :-(" @@ -442,7 +474,7 @@ testcase tSlideShowInteraction endif sleep 3 - '/// Slide Show->Interaction ///' + printlog "Slide Show->Interaction" SlideShowInteraction Kontext "TabInteraktion" sleep 1 @@ -658,7 +690,7 @@ testcase tSlideShowInteraction endif sleep 6 - '/// Do Page down + Page up due to focusing-problems ///' + printlog "Do Page down + Page up due to focusing-problems" kontext "Slides" hTypeKeys "<PAGEDOWN>" hTypeKeys "<PAGEUP>" @@ -828,20 +860,21 @@ testcase tSlideShowInteraction endcatch Kontext "DocumentImpress" - '/// Close the Navigator ///' + printlog "Close the Navigator" DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" sleep 3 - '/// Set "start with current page to ON = Default ///' + printlog "Set start with current page to ON = Default" setStartCurrentPage(TRUE) Call hCloseDocument -endcase +endcase 'tSlideShowInteraction '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- testcase tAendernObjektBenennen Printlog "- Context/Name object" + printlog "new document " Call hNewDocument - Call sSelectEmptyLayout '/// new document ///' + Call sSelectEmptyLayout sleep 1 Kontext "DocumentImpress" @@ -900,7 +933,7 @@ testcase tAendernObjektBenennen sleep 2 Call hCloseDocument sleep 2 -endcase +endcase 'tAendernObjektBenennen '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- @@ -912,23 +945,23 @@ testcase tSlideshowBackgroundAllSlides Background$ = ConvertPath(gOfficeBasisPath + "share\gallery\www-back\chocolate.jpg") Datei$ = ConvertPath (gOfficePath + "user\work\background.odp") - '/// Create a new document ///' + printlog "Create a new document" Printlog "- SlideshowBackground" Call hNewDocument - '/// Insert a new Slide ///' + printlog "Insert a new Slide" Kontext "DocumentImpress" InsertSlide - '/// Open the Contextmenu ///' + printlog "Open the Contextmenu" DocumentImpress.OpenContextMenu - '/// Select the entry "Slide" ///' + printlog "Select the entry Slide" hMenuFindSelect (".uno:PageMenu", true, 1, true) - '/// Select the entry "Background" ///' + printlog "Select the entry Background" hMenuSelectNr (4) - '/// In the open-file dialogue, choose and open a graphic-file you wish to have as a background ///' + printlog "In the open-file dialogue, choose and open a graphic-file you wish to have as a background" kontext "GrafikEinfuegenDlg" If GrafikEinfuegenDlg.Exists Then DateiName.SetText (Background$) @@ -937,7 +970,7 @@ testcase tSlideshowBackgroundAllSlides warnlog "GrafikEinfuegenDlg not existent... check why." End if - '/// If an "active"-message shows up, press "yes" to apply this background to all slides. ///' + printlog "If an active-message shows up, press yes to apply this background to all slides." kontext "Active" if Active.Exists then Active.Yes @@ -945,19 +978,20 @@ testcase tSlideshowBackgroundAllSlides QaErrorLog "No dialogue considering if we wish to apply the background to all slides." end if - '/// Save the document ///' + printlog "Save the document" Call hFileSaveAsKill (Datei$) - '/// Close the document ///' + printlog "Close the document" Call hCloseDocument - '/// Open the document ///' + printlog "Open the document" Call hFileOpen (Datei$) - '/// Close the document ///' + printlog "Close the document" Call hCloseDocument -endcase +endcase 'tSlideshowBackgroundAllSlides '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- testcase tSlideshowBackgroundSelectedSlide + Dim Datei$ as string Dim Background$ as string Dim i as integer @@ -965,23 +999,23 @@ testcase tSlideshowBackgroundSelectedSlide Background$ = ConvertPath(gOfficeBasisPath + "share\gallery\www-back\chocolate.jpg") Datei$ = ConvertPath (gOfficePath + "user\work\background.odp") - '/// Create a new document ///' + printlog "Create a new document" Printlog "- SlideshowBackground" Call hNewDocument - '/// Insert a new Slide ///' + printlog "Insert a new Slide" Kontext "DocumentImpress" InsertSlide - '/// Open the Contextmenu ///' + printlog "Open the Contextmenu" DocumentImpress.OpenContextMenu - '/// Select the entry "Slide" ///' + printlog "Select the entry Slide" hMenuFindSelect (".uno:PageMenu", true, 1, true) - '/// Select the entry "Background" ///' + printlog "Select the entry Background" hMenuSelectNr (4) - '/// In the open-file dialogue, choose and open a graphic-file you wish to have as a background ///' + printlog "In the open-file dialogue, choose and open a graphic-file you wish to have as a background" kontext "GrafikEinfuegenDlg" If GrafikEinfuegenDlg.Exists Then DateiName.SetText (Background$) @@ -990,7 +1024,7 @@ testcase tSlideshowBackgroundSelectedSlide warnlog "GrafikEinfuegenDlg not existent... check why." End if - '/// If an "active"-message shows up, press "No" to only apply this background to the selected slide. ///' + printlog "If an active-message shows up, press No to only apply this background to the selected slide." kontext "Active" if Active.Exists then Active.No @@ -998,14 +1032,14 @@ testcase tSlideshowBackgroundSelectedSlide QaErrorLog "No dialogue considering if we wish to apply the background to all slides." end if - '/// Save the document ///' + printlog "Save the document" Call hFileSaveAsKill (Datei$) - '/// Close the document ///' + printlog "Close the document" Call hCloseDocument - '/// Open the document ///' + printlog "Open the document" Call hFileOpen (Datei$) - '/// Close the document ///' + printlog "Close the document" Call hCloseDocument -endcase +endcase 'tSlideshowBackgroundSelectedSlide '--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/impress/i_slideshow3.inc b/testautomation/graphics/optional/includes/impress/i_slideshow3.inc index e2fe41063926..756eef806aa2 100644 --- a/testautomation/graphics/optional/includes/impress/i_slideshow3.inc +++ b/testautomation/graphics/optional/includes/impress/i_slideshow3.inc @@ -30,125 +30,140 @@ '* short description : '* '******************************************************************* -' #1 tExtrasInteraktion -' #1 tExtrasEffekt -' #1 tExtrasPraesentationseinstellungen -' #1 tExtrasIndividuellePraesentation -' #1 tExtrasInteraktion -' #1 tSlideshowContextMenuOneSlide -' #1 tSlideshowContextMenuMoreSlides -' #1 tiMousePointerHides -'\****************************************************************** testcase tExtrasInteraktion + + Dim i + Dim Zaehler + + Printlog " - SlideShow/Interaction" - Call hNewDocument - Call sSelectEmptyLayout - sleep 1 - Call hTextrahmenErstellen ("Seite 1",10,10,40,40) '/// create textbox ///' - SlideShowPresentationSettings '/// Set slide show settings ///' - Kontext "Bildschirmpraesentation" - NavigatorSichtbar.Check '/// Navigator visible ///' - Bildschirmpraesentation.OK - SlideShowInteraction '/// open Interaction ///' - Kontext "Interaktion" - if Interaktion.exists(5)then - AktionBeiMausklick.Select 1 '/// Select "Go to previous slide" ///' - else - Print "Interaction doesnt exist, something is wrong here." - endif - Interaktion.OK - Kontext "DocumentImpress" - SlideShowSlideshow '/// Run slideshow ///' - Sleep (2) - Kontext "DokumentPraesentation" - DokumentPraesentation.TypeKeys "<ESCAPE>" - Sleep 2 - Kontext "DocumentImpress" - gMouseClick 20,20 - EditSelectAll - try - EditCopy - Printlog " Interaction ->No action works" - Kontext "DocumentImpress" - catch - Warnlog " - Interaction->does not work properly: Should be: Page 2 but it is: " + GetClipboardText - DocumentImpress.TypeKeys "<ESCAPE>" - Kontext "DocumentImpress" - endcatch - hCloseDocument - Call hNewDocument - Call sSelectEmptyLayout - Call hRechteckErstellen (50,50,80,80) '/// create rectangle ///' - SlideShowInteraction - Kontext "Interaktion" - Dim i - Dim Zaehler - Zaehler=AktionBeiMausklick.GetItemCount - For i=2 to Zaehler - AktionBeiMausklick.Select i '/// select actions ///' - SetClipboard AktionBeiMausklick.GetSelText - Interaktion.OK - Kontext "DocumentImpress" - EditSelectAll - SlideShowInteraction - Kontext "Interaktion" + Call hNewDocument + Call sSelectEmptyLayout + sleep 1 + printlog "create textbox" + Call hTextrahmenErstellen ("Seite 1",10,10,40,40) + printlog "Set slide show settings" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + printlog "Navigator visible" + NavigatorSichtbar.Check + Bildschirmpraesentation.OK + printlog "open Interaction" + SlideShowInteraction + Kontext "Interaktion" + if Interaktion.exists(5)then + printlog "Select Go to previous slide" + AktionBeiMausklick.Select 1 + else + Print "Interaction doesnt exist, something is wrong here." + endif + Interaktion.OK + Kontext "DocumentImpress" + printlog "Run slideshow" + SlideShowSlideshow + Sleep (2) + Kontext "DokumentPraesentation" + DokumentPraesentation.TypeKeys "<ESCAPE>" + Sleep 2 + Kontext "DocumentImpress" + gMouseClick 20,20 + EditSelectAll + try + EditCopy + Printlog " Interaction ->No action works" + Kontext "DocumentImpress" + catch + Warnlog " - Interaction->does not work properly: Should be: Page 2 but it is: " + GetClipboardText + DocumentImpress.TypeKeys "<ESCAPE>" + Kontext "DocumentImpress" + endcatch + hCloseDocument + + Call hNewDocument + Call sSelectEmptyLayout + printlog "create rectangle" + Call hRechteckErstellen (50,50,80,80) + SlideShowInteraction + Kontext "Interaktion" + Zaehler=AktionBeiMausklick.GetItemCount + For i=2 to Zaehler + printlog "select actions" + AktionBeiMausklick.Select i + SetClipboard AktionBeiMausklick.GetSelText + Interaktion.OK + Kontext "DocumentImpress" + EditSelectAll + SlideShowInteraction + Kontext "Interaktion" + printlog "control if action is saved (closing reopening dialog)" if GetClipboardText<>AktionBeiMausklick.GetSelText Then - Warnlog " Action at mouseclick - " + GetClipboardText + " - not taken" '/// control if action is saved (closing reopening dialog) ///' + Warnlog " Action at mouseclick - " + GetClipboardText + " - not taken" else - Printlog " Action at mouseclick - " + GetClipboardText + " - runs" + Printlog " Action at mouseclick - " + GetClipboardText + " - runs" end if - next i - Interaktion.OK - sleep 1 - Call hCloseDocument '/// close document ///' -endcase + next i + Interaktion.OK + sleep 1 + printlog "close document" + Call hCloseDocument +endcase 'tExtrasInteraktion + +'------------------------------------------------------------------------------- testcase tExtrasEffekt qaerrorlog "Test not yet ready." - goto endsub - Dim i - Dim j - Dim k - Dim l - Dim m - Dim n - Dim Zaehler - Dim ZaehlerKmh - Dim ZaehlerText - Dim ZaehlerTon - Dim Zufall - Call hNewDocument '/// New impress document ///' - - '/// check state of navigator ! expected: closed ///' - Kontext "Navigator" - if Navigator.exists then - '///+ close navigator ! ///' - Navigator.Close - Warnlog "Navigator was open. Check earlier tests. Now closed." - else - printlog "Navigator: NOT available. Good." - endif - - gMouseClick 50,50 - hRechteckErstellen (20,20,50,50) '/// create rectangle ///' - sleep 2 - DocumentImpress.TypeKeys "<F2>" - DocumentImpress.TypeKeys "- This is text to test the text effects of the Effects flyer" - sleep 1 - gMouseClick 90,90 '/// deselect rectangle ///' - DocumentImpress.TypeKeys "<TAB>" '/// reselect rectangle ///' - - sleep 1 - Kontext "Effekt" + goto endsub + Dim i + Dim j + Dim k + Dim l + Dim m + Dim n + Dim Zaehler + Dim ZaehlerKmh + Dim ZaehlerText + Dim ZaehlerTon + Dim Zufall + + printlog "New impress document" + Call hNewDocument + + printlog " check state of navigator ! expected: closed" + Kontext "Navigator" + if Navigator.exists then + printlog " close navigator !" + Navigator.Close + Warnlog "Navigator was open. Check earlier tests. Now closed." + else + printlog "Navigator: NOT available. Good." + endif + + gMouseClick 50,50 + printlog "create rectangle" + hRechteckErstellen (20,20,50,50) + sleep 2 + DocumentImpress.TypeKeys "<F2>" + DocumentImpress.TypeKeys "- This is text to test the text effects of the Effects flyer" + sleep 1 + printlog "deselect rectangle" + gMouseClick 90,90 + printlog "reselect rectangle" + DocumentImpress.TypeKeys "<TAB>" + + sleep 1 + Kontext "Effekt" Printlog " - Test effect flyer" - SlideShowEffects '/// Open effect flyer ///' - Kontext "ExtrasEffekt" - sleep 1 - Effekte.Click - Zaehler=Effekteliste.GetItemCount '/// select each effect 1 time, assign effect and close dialog ///' - for i=1 to Zaehler '/// reopen dialog and check if the effect is still there ///' + printlog "Open effect flyer" + SlideShowEffects + Kontext "ExtrasEffekt" + sleep 1 + Effekte.Click + printlog "select each effect 1 time, assign effect and close dialog" + Zaehler=Effekteliste.GetItemCount + printlog "reopen dialog and check if the effect is still there" + for i=1 to Zaehler Effekteliste.Select i SetClipboard Effekteliste.GetSelText Effekt.TypeKeys "<TAB>" @@ -159,15 +174,16 @@ testcase tExtrasEffekt SlideShowEffects Kontext "Effekt" sleep 1 - if GetClipboardText<>Effekteliste.GetSelText Then Warnlog " - Invisible color not chosen" - printlog GetClipboardText + " should be " + Effekteliste.GetSelText + if GetClipboardText<>Effekteliste.GetSelText Then Warnlog " - Invisible color not chosen" + printlog GetClipboardText + " should be " + Effekteliste.GetSelText - sleep 1 + sleep 1 next i sleep 2 - Texteffekte.Click '/// test text effects ///' - sleep 1 - ZaehlerKmh=Geschwindigkeit.GetItemCount + printlog "test text effects" + Texteffekte.Click + sleep 1 + ZaehlerKmh=Geschwindigkeit.GetItemCount for j=1 to ZaehlerKmh Geschwindigkeit.Select j SetClipboard Geschwindigkeit.GetSelText @@ -176,14 +192,14 @@ testcase tExtrasEffekt SlideShowEffects Kontext "Effekt" sleep 1 - if GetClipboardText<>Geschwindigkeit.GetSelText Then Warnlog " - Speed not taken over" + if GetClipboardText<>Geschwindigkeit.GetSelText Then Warnlog " - Speed not taken over" next j - Printlog " - Speed test ok" + Printlog " - Speed test ok" - Printlog " - Test text effects" - Texteffekte.Click - sleep 1 - ZaehlerText=TexteffekteListe.GetItemCount + Printlog " - Test text effects" + Texteffekte.Click + sleep 1 + ZaehlerText=TexteffekteListe.GetItemCount for k=1 to ZaehlerText TexteffekteListe.Select k printlog TexteffekteListe.GetSelText + "-effect choosen" @@ -199,19 +215,19 @@ testcase tExtrasEffekt Texteffekte.Click printlog "and when we closed the window and opened again... " + TexteffekteListe.GetSelText + " was choosen" sleep 1 - if GetClipboardText<>TexteffekteListe.GetSelText Then Warnlog " - Texteffect did not changed" - sleep 1 + if GetClipboardText<>TexteffekteListe.GetSelText Then Warnlog " - Texteffect did not changed" + sleep 1 next k Printlog " - Test invisible color" - Effekte.Click - Effekteliste.Select 1 - Effekteauswahl.TypeKeys "<RIGHT>",2 - Zuweisen.Click - sleep 1 - Extras.Click - sleep 1 - randomize - Zufall=((2*Rnd)+1) + Effekte.Click + Effekteliste.Select 1 + Effekteauswahl.TypeKeys "<RIGHT>",2 + Zuweisen.Click + sleep 1 + Extras.Click + sleep 1 + randomize + Zufall=((2*Rnd)+1) for l=1 to 4 UnsichtbarMachen.Click sleep 1 @@ -222,14 +238,15 @@ testcase tExtrasEffekt Kontext "Effekt" sleep 1 Effekteauswahl.TypeKeys "<RIGHT>",2 - Extras.Click '/// test extras ///' + printlog "test extras" + Extras.Click sleep 1 UnsichtbarMachen.Click sleep 1 Zuweisen.Click sleep 1 next l - Printlog " - Blend with color" + Printlog " - Blend with color" sleep 2 for m=1 to 5 MitFarbeAbblenden.Click @@ -251,243 +268,271 @@ testcase tExtrasEffekt sleep 1 ' if GetClipboardText<>Abblendfarbe.GetSelText Then Warnlog " - Blendingcolor did not take over" next m - Printlog " - Test order" - Effekte.Click - sleep 1 - Effekteliste.Select 2 - Zuweisen.Click - Reihenfolge.Click - sleep 1 - sleep 1 - Printlog " - test preview window" - Vorschaufenster.Click '/// open preview window ///' - sleep 1 - Kontext "Vorschau" - if Vorschau.Exists = False Then Warnlog " - Preview window not opened" - Vorschau.Close - Kontext "Effekt" - Extras.Click - if not Klangliste.IsEnabled Then Klang.Click '/// insert sound ///' - sleep 1 -' ZaehlerTon=Klangliste.GetItemCount - for n=1 to 5 - SetClipboard Klangliste.GetSelText - Klangliste.Select n - VollstaendigAbspielen.Click - Effekt.Close - SlideShowEffects - Kontext "Effekt" - sleep 1 - Extras.Click - sleep 1 + Printlog " - Test order" + Effekte.Click + sleep 1 + Effekteliste.Select 2 + Zuweisen.Click + Reihenfolge.Click + sleep 1 + sleep 1 + Printlog " - test preview window" + printlog "open preview window" + Vorschaufenster.Click + sleep 1 + Kontext "Vorschau" + if Vorschau.Exists = False Then Warnlog " - Preview window not opened" + Vorschau.Close + Kontext "Effekt" + Extras.Click + printlog "insert sound" + if not Klangliste.IsEnabled Then Klang.Click + sleep 1 + ' ZaehlerTon=Klangliste.GetItemCount + for n=1 to 5 + SetClipboard Klangliste.GetSelText + Klangliste.Select n + VollstaendigAbspielen.Click + Effekt.Close + SlideShowEffects + Kontext "Effekt" + sleep 1 + Extras.Click + sleep 1 if GetClipboardText<>Klangliste.GetSelText Then Warnlog " - sound did not change" next n - Effekt.Close - sleep 1 - Call hCloseDocument '/// close document ///' -endcase + Effekt.Close + sleep 1 + printlog "close document" + Call hCloseDocument +endcase 'tExtrasEffekt + +'------------------------------------------------------------------------------- testcase tExtrasPraesentationseinstellungen -dim waschecked as boolean - Printlog " - SlideShow/Slideshow settings" - Call hNewDocument '/// New impress document ///' - setStartCurrentPage(FALSE) '/// Set ToolsOptions - Presentation - StartCurrentPage = off ///' - '/// check state of navigator ! expected: closed ///' - Kontext "Navigator" - if Navigator.exists then - '///+ close navigator ! ///' - Navigator.Close - Warnlog "Navigator was open. Check earlier tests. Now closed." - else - printlog "Navigator: NOT available. Good." - endif - Kontext "DocumentImpress" - ExtrasPraesentationseinstellung - Kontext "Bildschirmpraesentation" - AbDia.Check - SetClipboard AbDiaName.GetItemCount - Bildschirmpraesentation.OK - InsertSlide '/// insert slide ///' - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 - SlideShowPresentationSettings '/// slideshow settings ///' - Kontext "Bildschirmpraesentation" - if AbDiaName.GetItemCount <> GetClipboardText Then - Printlog " - Added page appears in list" - else - Warnlog " - Page not added to the list" - end if - AlleDias.Check '/// check all dias///' - Printlog " - Test all slides" - Bildschirmpraesentation.OK - hCloseDocument '/// close document ///' - DateiOeffnen '/// open document (diashow.odp) ///' - Kontext "OeffnenDlg" - if OeffnenDlg.Exists(10) then - Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") - else - Warnlog "Took more then 10 seconds to get the file-open -dialogue open. Ending Test." - goto endsub - endif - Oeffnen.Click - sleep (60) - ' 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." + + dim waschecked as boolean + + Printlog " - SlideShow/Slideshow settings" + printlog "New impress document" + Call hNewDocument + printlog "Set ToolsOptions - Presentation - StartCurrentPage = off" + setStartCurrentPage(FALSE) + printlog " check state of navigator ! expected: closed" + Kontext "Navigator" + if Navigator.exists then + printlog " close navigator !" + Navigator.Close + Warnlog "Navigator was open. Check earlier tests. Now closed." + else + printlog "Navigator: NOT available. Good." + endif + Kontext "DocumentImpress" + ExtrasPraesentationseinstellung + Kontext "Bildschirmpraesentation" + AbDia.Check + SetClipboard AbDiaName.GetItemCount + Bildschirmpraesentation.OK + printlog "insert slide" + InsertSlide + sleep 2 + hTypekeys "<Pagedown>" + sleep 2 + printlog "slideshow settings" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + if AbDiaName.GetItemCount <> GetClipboardText Then + Printlog " - Added page appears in list" + else + Warnlog " - Page not added to the list" + end if + printlog "check all dias" + AlleDias.Check + Printlog " - Test all slides" + Bildschirmpraesentation.OK + printlog "close document" + hCloseDocument + printlog "open document (diashow.odp)" + DateiOeffnen + Kontext "OeffnenDlg" + if OeffnenDlg.Exists(10) then + Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\diashow.odp") + else + Warnlog "Took more then 10 seconds to get the file-open -dialogue open. Ending Test." goto endsub - endif - endif - Kontext "DocumentImpress" - sleep 1 - SlideShowPresentationSettings - Kontext "Bildschirmpraesentation" - if Fenster.IsChecked = False Then '/// slideshow runs in window mode checked ///' - Fenster.Check - Printlog " - Slideshow in window mode" - else - Printlog " - Slideshow in window mode checked" - end if - Bildschirmpraesentation.OK + endif + Oeffnen.Click + sleep (60) + printlog "check if the document is writable" + if fIsDocumentWritable = false then + printlog "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 + Kontext "DocumentImpress" + sleep 1 + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + printlog "slideshow runs in window mode checked" + if Fenster.IsChecked = False Then + Fenster.Check + Printlog " - Slideshow in window mode" + else + Printlog " - Slideshow in window mode checked" + end if + Bildschirmpraesentation.OK Printlog " - Testing slide show" - SlideShowSlideshow '/// run slideshow ///' - sleep (3) - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<pagedown>" - try - Kontext "DocumentImpress" - ViewZoom '/// try using menue entrees (should be disabled while slideshow is running) ///' - Warnlog " - In slide show mode controls shouldn't be enabled" - Kontext "Massstab" - Massstab.OK - catch - Kontext "DocumentPresentation" - Printlog " - Slideshow runs" - endcatch - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" - sleep (5) - - kontext "DocumentPresentation" - if DocumentPresentation.Exists(3) then '/// test if application is still in slideshow mode ///' - warnlog " - We are still in slideshow mode" - DocumentPresentation.TypeKeys "<ESCAPE>" - else - Printlog " - Test Abdia page 3 ended" - endif - - Printlog " - From slides test" - SlideShowPresentationSettings '/// open slideshow settings ///' - Kontext "Bildschirmpraesentation" - Fenster.Check '/// check slideshow in window mode ///' - AbDia.Check - AbDiaName.Select 3 '/// slideshow begins at dia 3///' - Printlog " - From " + AbDiaName.GetSelText + " was the slides shown" - Bildschirmpraesentation.OK - SlideShowSlideshow '/// run slideshow ///' - sleep (3) - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<pagedown>" 'to get to 4 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" ' to get to the end - sleep 2 - '/// Click once more to get out of presentation-mode ///' - DocumentPresentation.TypeKeys "<pagedown>" 'out - sleep (3) - kontext "DocumentPresentation" - if DocumentPresentation.Exists(3) then - warnlog " - We are still in slideshow mode" - DocumentPresentation.TypeKeys "<ESCAPE>" + printlog "run slideshow" + SlideShowSlideshow + sleep (3) + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<pagedown>" + try + Kontext "DocumentImpress" + printlog "try using menue entrees (should be disabled while slideshow is running)" + ViewZoom + Warnlog " - In slide show mode controls shouldn't be enabled" + Kontext "Massstab" + Massstab.OK + catch + Kontext "DocumentPresentation" + Printlog " - Slideshow runs" + endcatch + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" + sleep (5) + + kontext "DocumentPresentation" + printlog "test if application is still in slideshow mode" + if DocumentPresentation.Exists(3) then + warnlog " - We are still in slideshow mode" + DocumentPresentation.TypeKeys "<ESCAPE>" + else + Printlog " - Test Abdia page 3 ended" + endif + + Printlog " - From slides test" + printlog "open slideshow settings" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + printlog "check slideshow in window mode" + Fenster.Check + AbDia.Check + printlog "slideshow begins at dia 3" + AbDiaName.Select 3 + Printlog " - From " + AbDiaName.GetSelText + " was the slides shown" + Bildschirmpraesentation.OK + printlog "run slideshow" + SlideShowSlideshow + sleep (3) + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<pagedown>" 'to get to 4 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" ' to get to the end + sleep 2 + printlog "Click once more to get out of presentation-mode" + DocumentPresentation.TypeKeys "<pagedown>" 'out + sleep (3) + kontext "DocumentPresentation" + if DocumentPresentation.Exists(3) then + warnlog " - We are still in slideshow mode" + DocumentPresentation.TypeKeys "<ESCAPE>" else - Printlog " - Test Abdia page 3 ended" - endif - Printlog " - Repeat endless" - - Kontext "DocumentImpress" - SlideShowPresentationSettings '/// open slideshow settings ///' - Kontext "Bildschirmpraesentation" - if AbDia.IsChecked=True Then AlleDias.Check - if Auto.IsChecked=False Then Auto.Check - Bildschirmpraesentation.OK - sleep (1) - SlideShowSlideshow 'start from 1 - sleep (3) - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<pagedown>" 'to 2 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 3 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 4 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to pause - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 1 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 2 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 3 - sleep 2 - DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" '/// Open the navigator ///' - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 4 - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to pause - sleep 2 - DocumentPresentation.TypeKeys "<pagedown>" 'to 1 - sleep 3 - DocumentPresentation.TypeKeys "<pagedown>" 'to 2 - sleep 3 - DocumentPresentation.TypeKeys "<pagedown>" 'to 3 - sleep 3 - Kontext "NavigatorDraw" - if NavigatorDraw.Exists then - Printlog " The navigator is open. good." - else - Warnlog " The navigator should be accessable. Opening now." - Kontext "DocumentImpress" - DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" - Kontext "NavigatorDraw" - end if - sleep 2 - if Liste.GetSelIndex <> 3 then - Warnlog " - Diashow not repeated: We should be at page no 3, but we are at page no: " + Liste.GetSelIndex - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" '/// Close the Navigator-window ///' - else - Printlog " - Repeat endless does work" - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" '/// Close the Navigator-window ///' - sleep 2 - endif - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<ESCAPE>" - sleep 2 - Kontext "DocumentImpress" - gMouseClick 80,80 - try - SlideShowPresentationSettings '/// test endless repeating setting ///' - Kontext "Bildschirmpraesentation" - Bildschirmpraesentation.OK - Printlog " - Repeat endless" - catch - Warnlog " - We are still in slideshow mode" - DocumentPresentation.TypeKeys "<ESCAPE>" - sleep 5 + Printlog " - Test Abdia page 3 ended" + endif + Printlog " - Repeat endless" + + Kontext "DocumentImpress" + printlog "open slideshow settings" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + if AbDia.IsChecked=True Then AlleDias.Check + if Auto.IsChecked=False Then Auto.Check + Bildschirmpraesentation.OK + sleep (1) + SlideShowSlideshow 'start from 1 + sleep (3) + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<pagedown>" 'to 2 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 3 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 4 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to pause + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 1 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 2 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 3 + sleep 2 + printlog "Open the navigator" + DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 4 + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to pause + sleep 2 + DocumentPresentation.TypeKeys "<pagedown>" 'to 1 + sleep 3 + DocumentPresentation.TypeKeys "<pagedown>" 'to 2 + sleep 3 + DocumentPresentation.TypeKeys "<pagedown>" 'to 3 + sleep 3 + Kontext "NavigatorDraw" + if NavigatorDraw.Exists then + Printlog " The navigator is open. good." + else + Warnlog " The navigator should be accessable. Opening now." + Kontext "DocumentImpress" + DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" + Kontext "NavigatorDraw" + end if + sleep 2 + if Liste.GetSelIndex <> 3 then + Warnlog " - Diashow not repeated: We should be at page no 3, but we are at page no: " + Liste.GetSelIndex + Kontext "DocumentPresentation" + printlog "Close the Navigator-window" + DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" + else + Printlog " - Repeat endless does work" + Kontext "DocumentPresentation" + printlog "Close the Navigator-window" + DocumentPresentation.TypeKeys "<MOD1 SHIFT F5>" + sleep 2 + endif + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<ESCAPE>" + sleep 2 + Kontext "DocumentImpress" + gMouseClick 80,80 + try + printlog "test endless repeating setting" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + Bildschirmpraesentation.OK + Printlog " - Repeat endless" + catch + Warnlog " - We are still in slideshow mode" + DocumentPresentation.TypeKeys "<ESCAPE>" + sleep 5 endcatch - Kontext "DocumentImpress" + Kontext "DocumentImpress" SlideShowPresentationSettings Kontext "BildschirmPraesentation" Fenster.Check - Printlog " - Test slide switching manually" '/// test dia switch manual ///' + printlog "test dia switch manual" + Printlog " - Test slide switching manually" if DiawechselManuel.IsChecked = False Then DiawechselManuel.Check BildschirmPraesentation.Ok sleep 1 @@ -512,592 +557,637 @@ dim waschecked as boolean Kontext "Navigator" sleep 5 - '/// Check state of navigator ! Expected: closed ///' - Kontext "Navigator" - if Navigator.exists then - '///+ Close Navigator ! ///' - Navigator.Close - Warnlog "Navigator: Should have been closed. Closing now." - else - printlog "Navigator: not available - Good" - endif - Kontext "DokumentPraesentation" - DokumentPraesentation.TypeKeys "<ESCAPE>" '/// Exit presentation-mode ///' - Kontext "DocumentImpress" - Call hCloseDocument '/// close document ///' -endcase + printlog " Check state of navigator ! Expected: closed" + Kontext "Navigator" + if Navigator.exists then + printlog " Close Navigator !" + Navigator.Close + Warnlog "Navigator: Should have been closed. Closing now." + else + printlog "Navigator: not available - Good" + endif + Kontext "DokumentPraesentation" + printlog "Exit presentation-mode" + DokumentPraesentation.TypeKeys "<ESCAPE>" + Kontext "DocumentImpress" + printlog "close document" + Call hCloseDocument +endcase 'tExtrasPraesentationseinstellungen + +'------------------------------------------------------------------------------- testcase tExtrasIndividuellePraesentation Printlog "- Slideshow/Individual slideshow" - Call hNewDocument '/// new impress document ///' - '/// Deactivate "Start with current page" in ToolsOptions ///' - setStartCurrentPage(FALSE) - '/// check state of navigator ! expected: closed ///' - Kontext "Navigator" - if Navigator.exists then - '///+ close navigator ! ///' - Navigator.Close - Warnlog "Navigator was open. Check earlier tests. Now closed." - else - printlog "Navigator: NOT available. Good." - endif - Printlog " - insert 3 slides for the individual slide show" - SlideShowPresentationSettings '/// open slide show settings ///' - Kontext "Bildschirmpraesentation" - Fenster.Check - Bildschirmpraesentation.OK - InsertSlide '/// insert slide ///' - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 - InsertSlide - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 - InsertSlide '/// insert another slide ///' - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 - Printlog " - Slides added" - sleep 1 - Kontext "DocumentImpress" - DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" '/// open navigator ///' - sleep 1 - Kontext "NavigatorDraw" + Call hNewDocument + printlog "new impress document" + Call sSelectEmptyLayout + printlog "Deactivate Start with current page in ToolsOptions" + setStartCurrentPage(FALSE) + printlog " check state of navigator ! expected: closed" + Kontext "Navigator" + if Navigator.exists then + printlog " close navigator !" + Navigator.Close + Warnlog "Navigator was open. Check earlier tests. Now closed." + else + printlog "Navigator: NOT available. Good." + endif + Printlog " - insert 3 slides for the individual slide show" + printlog "open slide show settings" + SlideShowPresentationSettings + Kontext "Bildschirmpraesentation" + Fenster.Check + Bildschirmpraesentation.OK + printlog "insert slide" + InsertSlide + sleep 2 + Call sSelectEmptyLayout + hTypekeys "<Pagedown>" + sleep 2 + InsertSlide + sleep 2 + Call sSelectEmptyLayout + hTypekeys "<Pagedown>" + sleep 2 + printlog "insert another slide" + InsertSlide + sleep 2 + Call sSelectEmptyLayout + hTypekeys "<Pagedown>" + sleep 2 + Printlog " - Slides added" + sleep 1 + Kontext "DocumentImpress" + printlog "open navigator" + DocumentImpress.TypeKeys "<MOD1 SHIFT F5>" + sleep 1 + Kontext "NavigatorDraw" if NavigatorDraw.Exists Then - Printlog " - Navigator exists" - Erste.Click '/// switch to 1st slide ///' - Kontext "DocumentImpress" - DocumentImpress.MouseDown ( 50, 50 ) '/// Make a click onto the slide to focus onto that ///' - DocumentImpress.MouseUp ( 50, 50 ) - hRechteckErstellen (10,10,20,20) '/// create rectangle ///' - Kontext "NavigatorDraw" - Naechste.Click '/// switch to 2nd slide ///' - Kontext "DocumentImpress" - hRechteckErstellen (30,30,40,40) '/// create another rectangle ///' - Kontext "NavigatorDraw" - Naechste.Click '/// switch to 3rd slide ///' - Kontext "DocumentImpress" - hRechteckErstellen (40,40,50,50) '/// create rectangle ///' - Kontext "NavigatorDraw" - Naechste.Click '/// switch to next slide ///' - Kontext "DocumentImpress" - hRechteckErstellen (30,30,40,40) '/// create rectangle ///' - Printlog " - Created rectangles on all slides" - else - Warnlog " No Navigator" - end if - sleep 1 - SlideShowCustomSlideshow '/// open custom slideshow ///' - Kontext "IndividuellePraesentation" - Printlog " - Create new slideshow" - Neu.Click '/// create new individual slideshow ///' - Kontext "IndividuellePraesentationDefinieren" - PraesentationName.SetText "Test 1" '/// set name of individiual slideshow to Test 1 ///' - Dim i - Dim Zaehler - Zaehler=SeitenPraesentation.GetItemCount '/// add slides to presentation ///' - For i=1 to Zaehler - SeitenPraesentation.SetNoSelection - SeitenPraesentation.Select i - Hinzufuegen.Click - if SelectedSlides.GetItemCount=i Then - Printlog " - slide added to slideshow" - else - Warnlog " Count does not match selection. Should be: "+ i + " but is: "+ IndividuellePraesentation.GetItemCount - end if - next i - Printlog " - Add slides using multiple selections" - SeitenPraesentation.Select 1 - Hinzufuegen.Click - SeitenPraesentation.Select 2 - Hinzufuegen.Click - SeitenPraesentation.Select 3 - Hinzufuegen.Click - SeitenPraesentation.Select 4 - Hinzufuegen.Click - - if SelectedSlides.GetItemCount=8 Then '/// control number of added slides ///' - Printlog " - slides has been added, multiple selection is working" - else - Warnlog " Multiple selection does not work" - end if - - IndividuellePraesentationDefinieren.OK - sleep 2 - Kontext "IndividuellePraesentation" - if IndividuellePraesentationBenutzen.IsChecked=False Then IndividuellePraesentationBenutzen.Check - sleep 2 - Starten.Click '/// run presentation ///' - Printlog " - Individual slideshow started" - sleep 5 - Kontext "Navigator" '/// Check if the navigator exists, if so - close it ///' - if Navigator.Exists Then - Printlog " - Navigator exists, we close it" - Navigator.Close '/// close navigator ///' - sleep 2 - end if - Kontext "DocumentPresentation" - sleep 3 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<RETURN>" - sleep 2 - DocumentPresentation.TypeKeys "<ESCAPE>" - sleep 5 + Printlog " - Navigator exists" + printlog "switch to 1st slide" + Erste.Click + Kontext "DocumentImpress" + printlog "Make a click onto the slide to focus onto that" + DocumentImpress.MouseDown ( 50, 50 ) + DocumentImpress.MouseUp ( 50, 50 ) + printlog "create rectangle" + hRechteckErstellen (10,10,20,20) + Kontext "NavigatorDraw" + printlog "switch to 2nd slide" + Naechste.Click + Kontext "DocumentImpress" + printlog "create another rectangle" + hRechteckErstellen (30,30,40,40) + Kontext "NavigatorDraw" + printlog "switch to 3rd slide" + Naechste.Click + Kontext "DocumentImpress" + printlog "create rectangle" + hRechteckErstellen (40,40,50,50) + Kontext "NavigatorDraw" + printlog "switch to next slide" + Naechste.Click + Kontext "DocumentImpress" + printlog "create rectangle" + hRechteckErstellen (50,50,60,60) + Printlog " - Created rectangles on all slides" + else + Warnlog " No Navigator" + end if + sleep 1 + printlog "open custom slideshow" + SlideShowCustomSlideshow + Kontext "IndividuellePraesentation" + printlog "create new individual slideshow" + Neu.Click + Kontext "IndividuellePraesentationDefinieren" + printlog "set name of individiual slideshow to Test 1" + PraesentationName.SetText "Test 1" + Dim i + Dim Zaehler + printlog "add slides to presentation" + Zaehler=SeitenPraesentation.GetItemCount + For i=1 to Zaehler + SeitenPraesentation.SetNoSelection + SeitenPraesentation.Select i + Hinzufuegen.Click + if SelectedSlides.GetItemCount=i Then + Printlog " - slide added to slideshow" + else + Warnlog " Count does not match selection. Should be: "+ i + " but is: "+ IndividuellePraesentation.GetItemCount + end if + next i + Printlog " - Add slides using multiple selections" + SeitenPraesentation.Select 1 + Hinzufuegen.Click + SeitenPraesentation.Select 2 + Hinzufuegen.Click + SeitenPraesentation.Select 3 + Hinzufuegen.Click + SeitenPraesentation.Select 4 + Hinzufuegen.Click + + printlog "control number of added slides" + if SelectedSlides.GetItemCount=8 Then + Printlog " - slides has been added, multiple selection is working" + else + Warnlog " Multiple selection does not work" + end if + + IndividuellePraesentationDefinieren.OK + sleep 2 +>>>>>>> ooo/DEV300_m101 Kontext "IndividuellePraesentation" - if IndividuellePraesentation.IsVisible=False Then - Warnlog " Slideshow should have ended" - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<ESCAPE>" - else - printlog " Presentation seems to have ended successfully" - end if + if IndividuellePraesentationBenutzen.IsChecked=False Then IndividuellePraesentationBenutzen.Check + sleep 2 + printlog "run presentation" + Starten.Click + Printlog " - Individual slideshow started" + sleep 5 + printlog "Check if the navigator exists, if so - close it" + Kontext "Navigator" + if Navigator.Exists Then + Printlog " - Navigator exists, we close it" + printlog "close navigator" + Navigator.Close + sleep 2 + end if + Kontext "DocumentPresentation" + sleep 3 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<RETURN>" + sleep 2 + DocumentPresentation.TypeKeys "<ESCAPE>" + sleep 5 + Kontext "IndividuellePraesentation" + if IndividuellePraesentation.IsVisible=False Then + Warnlog " Slideshow should have ended" + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<ESCAPE>" + else + printlog " Presentation seems to have ended successfully" + end if + + sleep 2 - sleep 2 + Kontext "IndividuellePraesentation" + printlog "Close custom slideshow" + IndividuellePraesentation.Close + + printlog "Navigator: Control if right slide is displayed" + Kontext "NavigatorDraw" + printlog " Now we switch to the navigator again" + printlog "Unless -Start on first slide- is activated? Default = No" + if Liste.GetSelIndex <> 4 then + Warnlog " This is not the right slide, it should be 4 but is: " + Liste.GetSelIndex + else + Printlog " - Individual slideshow seems to work" + end if + printlog "open custom slideshow" + SlideShowCustomSlideshow + printlog "Set Start with current page back to default = on, in ToolsOptions" + Kontext "IndividuellePraesentation" + if IndividuellePraesentationBenutzen.IsChecked=False Then IndividuellePraesentationBenutzen.Check + IndividuellePraesentation.Close + sleep 2 + Kontext "Navigator" 'Draw + if Navigator.exists then + printlog "Close the Navigator" + Navigator.Close + Kontext "NavigatorDraw" + if NavigatorDraw.exists then + NavigatorDraw.Close + endif + else + printlog "Navigator: NOT available. Good." + endif + Kontext "DocumentImpress" + setStartCurrentPage(TRUE) + printlog "close document" + Call hCloseDocument +endcase 'tExtrasIndividuellePraesentation - Kontext "IndividuellePraesentation" - IndividuellePraesentation.Close '/// Close custom slideshow ///' - - Kontext "NavigatorDraw" '/// Navigator: Control if right slide is displayed ///' - printlog " Now we switch to the navigator again" - if Liste.GetSelIndex <> 4 then '/// Unless -Start on first slide- is activated? Default = No ///' - Warnlog " This is not the right slide, it should be 4 but is: " + Liste.GetSelIndex - else - Printlog " - Individual slideshow seems to work" - end if - SlideShowCustomSlideshow '/// open custom slideshow ///' - '/// Set "Start with current page" back to default = on, in ToolsOptions ///' - Kontext "IndividuellePraesentation" - if IndividuellePraesentationBenutzen.IsChecked=False Then IndividuellePraesentationBenutzen.Check - IndividuellePraesentation.Close - sleep 2 - Kontext "Navigator" 'Draw - if Navigator.exists then - Navigator.Close '/// Close the Navigator ///' - Kontext "NavigatorDraw" - if NavigatorDraw.exists then - NavigatorDraw.Close - endif - else - printlog "Navigator: NOT available. Good." - endif - Kontext "DocumentImpress" - setStartCurrentPage(TRUE) - Call hCloseDocument '/// close document ///' -endcase - -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSlideshowContextMenuOneSlide + qaerrorlog "Test not yet ready." - goto endsub - dim NumberOfEntries as Integer - Printlog "- ContextMenu in Slideshow" - '/// New Impress Document ///' - Call hNewDocument - - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - '/// Check that the right mousebutton brings up the Context-Menu. ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - '/// Check that the right-click brought up a Context-Menu. ///' - '/// And check the number of Menu-Positions (there should be XXX of them ) ///' - NumberOfEntries = 0 - sleep 2 - try - NumberOfEntries = MenuGetItemCount - catch - warnlog " No ContextMenu found? Please inform the Automatic Tester" - kontext "DocumentImpress" - hOpenContextMenu - NumberOfEntries = MenuGetItemCount - endcatch - if (NumberOfEntries = 0) then - Warnlog " the Context-Menu doesnt contain any entries, or were not up. Test ends." - Goto Endsub - endif - if NumberOfEntries <> 3 then - warnlog " Expected three entries in this Menu, but found " + NumberOfEntries -' if NumberOfEntries <> 6 then -' warnlog " Expected six entries in this Menu, but found " + NumberOfEntries - else - printlog " Number of Entries was: " + NumberOfEntries - endif - '/// Check that every position contains the expected Undermenu. ("Screen": Black/White. and "End Slideshow") ///' - '/// And check that Menu-Item one opens an undermenu. ///' - Printlog " We open number one: " + MenuGetItemText(MenuGetItemID(1)) - hMenuSelectNr (1) - sleep 2 - NumberOfEntries = MenuGetItemCount - printlog " Menu-entries: " + MenuGetItemCount - if (NumberOfEntries <> 2) then - Warnlog " the third Context-Menu-entry was NOT 'Screen'." - else - Printlog " We open the next number one: " + MenuGetItemText(MenuGetItemID(1)) - hMenuSelectNr (1) - endif - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - hMenuSelectNr (1) 'Open the Screen -menu. - sleep 2 - Printlog " We open number two: " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) - hMenuSelectNr (2) 'Choose "White" - sleep 2 - - 'TODO - Due to existing bug, function not yet available. - '/// Change to slideshow-ending. Check that the Context-Menu also comes up here. ///' - 'DocumentPresentation. - hTypeKeys "<SPACE>" - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - NumberOfEntries = 0 - NumberOfEntries = MenuGetItemCount - if NumberOfEntries <> 0 then - printlog " Menu-entries: " + MenuGetItemCount - else - warnlog " No context-menu at Slideshow-endpage." - DocumentPresentation.TypeKeys "<ESCAPE>" - endif - - '/// And that one can go back. ///' - hMenuSelectNr (1) 'Open the Goto Slide -menu. - sleep 2 - Printlog " We open number one (should be 'Goto First Slide'): " + MenuGetItemText(MenuGetItemID(1)) - hMenuSelectNr (2) 'Choose "Back" 'TODO ;: but now we just end the slideshow - sleep 2 - - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<ESCAPE>" - DocumentPresentation.TypeKeys "<ESCAPE>" - Kontext "DocumentImpress" - InsertSlide - - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - '/// Check that the right mousebutton brings up the Context-Menu. ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - '/// Check that Menu-Item (three) really finishes the presentation. ///' - Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) - hMenuSelectNr (4) 'MenuGetItemCount) 'End Slideshow - if DocumentPresentation.Exists then - Warnlog "either wrong position for 'End Slideshow', or the command didnt work." - else - printlog "The presentation was closed, good." - endif - - '/// Check that one can step one step forward, even if there is no more than one slide. ///' - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - '/// Check that the right mousebutton brings up the Context-Menu. ///' - sleep (2) - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - - '/// Select the 'one step forward' -entry ///' - hMenuSelectNr (1) - - '/// Check that we're on the last slide ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - if MenuIsItemEnabled (MenugetItemID(4)) then - printlog "Jumped to the right slide" - else - warnlog "possibly the 'jump to slide' -menu didnt quite work" - endif - - '/// Close the Context-Menu ///' - hMenuSelectNr (0) - Kontext "DocumentPresentation" - - '/// Check if the context-menu also comes up at the very last page (slideshow-ending) ///' - DocumentPresentation.TypeKeys "<SPACE>" -' DocumentPresentation.TypeKeys "<SPACE>" - sleep 1 - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - if MenuGetItemText (MenuGetItemID(1)) <> "" then - Printlog "Context-menu came up at the last page: correct." - else - Warnlog "Context-menu did NOT come up correctly at the last page: false." - endif - - '/// Check if we from here, via the context menu, can go back to the first page ///' - hMenuSelectNr (2) 'Open the Goto Slide -menu. - sleep 1 - hMenuSelectNr (1) 'First Slide - - '/// Check that we're on the first slide ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - if MenuIsItemEnabled (MenugetItemID(3)) then - printlog "Jumped to the right slide" - else - warnlog "possibly the 'jump to slide' -menu didnt quite work from the last slide" - endif - - '/// Close the Context-Menu ///' - MenuSelect (0) - '/// Close the Presentation ///' - hTypeKeys "<ESCAPE>" - '/// Close Document ///' - Call hCloseDocument + goto endsub + + dim NumberOfEntries as Integer + + Printlog "- ContextMenu in Slideshow" + printlog "New Impress Document" + Call hNewDocument + + printlog "Start the Slideshow." + hTypeKeys "<F5>" + printlog "Check that the right mousebutton brings up the Context-Menu." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + printlog "Check that the right-click brought up a Context-Menu." + printlog "And check the number of Menu-Positions (there should be XXX of them )" + NumberOfEntries = 0 + sleep 2 + try + NumberOfEntries = MenuGetItemCount + catch + warnlog " No ContextMenu found? Please inform the Automatic Tester" + kontext "DocumentImpress" + hOpenContextMenu + NumberOfEntries = MenuGetItemCount + endcatch + if (NumberOfEntries = 0) then + Warnlog " the Context-Menu doesnt contain any entries, or were not up. Test ends." + Goto Endsub + endif + if NumberOfEntries <> 3 then + warnlog " Expected three entries in this Menu, but found " + NumberOfEntries + ' if NumberOfEntries <> 6 then + ' warnlog " Expected six entries in this Menu, but found " + NumberOfEntries + else + printlog " Number of Entries was: " + NumberOfEntries + endif + printlog "Check that every position contains the expected Undermenu. (Screen: Black/White. and End Slideshow)" + printlog "And check that Menu-Item one opens an undermenu." + Printlog " We open number one: " + MenuGetItemText(MenuGetItemID(1)) + hMenuSelectNr (1) + sleep 2 + NumberOfEntries = MenuGetItemCount + printlog " Menu-entries: " + MenuGetItemCount + if (NumberOfEntries <> 2) then + Warnlog " the third Context-Menu-entry was NOT 'Screen'." + else + Printlog " We open the next number one: " + MenuGetItemText(MenuGetItemID(1)) + hMenuSelectNr (1) + endif + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + printlog "Open the Screen -menu." + hMenuSelectNr (1) + sleep 2 + Printlog " We open number two: " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) + printlog "Choose White" + hMenuSelectNr (2) + sleep 2 + + 'TODO - Due to existing bug, function not yet available. + printlog "Change to slideshow-ending. Check that the Context-Menu also comes up here." + 'DocumentPresentation. + hTypeKeys "<SPACE>" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + NumberOfEntries = 0 + NumberOfEntries = MenuGetItemCount + if NumberOfEntries <> 0 then + printlog " Menu-entries: " + MenuGetItemCount + else + warnlog " No context-menu at Slideshow-endpage." + DocumentPresentation.TypeKeys "<ESCAPE>" + endif + + printlog "And that one can go back." + hMenuSelectNr (1) 'Open the Goto Slide -menu. + sleep 2 + Printlog " We open number one (should be 'Goto First Slide'): " + MenuGetItemText(MenuGetItemID(1)) + hMenuSelectNr (2) 'Choose "Back" 'TODO ;: but now we just end the slideshow + sleep 2 + + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<ESCAPE>" + DocumentPresentation.TypeKeys "<ESCAPE>" + Kontext "DocumentImpress" + InsertSlide + + printlog "Start the Slideshow." + hTypeKeys "<F5>" + printlog "Check that the right mousebutton brings up the Context-Menu." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + printlog "Check that Menu-Item (three) really finishes the presentation." + Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) + hMenuSelectNr (4) 'MenuGetItemCount) 'End Slideshow + if DocumentPresentation.Exists then + Warnlog "either wrong position for 'End Slideshow', or the command didnt work." + else + printlog "The presentation was closed, good." + endif + + printlog "Check that one can step one step forward, even if there is no more than one slide." + printlog "Start the Slideshow." + hTypeKeys "<F5>" + printlog "Check that the right mousebutton brings up the Context-Menu." + sleep (2) + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + printlog "Open the Goto Slide -menu" + hMenuSelectNr (2) + printlog "Select the 'one step forward' -entry" + hMenuSelectNr (1) + + printlog "Check that we're on the last slide" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + hMenuSelectNr (2) + if MenuIsItemEnabled (MenugetItemID(4)) then + printlog "Jumped to the right slide" + else + warnlog "possibly the 'jump to slide' -menu didnt quite work" + endif + + printlog "Close the Context-Menu" + hMenuSelectNr (0) + Kontext "DocumentPresentation" + + printlog "Check if the context-menu also comes up at the very last page (slideshow-ending)" + DocumentPresentation.TypeKeys "<SPACE>" + sleep 1 + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + if MenuGetItemText (MenuGetItemID(1)) <> "" then + Printlog "Context-menu came up at the last page: correct." + else + Warnlog "Context-menu did NOT come up correctly at the last page: false." + endif + + printlog "Check if we from here, via the context menu, can go back to the first page" + hMenuSelectNr (2) 'Open the Goto Slide -menu. + sleep 1 + hMenuSelectNr (1) 'First Slide + + printlog "Check that we're on the first slide" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + hMenuSelectNr (2) 'Open the Goto Slide -menu. + if MenuIsItemEnabled (MenugetItemID(3)) then + printlog "Jumped to the right slide" + else + warnlog "possibly the 'jump to slide' -menu didnt quite work from the last slide" + endif + + printlog "Close the Context-Menu" + MenuSelect (0) + printlog "Close the Presentation" + hTypeKeys "<ESCAPE>" + printlog "Close Document" + Call hCloseDocument endcase 'tSlideshowContextMenuOneSlide -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tSlideshowContextMenuMoreSlides + qaerrorlog "Test not yet ready." - goto endsub - dim NumberOfEntries as Integer - Printlog "- ContextMenu in Slideshow" - '/// New Impress Document ///' - Call hNewDocument - '/// Insert three new Slides ///' - InsertSlide - InsertSlide - InsertSlide - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - sleep (3) - '/// Check that the right mousebutton brings up the Context-Menu. ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - '/// Check that the right-click brought up a Context-Menu. ///' - '/// And check the number of Menu-Positions (there should be XXX of them ) ///' - NumberOfEntries = 0 - sleep 2 - try - NumberOfEntries = MenuGetItemCount - catch - warnlog " No ContextMenu found? Please inform the Automatic Tester" - kontext "DocumentImpress" - hOpenContextMenu - NumberOfEntries = MenuGetItemCount - endcatch - if (NumberOfEntries = 0) then - Warnlog " the Context-Menu doesnt contain any entries, or were not up. Test ends." - Goto Endsub - endif - if NumberOfEntries <> 6 then - warnlog " Expected six entries in this Menu, but found " + NumberOfEntries - else - printlog " Number of Entries was: " + NumberOfEntries - endif - '/// Check that every position contains the expected Undermenu. ("Screen": Black/White. and "End Slideshow") ///' - '/// And check that Menu-Item one opens an undermenu. ///' - Printlog " We open number four: " + MenuGetItemText(MenuGetItemID(4)) - hMenuSelectNr (3) - sleep 2 - NumberOfEntries = MenuGetItemCount - printlog " Menu-entries: " + MenuGetItemCount - if (NumberOfEntries <> 2) then - Warnlog " the first Context-Menu-entry was NOT 'Screen'." - else - Printlog " We open the next number one: " + MenuGetItemText(MenuGetItemID(1)) - hMenuSelectNr (1) - endif - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - hMenuSelectNr (3) 'Open the Screen -menu. - sleep 2 - Printlog " We open number two: " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) - hMenuSelectNr (2) 'Choose "White" - sleep 2 - - 'TODO - Due to existing bug, function not yet available. - '/// Change to slideshow-ending. Check that the Context-Menu also comes up here. ///' - 'DocumentPresentation. - hTypeKeys "<SPACE>" - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - NumberOfEntries = 0 - NumberOfEntries = MenuGetItemCount - if NumberOfEntries <> 0 then - printlog " Menu-entries: " + MenuGetItemCount - else - warnlog " No context-menu at Slideshow-endpage." - DocumentPresentation.TypeKeys "<ESCAPE>" - endif - - '/// And that one can go back. ///' - hMenuSelectNr (2) 'Open the Goto Slide -menu. - sleep 2 - Printlog " We open number one (should be 'Goto First Slide'): " + MenuGetItemText(MenuGetItemID(1)) - hMenuSelectNr (2) 'Choose "Back" 'TODO ;: but now we just end the slideshow - sleep 2 - - Kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<ESCAPE>" - DocumentPresentation.TypeKeys "<ESCAPE>" - Kontext "DocumentImpress" - - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - '/// Check that the right mousebutton brings up the Context-Menu. ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - '/// Check that Menu-Item (three) really finishes the presentation. ///' - Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) - hMenuSelectNr (4)'MenuGetItemCount) 'End Slideshow - sleep 4 - if DocumentPresentation.Exists then - Warnlog "either wrong position for 'End Slideshow', or the command didnt work." - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) - hMenuSelectNr (4)'MenuGetItemCount) 'End Slideshow - else - printlog "The presentation was closed, good." - endif - - '/// Check that one can step one step forward, even if there is no more than one slide. ///' - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - sleep (3) - '/// Check that the right mousebutton brings up the Context-Menu. ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - - '/// Select the 'one step forward' -entry ///' - hMenuSelectNr (1) - - '/// Check that we're on the last slide ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - if MenuIsItemEnabled (MenugetItemID(4)) then - printlog "Jumped to the right slide" - else - warnlog "possibly the 'jump to slide' -menu didnt quite work" - endif - - '/// Close the Context-Menu ///' - hMenuSelectNr (0) - Kontext "DocumentPresentation" - - '/// Check if the context-menu also comes up at the very last page (slideshow-ending) ///' - DocumentPresentation.TypeKeys "<SPACE>" - sleep 1 - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - if MenuGetItemText (MenuGetItemID(1)) <> "" then - Printlog "Context-menu came up at the last page: correct." - else - Warnlog "Context-menu did NOT come up correctly at the last page: false." - endif - - '/// Check if we from here, via the context menu, can go back to the first page ///' - hMenuSelectNr (2) 'Open the Goto Slide -menu. - sleep 1 - hMenuSelectNr (1) 'First Slide - - '/// Check that we're on the first slide ///' - Kontext "DocumentPresentation" - DocumentPresentation.MouseDown 50, 50, 3 - DocumentPresentation.MouseUp 50, 50, 3 - sleep 2 - - hMenuSelectNr (2) 'Open the Goto Slide -menu. - if MenuIsItemEnabled (MenugetItemID(3)) then - printlog "Jumped to the right slide" - else - warnlog "possibly the 'jump to slide' -menu didnt quite work from the last slide" - endif - - '/// Close the Context-Menu ///' - MenuSelect (0) - '/// Close the Presentation ///' - hTypeKeys "<ESCAPE>" - '/// Close Document ///' - Call hCloseDocument + goto endsub + + dim NumberOfEntries as Integer + + Printlog "- ContextMenu in Slideshow" + printlog "New Impress Document" + Call hNewDocument + printlog "Insert three new Slides" + InsertSlide + InsertSlide + InsertSlide + printlog "Start the Slideshow." + hTypeKeys "<F5>" + sleep (3) + printlog "Check that the right mousebutton brings up the Context-Menu." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + printlog "Check that the right-click brought up a Context-Menu." + printlog "And check the number of Menu-Positions (there should be XXX of them )" + NumberOfEntries = 0 + sleep 2 + try + NumberOfEntries = MenuGetItemCount + catch + warnlog " No ContextMenu found? Please inform the Automatic Tester" + kontext "DocumentImpress" + hOpenContextMenu + NumberOfEntries = MenuGetItemCount + endcatch + if (NumberOfEntries = 0) then + Warnlog " the Context-Menu doesnt contain any entries, or were not up. Test ends." + Goto Endsub + endif + if NumberOfEntries <> 6 then + warnlog " Expected six entries in this Menu, but found " + NumberOfEntries + else + printlog " Number of Entries was: " + NumberOfEntries + endif + printlog "Check that every position contains the expected Undermenu. (Screen: Black/White. and End Slideshow)" + printlog "And check that Menu-Item one opens an undermenu." + Printlog " We open number four: " + MenuGetItemText(MenuGetItemID(4)) + hMenuSelectNr (3) + sleep 2 + NumberOfEntries = MenuGetItemCount + printlog " Menu-entries: " + MenuGetItemCount + if (NumberOfEntries <> 2) then + Warnlog " the first Context-Menu-entry was NOT 'Screen'." + else + Printlog " We open the next number one: " + MenuGetItemText(MenuGetItemID(1)) + hMenuSelectNr (1) + endif + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + hMenuSelectNr (3) 'Open the Screen -menu. + sleep 2 + Printlog " We open number two: " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) + hMenuSelectNr (2) 'Choose "White" + sleep 2 + + 'TODO - Due to existing bug, function not yet available. + printlog "Change to slideshow-ending. Check that the Context-Menu also comes up here." + 'DocumentPresentation. + hTypeKeys "<SPACE>" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + NumberOfEntries = 0 + NumberOfEntries = MenuGetItemCount + if NumberOfEntries <> 0 then + printlog " Menu-entries: " + MenuGetItemCount + else + warnlog " No context-menu at Slideshow-endpage." + DocumentPresentation.TypeKeys "<ESCAPE>" + endif + + printlog "And that one can go back." + hMenuSelectNr (2) 'Open the Goto Slide -menu. + sleep 2 + Printlog " We open number one (should be 'Goto First Slide'): " + MenuGetItemText(MenuGetItemID(1)) + hMenuSelectNr (2) 'Choose "Back" 'TODO ;: but now we just end the slideshow + sleep 2 + + Kontext "DocumentPresentation" + DocumentPresentation.TypeKeys "<ESCAPE>" + DocumentPresentation.TypeKeys "<ESCAPE>" + Kontext "DocumentImpress" + + printlog "Start the Slideshow." + hTypeKeys "<F5>" + printlog "Check that the right mousebutton brings up the Context-Menu." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + printlog "Check that Menu-Item (three) really finishes the presentation." + Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) + hMenuSelectNr (4)'MenuGetItemCount) 'End Slideshow + sleep 4 + if DocumentPresentation.Exists then + Warnlog "either wrong position for 'End Slideshow', or the command didnt work." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + Printlog " We open the last entry (End Show): " + MenuGetItemText(MenuGetItemID(MenuGetItemCount)) + hMenuSelectNr (4)'MenuGetItemCount) 'End Slideshow + else + printlog "The presentation was closed, good." + endif + + printlog "Check that one can step one step forward, even if there is no more than one slide." + printlog "Start the Slideshow." + hTypeKeys "<F5>" + sleep (3) + printlog "Check that the right mousebutton brings up the Context-Menu." + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + hMenuSelectNr (2) 'Open the Goto Slide -menu. + + printlog "Select the 'one step forward' -entry" + hMenuSelectNr (1) + + printlog "Check that we're on the last slide" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + hMenuSelectNr (2) 'Open the Goto Slide -menu. + if MenuIsItemEnabled (MenugetItemID(4)) then + printlog "Jumped to the right slide" + else + warnlog "possibly the 'jump to slide' -menu didnt quite work" + endif + + printlog "Close the Context-Menu" + hMenuSelectNr (0) + Kontext "DocumentPresentation" + + printlog "Check if the context-menu also comes up at the very last page (slideshow-ending)" + DocumentPresentation.TypeKeys "<SPACE>" + sleep 1 + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + if MenuGetItemText (MenuGetItemID(1)) <> "" then + Printlog "Context-menu came up at the last page: correct." + else + Warnlog "Context-menu did NOT come up correctly at the last page: false." + endif + + printlog "Check if we from here, via the context menu, can go back to the first page" + hMenuSelectNr (2) 'Open the Goto Slide -menu. + sleep 1 + hMenuSelectNr (1) 'First Slide + + printlog "Check that we're on the first slide" + Kontext "DocumentPresentation" + DocumentPresentation.MouseDown 50, 50, 3 + DocumentPresentation.MouseUp 50, 50, 3 + sleep 2 + + hMenuSelectNr (2) 'Open the Goto Slide -menu. + if MenuIsItemEnabled (MenugetItemID(3)) then + printlog "Jumped to the right slide" + else + warnlog "possibly the 'jump to slide' -menu didnt quite work from the last slide" + endif + + printlog "Close the Context-Menu" + MenuSelect (0) + printlog "Close the Presentation" + hTypeKeys "<ESCAPE>" + printlog "Close Document" + Call hCloseDocument endcase 'tSlideshowContextMenuMoreSlides -'**************************************************************************************************** +'------------------------------------------------------------------------------- testcase tiMousePointerHides + qaerrorlog "Test not yet ready." - goto endsub - dim i as Integer - Printlog "- ContextMenu in Slideshow" - '/// New Impress Document ///' - Call hNewDocument - - '/// Start the Slideshow. ///' - hTypeKeys "<F5>" - sleep 1 - i = 0 - while ((getMouseStyle = 0) AND (i<20)) - sleep 1 - inc (i) - printlog getMouseStyle - if (getMouseStyle <> 0) then i = 20 - wend - if (getMouseStyle <> 0) then - printlog "Mousepointer disappeared like it should have" - else - warnlog "the mousepointer was still visible, after 20 seconds." - endif - - hTypeKeys "<ESCAPE>" - hTypeKeys "<ESCAPE>" - - '/// Close Document ///' - Call hCloseDocument -endcase 'tSlideshowContextMenuMoreSlides + goto endsub -'**************************************************************************************************** + dim i as Integer + Printlog "- ContextMenu in Slideshow" + printlog "New Impress Document" + Call hNewDocument + + printlog "Start the Slideshow." + hTypeKeys "<F5>" + sleep 1 + i = 0 + while ((getMouseStyle = 0) AND (i<20)) + sleep 1 + inc (i) + printlog getMouseStyle + if (getMouseStyle <> 0) then i = 20 + wend + if (getMouseStyle <> 0) then + printlog "Mousepointer disappeared like it should have" + else + warnlog "the mousepointer was still visible, after 20 seconds." + endif + + hTypeKeys "<ESCAPE>" + hTypeKeys "<ESCAPE>" + + printlog "Close Document" + Call hCloseDocument +endcase 'tiMousePointerHides + +'------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/impress/i_stylist.inc b/testautomation/graphics/optional/includes/impress/i_stylist.inc index 7efe28089365..1ef1773a5c55 100644 --- a/testautomation/graphics/optional/includes/impress/i_stylist.inc +++ b/testautomation/graphics/optional/includes/impress/i_stylist.inc @@ -29,15 +29,10 @@ '* '* short description : '* -'******************************************************************* -'* -' #1 tFormatStylistBackground -' #1 fGetSetPageBackground -'* '\******************************************************************* testcase tFormatStylistBackground -'/// special test for BUG # 96364 "Background style looses functionality over PPT Ex/import" ///' + printlog " special test for BUG # 96364 Background style looses functionality over PPT Ex/import" dim sFilter (50) as string dim sFileList (30) as string dim i as integer @@ -59,7 +54,7 @@ testcase tFormatStylistBackground goto endsub endif - '/// if not exists : gOfficePath + '\\user\\impress\\optional\\', create it ///' + printlog " if not exists : gOfficePath + '\\user\\impress\\optional\\', create it" if app.dir (ConvertPath ( gOfficePath + "user/work/impress") ) = "" then app.mkdir ConvertPath ( gOfficePath + "user/work/impress") endif @@ -67,23 +62,23 @@ testcase tFormatStylistBackground app.mkdir ConvertPath ( gOfficePath + "user/work/impress/optional") endif - '/// open application ///' + printlog " open application" Call hNewDocument iColor = 10 - '/// change background color via stylist ///' + printlog " change background color via stylist" if (iColor <> fGetSetPageBackground (iColor,0)) then warnlog "Stylist background was not changed as expected :-( "+iColor endif - '/// check if it is the same in Format -> Page ///' + printlog " check if it is the same in Format -> Page" if fGetSetPageBackground (0,1) <> iColor then warnlog " First stage error! Difference between stylist and menu entry :-( "+iColor endif - '/// save this in 3 formats: ///' - '///+ - StarImpress 5.0 ///' - '///+ - StarOffice 6.0 Presentation ///' - '///+ - Microsoft PowerPoint 97/2000/XP ///' + printlog " save this in 3 formats:" + printlog "+ - StarImpress 5.0" + printlog "+ - StarOffice 6.0 Presentation" + printlog "+ - Microsoft PowerPoint 97/2000/XP" FileSaveAs sleep 2 Kontext "SpeichernDlg" @@ -110,14 +105,14 @@ testcase tFormatStylistBackground printlog " saved with filter ("+i+"/3): "+ sFilter(i) next i - '/// close impress ///' + printlog "close impress" FileClose sleep 1 - kontext ' active about information loss ? + kontext if active.exists (5) then active.yes sleep 10 - '/// open just saved files ///' + printlog " open just saved files" sFileName = ConvertPath ( gOfficePath + "user/work/impress/optional/" ) GetFileList ( sFileName, "isty_*", sFileList() ) @@ -127,23 +122,23 @@ testcase tFormatStylistBackground hFileOpen ( sFileList(i) ) Sleep 5 If hIsNamedDocLoaded (sFileList(i)) Then - printlog " used filter: " + hGetUsedFilter() + printlog "used filter: " + hGetUsedFilter() else warnlog "document didn't get loaded" endif sleep 5 - '/// check if stylist, menue and prediction are as expected ///' + printlog " check if stylist, menue and prediction are as expected" iColor = 10 if ((fGetSetPageBackground (0,0) <> iColor) OR (fGetSetPageBackground (0,1) <> iColor)) then warnlog "Background was not as expected on loading :-( "+iColor endif iColor = 20 - '/// change background in stylist ///' + printlog " change background in stylist" if (fGetSetPageBackground (iColor,0) <> iColor) then warnlog "Stylist background was not changed as expected :-( "+iColor endif sleep 1 - '/// check if background is same in format menu ///' + printlog " check if background is same in format menu" if (fGetSetPageBackground (0,1) <> iColor) then warnlog "Format menu background is wrong :-( "+iColor endif @@ -151,7 +146,7 @@ testcase tFormatStylistBackground hCloseDocument sleep 2 next i -endcase +endcase 'tFormatStylistBackground '------------------------------------------------------------------------------ diff --git a/testautomation/graphics/optional/includes/impress/i_us2_present.inc b/testautomation/graphics/optional/includes/impress/i_us2_present.inc index eeeeb5effb6b..1db9740b577a 100644 --- a/testautomation/graphics/optional/includes/impress/i_us2_present.inc +++ b/testautomation/graphics/optional/includes/impress/i_us2_present.inc @@ -37,14 +37,13 @@ testcase i_us2_pres1 dim iPictures as integer dim PresentationFile1 as string PresentationFile1 = (ConvertPath (gOfficePath + "user\work\PwrPres1.odp")) + kontext "DocumentImpress" - printlog "New - Wizard - Presentation." + printlog "Starting with New - Wizard - Presentation." FileAutopilotPresentation - printlog "Called File-Autopilot-Presentation." - printlog "Create from Template" + printlog "Called File-Autopilot-Presentation, create from template." kontext "AutoPilotPraesentation1" FromTemplate.Check - 'This part is for language-indepencancy if gOOO = TRUE then TemplateRegion.Select (1) printlog "Choose a Presentation" @@ -56,7 +55,7 @@ testcase i_us2_pres1 if TemplateList.GetItemCount < 40 then TemplateRegion.Select (3) if TemplateList.GetItemCount < 40 then - Warnlog " No Templates selectable in the wizard. Please check." + Warnlog "No Templates selectable in the wizard. Please check." goto endsub endif endif @@ -71,29 +70,29 @@ testcase i_us2_pres1 sleep (1) Nextbutton.Click - printlog " Switched to the second Wizard-page." + printlog "Switched to the second Wizard-page." sleep (1) printlog "Presentations" kontext "AutoPilotPraesentation2" printlog "Output: Screen" - if gOOO = TRUE then 'OpenOffice.org + if gOOO = TRUE then Background.Select (2) if Backgroundchoice.GetItemCount < 2 then Background.Select (1) if Backgroundchoice.GetItemCount = 0 then - Warnlog " No Backgrounds selectable in the wizard. Please check." + Warnlog "No Backgrounds selectable in the wizard. Please check." goto endsub endif endif Backgroundchoice.Select (2) - else 'StarOffice + else Background.Select (3) if Backgroundchoice.GetItemCount < 10 then Background.Select (2) if Backgroundchoice.GetItemCount < 10 then Background.Select (3) if Backgroundchoice.GetItemCount < 10 then - Warnlog " No Backgrounds selectable in the wizard. Please check." + Warnlog "No Backgrounds selectable in the wizard. Please check." goto endsub endif endif @@ -104,7 +103,7 @@ testcase i_us2_pres1 printlog "Next" Nextbutton.Click - printlog " Switched to the third Wizard-page." + printlog "Switched to the third Wizard-page." sleep (1) kontext "AutoPilotPraesentation3" printlog "Random Effect. Random Speed. Click through every choice." @@ -118,7 +117,7 @@ testcase i_us2_pres1 printlog "Next" Nextbutton.Click - printlog " Switched to the fourth Wizard-page." + printlog "Switched to the fourth Wizard-page." sleep (1) kontext "AutoPilotPraesentation4" printlog "Fill in some company-name-subject-text" @@ -136,36 +135,50 @@ testcase i_us2_pres1 AutoPilotPraesentation5.OK sleep (1) - printlog " Pressed 'Create'." + printlog "Pressed 'Create'." printlog "Add a Slide via Insert - Slide." Kontext "DocumentImpress" - hTypeKeys "What we will talk about" - gMouseClick 1,1 - Kontext "DocumentImpress" DocumentImpress.UseMenu hMenuSelectNr (4) hMenuSelectNr (1) - call sSelectEmptyLayout + + Kontext "DocumentImpress" + DocumentImpress.UseMenu + hMenuSelectNr (5) + hMenuSelectNr (13) + printlog "Changing focus to TaskPane." + kontext "Tasks" + sleep (1) + printlog "Selecting 5th layout." + LayoutsPreview.TypeKeys "<HOME>" + sleep (1) + LayoutsPreview.TypeKeys "<RIGHT>", 4 + LayoutsPreview.TypeKeys "<RETURN>" sleep (1) + kontext "DocumentImpress" + + sleep (1) + hTypeKeys "What we will talk about" + gMouseClick 1,1 kontext "Slides" - SlidesControl.TypeKeys "<HOME><RETURN>" + SlidesControl.TypeKeys "<HOME>" kontext "DocumentImpress" - DocumentImpress.TypeKeys "<TAB>Text we just wrote..." + DocumentImpress.TypeKeys "<TAB>" + DocumentImpress.TypeKeys "Text we just wrote..." + DocumentImpress.TypeKeys "<ESCAPE>" printlog "Switch to the second slide." kontext "Slides" - SlidesControl.TypeKeys "<DOWN><RETURN>" - SlidesControl.TypeKeys "<RETURN>" + SlidesControl.TypeKeys "<DOWN>" kontext "DocumentImpress" printlog "Insert three lines with text, all with different formatting." call hTextrahmenErstellen ("First line with text",20,50,70,50) call hTextrahmenErstellen ("Second line with text",20,60,70,60) call hTextrahmenErstellen ("Third line with text",20,70,70,70) - printlog "Go down to the eleventh slide." + printlog "Go down to the third slide." kontext "Slides" SlidesControl.TypeKeys "<HOME>" - SlidesControl.TypeKeys "<PAGEDOWN>", 10 - SlidesControl.TypeKeys "<RETURN>" + SlidesControl.TypeKeys "<PAGEDOWN>", 3 printlog "Insert Smiley, + two circles around the eyes, + two new pupils," printlog "placed at some interesteing place inside the circles." Kontext "Toolbar" @@ -202,12 +215,12 @@ testcase i_us2_pres1 hTypeKeys "<Escape>" sleep (1) - printlog "Insert new slide." kontext "Slides" printlog "get to the last slide." - SlidesControl.TypeKeys "<PAGEDOWN>", 15 + SlidesControl.TypeKeys "<PAGEDOWN>", 3 + printlog "Insert 4th slide." SlidesControl.TypeKeys "<RETURN>" - printlog "Delete the two fields the stylist has." + printlog "Delete everything on the page." kontext "DocumentImpress" gMouseClick 1,1 EditSelectAll @@ -220,22 +233,25 @@ testcase i_us2_pres1 Oeffnen.Click gMouseClick 1,1 printlog "Add a text above the picture. 'There is movement..." - call hTextrahmenErstellen ("There is movement...",20,20,70,30) + call hTextrahmenErstellen ("There is movement...",20,40,70,30) printlog "Add a new slide." InsertSlide - printlog " Inserted new slide." + printlog "Inserted new slide." kontext "DocumentImpress" printlog "Bla bla about everything..." - call hTextrahmenErstellen ("Bla bla about everything...",20,20,70,30) + DocumentImpress.TypeKeys "<TAB>" + DocumentImpress.TypeKeys "Bla bla about everything..." + DocumentImpress.TypeKeys "<ESCAPE>",2 printlog "Add a new slide." InsertSlide printlog " Inserted new slide." kontext "DocumentImpress" printlog "Write text: Q & A" - call hTextrahmenErstellen ("Q & A",20,20,70,30) - DocumentImpress.TypeKeys "<SHIFT HOME>" + DocumentImpress.TypeKeys "<TAB>" + DocumentImpress.TypeKeys "Q & A" + DocumentImpress.TypeKeys "<ESCAPE>",2 sleep (1) printlog "Add a new slide." @@ -243,11 +259,13 @@ testcase i_us2_pres1 kontext "DocumentImpress" printlog "Thanks for listening, time for coffee... (ending)" - call hTextrahmenErstellen ("Class dismissed...",20,20,70,30) + DocumentImpress.TypeKeys "<TAB>" + DocumentImpress.TypeKeys "Class dismissed..." + DocumentImpress.TypeKeys "<ESCAPE>",2 printlog "Save Document" call hFileSaveAsKill (PresentationFile1) - printlog "OK saved at ", PresentationFile1 + printlog "OK, saved at ", PresentationFile1 sleep (1) printlog "Close Document" diff --git a/testautomation/graphics/optional/includes/impress/i_us_present.inc b/testautomation/graphics/optional/includes/impress/i_us_present.inc index ee0019586d14..ea0d1ff3af2d 100644 --- a/testautomation/graphics/optional/includes/impress/i_us_present.inc +++ b/testautomation/graphics/optional/includes/impress/i_us_present.inc @@ -31,20 +31,36 @@ '* '\******************************************************************** -testcase i_us_presentation1 +testcase i_us_presentation - dim iPictures as integer - dim PresentationFile1 as string + dim iPictures as integer 'variable for the number of the used picture gallery theme + dim iAnimations as Integer 'variable used for the number of the used animation gallery theme + dim iSize as integer 'step variable + dim sFileName as string 'name for ppt export file + dim iKeyStroke as integer 'counter variable for hitting space in running presentation + dim PresentationFile as string 'variable for the file name - PresentationFile1 = ConvertPath( gOfficePath + "user\work\PowerPes1.odp" ) - printlog "New impress document" + PresentationFile = ConvertPath( gOfficePath + "user\work\PowerPres1.odp" ) + printlog "Setting up an impress document in several steps..." + printlog "1. New impress document" Call hNewDocument - Call sSelectEmptyLayout + Kontext "DocumentImpress" + printlog "Selecting layout: Centered Text" + DocumentImpress.UseMenu + hMenuSelectNr (5) + hMenuSelectNr (13) + printlog "Changing focus to TaskPane." + sleep 1 + Kontext "Tasks" + printlog "to get to the very first position" + LayoutsPreview.TypeKeys "<HOME>" + printlog "'to get to the right position" + LayoutsPreview.TypeKeys "<RIGHT>", 5 + LayoutsPreview.TypeKeys "<RETURN>" WaitSlot (2000) kontext "DocumentImpress" - - printlog "Add second Master-Page " + printlog "Add a second Master-Page " ViewMasterPage kontext "Slides" SlidesControl.OpenContextMenu(true) @@ -54,9 +70,9 @@ testcase i_us_presentation1 sleep (1) printlog "Inserted second Master-Slide" - 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) @@ -111,20 +127,22 @@ testcase i_us_presentation1 MenuSelect 27353 sleep (2) Kontext "ExportierenDlg" + if ExportierenDlg.IsVisible(5) then printlog "Gallery-object correctly copied into Slide." ExportierenDlg.Close WaitSlot (2000) end if + kontext "GraphicObjectbar" + if GraphicObjectbar.Exists(5) = FALSE then kontext "DocumentImpress" ViewToolbarsPicture end if - kontext "Gallery" - Gallerys.Select (iPictures) - printlog " 50% Transparency" + kontext "GraphicObjectbar" + printlog "50% Transparency" WaitSlot (2000) kontext "GraphicObjectbar" Transparenz.SetText "50" @@ -134,23 +152,16 @@ testcase i_us_presentation1 sleep (1) kontext "GraphicFilterBar" Mosaic.Click - WaitSlot (2000) - kontext "Mosaic" - Width.SetText "16" - Height.SetText "16" - Mosaic.OK - - kontext "GraphicFilterBar" - Mosaic.Click kontext "Mosaic" if ( Mosaic.exists( 2 ) ) then Width.SetText "16" Height.SetText "16" Mosaic.OK else - warnlog( "Dialog <Mosaic> did not open" ) + warnlog "Dialog did not came up." endif kontext "GraphicFilterBar" + printlog "Closing dialog and Gallery." GraphicFilterBar.Close ToolsGallery WaitSlot (1000) @@ -158,13 +169,12 @@ testcase i_us_presentation1 gMouseClick 50,50 sleep (1) FormatPositionAndSize - kontext if ( Active.exists( 2 ) ) then active.setPage(TabPositionAndSize) kontext "TabPositionAndSize" - Width.SetText "15" - Height.SetText "11" + Width.SetText "28" + Height.SetText "21" SizePosition.TypeKeys "<RIGHT><DOWN>" TabPositionAndSize.OK else @@ -173,31 +183,26 @@ testcase i_us_presentation1 printlog "Close Master" hUseAsyncSlot( "ViewNormal" ) - + kontext "DocumentImpress" + printlog "Inserting title on first slide." + DocumentImpress.TypeKeys "<TAB>" + DocumentImpress.TypeKeys "<RETURN>" + DocumentImpress.TypeKeys "WELCOME!" + DocumentImpress.TypeKeys "<ESCAPE>", 2 + sleep 1 printlog "Save Document" - call hFileSaveAsKill (PresentationFile1) - + call hFileSaveAsKill (PresentationFile) ActiveDeactivateCTLSupport (FALSE) - printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation1 + printlog "-------------------------------------------------------------------------------" -'------------------------------------------------------------------------------- - -testcase i_us_presentation2 - - dim PresentationFile1 as string - dim PresentationFile2 as string - - PresentationFile1 = ConvertPath( gOfficePath + "user\work\PowerPes1.odp" ) - PresentationFile2 = ConvertPath( gOfficePath + "user\work\PowerPes2.odp" ) - - if ( FileExists( PresentationFile1 ) ) then 'if file exists... - hFileOpen (PresentationFile1) + printlog "2. Loading file again..." + if ( FileExists(PresentationFile) ) then 'if file exists... + hFileOpen (PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if sleep (2) @@ -206,55 +211,46 @@ testcase i_us_presentation2 SlidesControl.TypeKeys( "<PAGEDOWN>", 3 ) SlidesControl.TypeKeys "<SHIFT F10>" 'OpenContextMenu(true) sleep (1) - MenuSelect(MenuGetItemID(1)) 'New Slide 'No 2 - printlog " Inserted second normal Slide" - call sSelectEmptyLayout - printlog "2. Layouts: Text. Bild: Gallery: Animation - Gif" + printlog "Inserted second normal Slide" + printlog "Select 4th Layout: Title and 2 Content blocks" Kontext "Tasks" printlog "to get to the very first position" LayoutsPreview.TypeKeys "<HOME>" printlog "'to get to the right position" - LayoutsPreview.TypeKeys "<RIGHT>", 9 + LayoutsPreview.TypeKeys "<RIGHT>", 3 LayoutsPreview.TypeKeys "<RETURN>" - hUseAsyncSlot( "ViewNormal" ) - - printlog "3. Hide Slidepane (Oops! The user were too fast: accidently hide the pane)" + printlog "Hide Slidepane (Oops! The user were too fast: accidently hide the pane)" kontext "Slides" SlidesControl.FadeOut WaitSlot (1000) - - printlog "4. Restore Pane." + printlog "Restore Pane." SlidesControl.FadeIn - - printlog " Did the 'mistake' to FadeIn/Out the Slidepane" - -InsertGraphicsFromFile -Kontext "GrafikEinfuegenDlg" -if GrafikEinfuegenDlg.exists(5) then -printlog " The Insertgraphics-dialogue showed up correctly." -sleep (5) -else -warnlog " The Insertgraphics-dialogue didn't show up." -endif + printlog "Did the 'mistake' to FadeIn/Out the Slidepane" + InsertGraphicsFromFile + Kontext "GrafikEinfuegenDlg" + if GrafikEinfuegenDlg.exists(5) then + printlog " The Insertgraphics-dialogue showed up correctly." + sleep (5) + else + warnlog " The Insertgraphics-dialogue didn't show up." + endif printlog "Graphics-Import-dialogue. Select i_us_large.jpg" Kontext "GrafikEinfuegenDlg" - if ( GrafikEinfuegenDlg.exists( 2 ) ) then + if ( GrafikEinfuegenDlg.exists( 2 ) ) then Dateiname.SetText ConvertPath (gTesttoolPath + "graphics\required\input\i_us_large.jpg") Oeffnen.Click - Kontext "DocumentImpress" printlog "Deselect graphic" - DocumentImpress.MouseDoubleClick 90,90 - printlog " Inserted Graphic into the second Slide" - + DocumentImpress.TypeKeys "<ESCAPE>" + printlog "Inserted Graphic into the second Slide" 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" + DocumentImpress.TypeKeys "The World has just become easier now.." DocumentImpress.TypeKeys "<ESCAPE><ESCAPE>" DocumentImpress.TypeKeys "<TAB><TAB><TAB>" DocumentImpress.TypeKeys "<RETURN>" @@ -262,9 +258,9 @@ endif DocumentImpress.TypeKeys "<RETURN>" DocumentImpress.TypeKeys "Very durable" DocumentImpress.TypeKeys "<RETURN>" - DocumentImpress.TypeKeys "Priced lower than its predecessor!" + DocumentImpress.TypeKeys "Priced lower!" DocumentImpress.TypeKeys "<RETURN>" - DocumentImpress.TypeKeys "Sexy" + DocumentImpress.TypeKeys "Astonishing!" DocumentImpress.TypeKeys "<RETURN>" DocumentImpress.TypeKeys "Energy-efficient" DocumentImpress.TypeKeys "<ESCAPE><ESCAPE>" @@ -273,52 +269,36 @@ endif endif printlog "Save Document" - call hFileSaveAsKill (PresentationFile2) - - ActiveDeactivateCTLSupport (FALSE) - + call hFileSaveAsKill (PresentationFile) printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation2 - -'------------------------------------------------------------------------------- + printlog "-------------------------------------------------------------------------------" -testcase i_us_presentation3 - - dim PresentationFile2 as string - dim PresentationFile3 as string - - PresentationFile2 = ConvertPath( gOfficePath + "user\work\PowerPes2.odp" ) - PresentationFile3 = ConvertPath( gOfficePath + "user\work\PowerPes3.odp" ) - - if ( FileExists( PresentationFile2 ) ) then 'if file exists... - hFileOpen( PresentationFile2 ) + printlog "3. Loading file again.." + if ( FileExists(PresentationFile) ) then 'if file exists... + hFileOpen(PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if - printlog "Insert New Slide" + printlog "Insert New Slide, 3rd one" kontext "slides" SlidesControl.TypeKeys( "<PAGEDOWN>", 3 ) - kontext "DocumentImpress" - InsertSlide 'No 3 - - printlog "5. Layout. Clip/Text" + InsertSlide + printlog "5. Layout. Title only" kontext "Tasks" LayoutsPreview.TypeKeys "<HOME>" 'to get to the very first position LayoutsPreview.TypeKeys "<RIGHT>", 4 'to get to the right position LayoutsPreview.TypeKeys "<RETURN>" - hUseAsyncSlot( "ViewNormal" ) - kontext "DocumentImpress" Call gMouseClick 50,50 DocumentImpress.TypeKeys "<TAB><RETURN>" DocumentImpress.TypeKeys "A new form" - + DocumentImpress.TypeKeys "<ESCAPE>", 2 printlog "6. (Fat picture) InsertPictureFromFile: (empty slide) (ev size-fit)" printlog "insert graphic file (i_us_large.jpg)" InsertGraphicsFromFile @@ -329,39 +309,21 @@ testcase i_us_presentation3 Oeffnen.Click WaitSlot (2000) Kontext "DocumentImpress" - printlog "The user corrects the picture" DocumentImpress.MouseDown 50,50 DocumentImpress.MouseUp 50,50 DocumentImpress.TypeKeys "<DOWN>", 30 - printlog "Deselect graphic" DocumentImpress.MouseDoubleClick 90,90 - - printlog " Wrote Text, Inserted Graphic, and moved it in the third Slide" - + printlog "Wrote Text, Inserted Graphic, and moved it in the third Slide" printlog "Save Document" - call hFileSaveAsKill (PresentationFile3) - - ActiveDeactivateCTLSupport (FALSE) - + call hFileSaveAsKill (PresentationFile) printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation3 - -'------------------------------------------------------------------------------- - -testcase i_us_presentation4 - - dim PresentationFile3 as string - dim PresentationFile4 as string - dim iAnimations as Integer - dim iSize as integer - - PresentationFile3 = ConvertPath( gOfficePath + "user\work\PowerPes3.odp" ) - PresentationFile4 = ConvertPath( gOfficePath + "user\work\PowerPes4.odp" ) + printlog "-------------------------------------------------------------------------------" + printlog "4. reopening file..." select case iSprache case 01 : iAnimations = 01 'English case 07 : iAnimations = 01 'Russian @@ -382,167 +344,126 @@ testcase i_us_presentation4 warnlog "Please insert the entrienumbers for 'Backgrounds'. Language: " + iSprache end select - if ( FileExists( PresentationFile3 ) ) then 'if file exists... - hFileOpen( PresentationFile3 ) + if ( FileExists(PresentationFile) ) then 'if file exists... + hFileOpen( PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if kontext "slides" SlidesControl.TypeKeys( "<PAGEDOWN>", 5 ) - kontext "DocumentImpress" printlog "insert slide no 4" hUseAsyncSlot( "InsertSlide" ) - printlog "Background: picture (Gallery)" Kontext "Gallery" + if ( Not Gallery.Exists() ) then ToolsGallery end if kontext "Gallery" + if ( Gallery.exists( 2 ) ) then Gallerys.Select (iAnimations) kontext "Gallery" View.TypeKeys "<HOME><RIGHT><RIGHT>" - wait( 200 ) + sleep 1 View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - wait( 200 ) + sleep 1 MenuSelect(MenuGetItemID(1)) 'Insert - wait( 200 ) + sleep 1 MenuSelect(MenuGetItemID(1)) 'Copy else warnlog( "Could not access Gallery" ) endif - printlog "Check that we really got a copy of the object" - kontext "DocumentImpress" - DocumentImpress.OpenContextMenu(true) - WaitSlot (1000) - MenuSelect 27353 - - Kontext "ExportierenDlg" - if ( ExportierenDlg.exists( 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 - + sleep 1 kontext "DocumentImpress" - DocumentImpress.TypeKeys "<UP>", 82 - DocumentImpress.TypeKeys "<LEFT>", 130 - + DocumentImpress.TypeKeys "<UP>", 75 + DocumentImpress.TypeKeys "<LEFT>", 100 printlog "Deselect graphic" DocumentImpress.MouseDoubleClick 90,90 - printlog "Close the Gallery" ToolsGallery - printlog "Change Text on slide" DocumentImpress.TypeKeys "<TAB>" DocumentImpress.TypeKeys "<RETURN>" - DocumentImpress.TypeKeys "The process starts to flourish" + DocumentImpress.TypeKeys "The process starts here.." DocumentImpress.TypeKeys "<ESCAPE><ESCAPE>" gMouseClick 50,50 - - ActiveDeactivateCTLSupport (TRUE) - printlog( "Decrease..." ) - for iSize = 100 to 25 step -25 + + for iSize = 80 to 20 step -20 CreateTextSetEffectAndAngle - DocumentImpress.TypeKeys "<DOWN>", 80 + DocumentImpress.TypeKeys "<DOWN>", 70 DocumentImpress.TypeKeys "<LEFT>", iSize gMouseClick 90,90 next iSize printlog( "Increase..." ) - for iSize = 25 to 100 step 25 + + for iSize = 20 to 80 step 20 CreateTextSetEffectAndAngle - DocumentImpress.TypeKeys "<DOWN>", 80 - DocumentImpress.TypeKeys "<LEFT>", iSize + DocumentImpress.TypeKeys "<DOWN>", 70 + DocumentImpress.TypeKeys "<RIGHT>", iSize gMouseClick 90,90 next iSize - printlog " Inserted fourth slide with Gallery-object." - + printlog "Inserted fourth slide with Gallery-object." + printlog "Switching back task pane to default..." + Kontext "DocumentImpress" + DocumentImpress.UseMenu + hMenuSelectNr (5) + hMenuSelectNr (13) printlog "Save Document" - call hFileSaveAsKill (PresentationFile4) - - ActiveDeactivateCTLSupport (FALSE) - + call hFileSaveAsKill (PresentationFile) printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation4 - -'------------------------------------------------------------------------------- - -testcase i_us_presentation5 + printlog "-------------------------------------------------------------------------------" - dim PresentationFile4 as string - dim PresentationFile5 as string - - PresentationFile4 = ConvertPath( gOfficePath + "user\work\PowerPes4.odp" ) - PresentationFile5 = ConvertPath( gOfficePath + "user\work\PowerPes5.odp" ) - - if ( FileExists( PresentationFile4 ) ) then 'if file exists... - hFileOpen( PresentationFile4 ) + printlog "5. reloading file..." + if ( FileExists(PresentationFile) ) then + hFileOpen(PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if kontext "slides" SlidesControl.TypeKeys( "<PAGEDOWN>", 7 ) - kontext "DocumentImpress" - printlog "8. New Slide. (Insert Menu) (Duplicate slide)" - InsertDuplicateSlide 'No 5 + printlog "New Slide. (Insert Menu) (Duplicate slide)" + InsertDuplicateSlide 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>" hUseAsyncSlot( "EditSelectAll" ) DocumentImpress.TypeKeys "And does it with strength..." - - printlog " Inserted fifth slide with audience-joke." - + printlog "Inserted fifth slide with audience-joke." printlog "Save Document" - call hFileSaveAsKill (PresentationFile5) - - ActiveDeactivateCTLSupport (FALSE) - + call hFileSaveAsKill (PresentationFile) printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation5 - -'------------------------------------------------------------------------------- + printlog "-------------------------------------------------------------------------------" -testcase i_us_presentation6 - - dim PresentationFile5 as string - dim PresentationFile6 as string - - PresentationFile5 = ConvertPath( gOfficePath + "user\work\PowerPes5.odp" ) - PresentationFile6 = ConvertPath( gOfficePath + "user\work\PowerPes6.odp" ) - - if ( FileExists( PresentationFile5 ) ) then 'if file exists... - hFileOpen( PresentationFile5 ) + printlog "6. reloading file..." + if ( FileExists(PresentationFile) ) then 'if file exists... + hFileOpen(PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if kontext "slides" SlidesControl.TypeKeys( "<PAGEDOWN>", 6 ) - kontext "DocumentImpress" - printlog "9. Q&A Slide" + printlog "Q&A Slide" InsertSlide WaitSlot (1000) kontext "DocumentImpress" @@ -551,15 +472,15 @@ testcase i_us_presentation6 DocumentImpress.TypeKeys "Q&A" DocumentImpress.TypeKeys "<SHIFT HOME>" wait( 500 ) - Kontext "TextObjectbar" + if ( not TextObjectbar.Exists() ) then ViewToolbarsTextFormatting end if Kontext "TextObjectbar" wait( 500 ) - Printlog "- Change size of font" + Printlog "Change size of font" Schriftgroesse.Select "26" Schriftgroesse.TypeKeys "<RETURN>" Fett.Click @@ -569,77 +490,59 @@ testcase i_us_presentation6 Auswahl.Click gMouseClick 60,60 hUseAsyncSlot( "EditSelectAll" ) - DocumentImpress.TypeKeys "<DOWN>", 50 kontext "DocumentImpress" - printlog " Inserted sixth slide with Q&A." - + printlog "Inserted sixth slide with Q&A." printlog "Save Document" - call hFileSaveAsKill (PresentationFile6) - - ActiveDeactivateCTLSupport (FALSE) - + call hFileSaveAsKill (PresentationFile) printlog "Close Document" hFileCloseAll() -endcase 'i_us_presentation6 - -'------------------------------------------------------------------------------- - -testcase i_us_presentation7 + printlog "-------------------------------------------------------------------------------" - const KEY_STROKE_REPEAT = 8 + printlog "7. reloading file..." + sFileName = ConvertPath( gOfficePath + "user\work\export-test.ppt" ) - dim sFilter as string - dim sFileName as string - dim PresentationFile6 as string - dim PresentationFile7 as string - dim iKeyStroke as integer - - PresentationFile6 = ConvertPath( gOfficePath + "user\work\PowerPes6.odp" ) - PresentationFile7 = ConvertPath( gOfficePath + "user\work\PowerPes7.odp" ) - sFileName = ConvertPath( gOfficePath + "user\work\export-test.ppt" ) - - if ( FileExists( PresentationFile6 ) ) then 'if file exists... - hFileOpen( PresentationFile6 ) + if ( FileExists(PresentationFile) ) then 'if file exists... + hFileOpen(PresentationFile) else - warnlog " This test is supposed to run after the previous testcase has been run. Notify the Automatic-tester." + warnlog "Testdoc is missing or did not get saved." goto endsub end if kontext "slides" - SlidesControl.TypeKeys( "<PAGEDOWN>", KEY_STROKE_REPEAT ) - + SlidesControl.TypeKeys( "<PAGEDOWN>",7) kontext "DocumentImpress" - printlog " inserting Ending Slide" + printlog "inserting Ending Slide" InsertSlide 'No 7 - DocumentImpress.TypeKeys "Ende" - printlog " Inserted ending -slide." - + DocumentImpress.TypeKeys "End" + printlog "Inserted ending -slide." Kontext "Gallery" + if Gallery.Exists(2) then - warnlog " The Gallery was visible. Closed it. Check earlier ran tests for inconsistency." + warnlog "The Gallery was visible. Closed it. Check earlier ran tests for inconsistency." ToolsGallery WaitSlot (2000) end if kontext "slides" - for i = 1 to 7 + + for i = 1 to 8 sleep 1 SlidesControl.TypeKeys "<PAGEUP>" next i - SlidesControl.TypeKeys "<RETURN>" 'At the first slide hTypeKeys "<F5>" - kontext "DocumentPresentation" - for iKeyStroke = 1 to KEY_STROKE_REPEAT + + for iKeyStroke = 1 to 8 wait( 3000 ) DocumentPresentation.TypeKeys "<PAGEDOWN>" wait( 2000 ) next iKeyStroke kontext "DocumentPresentation" + if ( DocumentPresentation.notExists( 5 ) ) then printlog( "Presentation closed. Good." ) else @@ -656,17 +559,15 @@ testcase i_us_presentation7 kontext "DocumentImpress" printlog "Save Document" - call hFileSaveAsKill (PresentationFile7) - + call hFileSaveAsKill (PresentationFile) printlog( "Save as Powerpoint-file (Using filter at pos. 5 in the filter list)" ) FileSaveAs - Kontext "SpeichernDlg" - if ( SpeichernDlg.exists( 2 ) ) then + if ( SpeichernDlg.exists( 2 ) ) then Dateiname.SetText sFileName Dateityp.Select 5 ' Powerpoint (possibly) - printlog "Trying to save with filter: " + Dateityp.GetSelText + sFilter(5) + printlog "Trying to save with filter: " + Dateityp.GetSelText Speichern.Click Kontext "Messagebox" @@ -680,15 +581,11 @@ testcase i_us_presentation7 printlog "Close all open documents" hFileCloseAll() - printlog( "Reload file: " & sFileName ) hFileOpen sFileName sleep( 3 ) - printlog "Close the office-session" - ActiveDeactivateCTLSupport (FALSE) - printlog "Close Documents" hFileCloseAll() -endcase 'i_us_presentation7 +endcase 'i_us_presentation
\ No newline at end of file diff --git a/testautomation/graphics/optional/includes/impress/i_view.inc b/testautomation/graphics/optional/includes/impress/i_view.inc index 54ba5132d16e..214676c3b1a0 100644 --- a/testautomation/graphics/optional/includes/impress/i_view.inc +++ b/testautomation/graphics/optional/includes/impress/i_view.inc @@ -41,33 +41,35 @@ testcase tAnsichtHintergrundNotizen Printlog "- View background notes" - Call hNewDocument '/// new document ///' + printlog "new document" + Call hNewDocument try - ViewNotes '/// view background notes ///' + printlog "view background notes" + ViewNotes sleep 3 catch Warnlog "View-Notes could not be accessed" endcatch ViewWorkspaceDrawingView sleep 1 - Call hCloseDocument '/// close document ///' + printlog "close document" + Call hCloseDocument sleep 1 -endcase +endcase 'tAnsichtHintergrundNotizen '------------------------------------------------------------------------------- testcase tViewWorkspaceHandoutView Printlog "- View background handout" - Call hNewDocument '/// new document ///' + printlog "new document" + Call hNewDocument sleep 2 Kontext "DocumentImpress" - if NOT documentImpress.Exists then - hNewDocument - sleep 1 - end if - sleep 2 + DocumentImpress.UseMenu + hMenuSelectNr (5) + hMenuSelectNr (13) Printlog " ViewWorkspaceHandoutView" - ViewWorkspaceHandoutView '/// view background handout ///' + ViewWorkspaceHandoutView sleep 2 Kontext "Tasks" sleep 2 @@ -77,9 +79,11 @@ testcase tViewWorkspaceHandoutView Printlog " ViewWorkspaceHandoutView works" end if Printlog "ViewWorkspaceHandoutView closed" - ViewWorkspaceDrawingView '/// back to view background drawing ///' - Call hCloseDocument '/// close document ///' -endcase + printlog "back to view background drawing" + ViewWorkspaceDrawingView + printlog "close document" + Call hCloseDocument +endcase 'tViewWorkspaceHandoutView '------------------------------------------------------------------------------- @@ -89,67 +93,67 @@ testcase tViewWorkspaceOutlineView dim sFile as string dim i as integer - '/// load a document with heading styles in writer and use the function 'writer:'File->Send->Outline to presentation' to get it into the presentation ///' + printlog "load a document with heading styles in writer and use the function 'writer:'File->Send->Outline to presentation' to get it into the presentation" ' all 'heading 1' are new slides - '/// document used : "graphics\\required\\input\\outlinefromwriter.sxw" -> you get into writer ///' + printlog "document used : graphics\\required\\input\\outlinefromwriter.sxw -> you get into writer" sFile = ConvertPath (gTesttoolPath + "graphics\required\input\outlinefromwriter.sxw") hDateiOeffnen (sFile) sleep 10 - '///+ with 'File->Send->Outline to presentation' you get into impress ///' + printlog "with 'File->Send->Outline to presentation' you get into impress" FileSendOutlineToPresentation sleep 10 - Printlog "'/// View->Workspace->Outline View ///'" + Printlog "printlog View->Workspace->Outline View" ViewWorkspaceOutlineView sleep 1 - '/// go to the line with the 'I' (via 'search & replace' function) ///' + printlog "go to the line with the 'I' (via 'search & replace' function)" hTypeKeys "<STRG HOME>" EditSelectAll hFindeImDokument ("I") - '///<b> expected level/style: 'Outline 8' </b>///' - '/// get last character from selected style in stylist (expect a number of the outline(heading level) ///' + printlog "expected level/style: 'Outline 8'" + printlog "get last character from selected style in stylist (expect a number of the outline(heading level)" fGetPresentationStyle ("8") - '/// type keys [home] [tab] to go one level down ///' + printlog "type keys [home] [tab] to go one level down" Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys "<Home><Tab>" - '///<b> expected level/style: 'Outline 9' </b>///' + printlog "expected level/style: 'Outline 9'" fGetPresentationStyle ("9") Kontext "DocumentImpressOutlineView" - '/// Edit - "Select All" to go select the whole text ///' + printlog "Edit - Select All to go select the whole text" EditSelectAll - '/// type keys [shift]+[tab] eight times, to get all lines to the highest, except the one with the 'I' ///' + printlog "type keys [shift]+[tab] eight times, to get all lines to the highest, except the one with the 'I'" DocumentImpressOutlineView.TypeKeys ("<Shift Tab>", 8) hPrepareSearchBUG hTypeKeys "<STRG HOME>" EditSelectAll hFindeImDokument ("I") - '///<b> expected level/style: 'Outline 1' </b>///' + printlog "expected level/style: 'Outline 1" fGetPresentationStyle ("1") - '/// type keys [shift]+[tab] to get the last line to the highest level, too ///' + printlog "type keys [shift]+[tab] to get the last line to the highest level, too" Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys ("<Shift Tab>", 1) - '///<b> expected level/style: 'Title' </b>///' + printlog "expected level/style: 'Title'" fGetPresentationStyle (0) Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys ("<escape>", 1) - Printlog "'///<b> call 'Edit->Undo' nine times </b>///'" + Printlog "call 'Edit->Undo' nine times" for i = 1 to 9 editundo next i hPrepareSearchBUG hFindeImDokument ("I") - '///<b> expected level/style: 'Outline 9' </b>///' + printlog "expected level/style: 'Outline 9'" fGetPresentationStyle (9) - Printlog "'///<b> call 'Edit->Redo' nine times </b>///'" + Printlog "call 'Edit->Redo' nine times " for i = 1 to 9 editredo next i @@ -164,10 +168,10 @@ hPrepareSearchBUG hTypeKeys "<STRG HOME>" EditSelectAll hFindeImDokument ("I") - '///<b> expected level/style: 'Title' </b>///' + printlog "expected level/style: 'Title'" fGetPresentationStyle (0) - Printlog "'///<b> call 'Edit->Undo' nine times </b>///'" + Printlog "call 'Edit->Undo' nine times" for i = 1 to 9 editundo next i @@ -176,13 +180,13 @@ hPrepareSearchBUG hTypeKeys "<STRG HOME>" EditSelectAll hFindeImDokument ("I") - '///<b> expected level/style: 'Outline 9' </b>///' + printlog "expected level/style: 'Outline 9" fGetPresentationStyle (9) - '/// type keys [strg]+[A] ///' + printlog "type keys [strg]+[A]" Kontext "DocumentImpressOutlineView" EditSelectAll - '/// type keys [strg]+[X] ///' + printlog "type keys [strg]+[X]" DocumentImpressOutlineView.TypeKeys "<mod1 X>" kontext @@ -193,17 +197,17 @@ hPrepareSearchBUG Warnlog "messagebox missing ! (about deleting pages with graphic objects:)" endif - '/// 'Edit->Undo' ///' + printlog "'Edit->Undo'" editundo - '/// 'Edit->Redo' ///' + printlog "'Edit->Redo'" editredo - '/// 'Edit->Undo' ///' + printlog "'Edit->Undo'" editundo - '/// type keys [strg]+[A] ///' + printlog "type keys [strg]+[A]" Kontext "DocumentImpressOutlineView" EditSelectAll - '/// type keys [strg]+[X] ///' + printlog "type keys [strg]+[X]" DocumentImpressOutlineView.TypeKeys "<mod1 X>" kontext @@ -214,23 +218,23 @@ hPrepareSearchBUG Warnlog "messagebox missing ! (about deleting pages with graphic objects:)" endif - '/// type keys [strg]+[V] ///' + printlog "type keys [strg]+[V]" Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys "<mod1 V>" - '/// 'Edit->Undo' ///' + printlog "'Edit->Undo'" editundo - '/// 'Edit->Redo' ///' + printlog "'Edit->Redo'" editredo - '/// type keys [strg]+[End] ///' + printlog "type keys [strg]+[End]" Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys "<mod1 End>" - '/// type keys [strg]+[V] ///' + printlog "type keys [strg]+[V]" DocumentImpressOutlineView.TypeKeys "<mod1 V>" - '/// type keys [strg]+[A] ///' + printlog "type keys [strg]+[A]" EditSelectAll - '/// type keys [delete] ///' + printlog "type keys [delete]" DocumentImpressOutlineView.TypeKeys "<delete>" kontext @@ -242,7 +246,7 @@ hPrepareSearchBUG Warnlog "messagebox missing ! (about deleting pages with graphic objects:)" endif - '/// type keys [strg]+[A] ///' + printlog "type keys [strg]+[A]" Kontext "DocumentImpressOutlineView" EditSelectAll try @@ -252,7 +256,7 @@ hPrepareSearchBUG Warnlog "error 4711 TBO :-(" endcatch - '/// type keys [delete] ///' + printlog "type keys [delete]" Kontext "DocumentImpressOutlineView" DocumentImpressOutlineView.TypeKeys "<delete>" @@ -275,44 +279,50 @@ hPrepareSearchBUG endcatch ViewWorkspaceDrawingView - Call hCloseDocument '/// close document ///' - Call hCloseDocument '/// close document ///' -endcase + printlog "close document" + Call hCloseDocument +endcase 'tViewWorkspaceOutlineView '------------------------------------------------------------------------------- testcase tViewWorkspaceDrawingView Printlog "- View/Background-drawing" - Call hNewDocument '/// new document ///' + printlog "new document" + Call hNewDocument sleep 2 - ViewDrawing '/// view background drawing ///' + printlog "view background drawing" + ViewDrawing try - hRechteckErstellen ( 20,20,40,40 ) '/// create rectangle ///' + printlog "create rectangle" + hRechteckErstellen ( 20,20,40,40 ) sleep 1 Printlog " - rectangle created" catch Warnlog " Rectangle could not be created" endcatch - Call hCloseDocument '/// close document ///' -endcase + printlog "close document" + Call hCloseDocument +endcase 'tViewWorkspaceDrawingView '------------------------------------------------------------------------------- testcase tAnsichtEbene - printLog "- View/Layer" '/// view layer ///' - - - FileAutopilotPresentation '/// new document-autopilot ///' + printLog "- View/Layer" + + printlog "new document-autopilot" + FileAutopilotPresentation Kontext "AutopilotPraesentation1" sleep 5 AutopilotPraesentation1.Ok sleep 2 sleep 2 - ViewSlide '/// back to view slide ///' + printlog "back to view slide" + ViewSlide Sleep 2 - - Call hCloseDocument '/// close document ///' -endcase + printlog "close document" + Call hCloseDocument + +endcase 'tAnsichtEbene '------------------------------------------------------------------------------- diff --git a/testautomation/graphics/optional/includes/impress/im_002_.inc b/testautomation/graphics/optional/includes/impress/im_002_.inc deleted file mode 100644 index d1fa457ae8b2..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_002_.inc +++ /dev/null @@ -1,52 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Required Test Library (2) -'* -'\***************************************************************** - -testcase tiEditDeleteSlide -'/// open application ///' - Call hNewDocument -'/// Insert->Slide; press 'OK' ///' - InsertSlide - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 -'/// Edit->Delete Slide ///' - try - EditDeleteSlide - catch - warnlog "Error when deleting slide" - endcatch - Call hCloseDocument -'/// close application ///' -endcase - - diff --git a/testautomation/graphics/optional/includes/impress/im_003_.inc b/testautomation/graphics/optional/includes/impress/im_003_.inc deleted file mode 100644 index 1db0627e4a4e..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_003_.inc +++ /dev/null @@ -1,254 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Resource Test: View Menu -'* -'*********************************************************************************** -' #1 tiViewPanes -' #1 tiViewMasterView -' #1 tiViewSlideMaster -' #1 tiViewToolbar_1 -'\********************************************************************************** - -testcase tiViewPanes - goto endsub 'TODO WG, tiViewPanes outcommented due to reconstruction of test - dim bState as boolean - '/// open application ///' - Call hCloseDocument - Call hNewDocument - sleep 1 - kontext "Tasks" - if (NOT Tasks.exists) then - warnlog "Tasks Panel not visible on opening application. Opening now." - ViewTaskPane - endif - kontext "Slides" - if (NOT Slides.exists) then - warnlog "Slides Panel not visible on opening application. Opening now." - ViewTaskSlide - endif - kontext "Tasks" - '/// Deactivate all but "masterpages" ///' - View.OpenMenu - hMenuSelectNr (2) - View.OpenMenu - hMenuSelectNr (3) - View.OpenMenu - hMenuSelectNr (4) - - sleep 1 - - Tasks.TypeKeys ("<RIGHT><RIGHT><RIGHT>") - - try - kontext "recentlyUsed" - printlog "Toggeling Master Pages now with <space>" - kontext "MasterPages" - MasterPages.typeKeys "<space>" - kontext "recentlyUsed" - if (recentlyUsed.IsVisible = FALSE) then 'exists = FALSE) then - warnlog "View-menu didn't work" - endif - kontext "Tasks" - sleep 1 - '/// View->Task Pane ///' - ViewTaskPane - sleep 1 - if (Tasks.exists) then - warnlog "View->Task Panel failed" - ViewTaskPane - endif - '/// View->Task Pane ///' - ViewTaskPane - sleep 1 - if (NOT Tasks.exists) then - warnlog "View->Task Panel failed" - ViewTaskPane - endif - catch - warnlog "View->Task Pane couldn't get executed" - endcatch - kontext "Slides" - try - ViewTaskSlide - if (Slides.exists) then - warnlog "View->Slide Panel failed." - ViewTaskSlide - endif - '/// View->Slide Pane ///' - ViewTaskSlide - sleep 1 - if (NOT Slides.exists) then - warnlog "View->Slide Panel failed." - ViewTaskSlide - endif - catch - warnlog "View->Slide Pane couldn't get executed" - endcatch - - '/// Reactivate all pages in the Task-panel ///' - kontext "Tasks" - View.OpenMenu - hMenuSelectNr (2) - View.OpenMenu - hMenuSelectNr (3) - View.OpenMenu - hMenuSelectNr (4) -endcase - -testcase tiViewMasterView -'/// open application ///' - Call hNewDocument -'/// View->Master View->Drawing View ///' - sleep 1 - ViewWorkspaceDrawingView -' Kontext "DocumentImpress" -' gMouseClick 70,70 - sleep 5 -'/// View->Master View->Outline View ///' - ViewWorkspaceOutlineView -' Kontext "DocumentImpressOutlineView" -' DocumentImpressOutlineView.MouseDown 70,70 -' DocumentImpressOutlineView.MouseUp 70,70 - sleep 1 -'/// View->Master View->Slides View ///' - ViewWorkspaceSlidesView -' Kontext "DocumentImpressSlideView" -' DocumentImpressSlideView.MouseDown 70,70 -' DocumentImpressSlideView.MouseUp 70,70 - sleep 1 -'/// View->Master View->Notes View ///' - ViewWorkspaceNotesView - sleep 1 -'/// View->Master View->Handout View ///' - ViewWorkspaceHandoutView - sleep 1 -'/// View->Master View->Drawing View ///' - ViewWorkspaceDrawingView -'/// close application ///' - sleep 1 - Call hCloseDocument -endcase - -testcase tiViewSlideMaster -'/// open application with : File->Autopilot->Presentation; OK; OK ///' -' Call hNewDocument - FileAutopilotPresentation ' to get a title :-) - sleep 2 - Kontext "AutopilotPraesentation1" - AutopilotPraesentation1.Ok - sleep 1 - Kontext "Seitenlayout" ' aka: Modify Slide - if Seitenlayout.exists(5) then - warnlog "Slidelayout has to vanish; moved to sidebar" - Seitenlayout.OK - endif - kontext "DocumentImpress" - sleep 1 -'/// View->Slide ///' - ViewSlide - Sleep 1 -'/// View->Master->Drawing ///' - ViewDrawing - Sleep 1 -'/// View->Slide ///' - ViewSlide - Sleep 1 -'/// View->Master->Title ///' - try - ViewTitle - Errorlog "View - Master - Title Slide Master should NOT be accessable" - catch - printlog "View - Master - Title Slide Master not accessable - good" - endcatch - Sleep 1 -'/// View->Slide ///' - ViewSlide - Sleep 1 -'/// View->Master->Handout ///' - ViewHandout - Sleep 1 -' ViewSlide - Sleep 1 -'/// View->Master->Notes ///' - ViewNotes - kontext "DocumentImpress" - Sleep 1 -'/// View->Slide ///' - ViewSlide - Sleep 1 -'/// close application ///' - Call hCloseDocument -endcase - -testcase tiViewToolbar_1 - Dim Zaehler as integer - Dim i as integer - -'/// open application ///' - Call hNewDocument - sleep 2 -'/// Insert->Graphic... : "global\input\graf_inp\desp.bmp" ///' - InsertGraphicsFromFile - sleep 2 - Kontext "GrafikEinfuegenDlg" - sleep 1 - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - sleep 1 - Oeffnen.Click - sleep 3 - Kontext "Messagebox" - if Messagebox.Exists then - Warnlog Messagebox.GetText - Messagebox.OK - end if - Kontext "DocumentImpress" -'/// select graphic ///' - EditSelectAll - sleep 2 - Kontext "GraphicObjectbar" - sleep 1 -'/// The Graphics Toolbar has to be visible now; If not -> ERROR ///' - if GraphicObjectbar.Exists Then - Printlog "- graphic object toolbar exists" - Zaehler=Grafikmodus.GetItemCount - for i = 1 to Zaehler - Printlog "- access all controls in the toolbar (" +i+"/"+Zaehler+")" - Grafikmodus.Select i - sleep 3 - next i - sleep 3 - else - Warnlog "- No graphic function toolbar visible" - end if -'/// close application ///' - Call hCloseDocument -endcase - - diff --git a/testautomation/graphics/optional/includes/impress/im_004_.inc b/testautomation/graphics/optional/includes/impress/im_004_.inc deleted file mode 100644 index 17d00addc847..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_004_.inc +++ /dev/null @@ -1,58 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Required Test Library (4) -'* -'\***************************************************************** - -testcase tiInsertSlideExpandSummary - -'/// open application ///' - Call hNewDocument - ' presupposition -'/// View->Master View->Outline View ///' - ViewWorkspaceOutlineView - Sleep 1 - Kontext "DocumentImpressOutlineView" -'/// Type 2 rows ///' - DocumentImpressOutlineView.TypeKeys "Herbert<Return>Rudi" -'/// View->Master View->Drawing View ///' - ViewWorkspaceDrawingView - Sleep 1 - ' test menue entries -'/// Insert->Summery Slide ///' - InsertSummerySlide - Sleep 1 -'/// Insert->Expand Slide ///' - InsertExpandSlide - Sleep 2 -'/// close application ///' - Call hCloseDocument -endcase - diff --git a/testautomation/graphics/optional/includes/impress/im_005_.inc b/testautomation/graphics/optional/includes/impress/im_005_.inc deleted file mode 100644 index 1aa218f3ecba..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_005_.inc +++ /dev/null @@ -1,50 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Required Test Library (5) -'* -'\***************************************************************** - -testcase tiFormatModifyLayout - -'/// open application ///' - Call hNewDocument -'/// Impress: Format->Modify Layout ///' -'/// Draw : kontext menu: Slide-> Modify Slide (always disabled :-( ?///' - FormatPage ' 27046 SID_MODIFYPAGE - Kontext "SeitenLayout" - DialogTest ( SeitenLayout ) - sleep 1 -'/// cancel dialog 'Page Setup' ///' - SeitenLayout.Cancel -'/// close application ///' - Call hCloseDocument -endcase - - diff --git a/testautomation/graphics/optional/includes/impress/im_007_.inc b/testautomation/graphics/optional/includes/impress/im_007_.inc deleted file mode 100644 index fc9ba2800e0c..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_007_.inc +++ /dev/null @@ -1,693 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Required Test Library (7) -'* -'\***************************************************************** - -' this menue is only in impress availble -testcase tSlideShowSlideShow - '/// open application ///' - Call hNewDocument - '/// Slide Show->Slide Show Settings ///' - SlideShowPresentationSettings - Kontext "Bildschirmpraesentation" - '/// check if 'type' 'default' is checked, it has to be the default !///' - if standard.IsChecked then - if LogoAnzeigen.isEnabled then - Warnlog "'Show Logo' is Enabled :-(" - endif - else - Warnlog "type 'default' is not checked as default :-(" - endif - '/// check checkbox 'Window' ///' - Fenster.Check - Printlog "- Presentation in window mode is checked" - '/// close dialog with OK 'Slide Show' ///' - Bildschirmpraesentation.Ok - sleep 3 - '/// Slide Show->Slide Show ///' - SlideShowSlideshow - Sleep 5 - try - Kontext "DocumentPresentation" - sleep 3 - '/// Press <Esc> to leave presentation mode ///' - DocumentPresentation.Typekeys ("<Escape>") - Sleep 3 - Kontext "DocumentImpress" - DocumentImpress.MouseDoubleClick ( 50, 50 ) - Sleep 3 - catch - ' FileClose - warnlog "had to catch <the ball> :-( " - ' Kontext "Messagebox" - ' if Messagebox.Exists (5) Then Messagebox.No - ' Kontext - ' sleep (12) - ' start sAppExe$ - ' sleep (6) - ' Kontext - ' if Office.Exists(2) then Resetapplication - ' Warnlog "Slide didn't end, application wasn't in document edit mode" - endcatch - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowRehearseTimings - goto endsub - '/// open application ///' - Call hNewDocument - '/// Slide Show->Slide Show Settings ///' - SlideShowPresentationSettings - Kontext "Bildschirmpraesentation" - '/// check checkbox 'Window' ///' - Fenster.Check - '/// close dialog with OK 'Slide Show' ///' - Bildschirmpraesentation.Ok - '/// Slide Show->Rehearse Timings ///' - SlideShowRehearseTimings - sleep 2 - Kontext "DocumentPresentation" - '/// Press <Esc> to leave presentation mode ///' - if DocumentPresentation.Exists (5) then - DocumentPresentation.Typekeys ("<Escape>") - else - Warnlog "SlideShowRehearseTimings mode not accessible" - endif - Sleep 3 - if DocumentPresentation.Exists then ' the kontext hasnt to be available, else ERROR - DocumentPresentation.TypeKeys "<ESCAPE>" ' => I mustn't be here ever ! - Warnlog "- Slide show mode should have ended" - else - printlog "SlideShowRehearseTimings mode not accessible :-) " - end if - sleep 3 - try - Kontext "DocumentImpress" - DocumentImpress.MouseDoubleClick ( 50, 50 ) - - sleep 3 - catch - warnlog "Had to catch <the ball> :-( " - endcatch - sleep 3 - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowSlideShowSettings - '/// open application ///' - Call hNewDocument - sleep 2 - '/// Slide Show->Slide Show Settings ///' - SlideShowPresentationSettings - Kontext "Bildschirmpraesentation" - call Dialogtest (Bildschirmpraesentation) - '/// check checkbox in section 'Range' - 'From: ///' - AbDia.Check - '/// select the 3rd item from the top from listbox 'From:' ///' - AbDiaName.GetSelText - '/// check checkbox 'All Slides' ///' - AlleDias.Check - '///' RangeCustomSlideShow ' gets tested in tSlideShowCustomSlideShow ///' - ' IndividuellePraesentationName - '///<b> check checkbox 'window' </b>///' - Fenster.Check - '/// check checkbox 'default' ///' - Standard.Check - '///<b> check check box 'Auto' -> implies looping of slideshow in fullscreen mode </b>///' - Auto.Check - '/// set duration of pause to '00:00:05' ///' - Zeit.GetText - '/// check check box 'Show logo' ///' - LogoAnzeigen.Check - '///<b> check checkbox 'Change slides maually' </b>///' - DiawechselManuel.Check - '///<b> check checkbox 'Mouse pointer as pen' </b>///' - MauszeigerAlsStift.Check - '///<b> UNcheck checkbox 'Mouse pointer visible' </b>///' - MauszeigerSichtbar.UnCheck - '///<b> check checkbox 'Navigator visible' </b>///' - NavigatorSichtbar.Check - '///<b> UNcheck checkbox 'animations allowed' </b>///' - AnimationenZulassen.UnCheck - '///<b> UNcheck checkbox 'Change slides by clicking on background' </b>///' - DiaWechselAufHintergrund.UnCheck - '///<b> check checkbox 'Presentation always on top' </b>///' - PraesentationImmerImVordergrund.Check - '/// cancel dialog 'Slide Show' ///' - Bildschirmpraesentation.Cancel - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowCustomSlideShow - '/// open application ///' - Call hNewDocument - sleep 2 - '/// Slide Show->Custom Slide Show ///' - SlideShowCustomSlideshow - Kontext "IndividuellePraesentation" - call Dialogtest (IndividuellePraesentation) - '/// click button 'New' ///' - Neu.Click - Kontext "IndividuellePraesentationDefinieren" - Call DialogTest (IndividuellePraesentationDefinieren) - '/// select the first entry in the list 'Existing Slides' ///' - SeitenPraesentation.Select 1 - '/// click button '>>' ///' - Hinzufuegen.Click - '/// close dialog 'Define Custom Slide Show' with OK ///' - IndividuellePraesentationDefinieren.OK - Kontext "IndividuellePraesentation" - '/// click button 'Copy' ///' - Kopieren.Click - '/// click button 'Delete' ///' - Loeschen.Click - '/// click button 'Edit' ///' - Bearbeiten.Click - Kontext "IndividuellePraesentationDefinieren" - '/// select 1st entry in the list 'Selected Slides' ///' - SelectedSlides.Select 1 - '/// click button '<<' ///' - Entfernen.Click - '/// close dialog 'Define Custom Slide Show' with Cancel ///' - IndividuellePraesentationDefinieren.Cancel - Kontext "IndividuellePraesentation" - '/// check checkbox 'Use Custom Slide Show' ///' - IndividuellePraesentationBenutzen.Check - sleep 1 - '///+ UNcheck checkbox 'Use Custom Slide Show' ///' - IndividuellePraesentationBenutzen.UnCheck - '/// click button 'Start...' ///' - Starten.Click - sleep 5 - '/// press key [space] 2 times ///' - kontext "DocumentPresentation" - DocumentPresentation.TypeKeys "<space>" - sleep 1 - DocumentPresentation.TypeKeys "<space>" - sleep 1 - '/// close dialog 'Custom Slide Shows' ///' - ' IndividuellePraesentation.Close ' slide show ends dialog ! - '/// Slide Show->Slide Show Settings ///' - try - SlideShowPresentationSettings - catch - warnlog "Presentation did not end :-(" - DocumentPresentation.TypeKeys "<escape>" - endcatch - Kontext "Bildschirmpraesentation" - if Bildschirmpraesentation.exists (5) then - '/// check checkbox 'Custom Slide Show' ///' - RangeCustomSlideShow.Check - printlog "check: '" + IndividuellePraesentationName.GetSelText + "'" - '/// cancel dialog 'Slide Show' ///' - Bildschirmpraesentation.Cancel - else - warnlog "Dialog not open? SlideShowPresentationSettings" - endif - '/// Slide Show->Custom Slide Show ///' - SlideShowCustomSlideshow - Kontext "IndividuellePraesentation" - if (IndividuellePraesentation.exists (5)) then - '/// click button 'Delete' ///' - Loeschen.Click - '/// close dialog 'Custom Slide Shows' ///' - IndividuellePraesentation.Close - else - warnlog "Dialog not open? SlideShowCustomSlideshow" - endif - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowSlideTransition - goto endsub '"#149943# - Outcommented tSlideShowSlideTransition due to bug." - dim i as integer - dim a as integer - dim iCount as integer - - '/// open application ///' - Call hNewDocument - '/// create rectangle ///' - Call hRechteckErstellen ( 10, 10, 20, 40 ) - sleep 1 - '/// Slide Show->Slide Transition ///' - SlideShowSlideTransition - sleep 2 - '/// The 'Slide Transition' in the right 'Tasks' Pane has to come up ///' - Kontext "Tasks" - '/// Select the second entry from teh Listbox 'Applay to selected slides' ///' - TransitionApplyToSelectedSlide.select (2) - sleep 5 ' takes some time, until it is run - Printlog "Count of effects : "+TransitionApplyToSelectedSlide.GetItemCount - Printlog "Count of Speeds : "+TransitionSpeed.GetItemCount - iCount = TransitionSound.GetItemCount - Printlog "Count of Sounds : " + iCount - - '/// One Entry of the Listbox 'Sound' is 'Other sound...', select it ///' - TransitionSound.typeKeys "<home>" - i = 0 - for a = 1 to iCount - TransitionSound.select (a) - kontext "OeffnenDlg" - if (OeffnenDlg.exists (5)) then - if (0=i) then - ' remember when dialog came up - i = a - OeffnenDlg.cancel - else - warnlog "File Open Dialog comes up a second time!" - OeffnenDlg.cancel - endif - endif - kontext "Tasks" - ' the Checkbox is disabled on teh first three entries: <No Sound>, <Stop previous sound>... - if (TransitionLoopUntilNextSound.isEnabled AND (a<4)) then - qaErrorLog "May be Language specific -> Evaluation of TBO; " + a - endif - next a - TransitionSound.select (i) - '/// The dialog 'Open' comes up///' - sleep 1 - kontext "OeffnenDlg" - if (OeffnenDlg.exists (5)) then - '/// Read all entries in Listbox 'File type' ///' - for i = 1 to Dateityp.getItemCount - printlog "" + i + ":" + Dateityp.getItemText(i) - next i - '/// cancel dialog 'Open' ///' - OeffnenDlg.cancel - else - warnlog "Impress:Tasks Pane:Slide Transition:Sound:Other sound... disdn't bring up teh File Open Dialog!" - endif - kontext "Tasks" - sleep (2) - '/// check checkbox 'Automatically after' ///' - TransitionAutomaticallyAfter.check - sleep (2) - '/// press key 'Page Up' in box ///' - TransitionAutomaticallyAfterTime.typeKeys "<PageUp>" - sleep 9 - '/// check the standard checkbox 'On mouse click' ///' - TransitionOnMouseClick.check - sleep (2) - '/// press button 'Apply to All Slides' ///' - TransitionApplyToAllSlides.click - sleep (2) - '/// press button 'Play' ///' - TransitionPlay.click - sleep 10 - '/// press button 'Slide Show' ///' - TransitionSlideShow.click - sleep 2 - kontext "DocumentPresentation" - if DocumentPresentation.exists (10) then - printlog "Presentation started :-)" - DocumentPresentation.typeKeys "<escape>" - else - warnlog "Impress:Tasks Pane:Slide Transition:Slide Show button doesn't start slideshow!" - endif - kontext "Tasks" - - '/// uncheck and check Checkbox 'Automatic Preview' ///' - '/// default is checked ///' - if (NOT TransitionAutomaticPreview.isChecked) then - warnlog "Impress:Tasks Pane:Slide Transition: Automatic preview has to be checked by default, wasn't!" - endif - sleep (2) - TransitionAutomaticPreview.unCheck - sleep (2) - TransitionAutomaticPreview.Check - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowShowHideSlide - '/// open application ///' - Call hNewDocument - '/// create rectangle ///' - Call hRechteckErstellen ( 10, 10, 20, 40 ) - '/// View->Master View->Slides View ///' - ViewWorkspaceSlidesView - sleep 1 - '/// Slide Show->Hide Slide ///' - SlideShowHideSlide - sleep 1 - '/// Slide Show->Show Slide ///' - SlideShowShowSlide - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowAnimation - '/// open application ///' - Call hNewDocument - sleep 1 - '/// create rectangle ///' - Call hRechteckErstellen ( 10, 10, 20, 40 ) - sleep 1 - '/// Insert ->Animated image ///' - Opl_SD_EffekteZulassen - Kontext "Animation" - sleep 1 - '/// click button 'Apply Object' ///' - BildAufnehmen.Click 'BildAufnehmen - '/// click button 'Create' ///' - Erstellen.Click - sleep 1 - '/// Select 1st entry from top in 'Alignment' ///' - Anpassung.Select 1 - sleep 1 - '/// click button 'Create' ///' - Erstellen.Click - sleep 1 - '/// click button 'Apply Objects Individually' ///' - AlleAufnehmen.Click - sleep 1 - '/// click button 'First Image' ///' - ErstesBild.Click - sleep 1 - '/// click button 'Last Image' ///' - LetztesBild.Click - sleep 1 - '/// click button 'BAckwards' ///' - Rueckwaerts.Click - sleep 1 - '/// click button 'Play' ///' - Abspielen.Click - sleep 1 - '/// click in Number field 'Image Number' Less - More ///' - AnzahlBilder.Less - sleep 1 - AnzahlBilder.More - sleep 1 - '/// check 'Bitmap Object' ///' - AnimationsgruppeBitmapobjekt.Check - sleep 1 - '/// Type '10' into the field 'Duration' ///' - AnzeigedauerProBild.SetText "10" - '/// click button 'Play' ///' - Abspielen.Click - '/// wait 5 seconds ///' - sleep 5 - '/// click button 'Stop' ///' - try - Stopp.Click - catch - warnlog "Stopbutton doesn't work" - endcatch - sleep 1 - '/// Select 1st entry from top in 'Loop Count' ///' - AnzahlDurchlaeufe.Select 1 - sleep 1 - '/// click button 'Delete Current Image' ///' - BildLoeschen.Click - sleep 1 - '/// check 'Group Object' ///' - AnimationsgruppeGruppenobjekt.Check - sleep 1 - '/// click button 'Delete All Images' ///' - AlleLoeschen.Click - kontext "Messagebox" - '/// there has to be a messagebox 'Really delete?' say YES!; else ERROR ///' - if Messagebox.exists (5) then - Messagebox.YES - else - warnlog "No one cares about my data :-( No one asked if all shall be deleted :-( " - endif - sleep 1 - kontext "Animation" - '/// close dialog 'Animation' ///' - Animation.Close - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowCustomAnimation - dim bError as boolean - - '/// open application ///' - Call hNewDocument - '/// create textbox with text ///' - Call hTextrahmenErstellen ("Test text to test text effects", 10, 10, 20, 40 ) - '/// Slide Show->Custom Animation... ///' - SlideShowCustomAnimation - Kontext "Tasks" - '/// click button 'Add...' ///' - EffectAdd.click - '/// Dialog 'Custom Animation' comes up ///' - kontext - '/// Switch to TabPage: Entrance ///' - active.setPage(TabEntrance) - kontext "TabEntrance" - if TabEntrance.exists(5) then - DialogTest(TabEntrance) - '/// select in the listbox 'Effects' the second entry///' - Effects.select(2) - Speed.getItemCount - AutomaticPreview.unCheck - sleep 1 - AutomaticPreview.Check - kontext - '/// Switch to TabPage: Emphasis ///' - active.setPage(TabEmphasis) - kontext "TabEmphasis" - if TabEmphasis.exists(5) then - DialogTest(TabEmphasis) - else - bError = true - warnlog "Impress:Tasks Pane:Custom Animation:TabEmphasis tabPage doesn't work." - endif - kontext - '/// Switch to TabPage: Exit ///' - active.setPage(TabExit) - kontext "TabExit" - if TabExit.exists(5) then - DialogTest(TabExit) - else - bError = true - warnlog "Impress:Tasks Pane:Custom Animation:TabExit tabPage doesn't work." - endif - kontext - '/// Switch to TabPage: Motion Paths ///' - active.setPage(TabMotionPaths) - kontext "TabMotionPaths" - if TabMotionPaths.exists(5) then - DialogTest(TabMotionPaths) - Effects.select(7) - else - bError = true - warnlog "Impress:Tasks Pane:Custom Animation:TabMotionPaths tabPage doesn't work." - endif - '/// Close dialog 'Custom Animation' with 'OK' ///' - TabMotionPaths.OK - bError = false - else - bError = true - warnlog "Impress:Tasks Pane:Custom Animation:Add... button didn't work." - endif - Kontext "Tasks" - if (NOT bError) then - '/// click button 'Change...' ///' - EffectChange.click - '/// Dialog 'Custom Animation' comes up ///' - kontext - '/// Switch to TabPage: Entrance ///' - active.setPage(TabEntrance) - kontext "TabEntrance" - if (NOT TabEntrance.exists(5)) then - warnlog "Impress:Tasks Pane:Custom Animation:Change... button didn't work." - endif - TabEntrance.cancel - Kontext "Tasks" - EffectStart.getItemCount - if EffectProperty.isEnabled then - EffectProperty.getItemCount - endif - '/// CLick on button '...' (Options) ///' - EffectOptions.click - kontext "TabEffect" - if TabEffect.exists(5) then - dialogTest(TabEffect) - Sound.getItemCount - AfterAnimation.getItemCount - '/// switch to TabPage 'Timing' ///' - Kontext - active.setPage TabTiming - kontext "TabTiming" - if TabTiming.exists(5) then - dialogTest(TabTiming) - TimingStart.getItemCount - Delay.getText - Speed.getItemCount - Repeat.getItemCount - Rewind.ischecked - TriggerAnimate.isChecked - TriggerStart.isChecked - Shape.getItemCount - else - warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: Timing TabPage didn't work." - endif - '/// switch to TabPage 'Timing' ///' - Kontext - active.setPage TabTextAnimation - kontext "TabTextAnimation" - if TabTextAnimation.exists(5) then - dialogTest(TabTextAnimation) - GroupText.getItemCount - AnimateAttachedShape.isChecked - TabTextAnimation.cancel - else - warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: TextAnimation TabPage didn't work." - endif - else - warnlog "Impress:Tasks Pane:Custom Animation:... button didn't work." - endif - Kontext "Tasks" - EffectSpeed.getItemCount - EffectList.getItemCount - EffectPlay.click - '/// Wait five seconds so the Playfunction has ended ///' - sleep 5 - EffectSlideShow.click - sleep 1 - kontext "DocumentPresentation" - if DocumentPresentation.exists (5) then - printlog "Presentation started :-)" - DocumentPresentation.typeKeys "<escape>" - else - warnlog "Impress:Tasks Pane:Custom Animation:Slide Show button doesn't start slideshow!" - endif - kontext "Tasks" - EffectAutomaticPreview.isChecked - '/// click button 'Remove' ///' - EffectRemove.click - endif - '/// close application ///' - Call hCloseDocument -endcase - -testcase tSlideShowInteraction - '/// open application ///' - Call hNewDocument - sleep 2 - '/// create rectangle ///' - Call hRechteckErstellen (10, 10, 20, 20) - sleep 3 - '/// Slide Show->Interaction ///' - SlideShowInteraction - Kontext "TabInteraktion" - Call DialogTest (TabInteraktion, 1) - '///+ Select 6th entry from top in 'Action at mouse click' : 'Go to page or object' ///' - AktionBeiMausklick.select 6 - Printlog AktionBeiMausklick.GetSelText + " chosen" - Call DialogTest (TabInteraktion, 2) - '///+ click button 'Find' ///' - sleep 1 - suchen.click - Kontext "TabInteraktion" - '/// Select 7th entry from top in 'Action at mouse click' : 'Go to document' ///' - sleep 1 - AktionBeiMausklick.select 7 - sleep 1 - Printlog AktionBeiMausklick.GetSelText + " chosen" - Kontext "TabInteraktion" - Call DialogTest (TabInteraktion, 3) - '///+ click button 'Browse...' ///' - Durchsuchen.click - sleep 1 - kontext "OeffnenDlg" - call Dialogtest (OeffnenDlg) - '///+ cancel dialog 'open' ///' - OeffnenDlg.cancel - Kontext "TabInteraktion" - sleep 1 - '/// Select 9th entry from top in 'Action at mouse click' : 'Play Sound' ///' - AktionBeiMausklick.select 8 - Printlog AktionBeiMausklick.GetSelText + " chosen" - Call DialogTest (TabInteraktion, 4) - '///+ click button 'Browse...' ///' - Durchsuchen.click - sleep 1 - Kontext "OeffnenDlg" - Call dialogTest (OeffnenDlg) - '///+ cancel dialog 'open' ///' - OeffnenDlg.Cancel - sleep 1 - Kontext "TabInteraktion" - '/// Select 8th entry from top in 'Action at mouse click' : 'Run Program' ///' - AktionBeiMausklick.select 9 - Printlog AktionBeiMausklick.GetSelText + " chosen" - Call DialogTest (TabInteraktion, 7) - Kontext "TabInteraktion" - '///+ click button 'Browse...' ///' - Durchsuchen.Click - sleep 1 - Kontext "OeffnenDlg" - Call dialogTest (OeffnenDlg) - '///+ cancel dialog 'open' ///' - OeffnenDlg.Cancel - sleep 1 - '/// Select 9th entry from top in 'Action at mouse click' : 'Run Macro' ///' - Kontext "TabInteraktion" - AktionBeiMausklick.select 10 - Printlog AktionBeiMausklick.GetSelText + " chosen" - sleep 3 - Call DialogTest (TabInteraktion, 6) - '///+ click button 'Browse...' ///' - Durchsuchen.Click - sleep 1 - Kontext "ScriptSelector" - sleep 1 - Call DialogTest ( ScriptSelector, 1) - sleep 1 - '///+ cancel dialog 'ScriptSelector' ///' - ScriptSelector.Cancel - sleep 1 - '/// Select 10th entry from top in 'Action at mouse click' : 'Exit Presentation' ///' - Kontext "TabInteraktion" - AktionBeiMausklick.select 11 - Printlog AktionBeiMausklick.GetSelText + " chosen" - Call DialogTest (TabInteraktion, 7) - Kontext "TabInteraktion" - '/// close dialog 'Interaction' ///' - TabInteraktion.Close - sleep 2 - '/// close application ///' - Call hCloseDocument -endcase - - - - - diff --git a/testautomation/graphics/optional/includes/impress/im_011_.inc b/testautomation/graphics/optional/includes/impress/im_011_.inc deleted file mode 100644 index 30ab1bebb74e..000000000000 --- a/testautomation/graphics/optional/includes/impress/im_011_.inc +++ /dev/null @@ -1,173 +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 : wolfram.garten@oracle.com -'* -'* short description : Impress Required Test Library (11) -'* -'\***************************************************************** - -testcase tiDiaLeiste - -' only in IMPRESS - dim sTemp as string - Dim i,x as integer - -'/// open application ///' - Call hNewDocument - sleep 1 -'/// Change options so the presentation won't start from the current, but the first slide. ///' - ToolsOptions - hToolsOptions ( "IMPRESS", "General" ) - MitAktuellerSeite.Uncheck - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK - -'/// insert a graphic: "global\input\graf_inp\desp.bmp") ///' - Printlog "- Insert graphic from file so there is something for the slide mode" - hGrafikEinfuegen ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - sleep 3 -'///+ Insert->Slide ///' - InsertSlide - sleep 2 - hTypekeys "<Pagedown>" - sleep 2 -'///+ insert a graphic: "global\input\graf_inp\desp.bmp") ///' - hGrafikeinfuegen ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - sleep 3 -'///+ View->Master View->Slides View ///' - ViewWorkspaceSlidesView - sleep 2 -'-------------------------------- Ueberblendeffekt ---------------------------------------- - Printlog "- Test blend effect" - Kontext "SlideViewObjectbar" ' CORRECT - sleep 5 - - if Ueberblendeffekt.GetItemCount <> 57 then warnlog "these are not 57: " + Ueberblendeffekt.GetItemCount -'/// select last entry 'Automatic (random)' in listbox 'Slide Effects' on object toolbar ///' - Ueberblendeffekt.Select (Ueberblendeffekt.GetItemCount) - Printlog " select last effect (random effect): " + Ueberblendeffekt.GetSelText - -' Printlog Geschwindigkeit.GetRT ' 341 listbox -' Printlog Diawechsel.GetRT ' 341 listbox -' Printlog Zeit.GetRT ' 353 spinfield -' Printlog DiasProReihe.GetRT ' 353 spinfield -' Printlog PraesentationMitZeitnahme.GetRT doesn't work, but behave as button -' Printlog DiaAnzeigen.GetRT doesn't work, but behave as button - -'-------------------------------- Geschwindigkeit ----------------------------------------- - Printlog "- Check different speed settings" - Kontext "SlideViewObjectbar" -'/// select every item in list 'Transition Speed' ///' - x = Geschwindigkeit.GetItemCount - for i = 1 to x - Geschwindigkeit.Select i - Printlog " changed to: " + Geschwindigkeit.GetSelText - next i -'-------------------------------- Diawechsel ---------------------------------------------- - Printlog "- Style of slide change" - Kontext "SlideViewObjectbar" -'/// select every item in list 'Auto Transition' ///' - x = Diawechsel.GetItemCount - for i = 1 to x - Diawechsel.Select i - Printlog " Changed to: " + Diawechsel.GetSelText + "; is time enabled ?: "+Zeit.IsEnabled - next i -'-------------------------------- Diawechsel Zeitintervall -------------------------------- - Printlog "- Zeitintervall testen" - Kontext "SlideViewObjectbar" -'/// select last entry 'Automatic' in listbox 'Auto Transition' ///' - Diawechsel.Select (Diawechsel.GetItemCount) ' automatic is usually the last one - sleep 1 - if (Zeit.IsEnabled = FALSE) Then Warnlog "- Time should be editable, if automatic is chosen" -'/// type "15" into the field 'Time' ///' - Zeit.SetText "15" - sleep 1 - Printlog " Time set to: " + Zeit.GetText -'-------------------------------- Praesentation mit Zeitnahme ------------------------------ - Printlog "- Presentation with rehearsed timings" - Kontext "SlideViewObjectbar" -'/// click button 'Rehearse Timings' ///' - PraesentationMitZeitnahme.Click - sleep 2 - Kontext "DocumentPresentation" - if DocumentPresentation.exists (5) then - sleep 5 -'/// wait some seconds and click with mouse ///' - DocumentPresentation.MouseDown 50,50 - DocumentPresentation.MouseUp 50,50 - sleep 2 -'/// wait some seconds and click with mouse ///' - DocumentPresentation.MouseDown 50,50 - DocumentPresentation.MouseUp 50,50 - sleep 3 - else - warnlog "Didn't switch into presentation mode :-(" - endif - Kontext "DocumentPresentation" - if DocumentPresentation.exists (5) then - warnlog "We are still in presentation mode :-( WHY!!!!???" - endif -'------------------------------- Dia anzeigen ja/nein -------------------------------------- - Printlog "- Show slide yes/no" - Kontext "SlideViewObjectbar" -'/// click button 'Show/Hide Slide' ///' - DiaAnzeigen.Click - sleep 3 -'/// click button 'Show/Hide Slide' ///' - DiaAnzeigen.Click -'------------------------------- Dias pro Reihe -------------------------------------------- - Printlog "- Presentation with rehearsed timings" - Kontext "SlideViewObjectbar" - sTemp = DiasProReihe.GetText -'/// press button 'less' in field 'Slides Per Row' ///' - DiasProReihe.Less - if sTemp = DiasProReihe.GetText then warnlog " nothing changed (less)" - sTemp = DiasProReihe.GetText -'/// press button 'more' in field 'Slides Per Row' ///' - DiasProReihe.more - if sTemp = DiasProReihe.GetText then warnlog " nothing changed (more 1)" - sTemp = DiasProReihe.GetText -'/// press button 'more' in field 'Slides Per Row' ///' - DiasProReihe.more - if sTemp = DiasProReihe.GetText then warnlog " nothing changed (more 2)" - kontext - if active.exists then - warnlog "active (1): '"+active.gettext+"'" - endif -'/// Restore default settings in ToolsOptions ///' - ToolsOptions - hToolsOptions ( "IMPRESS", "General" ) - MitAktuellerSeite.Check - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK -'/// close application ///' - Call hCloseDocument - sleep 2 -endcase - - diff --git a/testautomation/graphics/optional/includes/impress/options.inc b/testautomation/graphics/optional/includes/impress/options.inc index cfce04e68805..d67eaea8d195 100644 --- a/testautomation/graphics/optional/includes/impress/options.inc +++ b/testautomation/graphics/optional/includes/impress/options.inc @@ -41,8 +41,7 @@ function tiPEngineOptionsTest dim lala, optsound, os, oa, odc, ota, ets, etspeed, etrep, etshap, etgt as integer Kontext "Tasks" -' if (NOT bError) then - '/// CLick on button '...' (Options) ///' + printlog "CLick on button '...' (Options)" EffectOptions.Click kontext "TabEffect" if TabEffect.Exists(5) then @@ -56,13 +55,6 @@ function tiPEngineOptionsTest kontext "TabEffect" else kontext "TabEffect" -' if play.isEnabled then -' try -' play.click -' catch -' warnlog Sound.GetSelText + " wasn't played correctly." -' endcatch -' endif endif next os if AfterAnimation.isEnabled AND AfterAnimation.isVisible then @@ -89,7 +81,7 @@ function tiPEngineOptionsTest for ota = 1 to TextAnimation.GetItemCount TextAnimation.Select ota next ota - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext Active.SetPage TabTiming kontext "TabTiming" @@ -130,7 +122,7 @@ function tiPEngineOptionsTest else warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: Timing TabPage didn't work." endif - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext active.setPage TabTextAnimation kontext "TabTextAnimation" @@ -163,9 +155,9 @@ function tiPEngineOptionsTest warnlog "Impress:Tasks Pane:Custom Animation:... button didn't work." endif Kontext "Tasks" -end function - +end function 'tiPEngineOptionsTest +'------------------------------------------------------------------------------- function optionstest2 dim filedialogue as boolean @@ -188,7 +180,7 @@ function optionstest2 else Warnlog "DelayBetweenCharacters should have been enabled" endif - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext Active.SetPage TabTiming kontext "TabTiming" @@ -234,7 +226,7 @@ function optionstest2 else warnlog "Impress:Tasks Pane:Custom Animation:Effect Options: Timing TabPage didn't work." endif - '/// switch to TabPage 'Timing' ///' + printlog "switch to TabPage 'Timing'" Kontext active.setPage TabTextAnimation kontext "TabTextAnimation" @@ -267,4 +259,4 @@ function optionstest2 warnlog "Impress:Tasks Pane:Custom Animation:... button didn't work." endif Kontext "Tasks" -end function +end function 'optionstest2
\ No newline at end of file diff --git a/testautomation/graphics/required/d_opt.bas b/testautomation/graphics/required/d_opt.bas index 1447b1f4e276..1447b1f4e276 100644..100755 --- a/testautomation/graphics/required/d_opt.bas +++ b/testautomation/graphics/required/d_opt.bas diff --git a/testautomation/graphics/required/d_updt.bas b/testautomation/graphics/required/d_updt.bas index 40dd64e3b50c..40dd64e3b50c 100644..100755 --- a/testautomation/graphics/required/d_updt.bas +++ b/testautomation/graphics/required/d_updt.bas diff --git a/testautomation/graphics/required/i_opt.bas b/testautomation/graphics/required/i_opt.bas index eb159ac83a55..eb159ac83a55 100644..100755 --- a/testautomation/graphics/required/i_opt.bas +++ b/testautomation/graphics/required/i_opt.bas diff --git a/testautomation/graphics/required/i_updt_1.bas b/testautomation/graphics/required/i_updt_1.bas index f829cc9b8713..f829cc9b8713 100644..100755 --- a/testautomation/graphics/required/i_updt_1.bas +++ b/testautomation/graphics/required/i_updt_1.bas diff --git a/testautomation/graphics/required/i_updt_2.bas b/testautomation/graphics/required/i_updt_2.bas index 3d61eea42a4b..3d61eea42a4b 100644..100755 --- a/testautomation/graphics/required/i_updt_2.bas +++ b/testautomation/graphics/required/i_updt_2.bas diff --git a/testautomation/graphics/required/includes/global/gallery.inc b/testautomation/graphics/required/includes/global/gallery.inc deleted file mode 100644 index cfdac0029ec1..000000000000 --- a/testautomation/graphics/required/includes/global/gallery.inc +++ /dev/null @@ -1,987 +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 : wolfram.garten@oracle.com -'* -'* short description : Global Required/resource test: Checking the gallery -'* -'\****************************************************************************** -testcase tGallery_DialogTest - '///Open a new Writer document - '///Tools / Gallery - printlog "- Working with Gallery-Beamer!" - gApplication = "WRITER" - call hNewDocument - call hOpenGallery - Kontext "DocumentWriter" - '///+Undock the <i>Gallery Beamer</i> - printlog "- undock the Gallery Beamer" - Kontext "Gallery" - Gallery.Undock ( AlignTop ) - sleep(2) - '///+<ul><li>Move the gallery-window</li></ul> - printlog " - move the gallery window" - Gallery.move ( 20, 20 ) - sleep(2) - '///+Dock the <i>Gallery Beamer</i> - printlog "- dock the Gallery Beamer" - Gallery.Dock ( AlignTop ) - sleep(2) - '///+Close the <i>Gallery Beamer</i> (Tools / Gallery) - printlog "- close the Gallery Beamer" - ToolsGallery - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_ActivateAndUpdateAllThemes - Dim iThemeCount as Integer - Dim i as Integer - Dim j as Integer - Dim Gallerytext as string - '///Activate and update all gallery themes (NET installation: Activate only!) - '///Open a new Writer document - '///+Tools / Gallery - '///+Click on each theme and update it (via context menu) - printlog "activate and update all gallery-themes" - gApplication = "WRITER" - call hNewDocument - Kontext - call hOpenGallery - Kontext "Gallery" - iThemeCount = Gallerys.GetItemCount - for i=1 to iThemeCount - if gNetzInst = FALSE then - Kontext "Gallery" - Gallerytext = Gallerys.GetItemText(i) - printlog "- " + i + ". entry (" & Gallerytext & ")" - Gallerys.Select i - Gallerys.MouseMove ( 10, 10 ) - Gallerys.OpenContextMenu - sleep (3) - printlog " - update" - hMenuSelectNr (1) - sleep (3) - Kontext "Messagebox" - if Messagebox.Exists(3) then - if Messagebox.getRT=304 then - printlog "- 'MyTheme' is the " & i & "'s entry." - Messagebox.No - end if - else - for j = 1 to 800 - Kontext "AktualisierenGallery" - if AktualisierenGallery.Exists then - printlog "DEBUG (j): " & j - sleep (1) - else - printlog "DEBUG: 800 reached!" - j=801 - end if - next j - end if - end if - next i - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_CheckNames - Dim iThemeCount as Integer - Dim i as Integer - Dim j as Integer - Dim ssList (100) as String - Dim siList (100) as String - Dim sFileName as String - Dim iGalleryThemes as integer - - if gOOO = true then - sFileName = ConvertPath ( gTesttoolPath + "graphics\required\input\gallery\gal_oo_" + iSprache + ".txt" ) - else - sFileName = ConvertPath ( gTesttoolPath + "graphics\required\input\gallery\gal_" + iSprache + ".txt" ) - end if - - '///Check the names for the gallery themes - '///Open a new Writer document - '///+Tools / Gallery - gApplication = "WRITER" - call hNewDocument - Kontext - call hOpenGallery - '///+Check the number of gallery themes. For StarOffice: should be 32. For OpenOffice.Org: should be 6. - printlog "- check the number of gallery-themes" - Kontext "Gallery" - if NOT gOOO then - if bAsianLan then - iGalleryThemes = 29 ' Flags are not allowed! - else - iGalleryThemes = 30 - end if - else - if bAsianLan then - iGalleryThemes = 6 ' Flags are not allowed! - else - iGalleryThemes = 6 - end if - end if - iThemeCount = Gallerys.GetItemCount - if (iThemeCount <> iGalleryThemes) then - warnlog "Difference in count of gallery themes; found: '" + iThemeCount + "'; expected: '"+ iGalleryThemes +"'" - end if - for i=1 to iThemeCount - Gallerys.Select i - ListAppend ( siList(), Gallerys.GetSelText ) - next i - '///+Check all names with a list which depends on language (<i>gTestToolPath</i>/graphics/udpate/input/gallery) - printlog "- check the names of gallery-themes" - if Dir ( sFilename ) = "" then - warnlog "The file for comparison does not exists. The file will be written!" - warnlog "Please control : " + sFilename - ListWrite ( siList(), sFilename, "utf8" ) - else - printlog " file for comparison is : " + sFilename - ListRead ( ssList (), sFilename, "uft8" ) - gCompare2Lists ( siList(), ssList () ) - end if - ToolsGallery - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_CheckContextMenuForGalleryThemes - Dim iForBidden as Integer - Dim iMenuEntries as Integer - Dim i as Integer - Dim iThemeCount as Integer - '/// Check the contextmenu for the gallery themes - '/// Open a new Writer document - '/// +Tools / Gallery - printlog "check the contextmenu for the gallery-themes" - gApplication = "WRITER" - call hNewDocument - call hOpenGallery - '/// +Testing <i>rename</i> and <i>properties</i> for each gallery theme (via context-menu) - '/// +<ul><li>Only the private gallery theme must be deleteable (different 3 entries in the context-menu than the rest)</li></ul> - Kontext "Gallery" - iThemeCount = Gallerys.GetItemCount - Gallerys.MouseMove ( 10, 10 ) - for i=1 to iThemeCount - Kontext "Gallery" - printlog "- " + i + ". entry" - sleep 1 - Gallerys.Select 1 - sleep (1) - Gallerys.Select i - sleep (1) - Gallerys.OpenContextMenu - sleep (2) - iMenuEntries = hMenuItemGetCount - if iMenuEntries <> 3 then - if gNetzInst = FALSE then - warnlog "There are not 3 entries! => no test on the contextmenu!" - else - if iMenuEntries <> 1 then - warnlog "Net-Inst : There are not 1 entries! => no test on the contextmenu!" - else - sleep (3) - hMenuSelectNr(1) - Kontext - if Active.GetPageCount <> 1 then - warnlog "There are more than 1 Tabpage in Net-Installation ( perhaps no root-installation )!" - end if - Active.SetPage TabAllgemeinGallery - Kontext "TabAllgemeinGallery" - TabAllgemeinGallery.Cancel - sleep (1) - end if - end if - else - sleep (1) - hMenuSelectNr(2) - Kontext "GalleryNewTitle" - GalleryNewTitle.Cancel - sleep(1) - Kontext "Gallery" - Gallerys.OpenContextMenu - sleep (3) - hMenuSelectNr (3) - Kontext - Active.SetPage TabAllgemeinGallery - Active.SetPage TabDateien - Kontext "TabDateien" - TabDateien.Cancel - sleep(1) - end if - next i - ToolsGallery - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_CreateAndWorkWithANewGalleryThemes - Dim iMenuEntries as Integer - Dim j as Integer - '/// Open a new Writer document - '/// Tools / Gallery - printlog "create a new gallery-theme ( TT-theme )" - gApplication = "WRITER" - call hNewDocument - call hOpenGallery - iMenuEntries = Gallerys.GetItemCount - printlog "- Clicking on 'New Theme' and creating a new theme" - '/// Create a new gallery-theme - '/// + by clicking on <i>New Theme</i> - NewTheme.Click - '/// +Activate <i>General</i> tabpage and insert <b><i>TT-theme</b></i> as name - Kontext - Active.SetPage TabAllgemeinGallery - Kontext "TabAllgemeinGallery" - NeuesThema.SetText "TT-theme" - sleep (1) - printlog " - named the new theme 'TT-theme' on the general-page" - printlog " - insert all files out of '[gTestToolpath]\global\input\graf_inp' in the files-page" - '/// +Activate <i>Files</i> tabpage - Kontext - Active.SetPage TabDateien - Kontext "TabDateien" - printlog " - click 'add' without a selected file => insert-graphic-dialog has to be be visible" - '/// +Click on <i>Add</i> (If no file is selected the <i>Graphic-Insert</i> dialog has to be be opened -> close it) - Hinzufuegen.Click - sleep (1) - Kontext "GrafikEinfuegenDlg" - GrafikEinfuegenDlg.Cancel - sleep (1) - printlog " - click 'find files' to insert the path for graphics" - '///+Click on <i>Find Files</i> => <i>select-path</i> dialog will be visible - Kontext "TabDateien" - Suche.Click - sleep (1) - '/// +Insert [gTesttoolPath]/input/global/graf_inp as path-name as click on <i>Select</i> - Kontext "OeffnenDlg" - Pfad.SetText ( convertPath ( gTesttoolPath + "global\input\graf_inp" ) ) - sleep (1) - Auswaehlen.Click - sleep (10) - '/// +Click on <i>Add</i> for some graphics - printlog " - 'add' one by one" - Kontext "TabDateien" - DateiListe.Select 1 - WaitSlot(1000) - Hinzufuegen.Click - sleep (1) - DateiListe.Select 1 - Hinzufuegen.Click - sleep (1) - '/// +Click on <i>Add all</i> for rest of the graphics - '/// +<ul><li>apply-dialog -> cancel</li></ul> - '/// +click on <i>Add all</i> for rest of the graphics - printlog " - 'add all' for the rest of the files" - DateiListe.Select 1 - HinzufuegenAlle.Click - printlog " - apply-dialog -> cancel" - Kontext "ApplyGallery" - for j=1 to 100 - if ApplyGallery.Exists then - try - ApplyGallery.Cancel - catch - endcatch - else - if j>5 then j=101 - sleep (1) - end if - next j - Kontext "TabDateien" - if DateiListe.GetItemCount > 1 then - printlog " - 'add all' for the rest of the files" - DateiListe.Select 1 - HinzufuegenAlle.Click - sleep (2) - Kontext "ApplyGallery" - for j=1 to 100 - If ApplyGallery.Exists then - sleep (1) - else - j=101 - end if - next j - end if - Kontext "TabDateien" - printlog " - click 'OK' for the tabpages" - TabDateien.OK - '/// +Check if the new entry is inserted and select it - printlog " - check if the new entrie is inserted and select it" - Kontext "Gallery" - if Gallerys.GetItemCount <> ( iMenuEntries + 1 ) then - warnlog "No new theme was created => the test ends here" - ToolsGallery - call hCloseDocument - else - gMouseClick 50,50 '/// make mouseclick to set focus ///' - Kontext "Gallery" - Gallerys.Select "TT-theme" - Gallerys.MouseMove ( 10, 10 ) - sleep (1) - Gallerys.OpenContextMenu - '/// +Update the entry (1. entry in context menu ) => cancel it - printlog " - update the entry => cancel the update" - sleep (3) - hMenuSelectNr (1) - sleep (1) - Kontext "AktualisierenGallery" - if AktualisierenGallery.Exists <> TRUE then - AktualisierenGallery.Cancel - end if - do - sleep 1 - loop while AktualisierenGallery.Exists - Kontext "Gallery" - Gallerys.Select "TT-theme" - Gallerys.OpenContextMenu - '/// +Update it (1. entry in context menu ) - printlog " - update" - sleep (3) - hMenuSelectNr (1) - for j=1 to 100 - Kontext "AktualisierenGallery" - if AktualisierenGallery.Exists <> TRUE then - j=101 - else - sleep (1) - end if - next j - '/// +Rename it (3. entry in context menu) - printlog " - rename ( 3. entry in context-menu )" - Kontext "Gallery" - Gallerys.OpenContextMenu - sleep (3) - hMenuSelectNr (3) - Kontext "GalleryNewTitle" - Title.SetText "New TT-theme" - GalleryNewTitle.OK - Kontext "Gallery" - Gallerys.Select "New TT-theme" - '///+Add new files in properties (4. entry in context menu) - printlog " - add new graphics in properties ( 4. entry in context-menu )" - Kontext "Gallery" - Gallerys.OpenContextMenu - sleep (3) - hMenuSelectNr (4) - Kontext - Active.SetPage TabDateien - Kontext "TabDateien" - Suche.Click - Kontext "OeffnenDlg" - Pfad.SetText ( convertPath ( gTesttoolPath + "global\input\graf_inp" ) ) - Auswaehlen.Click - sleep (10) - Kontext "TabDateien" - DateiListe.Select 1 - Hinzufuegen.Click - TabDateien.OK - '/// +Delete the entry (2. entry in context menu) - printlog " - delete the entry ( 2. entry in context-menu )" - printlog " - messagebox -> no" - Kontext "Gallery" - Gallerys.Select "New TT-theme" - sleep (3) - Gallerys.OpenContextMenu - sleep (3) - hMenuSelectNr (2) - Kontext "Active" - sleep (1) - Active.No - printlog " - messagebox -> yes" - Kontext "Gallery" - sleep (1) - Gallerys.Select "New TT-theme" - sleep (1) - Gallerys.OpenContextMenu - sleep (3) - hMenuSelectNr (2) - Kontext "Active" - Active.Yes - try - Kontext "Gallery" - Gallerys.Select "New TT-theme" - warnlog "The entry isn't deleted!" - catch - endcatch - end if - sleep 10 - ToolsGallery - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_GalleryView_Preview - Dim jpeg_bkg as Integer - Dim iAnimation as Integer - Dim iSound as Integer - Dim i as Integer - Dim iPreview as Integer - Dim iTitle as Integer - if NOT gOOO then - select case iSprache - case 01 : jpeg_bkg = 3 : iAnimation = 1 : iSound = 28 - case 07 : jpeg_bkg = 29 : iAnimation = 1 : iSound = 6 - case 31 : jpeg_bkg = 3 : iAnimation = 3 : iSound = 11 - case 33 : jpeg_bkg = 13 : iAnimation = 1 : iSound = 29 - case 34 : jpeg_bkg = 11 : iAnimation = 1 : iSound = 28 - case 36 : jpeg_bkg = 12 : iAnimation = 1 : iSound = 10 - case 39 : jpeg_bkg = 10 : iAnimation = 1 : iSound = 27 - 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 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 - case 86 : jpeg_bkg = 1 : iAnimation = 9 : iSound = 13 - case 88 : jpeg_bkg = 1 : iAnimation = 7 : iSound = 20 - case else : jpeg_bkg = 10 : iAnimation = 1 : iSound = 17 - warnlog "Please insert the entrienumbers for 'Backgrounds', 'Sounds' and one with normal files ( Animations )" - end select - else ' Testing OOO - select case iSprache - case 01 : jpeg_bkg = 1 : iAnimation = 5 : iSound = 2 - case 07 : jpeg_bkg = 1 : iAnimation = 5 : iSound = 2 - case 31 : jpeg_bkg = 3 : iAnimation = 1 : iSound = 1 - case 33 : jpeg_bkg = 3 : iAnimation = 1 : iSound = 2 - case 34 : jpeg_bkg = 1 : iAnimation = 1 : iSound = 2 - case 36 : jpeg_bkg = 2 : iAnimation = 1 : iSound = 2 - case 39 : jpeg_bkg = 2 : iAnimation = 1 : iSound = 2 - 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 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 - case 86 : jpeg_bkg = 1 : iAnimation = 5 : iSound = 3 - case 88 : jpeg_bkg = 1 : iAnimation = 5 : iSound = 2 - case else : jpeg_bkg = 1 : iAnimation = 5 : iSound = 2 - warnlog "Please insert the entrienumbers for 'Backgrounds', 'Sounds' and one with normal files ( Animations )" - end select - end if - '/// Open a new Writer document - '/// Tools / Gallery - printlog "open a writer and the gallery" - gApplication = "WRITER" - call hNewDocument - Kontext - call hOpenGallery - '/// Check the view for Background-pictures (JPEGs), for standard graphic files (Animation) and for <i>Sound</i> objects - for i=1 to 3 - if i=1 then - Gallerys.Select jpeg_bkg - printlog "selected gallery-theme : Backgrounds (Jpeg-files)" - end if - if i=2 then - Gallerys.Select iAnimation - printlog "selected gallery-theme : Animation" - end if - if i=3 then - Gallerys.Select iSound - printlog "selected gallery-theme : Sound" - end if - if gNetzInst = FALSE then - iPreview = 2 : iTitle = 3 - else - iPreview = 2 : iTitle = 0 - end if - '/// Test the list-view - '/// +Click on List-View-Button in toolbar - printlog "- list-view" - printlog " - open the list-view" - ListView.Click - sleep (1) - printlog " - Press Home + Enter to focus and enter Preview-mode." - '/// +Double-click on an object (preview has to be visible) - View.TypeKeys "<HOME>" - View.TypeKeys "<RETURN>" - sleep (2) - '/// +Back to normal view with Enter - View.TypeKeys "<RETURN>" - sleep (2) - '/// +Preview out of context menu on/off - printlog " - preview out of context menu on/off" - View.TypeKeys "<HOME>" - Sleep (2) - View.OpenContextMenu true - sleep (3) - hMenuSelectNr ( iPreview ) - sleep (3) - kontext "Gallery" - Sleep (2) - View.OpenContextMenu true - sleep (2) - hMenuSelectNr ( iPreview ) - sleep (3) - '/// +Title (FAT installation only) - if gNetzInst = FALSE then - printlog " - title" - Kontext "Gallery" - sleep (2) - View.OpenContextMenu true - sleep (3) - hMenuSelectNr ( iTitle ) - Kontext "GalleryNewTitle" - sleep (1) - GalleryNewTitle.Cancel - sleep (1) - Kontext "Gallery" - end if - View.OpenContextMenu true - sleep (3) - hMenuSelectNr ( iPreview ) - sleep (3) - '/// Should now be in Preview-mode. Check if we are. ///' - View.OpenContextMenu true - sleep (3) - printlog MenuIsItemChecked (MenuGetItemID(iPreview+1)) - if MenuIsItemChecked (MenuGetItemID(iPreview+1)) then - Printlog " Entered Preview-mode correctly" - sleep (1) - else - Warnlog " Didnt seem to enter preview-mode correctly." - end if - MenuSelect (0) - sleep (1) - '/// From here, try switching to icon-view ///' - '///+Click on Icon-View-Button in toolbar - printlog "- icon-view" - if IconView.isEnabled then - IconView.Click - qaErrorLog "The bug 64543 has been fixed! Please report to FHA." - end if - sleep (1) - View.TypeKeys "<HOME>" - printlog " - Enter to get out of Preview-mode" - '/// +Press Return on an object (preview has to be visible) - View.TypeKeys "<RETURN>" - sleep (2) - '/// +Back to normal view with Return - View.TypeKeys "<RETURN>" - sleep (2) - '/// +Preview out of context menu on/off - printlog " - preview out of context menu on/off" - View.TypeKeys "<HOME>" - sleep (3) - View.OpenContextMenu true - sleep (3) - hMenuSelectNr ( iPreview ) - sleep (3) - View.OpenContextMenu true - sleep (3) - hMenuSelectNr ( iPreview ) - sleep (3) - '/// +Title (FAT installation only) - if gNetzInst = FALSE then - printlog " - title" - try - View.OpenContextMenu true - sleep (3) - catch - warnlog "Could not open Contextmenu for Title nr:" +iTitle - endcatch - hMenuSelectNr ( iTitle ) - Kontext "GalleryNewTitle" - GalleryNewTitle.Cancel - Kontext "Gallery" - end if - next i - sleep 1 ' else crash - ToolsGallery - - '/// If the MediaPlayer exists - close it ///' - kontext "Mplayer" - if Mplayer.Exists then - if (gApplication = "IMPRESS") then - kontext "DocumentImpress" - else - kontext "DocumentDraw" - end if - ToolsMediaPlayer - else - if (gApplication = "IMPRESS") then - kontext "DocumentImpress" - else - kontext "DocumentDraw" - end if - end if - - call hCloseDocument -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_GalleryView_Insert - Dim jpeg_bkg as Integer - Dim iAnimation as Integer - Dim i as Integer - Dim j as Integer - Dim k as Integer - '/// Test gallery-view -> insert gallery-object with context-menu (3D-Object (<i>internal object</i>), Animation (<i>as file</i>)) - if NOT gOOO then - select case iSprache - case 01 : jpeg_bkg = 3 : iAnimation = 1 - case 07 : jpeg_bkg = 29 : iAnimation = 1 - case 31 : jpeg_bkg = 3 : iAnimation = 3 - case 33 : jpeg_bkg = 13 : iAnimation = 1 - case 34 : jpeg_bkg = 7 : iAnimation = 1 - case 36 : jpeg_bkg = 12 : iAnimation = 1 - case 39 : jpeg_bkg = 10 : iAnimation = 1 - case 46 : jpeg_bkg = 1 : iAnimation = 2 - case 48 : jpeg_bkg = 3 : iAnimation = 1 - case 49 : 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 - case 86 : jpeg_bkg = 17 : iAnimation = 15 - case 88 : jpeg_bkg = 17 : iAnimation = 15 - case else : jpeg_bkg = 1 : iAnimation = 2 - warnlog "Please insert the entrienumbers for 'Backgrounds' and one with normal files ( Animations )" - end select - else ' Testing OOO - select case iSprache - case 01 : jpeg_bkg = 3 : iAnimation = 1 - case 07 : jpeg_bkg = 5 : iAnimation = 1 - case 31 : jpeg_bkg = 3 : iAnimation = 3 - case 33 : jpeg_bkg = 5 : iAnimation = 1 - case 34 : jpeg_bkg = 6 : iAnimation = 1 - case 36 : jpeg_bkg = 5 : iAnimation = 1 - case 39 : jpeg_bkg = 5 : iAnimation = 1 - case 46 : jpeg_bkg = 1 : iAnimation = 2 - case 48 : jpeg_bkg = 3 : iAnimation = 1 - case 49 : 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 - case 86 : jpeg_bkg = 5 : iAnimation = 5 - case 88 : jpeg_bkg = 5 : iAnimation = 1 - case else : jpeg_bkg = 1 : iAnimation = 2 - warnlog "Please insert the entrienumbers for 'Backgrounds' and one with normal files ( Animations )" - end select - end if - '/// Test following for all applications (Writer, Calc, Impress, Draw) - for i=1 to 4 ' each application - if i=1 then gApplication = "WRITER" - if i=2 then gApplication = "CALC" - if i=3 then gApplication = "IMPRESS" - if i=4 then gApplication = "DRAW" - - '/// +Open a new document - '/// +Open the Gallery - printlog gApplication 'Chr(13) - call hNewDocument - call hOpenGallery - '/// +Select 3D-theme (these are internal objects and not realy files) - '/// +<ul><li>on context menu there are only 2 entries for insert (copy, link) - '/// +<li>insert the object per <i>copy</i></li> - '/// +<li>insert the object per <i>link</i></li></ul> - '/// +Select Animation theme (these are realy files) - '/// +<ul><li>On context menu there are only 2 entries for insert (copy, link ) for Calc, Draw Impress</li> - '/// +<li>On context menu there are only 3 entries for insert (copy, link, background / page, paragraph ) for Writer</li> - '/// +<li>insert the object per <i>copy</i></li> - '/// +<li>insert the object per <i>link</i></li> - '/// +<li>Only for the Writer:<ul> - '/// +<li>Insert the object per background / page</li> - '/// +<li>insert the object per background / paragraph</li></ul></li></ul> - '/// +Close the Gallery - '/// +Close the document - '/// Since the GraphicObjectbar could disturb our testing, we close it if it is open ///' - ' kontext "GraphicObjectbar" - ' if GraphicObjectbar.Exists then GraphicObjectbar.Close - for j=1 to 2 ' the two gallery-theme - if j=1 then - Gallerys.Select jpeg_bkg - printlog " selected gallery-theme : Backgrounds" - end if - - if j=2 then - Gallerys.Select iAnimation - printlog " selected gallery-theme : Animation" - end if - - if i=1 then ' test for writer - for k=1 to 2 - if k=1 then - ListView.Click - printlog " - insert on list view" - else - IconView.Click - printlog " - insert on icon view" - end if - - sleep (2) - View.Mousedown ( 5, 18 ) - View.Mouseup ( 5, 18 ) - View.typekeys "<DOWN>,<UP>" - - sleep (3) - View.TypeKeys "<SHIFT F10>" ' OpenContextMenu - sleep (3) - hMenuSelectNr ( 1 ) - - if j=1 then - printlog " - copy" - sleep (1) - hMenuSelectNr ( 1 ) - sleep (2) - else - printlog " - copy" - sleep (1) - hMenuSelectNr ( 1 ) - sleep (3) - - printlog " - link" - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - sleep (1) - hMenuSelectNr ( 1 ) - hMenuSelectNr ( 2 ) - sleep (3) - - printlog " - background -> page" - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - sleep (2) - hMenuSelectNr ( 1 ) - hMenuSelectNr ( 3 ) - hMenuSelectNr ( 1 ) - sleep (3) - - printlog " - background -> paragraph" - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - sleep (2) - hMenuSelectNr ( 1 ) - hMenuSelectNr ( 3 ) - hMenuSelectNr ( 2 ) - sleep (3) - end if - - kontext "GraphicObjectbar" - if GraphicObjectbar.Exists then - if GraphicObjectbar.isDocked = False then - GraphicObjectbar.Move 900,900 - end if - end if - kontext "Gallery" - - next k - else ' test for other applications ( calc, impress, draw ) - kontext "GraphicObjectbar" - if GraphicObjectbar.Exists then - if GraphicObjectbar.isDocked = False then - GraphicObjectbar.Move 900,900 - end if - end if - kontext "Gallery" - - kontext "Gluepointsobjectbar" - if Gluepointsobjectbar.Exists then - if Gluepointsobjectbar.isDocked = false then - Gluepointsobjectbar.Move 900,900 - end if - end if - kontext "Gallery" - - kontext "Optionsbar" - if Optionsbar.Exists then - if Optionsbar.isDocked = false then - Optionsbar.Move 900,900 - end if - end if - kontext "Gallery" - - for k=1 to 2 - if k=1 then - ListView.Click - printlog " - insert on list view" - else - IconView.Click - printlog " - insert on icon view" - end if - - sleep (1) - View.Mousedown ( 5, 18 ) - View.Mouseup ( 5, 18 ) - View.typekeys "<DOWN>,<UP>" - - sleep (1) - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - printlog " - copy" - sleep (3) - hMenuSelectNr ( 1 ) - hMenuSelectNr ( 1 ) - sleep (3) - - if j=2 then - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu - printlog " - link" - sleep (3) - hMenuSelectNr ( 1 ) - hMenuSelectNr ( 2 ) - sleep (2) - end if - - next k - end if - next j - ToolsGallery - WaitSlot (2000) - call hCloseDocument - WaitSlot (2000) - next i -endcase - -'------------------------------------------------------------------------- - -testcase tGallery_GalleryView_Delete - Dim jpeg_bkg as Integer - Dim iAnimation as Integer - Dim iSound as Integer - Dim i as Integer - Dim j as Integer - Dim k as Integer - - if gNetzInst = TRUE then - ' TODO: since we now only know net- installations, make it work! - printlog "No test for 'net' installations, because there are no rights to delete objects out of Gallery!" - 'NOTE: Jump to NotForNetInst... - Goto NotForNetInst - end if - - '/// Test gallery view -> delete objects with context-menu ( Backgrounds (<i>internal object</i>), Animation (<i>file</i>), Sound (<i>file</i>)) - select case iSprache - case 01 : jpeg_bkg = 1 : iAnimation = 2 : iSound = 28 - case 07 : jpeg_bkg = 29 : iAnimation = 1 : iSound = 6 - case 31 : jpeg_bkg = 1 : iAnimation = 2 : iSound = 28 - case 33 : jpeg_bkg = 13 : iAnimation = 1 : iSound = 29 - case 34 : jpeg_bkg = 7 : iAnimation = 1 : iSound = 28 - case 36 : jpeg_bkg = 12 : iAnimation = 1 : iSound = 10 - 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 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 - case 86 : jpeg_bkg = 1 : iAnimation = 9 : iSound = 13 - case 88 : jpeg_bkg = 1 : iAnimation = 7 : iSound = 20 - case else : jpeg_bkg = 1 : iAnimation = 2 : iSound = 17 - warnlog "Please insert the entrienumbers for '3D-graphics', 'Sounds' and one with normal files ( Animations )" - end select - - '/// Open a new writer-doc - '/// Tools / Gallery - gApplication = "WRITER" - call hNewDocument - call hOpenGallery - '/// Delete one object in list-view and icon-view for 3D, Animation and Sound - for i=1 to 3 - Kontext "Gallery" - if i=1 then - Gallerys.Select jpeg_bkg - printlog " selected gallery-theme : Backgrounds" - end if - - if i=2 then - Gallerys.Select iAnimation - printlog " selected gallery-theme : Animation" - end if - - if i=3 then - Gallerys.Select iSound - printlog " selected gallery-theme : Sound" - end if - - for j=1 to 2 - Kontext "Gallery" - if j=1 then - IconView.Click - printlog " Icon view" - sleep 1 - end if - if j=2 then - ListView.Click - printlog " List view" - end if - - for k=1 to 2 - Kontext "Gallery" - sleep (1) - View.MouseMove ( 5, 15 ) - View.TypeKeys "<SHIFT F10>" 'OpenContextMenu true - hMenuSelectNr ( 4 ) - kontext "Active" - if k=1 then - Active.No - printlog " delete one object => no" - else - Active.Yes - printlog " delete one object => yes" - end if - next k - next j - next i - ToolsGallery - call hCloseDocument - 'NOTE: Jump End NotForNetInst - NotForNetInst: -endcase - -'------------------------------------------------------------------------- -testcase tGallery_Quick_check - - '/// Short check, if at least 2 files exist in the gallery, and if they are > 0 in size ///' - '/// One in the gallery folder itself and the other one in a subfolder. ///' - dim sFile(1) as string - dim i as integer - - sFile(0) = ConvertPath ( gOfficeBasisPath + "share/gallery/apples.gif" ) ' - sFile(1) = ConvertPath ( gOfficeBasisPath + "share/gallery/bullets/coffee_1.gif" ) ' - '/// Open a new document - call hNewDocument - for i = 0 to 1 - '/// Click to deselect any selected objects ///' - gMouseclick 1, 50 - if FileExists(sFile(i)) then - if (FileLen(sFile(i)) > 0 ) then - call hGrafikEinfuegen ( sFile(i) ) - else - warnlog "File lenght is 0: '" + sFile(i) + "'" - end if - else - warnlog "File doesn't exist: '" + sFile(i) + "'" - end if - next i - '///close the document - call hCloseDocument -endcase - diff --git a/testautomation/graphics/required/includes/global/gallery2.inc b/testautomation/graphics/required/includes/global/gallery2.inc deleted file mode 100644 index 0662b3412ba7..000000000000 --- a/testautomation/graphics/required/includes/global/gallery2.inc +++ /dev/null @@ -1,290 +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 : wolfram.garten@oracle.com -'* -'* short description : Checking all gallery themes -'* -'***************************************************************** -'* -' #1 tLoad100GalleryGraphicFiles 'Inserting 100 gallery graphics and checking the sizes -' #1 tCheckAllGalleryGraphicFiles 'Checking the size ( > 0 Byte ) of all gallery-files. -' #1 tInsertGalleryObjects 'Inserting random objects via contextmenu-insert-copy. -' #0 LoadGraphic -' #0 CheckGraphic -' #0 makeNumOutOfText -' #1 tSettingsToCM 'Measurement unit for textdocuments to cm -' #1 tResetSettings 'Resetting the measurement unit for textdocuments. -'* -'\****************************************************************************** - -testcase tSettingsToCM - - printlog " Setting the measurement unit for textdocuments to cm." - printlog " +Tools / options / text documents / general" - ExitRestartTheOffice - WaitSlot (10000) - Call hNewDocument - ToolsOptions - hToolsOptions ( "WRITER", "General" ) - iSaveSetting = Masseinheit.GetSelIndex - Masseinheit.Select 2 - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK - Call hCloseDocument - -endcase -'------------------------------------------------------------------------- -testcase tLoad100GalleryGraphicFiles - - '/// Inserting all gallery graphics in a Writer document and checking the sizes. - Dim lsFiles (3000) as String - Dim lsGraphics (3000) as String - Dim i as Integer - Dim y as Integer - Dim t as Integer - Dim iCount as Integer - Dim corLoad as Boolean - Dim x as boolean - - '/// Geting all installed gallery objects out of the installation in a list. - if gNetzInst = TRUE then - GetAllFileList ( ConvertPath ( gOfficeBasisPath + "share\gallery\" ), "*.*", lsFiles () ) - else - GetAllFileList ( ConvertPath ( gOfficePath + "share\gallery\" ), "*.*", lsFiles () ) - end if - call GetOnlyGraphics ( lsFiles (), lsGraphics() ) - iCount = ListCount ( lsGraphics() ) - printlog " We have " + iCount + " graphics in the gallery." - '/// + Open a new document - call hNewDocument - - for i = 1 to 100 - for y = 1 to 1 - randomize - t = Int((iCount*Rnd)) - if (t<1) then 'just so we get it between 1 and the amount of items. - y = y - 1 - end if - next y - - corLoad = FALSE - try - '/// <i>Loop begin</i> - '/// + Inserting all gallery files and checking the sizes - '/// +- Iinsert / graphic / from file - '/// +- Check the size in 'format / graphics' on the <i>Type</i> tabpage - '/// +-- The size should noz be smaler than 17*25cm / photos 21*25cm - '/// + Deleting the graphic with <delete> of the keyboard - '/// <i>Loop ends</i> - x = LoadGraphic ( lsGraphics(t), corLoad ) - printlog - catch - ExceptLog - if corLoad = FALSE then - warnlog "Problems with " + lsGraphics(t) - ResetApplication - call hNewDocument - end if - endcatch - if (not x) then - printlog " Tested nr: " + t + " : " + lsGraphics(t) - end if - next i - - '/// Close the gallery ///' - ToolsGallery - WaitSlot (2000) - '/// Close the document ///' - call hCloseDocument -endcase 'tLoadAllGalleryGraphicFiles - -'------------------------------------------------------------------------- - -testcase tCheckAllGalleryGraphicFiles -'/// Checking the filesize of all gallery graphics. - Dim lsFiles (3000) as String - Dim lsGraphics (3000) as String - Dim i as Integer - Dim y as Integer - Dim t as Integer - Dim iCount as Integer - Dim corLoad as Boolean - Dim x as boolean - - '/// Geting all installed gallery objects out of the installation in a list. - if gNetzInst = TRUE then - GetAllFileList ( ConvertPath ( gOfficeBasisPath + "share\gallery\" ), "*.*", lsFiles () ) - else - GetAllFileList ( ConvertPath ( gOfficePath + "share\gallery\" ), "*.*", lsFiles () ) - end if - call GetOnlyGraphics ( lsFiles (), lsGraphics() ) - iCount = ListCount ( lsGraphics() ) - printlog " We have " + iCount + " graphics in the gallery." - '/// Open a new document - call hNewDocument - - for i=1 to iCount - corLoad = FALSE - try - '/// <i>Loop begin</i> - '///+ Inserting all gallery files and checking the sizes - '///+- Iinsert / graphic / from file - '///+- Check the size in 'format / graphics' on the <i>Type</i> tabpage - '///+-- The size should noz be smaler than 17*25cm / photos 21*25cm - '///+ Deleting the graphic with <delete> of the keyboard - '/// <i>Loop ends</i> - x = CheckGraphic ( lsGraphics(i), corLoad ) - catch - ExceptLog - if corLoad = FALSE then - warnlog "Problems with " + lsGraphics(i) - ResetApplication - call hNewDocument - end if - endcatch - if (not x) then - printlog " Tested nr: " + i + " : " + lsGraphics(i) - end if - next i - '/// Close the gallery ///' - ToolsGallery - WaitSlot (2000) - '/// Close the document ///' - call hCloseDocument -endcase 'tLoadAllGalleryGraphicFiles - -'------------------------------------------------------------------------- - -testcase tInsertGalleryObjects - Dim lsFiles (3000) as String - Dim lsGraphics (3000) as String - Dim CountOfThemes - Dim HowManyItems as Integer - Dim WhichOne as Integer - Dim CountOfItems as Integer - Dim ct as Integer - Dim i as Integer - Dim d as Integer - Dim iCount as Integer - Dim corLoad, x as Boolean - - '/// 1. Select theme ///' - call hNewDocument - call hOpenGallery - kontext "Gallery" - CountOfThemes = Gallerys.GetItemCount - for ct = 1 to CountOfThemes - Gallerys.Select ct - printlog " Selected Gallery-Theme nr: " + ct + ": " + Gallerys.GetSelText - kontext "Gallery" - CountOfItems = View.GetItemCount() - '/// 2. Choose if we should test 3,4 or 5 objects. ///' - for d = 1 to 1 - randomize - HowManyItems=Int((5*Rnd)+(3*Rnd)) - if CountOfItems = 0 then - QaErrorLog " There were no objects in the the gallery-theme on position: " + ct - else - if (HowManyItems<3) then 'just so we get it between 3 and 5. - d = d - 1 - else - printlog " Will now select and copy " + HowManyItems + " items from this Theme." - end if - for i = 1 to HowManyItems - '/// 3. Select the objects ///' - for x = 1 to 1 - randomize - WhichOne=Int(CountOfItems*RND) '(5*Rnd)+(CountOfItems*Rnd)) - if (WhichOne<1) then 'just so we get it between 1 and the amount of items. '>(CountOfItems + 1)) OR (WhichOne<1) then ' - x = x - 1 - end if - next x - printlog " Will copy object nr: " + WhichOne - View.Mousemove (1,1) - View.TypeKeys "<HOME>" - View.TypeKeys "<RIGHT>", (WhichOne) - kontext "GraphicObjectBar" - if GraphicObjectBar.Exists then - if GraphicObjectBar.IsDocked = False then GraphicObjectBar.Dock - end if - kontext "Gallery" - sleep (1) - View.TypeKeys("<shift f10>") - sleep (1) - try - dim number as integer - number = MenuGetItemCount - if (number > 2) AND (number < 10) then - '/// 4. Copy the selected item into our document. ///' - hMenuSelectNr (1) 'Insert - hMenuSelectNr (1) 'As Copy - sleep (1) - else - Warnlog " The contextmenu came up, but the number of entries were strange." - printlog " Number of entries:" + number - MenuSelect(0) - end if - catch - warnlog " A contextmenu didnt come up for the gallery-theme on position: " + ct - i = HowManyItems - endcatch - '/// 5. Repeat 3.-5. until 2. is fulfilled. ///' - next i - end if 'if the theme didnt have any objects, we landed here. - next d - '/// 6. Change Theme. ///' - '/// 7. Repeat 2. - 8. until all themes are done. ///' - next ct - - Kontext "Gallery" - if Gallery.Exists(2) then - ToolsGallery - WaitSlot (2000) - end if - - '/// Remove the last copied object. ///' - hTypeKeys "<DELETE>" - call hCloseDocument - -endcase 'tInsertGalleryObjects - -'------------------------------------------------------------------------- -testcase tResetSettings - - printlog "Resetting the measurement unit for textdocuments." - printlog "+Tools / options / text documents / general" - call hNewDocument - ToolsOptions - hToolsOptions ( "WRITER", "General" ) - Masseinheit.Select iSaveSetting - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK - call hCloseDocument - -endcase 'tResetSettings -'------------------------------------------------------------------------- diff --git a/testautomation/graphics/required/includes/global/id_001.inc b/testautomation/graphics/required/includes/global/id_001.inc index 18555fcfcb4d..b878278961b1 100644 --- a/testautomation/graphics/required/includes/global/id_001.inc +++ b/testautomation/graphics/required/includes/global/id_001.inc @@ -30,7 +30,34 @@ '* short description : '* '\****************************************************************************** - +sub id_001 + + printLog Chr(13) + "--------- id_001 ----------" + + qaerrorlog "#74988# tiFilePassword outcommented due to bug. -FHA" + call tiFilePassword + call tiFileSaveAs + call tiFileReload + call tiFileVersion + printlog " File->Send not possible to test, because extrnal prg get's called!" + call tiFileTemplates + ' Call tiFileNew instead i call: + call tmFileNewFromTemplate + call tmFileOpen + call tmFileClose + call tmFileSave + call tmFileSaveAs + call tmFileExit + + call tmFileSaveAll + call tmFileProperties + call tdFileExport + call tmFilePrinterSetting + ' special cases + ' Call AutoPilot 'inc\desktop\autopilo.inc + call tmFileExit ' don't test because unpredictable behaviour +end sub +'------------------------------------------------------------------------------ testcase tiFileSaveAs dim sFileName as string ' test document & new created doc @@ -55,9 +82,9 @@ testcase tiFileSaveAs sFilter (0) = 0 ' initalize ;-)... printlog " used document: graphics\required\input\tbo_alf_.od?" - sFileName = "graphics\required\input\tbo_alf_." + ExtensionString ' this is the file with all features + sFileName = "graphics\required\input\tbo_alf_." + ExtensionString printlog "FileName is " + sFileName - sFile = "isas_" ' this is the filename of the export files + sFile = "isas_" sPath = ConvertPath ( gOfficePath + "user/work/graphics/required/"+gApplication+"\"+ gPlatform) ' this is the export path printlog "sPath is " + sPath if dir (sPath) = "" then @@ -65,7 +92,7 @@ testcase tiFileSaveAs end if printlog " deleting all files in output directory: \\user\\work\\graphics\\required\\gApplication gPlatform isas_*" - if gSamePC = TRUE then ' delete export directory + if gSamePC = TRUE then GetFileList ( sPath, sFile+"*", Exlist() ) if KillFileList ( Exlist() ) <> TRUE then Warnlog "Couldn't delete all Files in Output-Export-Directory, the followings are still there:" @@ -78,68 +105,122 @@ testcase tiFileSaveAs printlog "load a sample presentation file" Call hFileOpen ( ConvertPath(gTesttoolPath + sFileName) ) WaitSlot (3000) - - printlog "running 5 times save as with different Filters" - for i = 1 to 6 'run it 5 times - printlog "calling Save as Dialog" - FileSaveAs - WaitSlot (2000) - Kontext "SpeichernDlg" - printlog "Selecting filter according to number of run" - Dateityp.Select i - sFilterName = Dateityp.GetSelText - sFileName = sPath + sFile + (i) - printlog "Filename is " & sFileName - printlog "Filtername for this file is " & sFilterName - Dateiname.SetText (sFileName) - Speichern.Click - kontext "AlienWarning" - if AlienWarning.exists(5) then - AlienWarning.OK + + printlog "Select between Impress and Draw:" + + if (gApplication = "DRAW") then + printlog "CASE DRAW: running 4 times save as with different Filters" + for i = 1 to 4 + printlog "calling Save as Dialog, " & i + FileSaveAs + WaitSlot (2000) + Kontext "SpeichernDlg" + printlog "Selecting filter according to number of run" + Dateityp.Select i + sFilterName = Dateityp.GetSelText + sFileName = sPath + sFile + (i) + printlog "Filename is " & sFileName + printlog "Filtername for this file is " & sFilterName + Dateiname.SetText (sFileName) + Speichern.Click + kontext "AlienWarning" + if AlienWarning.exists(5) then + AlienWarning.OK + end if + WaitSlot (5000) + next i + printlog "closing the sample file" + fileclose + WaitSlot (3000) + kontext "Messagebox" + if Messagebox.exists then + printlog "Messagebox about informationloss... :-) that's OK: 'Text in the messagebox: "+Messagebox.GetText+"'" + Messagebox.YES end if - WaitSlot (5000) - next i - printlog "closing the sample file" - fileclose - WaitSlot (3000) - kontext "Messagebox" - if Messagebox.exists then - printlog "Messagebox about informationloss... :-) that's OK: 'Text in the messagebox: "+Messagebox.GetText+"'" - Messagebox.YES - end if - - printlog "Loading the former saved files:" - for i = 1 to 6 'run it 5 times - - FileOpen - Kontext "OeffnenDlg" - WaitSlot (2000) - DateiAuswahl.TypeKeys "<END>" - DateiAuswahl.TypeKeys "<HOME>" - if i <> 1 then - DateiAuswahl.TypeKeys "<DOWN>", (i-1) - endif - sFileNameLoaded = Dateiname.GetSelText - printlog "File will be loaded: " & sFileNameLoaded - Oeffnen.Click - printlog "Closing doc if it gets loaded: " & sFileNameLoaded - if gApplication = "IMPRESS" then - Kontext "DocumentImpress" - if DocumentImpress.exists(5) then - Call hCloseDocument - else - warnlog "File did not get loaded." + + printlog "Loading the former saved files:" + for i = 1 to 4 'run it 4 times + + FileOpen + Kontext "OeffnenDlg" + WaitSlot (2000) + DateiAuswahl.TypeKeys "<END>" + DateiAuswahl.TypeKeys "<HOME>" + if i <> 1 then + DateiAuswahl.TypeKeys "<DOWN>", (i-1) endif - else + sFileNameLoaded = Dateiname.GetSelText + printlog i & ":File will be loaded: " & sFileNameLoaded + Oeffnen.Click + printlog "Closing doc if it gets loaded: " & sFileNameLoaded Kontext "DocumentDraw" if DocumentDraw.exists(5) then Call hCloseDocument else warnlog "File did not get loaded." endif - endif - WaitSlot (2000) - next i + WaitSlot (2000) + next i + else + printlog "CASE IMPRESS: running 9 times save as with different Filters" + for i = 1 to 9 + printlog "calling Save as Dialog, " & i + FileSaveAs + WaitSlot (2000) + Kontext "SpeichernDlg" + printlog "Selecting filter according to number of run" + Dateityp.Select i + sFilterName = Dateityp.GetSelText + sFileName = sPath + sFile + (i) + printlog "Filename is " & sFileName + printlog "Filtername for this file is " & sFilterName + Dateiname.SetText (sFileName) + Speichern.Click + kontext "AlienWarning" + if AlienWarning.exists(5) then + AlienWarning.OK + end if + WaitSlot (5000) + next i + printlog "closing the sample file" + fileclose + WaitSlot (3000) + kontext "Messagebox" + if Messagebox.exists then + printlog "Messagebox about informationloss... :-) that's OK: 'Text in the messagebox: "+Messagebox.GetText+"'" + Messagebox.YES + end if + + printlog "Loading the former saved files:" + for i = 1 to 9 'run it 9 times + FileOpen + Kontext "OeffnenDlg" + WaitSlot (2000) + DateiAuswahl.TypeKeys "<END>" + DateiAuswahl.TypeKeys "<HOME>" + if i <> 1 then + DateiAuswahl.TypeKeys "<DOWN>", (i-1) + endif + sFileNameLoaded = Dateiname.GetSelText + printlog i & ":File will be loaded: " & sFileNameLoaded + Oeffnen.Click + printlog "Closing doc if it gets loaded: " & sFileNameLoaded + printlog "For checking if its open and closing the doc we need to differ Impress and Draw:" + Kontext "DocumentImpress" + if DocumentImpress.exists(5) then + Call hCloseDocument + else + Kontext "DocumentDraw" + if DocumentDraw.exists(5) then + Call hCloseDocument + else + warnlog "File did not get loaded." + endif + endif + + WaitSlot (2000) + next i + endif endcase 'tiFileSaveAs diff --git a/testautomation/graphics/required/includes/global/id_002.inc b/testautomation/graphics/required/includes/global/id_002.inc index 9cc7dd10da53..0b2a91818cda 100644 --- a/testautomation/graphics/required/includes/global/id_002.inc +++ b/testautomation/graphics/required/includes/global/id_002.inc @@ -30,6 +30,27 @@ '* short description : '* '\****************************************************************************** +sub id_002 + + printLog Chr(13) + "--------- id_002 ----------" + + call tiEditUndoRedo + call tiEditRepeat + call tiEditCutPasteCopySelectall + call tiEditPasteSpecial + call tiEditSearchAndReplace + call tiEditDuplicate + call tEditPoints + call tiEditFields + call tdEditDeleteSlide + call tiEditLinks + call tiEditImageMap + call tiEditObjectProperties + call tiEditObjectEdit + call tiEditPlugIn + call tiEditHyperlink +end sub +'------------------------------------------------------------------------- testcase tiEditUndoRedo printlog " open application" diff --git a/testautomation/graphics/required/includes/global/id_003.inc b/testautomation/graphics/required/includes/global/id_003.inc index 65e11b8a4e31..e7c47b2c434c 100644 --- a/testautomation/graphics/required/includes/global/id_003.inc +++ b/testautomation/graphics/required/includes/global/id_003.inc @@ -30,6 +30,21 @@ '* short description : '* '\****************************************************************************** + +sub id_003 + + printLog Chr(13) + "--------- id_003 ----------" + + call tiViewNavigator + call tiViewZoom + call tiViewToolbar + Call tToolsCustomize 'global\required\include + call tiViewDisplayQuality + call tiViewLayer + call tViewSnapLines + call tViewGrid +end sub +'------------------------------------------------------------------------- testcase tiViewNavigator printlog " open application " diff --git a/testautomation/graphics/required/includes/global/id_004.inc b/testautomation/graphics/required/includes/global/id_004.inc index 3e4d3d86c07a..c06f88c682b8 100644 --- a/testautomation/graphics/required/includes/global/id_004.inc +++ b/testautomation/graphics/required/includes/global/id_004.inc @@ -30,6 +30,34 @@ '* short description : '* '\****************************************************************************** +sub id_004 + + printLog Chr(13) + "--------- id_004 ----------" + + call tiInsertSlide + call tiInsertDuplicateSlide + ' v expand slide + ' v summary slide + call tiInsertField + call tiInsertSpecialCharacter + call tiInsertHyperlink + call tiInsertScan + call tiInsertGraphic + call tiInsertObjectSound + call tiInsertObjectVideo + call tiInsertObjectSound + call tiInsertObjectVideo + call tiInsertChart + call tiInsertObjectOLEObjects + call tiInsertSpreadsheet + call tiInsertFormula + call tiInsertFloatingFrame + call tiInsertFile + call tiInsertPlugin + call tiInsertSnappointLine + call tdInsertLayer ' IMPRESS: Edit->Layer->Insert +end sub +'------------------------------------------------------------------------------ testcase tiInsertSlide printlog "Dateiname.settext Convertpath (gTesttoolPath + global\input\graf_inp\stabler.tif) " @@ -221,7 +249,7 @@ testcase tiInsertGraphic catch Warnlog "Insert graphic doesn't work :-(" endcatch - + WaitSlot (2000) printlog "close application " Call hCloseDocument @@ -279,11 +307,11 @@ testcase tiInsertChart InsertChart WaitSlot (2000) Kontext "Messagebox" - if Messagebox.Exists then - Warnlog Messagebox.GetText - Messagebox.OK - sleep 1 - end if + if Messagebox.Exists then + Warnlog Messagebox.GetText + Messagebox.OK + sleep 1 + end if gMouseClick 1,1 sleep 2 printlog "close application " @@ -332,17 +360,17 @@ testcase tiInsertSpreadsheet InsertSpreadsheetDraw WaitSlot (2000) Kontext "Messagebox" - if Messagebox.Exists (5) then - Warnlog Messagebox.GetText - Messagebox.OK - end if - sleep 2 - printlog "click somewhere out of the object, to deselect it " - gMouseClick 1,1 - sleep 1 - printlog "select and delete object with keys: <Tab><Delete> " - hTypekeys "<Tab><Delete>" - sleep 2 + if Messagebox.Exists (5) then + Warnlog Messagebox.GetText + Messagebox.OK + end if + sleep 2 + printlog "click somewhere out of the object, to deselect it " + gMouseClick 1,1 + sleep 1 + printlog "select and delete object with keys: <Tab><Delete> " + hTypekeys "<Tab><Delete>" + sleep 2 printlog "close application " Call hCloseDocument diff --git a/testautomation/graphics/required/includes/global/id_005.inc b/testautomation/graphics/required/includes/global/id_005.inc index 07783761b452..cba38479f34b 100644 --- a/testautomation/graphics/required/includes/global/id_005.inc +++ b/testautomation/graphics/required/includes/global/id_005.inc @@ -30,6 +30,33 @@ '* short description : '* '\****************************************************************************** +sub id_005 + + printLog Chr(13) + "--------- id_005 ----------" + + call tiFormatDefault + call tiFormatLine + call tdFormatArea + call tiFormatText + call tiFormatPositionAndSize + call tiFormatCharacter + call tiFormatControlForm + ' ^ Form + call tiFormatDimensions + call tiFormatConnector + call tiFormat3D_Effects + call tiFormatNumberingBullets + call tiFormatCaseCharacter + call tiFormatParagraph + call tiFormatPage + call tiFormatStylesAndFormatting + call tiFormatStylesSlideDesign + call tiFormatFontwork + call tiFormatGroup + printlog " format->group is also modify->group " + +end sub +'------------------------------------------------------------------------------ testcase tiFormatDefault printlog "open application" @@ -985,8 +1012,8 @@ testcase tiFormatStylesSlideDesign DeleteUnusedBackgrounds.check printlog "click button 'Load...'" Laden.Click - kontext "Neu" - printlog "click button 'more'" + sleep (10) + Kontext "Neu" Zusaetze.click sleep 1 kontext "Neu" diff --git a/testautomation/graphics/required/includes/global/id_006.inc b/testautomation/graphics/required/includes/global/id_006.inc index 0b210157e333..1b3a8b3c39a9 100644 --- a/testautomation/graphics/required/includes/global/id_006.inc +++ b/testautomation/graphics/required/includes/global/id_006.inc @@ -30,7 +30,6 @@ '* short description : '* '\********************************************************************************** - sub id_Tools printLog "--------- id_006 ----------" call tiToolsSpellchecking @@ -44,19 +43,21 @@ sub id_Tools call tiToolsEyedropper call tToolsOptionsTest ' global one end sub + '------------------------------------------------------------------------------- + testcase tiToolsSpellchecking if not gOOO then ' Spellcheck doesn't work in OOo builds. - '/// open application ///' + printlog "open application" Call hNewDocument - WaitSlot (2000) 'sleep 2 - '/// call subroutine 'hSetSpellHypLanguage' for setting the default language in th eoptions, to enable it for languages, which don't provide a dictionary (usually asian ones) ///' + WaitSlot (2000) + printlog " call subroutine 'hSetSpellHypLanguage' for setting the default language in th eoptions, to enable it for languages, which don't provide a dictionary (usually asian ones)" call hSetSpellHypLanguage - '/// create textframe with content ///' + printlog "create textframe with content" Call hTextrahmenErstellen ("Whaaaat", 10, 10, 30, 40) sleep 1 - '/// Tools->Spellcheck->Check ///' + printlog "Tools->Spellcheck->Check" ToolsSpellCheck WaitSlot (1000) 'sleep 1 Kontext "MessageBox" @@ -68,14 +69,14 @@ testcase tiToolsSpellchecking Kontext "Rechtschreibung" if Rechtschreibung.exists then Call DialogTest ( Rechtschreibung ) - '/// close dialog 'Spellcheck' ///' + printlog "close dialog 'Spellcheck'" Rechtschreibung.Close else warnlog " Spellcheck dialog didn't came up :-(" end if end if sleep 1 - '/// say OK to messagebox about 'Spellcheck has been completed' ///' + printlog "say OK to messagebox about 'Spellcheck has been completed'" Kontext "Messagebox" if Messagebox.exists (5) then warnlog "Shouldn't be any messagebox after pressing close in spellchecker" @@ -83,26 +84,30 @@ testcase tiToolsSpellchecking sleep (2) Kontext end if - '/// close application ///' + printlog "close application" Call hCloseDocument else goto endsub endif -endcase +endcase 'tiToolsSpellchecking + '------------------------------------------------------------------------------- + testcase tiToolsSpellcheckingAutomatic - '/// open application ///' + printlog "open application" Call hNewDocument - '/// Tools->Spellcheck->AutoSpellcheck ///' + printlog "Tools->Spellcheck->AutoSpellchec" ToolsSpellcheckAutoSpellcheck - '/// create textframe with text ///' + printlog " create textframe with text " Call hTextrahmenErstellen ("What", 10, 10, 30, 40) sleep 2 - '/// Tools->Spellcheck->AutoSpellcheck ///' + printlog "Tools->Spellcheck->AutoSpellcheck " ToolsSpellcheckAutoSpellcheck - '/// close application ///' + printlog "close application " Call hCloseDocument -endcase +endcase 'tiToolsSpellcheckingAutomatic + '------------------------------------------------------------------------------- + testcase tiToolsThesaurus Dim sWord as string Dim sExt as string @@ -165,20 +170,16 @@ testcase tiToolsThesaurus sWord = "Hello" endif end select - PrintLog "Thesaurus with 1 word: " + sWord - - if( Ucase(gApplication) = "DRAW" ) then + if( gApplication = "DRAW" ) then sExt = ".odg" elseif( Ucase(gApplication) = "IMPRESS" ) then sExt = ".odp" endif - Call hFileOpen (gTesttoolpath + "graphics\required\input\recht_" + iSprache + sExt) - Call sMakeReadOnlyDocumentEditable() + hFileOpenLocally( gTesttoolpath + "graphics\required\input\recht_" + iSprache + sExt) Call hTextrahmenErstellen (sWord,20,20,50,30) sleep 1 - printlog "select the word" hTypeKeys "<Home><SHIFT END>" @@ -197,132 +198,138 @@ testcase tiToolsThesaurus warnlog "the thesaurus does not appear" end if Call hCloseDocument -endcase +endcase 'tiToolsThesaurus + '------------------------------------------------------------------------------- + testcase tiToolsHyphenation - '/// open application ///' + printlog "open application " Call hNewDocument - '/// Tools->Hyphenation ///' + printlog "Tools->Hyphenation " ToolsLanguageHyphenationDraw - WaitSlot (2000) 'sleep 2 - '/// Tools->Hyphenation ///' + WaitSlot (2000) + printlog "Tools->Hyphenation " ToolsLanguageHyphenationDraw - '/// close application ///' + printlog "close application " Call hCloseDocument -endcase +endcase 'tiToolsHyphenation + '------------------------------------------------------------------------------- + testcase tiToolsAutoCorrect dim iLanguage as integer ' for resetting the language - '/// open application ///' + printlog "open application " Call hNewDocument - WaitSlot (1000) 'sleep 1 - '/// Tools->Autocorrect ///' + WaitSlot (1000) + printlog "Tools->Autocorrect " ToolsAutocorrect - WaitSlot (2000) 'sleep 1 + WaitSlot (2000) Kontext - '/// select tabpage 'Replace' ///' + printlog "select tabpage 'Replace' " Messagebox.SetPage TabErsetzung Kontext "TabErsetzung" - Call DialogTest ( TabErsetzung ) - '/// remember the language, that is selected in the 'Replacements and exceptions for Language' Listbox ///' - iLanguage = WelcheSprache.GetSelIndex - '///+ change the language to the 1st from the top ///' - WelcheSprache.Select 1 ' select language with empty list - '///+ type something into the field 'replace' ///' - Kuerzel.SetText "a" - '///+ type something into the field 'with' ///' - ErsetzenDurch.SetText "b" - '///+ click button 'new' ///' - Neu.Click - sleep 1 - '///+ click button 'delete' ///' + Call DialogTest ( TabErsetzung ) + printlog "remember the language, that is selected in the 'Replacements and exceptions for Language' Listbox " + iLanguage = WelcheSprache.GetSelIndex + printlog "+ change the language to the 1st from the top " + WelcheSprache.Select 1 ' select language with empty list + printlog "+ type something into the field 'replace' " + Kuerzel.SetText "a" + printlog "+ type something into the field 'with' " + ErsetzenDurch.SetText "b" + printlog "+ click button 'new' " + Neu.Click + sleep 1 + printlog "+ click button 'delete' " + Loeschen.Click + sleep 1 + try + printlog "+ click button 'delete' again " Loeschen.Click - sleep 1 - try - '///+ click button 'delete' again ///' - Loeschen.Click - catch - printlog "ok was CRASH before" '# - endcatch - '///+ if nothing happens it is ok, was a Crash before :-( ///' - '///+ restore cthe remembered language ///' - WelcheSprache.select (iLanguage) - Kontext - '/// select tabpage 'Exception' ///' - Messagebox.SetPage TabAusnahmen - Kontext "TabAusnahmen" - Call DialogTest ( TabAusnahmen ) - '/// type something into the field 'Abbreviations' ///' - Abkuerzungen.settext "Lala" - '///+ click button 'new' in 'Abbreviations' ///' - AbkuerzungenNeu.click - '///+ click button 'delete' in 'Abbreviations' ///' - AbkuerzungenLoeschen.click - '/// type something into the field 'Word with TWo INitial CApitals' ///' - Woerter.settext "LALA" - '///+ check the checkbox 'AutoInclude' in 'Word with TWo INitial CApitals' ///' - WoerterAutomatisch.Check - '///+ click button 'new' in 'Word with TWo INitial CApitals' ///' - WoerterNeu.click - '///+ click button 'delete' in 'Word with TWo INitial CApitals' ///' - WoerterLoeschen.click - '///+ UNcheck the checkbox 'AutoInclude' in 'Word with TWo INitial CApitals' ///' - WoerterAutomatisch.UnCheck - Kontext - '/// select tabpage 'Options' ///' - Messagebox.SetPage TabOptionen - Kontext "TabOptionen" - Call DialogTest ( TabOptionen ) - Kontext - '/// select tabpage 'Custom Quotes' ///' - Messagebox.SetPage TabLocalizedOptions - Kontext "TabLocalizedOptions" ' 1a - '/// in the part of 'single quotes': ///' - '///+ check 'replace' ///' - '///+ click 'start quote' ///' - SingleQuotesReplace.Check - SingleQuotesStart.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 1 ) - '///+ cancel dialog 'start quote' ///' - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 1b - '///+ click 'end quote' ///' - SingleQuotesEnd.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 2 ) - '///+ cancel dialog 'end quote' ///' - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 1s - '///+ click button 'default' ///' - SingleQuotesDefault.Click - - Kontext "TabLocalizedOptions" ' 2a - '/// in the part of 'double quotes': ///' - '///+ click 'start quote' ///' - DoubleQuotesStart.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 3 ) - '///+ cancel dialog 'start quote' ///' - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 2b - '///+ click 'end quote' ///' - DoubleQuotesEnd.Click - Kontext "Sonderzeichen" - Call DialogTest ( Sonderzeichen, 4 ) - '///+ cancel dialog 'end quote' ///' - Sonderzeichen.Cancel - Kontext "TabLocalizedOptions" ' 2s - '///+ click button 'default' ///' - DoubleQuotesDefault.Click - '///+ UNcheck 'replace' ///' - SingleQuotesReplace.UnCheck - '/// cancel dialog 'AtorCorrect' ///' - TabLocalizedOptions.cancel - '/// close application ///' + catch + printlog "ok was CRASH before" + endcatch + printlog "+ if nothing happens it is ok, was a Crash before :-( " + printlog "+ restore cthe remembered language " + WelcheSprache.select (iLanguage) + Kontext + printlog "select tabpage 'Exception' " + Messagebox.SetPage TabAusnahmen + Kontext "TabAusnahmen" + Call DialogTest ( TabAusnahmen ) + printlog "type something into the field 'Abbreviations' " + Abkuerzungen.settext "Lala" + printlog "+ click button 'new' in 'Abbreviations' " + AbkuerzungenNeu.click + printlog "+ click button 'delete' in 'Abbreviations' " + AbkuerzungenLoeschen.click + printlog "type something into the field 'Word with TWo INitial CApitals' " + Woerter.settext "LALA" + printlog "+ check the checkbox 'AutoInclude' in 'Word with TWo INitial CApitals' " + WoerterAutomatisch.Check + printlog "+ click button 'new' in 'Word with TWo INitial CApitals' " + WoerterNeu.click + printlog "+ click button 'delete' in 'Word with TWo INitial CApitals' " + WoerterLoeschen.click + printlog "+ UNcheck the checkbox 'AutoInclude' in 'Word with TWo INitial CApitals' " + WoerterAutomatisch.UnCheck + Kontext + printlog "select tabpage 'Options' " + Messagebox.SetPage TabOptionen + Kontext "TabOptionen" + Call DialogTest ( TabOptionen ) + Kontext + printlog "select tabpage 'Custom Quotes' " + Messagebox.SetPage TabLocalizedOptions + Kontext "TabLocalizedOptions" ' 1a + printlog "in the part of 'single quotes': " + printlog "+ check 'replace' " + printlog "+ click 'start quote' " + SingleQuotesReplace.Check + SingleQuotesStart.Click + Kontext "Sonderzeichen" + Call DialogTest ( Sonderzeichen, 1 ) + printlog "+ cancel dialog 'start quote' " + Sonderzeichen.Cancel + Kontext "TabLocalizedOptions" ' 1b + printlog "+ click 'end quote' " + SingleQuotesEnd.Click + Kontext "Sonderzeichen" + Call DialogTest ( Sonderzeichen, 2 ) + printlog "+ cancel dialog 'end quote' " + Sonderzeichen.Cancel + Kontext "TabLocalizedOptions" ' 1s + printlog "+ click button 'default' " + SingleQuotesDefault.Click + + Kontext "TabLocalizedOptions" ' 2a + printlog " in the part of 'double quotes': " + printlog "+ click 'start quote' " + DoubleQuotesStart.Click + Kontext "Sonderzeichen" + Call DialogTest ( Sonderzeichen, 3 ) + printlog "+ cancel dialog 'start quote' " + Sonderzeichen.Cancel + Kontext "TabLocalizedOptions" ' 2b + printlog "+ click 'end quote' " + DoubleQuotesEnd.Click + Kontext "Sonderzeichen" + Call DialogTest ( Sonderzeichen, 4 ) + printlog "+ cancel dialog 'end quote' " + Sonderzeichen.Cancel + Kontext "TabLocalizedOptions" ' 2s + printlog "+ click button 'default' " + DoubleQuotesDefault.Click + printlog "+ UNcheck 'replace' " + SingleQuotesReplace.UnCheck + printlog " cancel dialog 'AtorCorrect' " + TabLocalizedOptions.cancel + printlog " close application " Call hCloseDocument -endcase + +endcase 'tiToolsAutoCorrect '------------------------------------------------------------------------------- + testcase tChineseTranslation qaerrorlog( "#i89634# - Chinese Translation dialog does not close" ) @@ -337,139 +344,143 @@ testcase tChineseTranslation sFileName = "graphics\required\input\tchinese.odg" end if - '/// Open application ///' + printlog "Open application " Call hNewDocument - WaitSlot (2000) 'sleep 1 - '/// Save old state and Activate Support for Asian language ///' + WaitSlot (2000) + printlog "Save old state and Activate Support for Asian language " bSavedAsianSupport = ActiveDeactivateAsianSupport(TRUE) - '/// Open Document ///' + printlog "Open Document " Call hFileOpen ( ConvertPath(gTesttoolPath + sFileName) ) - '/// If write-protected - open as Temp-file ///' + printlog "If write-protected - open as Temp-file " sleep (2) Kontext "Standardbar" - if Bearbeiten.GetState(2) <> 1 then - Bearbeiten.Click '0 = not pressed. 1 = pressed. - Kontext - if Active.Exists(1) then - Active.Yes - else - warnlog "No messagebox after making document editable? - Test canceled here" - goto endsub - end if + if Bearbeiten.GetState(2) <> 1 then + Bearbeiten.Click '0 = not pressed. 1 = pressed. + Kontext + if Active.Exists(1) then + Active.Yes + else + warnlog "No messagebox after making document editable? - Test canceled here" + goto endsub end if + end if if uCase(gApplication) = "IMPRESS" then Kontext "DocumentImpress" else Kontext "DocumentDraw" end if - '/// Select all, Press RETURN to enter text in Editmode ///' - '/// Move marker to top of the text, go two steps right, mark two characters ///' + printlog "Select all, Press RETURN to enter text in Editmode " + printlog "Move marker to top of the text, go two steps right, mark two characters " EditSelectAll hTypeKeys "<RETURN>" hTypeKeys "<MOD1 HOME><RIGHT><RIGHT><SHIFT RIGHT RIGHT>" - '/// Open Chinesetranslation ///' + printlog "Open Chinesetranslation " ToolsChineseTranslation WaitSlot (2000) 'sleep 1 kontext "ChineseTranslation" - '/// Check if everything is there ///' - Call DialogTest ( ChineseTranslation ) - '/// Click on EditTerms ///' - EditTerms.Click - kontext "ChineseDictionary" - '/// Check if everything is there ///' - Call DialogTest ( ChineseDictionary ) - '/// Close dialog 'ChineseDictionary' with 'OK' ///' - ChineseDictionary.Ok + printlog " Check if everything is there " + Call DialogTest ( ChineseTranslation ) + printlog " Click on EditTerms " + EditTerms.Click + kontext "ChineseDictionary" + printlog " Check if everything is there " + Call DialogTest ( ChineseDictionary ) + printlog " Close dialog 'ChineseDictionary' with 'OK' " + ChineseDictionary.Ok kontext "ChineseTranslation" - '/// Close dialog 'Chinese' with 'OK' ///' - ChineseTranslation.OK + printlog " Close dialog 'Chinese' with 'OK' " + ChineseTranslation.OK kontext - '/// if messagebox exist, say OK; ('Spellcheck completed' or 'Word not found') ///' - if Messagebox.exists (5) then - printlog "Messagebox: "+Messagebox.gettext+"'" - Messagebox.ok - end if - '/// Restore old state for Asian language ///' + printlog " if messagebox exist, say OK; ('Spellcheck completed' or 'Word not found') " + if Messagebox.exists (5) then + printlog "Messagebox: "+Messagebox.gettext+"'" + Messagebox.ok + end if + printlog " Restore old state for Asian language " ActiveDeactivateAsianSupport(bSavedAsianSupport) - '/// Close application ///' + printlog " Close application " Call hCloseDocument -endcase + +endcase 'tChineseTranslation '------------------------------------------------------------------------------- + testcase tiToolsMacro - '/// open application ///' + printlog "open application " Call hNewDocument WaitSlot (2000) 'sleep 2 - '/// Tools->Macro ///' + printlog "Tools->Macro " ToolsMacro Kontext "Makro" - Call DialogTest ( Makro ) - '/// click button 'organizer...' ///' - Verwalten.Click - + Call DialogTest ( Makro ) + printlog "click button 'organizer...' " + Verwalten.Click Kontext - '/// switch to tabpage 'Modules' ///' - Messagebox.SetPage TabModule - Kontext "TabModule" - Call DialogTest ( TabModule ) - + printlog "switch to tabpage 'Modules' " + Messagebox.SetPage TabModule + Kontext "TabModule" + Call DialogTest ( TabModule ) Kontext - '/// switch to tabpage 'Libraries' ///' - Messagebox.SetPage TabBibliotheken - Kontext "TabBibliotheken" - Call DialogTest ( TabBibliotheken ) - '/// click lbutton 'append' ///' - Hinzufuegen.Click - Kontext "Messagebox" - if Messagebox.Exists (5) then - if Messagebox.GetRT = 304 then - Warnlog Messagebox.Gettext - Messagebox.Ok - end if - end if - Kontext "OeffnenDlg" - '/// cancel dialog 'append libraries' ///' - OeffnenDlg.Cancel - Kontext "TabBibliotheken" - '/// click button 'new' ///' - Neu.Click - kontext "NeueBibliothek" - sleep 1 'Bibliotheksname - '/// cancel dialog 'new library' ///' - NeueBibliothek.cancel - Kontext "TabBibliotheken" - '/// close dialog 'macro organizer' ///' - TabBibliotheken.Close + printlog "switch to tabpage 'Libraries' " + Messagebox.SetPage TabBibliotheken + Kontext "TabBibliotheken" + Call DialogTest ( TabBibliotheken ) + printlog "click lbutton 'append' " + Hinzufuegen.Click + Kontext "Messagebox" + if Messagebox.Exists (5) then + if Messagebox.GetRT = 304 then + Warnlog Messagebox.Gettext + Messagebox.Ok + end if + end if + Kontext "OeffnenDlg" + printlog "cancel dialog 'append libraries' " + OeffnenDlg.Cancel + Kontext "TabBibliotheken" + printlog "click button 'new' " + Neu.Click + kontext "NeueBibliothek" + sleep 1 'Bibliotheksname + printlog "cancel dialog 'new library' " + NeueBibliothek.cancel + Kontext "TabBibliotheken" + printlog "close dialog 'macro organizer' " + TabBibliotheken.Close Kontext "Makro" - '/// close dialog 'macro' ///' - Makro.Cancel - '/// close application ///' + printlog "close dialog 'macro' " + Makro.Cancel + printlog "close application " Call hCloseDocument -endcase +endcase 'tiToolsMacro + '------------------------------------------------------------------------------- + testcase tiToolsGallery - '/// open application ///' + printlog "open application " Call hNewDocument - '/// Tools->Gallery ///' + printlog "Tools->Gallery " ToolsGallery WaitSlot (2000) 'sleep 1 - '/// Tools->Gallery ///' + printlog "Tools->Gallery " ToolsGallery - '/// close application ///' + printlog "close application " Call hCloseDocument -endcase +endcase'tiToolsGallery + '------------------------------------------------------------------------------- + testcase tiToolsEyedropper - '/// open application ///' + printlog "open application " Call hNewDocument - '/// Tools->Eyedropper ///' + printlog "Tools->Eyedropper " ToolsEyedropper Kontext "Pipette" Call DialogTest (Pipette) - '/// close dialog 'Eyedropper' ///' + printlog "close dialog 'Eyedropper' " Pipette.Close sleep 1 - '/// close application ///' + printlog "close application " Call hCloseDocument -endcase +endcase 'tiToolsEyedropper diff --git a/testautomation/graphics/required/includes/global/id_007.inc b/testautomation/graphics/required/includes/global/id_007.inc index 17a4456ccb5f..81c265bca515 100644 --- a/testautomation/graphics/required/includes/global/id_007.inc +++ b/testautomation/graphics/required/includes/global/id_007.inc @@ -29,489 +29,486 @@ '* '* short description : '* -'\********************************************************************************** +'\****************************************************************************** + +sub id_007 + + printLog Chr(13) + "--------- id_007 ----------" + + call tdModifyFlipVertikal + call tdModifyFlipHorizontal + call tdContextConvertIntoCurve + call tdContextConvertIntoPolygon + call tdContextConvertIntoContour + call tdContextConvertInto3D + call tdContextConvertIntoRotationObject + call tdContextConvertIntoBitmap + call tdContextConvertIntoMetaFile + call tdModifyArrange + call tdModifyArrangeObjects + call tdModifyAlignment + call tdContextDistribution + call tdContextDescriptionObject + call tdContextNameObject + call tdModifyConnectBreak + call tdModifyShapes + call tdModifyCombineSplit +end sub +'------------------------------------------------------------------------------- testcase tdModifyFlipVertikal - - '/// open application ///' + printlog "open application" Call hNewDocument ' imp: contextmenue same SID! sleep 1 - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) try - '/// imp: Kontextmenu: Flip->Vertically ///' - '///+ Modify->Flip->Vertically ///' + printlog "imp: Kontextmenu: Flip->Vertically" ContextFlipVerticalDraw Printlog "- Flip-vertical is working" catch Warnlog "- Flip-Vertical does not work" endcatch sleep 1 - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyFlipVertikal '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyFlipHorizontal - '/// open application ///' + printlog "open application" Call hNewDocument ' imp: contextmenue same SID! WaitSlot (1000) - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) try - '/// imp: Kontextmenu: Flip->Horizontally ///' - '///+ Modify->Flip->Horizontally ///' + printlog "imp: Kontextmenu: Flip->Horizontally" ContextFlipHorizontalDraw Printlog "- Flip-horizontal is working" catch Warnlog "- Flip-horizontal does not work" endcatch sleep 1 - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyFlipHorizontal '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoCurve - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) - '/// Modify->Convert->To Curve ///' - '///+ Modify->Convert->To Curve ///' + printlog "Modify->Convert->To Curve" ContextConvertIntoCurve WaitSlot (2000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoCurve '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoPolygon dim iWaitIndex as integer - '/// open application ///' - Call hNewDocument ' imp: contextmenue same SID! + + printlog "open application" + Call hNewDocument InsertGraphicsFromFile Kontext "GrafikEinfuegenDlg" - '/// Check if the dialogue is there. If not - wait for maximum 10 seconds) - iWaitIndex = 0 - do while NOT GrafikEinfuegenDlg.Exists AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if NOT GrafikEinfuegenDlg.Exists AND iWaitIndex = 10 then - warnlog "Dialogue Insert Graphics didnt work. Ending testcase." - Call hCloseDocument - goto endsub - end if - '/// insert graphic: "global\input\graf_inp\enter.bmp" ///' - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") - Oeffnen.Click - sleep 3 - '/// Modify->Convert->To Polygon ///' - '/// Modify->Convert->To Polygon ///' - ContextConvertIntoPolygon - Kontext "InPolygonUmwandeln" - Call DialogTest (InPolygonUmwandeln) - '/// check checkbox: 'Fill holes' ///' - LoecherFuellen.Check - '/// click more in number field: 'Number of colors' ///' - Farbanzahl.More - '/// click more in number field: 'Point reductionn' ///' - Punktreduktion.More - '/// click more in number field: 'Tile size' ///' - Kachelgroesse.More - '/// click button 'Preview' ///' - Vorschau.Click - sleep 10 - '/// cancel dialog 'Convert to Polygon' ///' - InPolygonUmwandeln.Cancel - sleep (2) - '/// close application ///' + printlog "Check if the dialogue is there. If not - wait for maximum 10 seconds)" + iWaitIndex = 0 + do while NOT GrafikEinfuegenDlg.Exists AND iWaitIndex < 10 + sleep(1) + iWaitIndex = iWaitIndex + 1 + loop + if NOT GrafikEinfuegenDlg.Exists AND iWaitIndex = 10 then + warnlog "Dialogue Insert Graphics didnt work. Ending testcase." + Call hCloseDocument + goto endsub + end if + printlog "insert graphic: global\input\graf_inp\enter.bmp" + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\enter.bmp") + Oeffnen.Click + sleep 3 + printlog "Modify->Convert->To Polygon" + ContextConvertIntoPolygon + Kontext "InPolygonUmwandeln" + Call DialogTest (InPolygonUmwandeln) + printlog "check checkbox: 'Fill holes'" + LoecherFuellen.Check + printlog "click more in number field: 'Number of colors'" + Farbanzahl.More + printlog "click more in number field: 'Point reductionn'" + Punktreduktion.More + printlog "click more in number field: 'Tile size'" + Kachelgroesse.More + printlog "click button 'Preview'" + Vorschau.Click + sleep 10 + printlog "cancel dialog 'Convert to Polygon'" + InPolygonUmwandeln.Cancel + sleep (2) + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoPolygon '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoContour - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) - '/// Modify->Convert->To Contour ///' - '/// Modify->Convert->To Contour ///' + printlog "Modify->Convert->To Contour" ContextConvertIntoContour WaitSlot (1000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoContour '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertInto3D - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) - '/// Modify->Convert->To 3D ///' - '/// Modify->Convert->To 3D ///' + printlog "Modify->Convert->To 3D" ContextConvertInto3D WaitSlot (1000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertInto3D '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoRotationObject - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (1000) - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen (20,20,50,50) sleep 2 - '/// Modify->Convert->To 3D Rotation Object ///' - '/// Modify->Convert->To 3D Rotation Object ///' + printlog "Modify->Convert->To 3D Rotation Object" ContextConvertInto3DRotationObject WaitSlot (1000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoRotationObject '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoBitmap - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (3000) InsertGraphicsFromFile WaitSlot (3000) Kontext "GrafikEinfuegenDlg" - sleep 2 - '/// insert graphic: "global\input\graf_inp\columbia.dxf" ///' - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\columbia.dxf") - sleep 2 - Oeffnen.Click - sleep 2 - try - '/// Modify->Convert->To Bitmap ///' - ContextConvertIntoBitmap - Printlog "- Convert into bitmap is working" - catch - Warnlog "- Convert into bitmap does not work" - endcatch - '/// close application ///' + sleep 2 + printlog "insert graphic: global\input\graf_inp\columbia.dxf" + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\columbia.dxf") + sleep 2 + Oeffnen.Click + sleep 2 + try + printlog "Modify->Convert->To Bitmap" + ContextConvertIntoBitmap + Printlog "- Convert into bitmap is working" + catch + Warnlog "- Convert into bitmap does not work" + endcatch +printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoBitmap '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextConvertIntoMetaFile - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (3000) InsertGraphicsFromFile WaitSlot (1000) kontext "Messagebox" - if Messagebox.Exists (5) Then Messagebox.OK - sleep 1 - Kontext "GrafikEinfuegenDlg" - '/// insert graphic: "global\input\graf_inp\desp.bmp" ///' - sleep 2 - Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - sleep 2 - Preview.Click - sleep 3 - Oeffnen.Click - sleep 5 - try - '/// Modify->Convert->To Metafile ///' - '/// Modify->Convert->To Metafile ///' - ContextConvertIntoMetafile - Printlog "- convert into meta file does work" - catch - Warnlog "- convert into meta file does not work" - endcatch - '/// close application ///' + if Messagebox.Exists (5) Then Messagebox.OK + sleep 1 + Kontext "GrafikEinfuegenDlg" + printlog "insert graphic: global\input\graf_inp\desp.bmp" + sleep 2 + Dateiname.SetText ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") + sleep 2 + Preview.Click + sleep 3 + Oeffnen.Click + sleep 5 + try + printlog "Modify->Convert->To Metafile" + printlog "Modify->Convert->To Metafile" + ContextConvertIntoMetafile + Printlog "- convert into meta file does work" + catch + Warnlog "- convert into meta file does not work" + endcatch + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextConvertIntoMetaFile '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyArrange - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen ( 10, 10, 20, 40 ) hTypeKeys("<escape>") Call hRechteckErstellen ( 30, 30, 50, 60 ) - '/// Modify->Arrange->Bring to Front ///' - '///+ Modify->Arrange->Bring to Front ///' + printlog "Modify->Arrange->Bring to Front" FormatArrangeBringToFront WaitSlot (1000) - '/// Modify->Arrange->Bring Forward ///' - '///+ Modify->Arrange->Bring Forward ///' + printlog "Modify->Arrange->Bring Forward" ContextArrangeBringForward WaitSlot (1000) - '/// Modify->Arrange->Send Backward ///' - '///+ Modify->Arrange->Send Backward ///' + printlog "Modify->Arrange->Send Backward" ContextArrangeBringBackward WaitSlot (1000) - '/// Modify->Arrange->Send to Back ///' - '///+ Modify->Arrange->Send to Back ///' + printlog "Modify->Arrange->Send to Back" FormatArrangeSendToBack WaitSlot (1000) - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll - '/// Modify->Arrange->Reverse ///' - '///+ Modify->Arrange->Reverse ///' + printlog "Modify->Arrange->Reverse" ContextArrangeReverse WaitSlot (1000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyArrange '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyArrangeObjects - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (1000) - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen ( 20, 20, 30, 50 ) hTypeKeys("<escape>") Call hRechteckErstellen ( 30,30,50,50 ) - '/// Modify->Arrange->In Front of Object ///' - '///+ Modify->Arrange->In Front of Object ///' + printlog "Modify->Arrange->In Front of Object" ContextArrangeInFrontOfObject - '/// click on the upper left rectangle ///' + printlog "click on the upper left rectangle" gMouseClick 11,11 - '/// Modify->Arrange->Behind Object ///' - '///+ Modify->Arrange->Behind Object ///' + printlog "Modify->Arrange->Behind Object" ContextArrangeBehindObject - '/// click on the lower right rectangle ///' + printlog "click on the lower right rectangle" gMouseClick 45,45 sleep 1 - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyArrangeObjects '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyAlignment - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (1000) - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 20, 20, 30, 50 ) - '/// Modify->Alignment->Left ///' - '///+ Modify->Alignment->Left ///' + printlog "Modify->Alignment->Left" ContextAlignmentLeft WaitSlot (1000) - '/// Modify->Alignment->Centered ///' - '///+ Modify->Alignment->Centered ///' + printlog "Modify->Alignment->Centered" ContextAlignmentCentered WaitSlot (1000) - '/// Modify->Alignment->Right ///' - '///+ Modify->Alignment->Right ///' + printlog "Modify->Alignment->Right" ContextAlignmentRight WaitSlot (1000) - '/// Modify->Alignment->Top ///' - '///+ Modify->Alignment->Top ///' + printlog "Modify->Alignment->Top" ContextAlignmentTop WaitSlot (1000) - '/// Modify->Alignment->Center ///' - '///+ Modify->Alignment->Center ///' + printlog "Modify->Alignment->Center" ContextAlignmentBottom WaitSlot (1000) - '/// Modify->Alignment->Bottom ///' - '///+ Modify->Alignment->Bottom ///' + printlog "Modify->Alignment->Bottom" ContextAlignmentCenter WaitSlot (1000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyAlignment '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextDistribution - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (3000) - '/// create 3 rectangles ///' + printlog "create 3 rectangles" Call sSelectEmptyLayout Call hRechteckErstellen (20,20,30,30) Call hRechteckErstellen (40,40,50,50) Call hRechteckErstellen (60,60,70,70) sleep 1 - '/// select all with keyboard: <STRG>+ <A> ///' + printlog "select all with keyboard: <STRG>+ <A>" EditSelectAll sleep 1 - '/// Modify->Distibution... ///' - '///+ Modify->Distibution... ///' + printlog "Modify->Distibution..." ContextDistribution Kontext "VerteilenDlg" - sleep 1 - Call DialogTest (VerteilenDlg) - sleep 1 - '/// check radiobutton horizontal 'Left' ///' - Links.Check - '///+ check radiobutton 'Center' ///' - MitteHorizontal.Check - '///+ check radiobutton 'spacing' ///' - AbstandHorizontal.Check - '///+ check radiobutton 'right' ///' - Rechts.Check - '///+ check radiobutton 'none' ///' - KeineHorizontal.Check - '/// check radiobutton vertical 'top' ///' - Oben.Check - '///+ check radiobutton 'center' ///' - MitteVertikal.Check - '///+ check radiobutton 'spacing' ///' - AbstandVertikal.Check - '///+ check radiobutton 'bottom' ///' - Unten.Check - '///+ check radiobutton 'none' ///' - KeineVertikal.Check - '/// cancel dialog 'Distribution' ///' - VerteilenDlg.Cancel - sleep 2 - '/// close application ///' + sleep 1 + Call DialogTest (VerteilenDlg) + sleep 1 + printlog "check radiobutton horizontal 'Left'" + Links.Check + printlog "check radiobutton 'Center'" + MitteHorizontal.Check + printlog "check radiobutton 'spacing'" + AbstandHorizontal.Check + printlog "check radiobutton 'right'" + Rechts.Check + printlog "check radiobutton 'none'" + KeineHorizontal.Check + printlog "check radiobutton vertical 'top'" + Oben.Check + printlog "check radiobutton 'center'" + MitteVertikal.Check + printlog "check radiobutton 'spacing'" + AbstandVertikal.Check + printlog "check radiobutton 'bottom'" + Unten.Check + printlog "check radiobutton 'none'" + KeineVertikal.Check + printlog "cancel dialog 'Distribution'" + VerteilenDlg.Cancel + sleep 2 + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextDistribution '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextDescriptionObject - '/// Open application ///' + printlog "Open application" Call hNewDocument WaitSlot (1000) - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) ContextDescriptionObject Kontext "DescriptionObject" - Call DialogTest (DescriptionObject) - '/// Cancel dialog 'DescriptionObject' ///' - DescriptionObject.Cancel - '/// Close application ///' + Call DialogTest (DescriptionObject) + printlog "Cancel dialog 'DescriptionObject'" + DescriptionObject.Cancel + printlog "Close application" Call hCloseDocument -endcase +endcase 'tdContextDescriptionObject '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdContextNameObject - '/// open application ///' + printlog "open application" Call hNewDocument WaitSlot (1000) - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen ( 20, 20, 30, 50 ) hTypeKeys("<escape>") Call hRechteckErstellen ( 30, 40, 50, 60 ) sleep 1 - '/// select both by spanning a selection with the mouse ///' + printlog "select both by spanning a selection with the mouse" gMouseMove 1,1,70,70 sleep 1 - '/// Modify->Group ///' - '///+ Modify->Group ///' + printlog "Modify->Group" FormatGroupGroup WaitSlot (1000) - '/// Modify->Name Object ///' - '///+ Modify->Name Object ///' + printlog "Modify->Name Object" ContextNameObject Kontext "NameDlgObject" - Call DialogTest (NameDlgObject) - '/// cancel dialog 'name' ///' - NameDlgObject.Cancel - '/// Modify->UnGroup ///' - '///+ Modify->UnGroup ///' - FormatUngroupDraw - '/// close application ///' + Call DialogTest (NameDlgObject) + printlog "cancel dialog 'name'" + NameDlgObject.Cancel + printlog "Modify->UnGroup" + FormatUngroupDraw + printlog "close application" Call hCloseDocument -endcase +endcase 'tdContextNameObject '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyConnectBreak - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout sleep 1 - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen (10,10,30,30) Call hRechteckErstellen (35,35,50,50) sleep 1 - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll - '/// Modify->Connect ///' - '///+ Modify->Connect ///' + printlog "Modify->Connect" ContextConnect sleep 1 try - '/// Modify->Break ///' - '///+ Modify->Break ///' + printlog "Modify->Break" ContextBreak catch - Warnlog "- Modify-Break does not work" + Warnlog "- Modify-Break does not work" endcatch sleep 1 - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyConnectBreak '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyShapes - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout sleep 1 - '/// create two rectangles ///' + printlog "create two rectangles" gMouseClick 50,50 Call hRechteckErstellen (30,30,50,50) Call hRechteckErstellen (60,60,80,80) sleep 1 - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll sleep 1 try - '/// Modify->Shapes->Merge ///' - '///+ Modify->Shapes->Merge ///' - ModifyShapesMerge ' 1 + printlog "Modify->Shapes->Merge" + ModifyShapesMerge ' 1 WaitSlot (1000) 'sleep 1 - Printlog "- Modify-Shape merge is working" + Printlog "- Modify-Shape merge is working" catch - Warnlog "- Modify-shape merge is not working" + Warnlog "- Modify-shape merge is not working" endcatch - '/// select all and delete it ///' + printlog "select all and delete it" EditSelectAll sleep 1 hTypeKeys "<DELETE>" sleep 1 - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen (30,30,50,50) Call hRechteckErstellen (60,60,80,80) sleep 1 - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll sleep 1 try - '/// Modify->Shapes->Substract ///' - '///+ Modify->Shapes->Substract ///' - ModifyShapesSubstract ' 2 - Printlog "- Modify-shape-substract is working" + printlog "Modify->Shapes->Substract" + ModifyShapesSubstract ' 2 + Printlog "- Modify-shape-substract is working" catch - Warnlog "- Modify-shape substract is not working" + Warnlog "- Modify-shape substract is not working" endcatch sleep 1 - '/// select all and delete it ///' + printlog "select all and delete it" EditSelectAll sleep 1 hTypeKeys "<DELETE>" sleep 1 - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen (30,30,50,50) sleep 1 Call hRechteckErstellen (60,60,80,80) @@ -519,45 +516,42 @@ testcase tdModifyShapes EditSelectall sleep 1 try - '/// Modify->Shapes->Intersect ///' - '///+ Modify->Shapes->Intersect ///' - ModifyShapesIntersect ' 3 - Printlog "- Modify-shape intersect is working" + printlog "Modify->Shapes->Intersect" + ModifyShapesIntersect ' 3 + Printlog "- Modify-shape intersect is working" catch - Warnlog "- Modify-Shape intersect is not working" + Warnlog "- Modify-Shape intersect is not working" endcatch - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyShapes '------------------------------------------------------------------------------------------------------------------------------------------------ testcase tdModifyCombineSplit - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout sleep 1 - '/// create two rectangles ///' + printlog "create two rectangles" Call hRechteckErstellen (30,30,50,50) Call hRechteckErstellen (60,60,80,80) sleep 1 - '/// Edit->Select All ///' + printlog "Edit->Select All" EditSelectAll sleep 1 try - '/// Modify->Shapes->Combine ///' - '///+ Modify->Shapes->Combine ///' - ContextCombine - Printlog "- Modify combine is working" - '/// Modify->Shapes->Split ///' - '///+ Modify->Shapes->Split ///' - ContextSplit - Printlog "- Modify-split is working" + printlog "Modify->Shapes->Combine" + ContextCombine + Printlog "- Modify combine is working" + printlog "Modify->Shapes->Split" + ContextSplit + Printlog "- Modify-split is working" catch - Warnlog "- Modify-combine and split are not working" + Warnlog "- Modify-combine and split are not working" endcatch - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tdModifyCombineSplit -'------------------------------------------------------------------------------------------------------------------------------------------------ +'------------------------------------------------------------------------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/global/id_008.inc b/testautomation/graphics/required/includes/global/id_008.inc index 4add85a48463..f88174929c1f 100644 --- a/testautomation/graphics/required/includes/global/id_008.inc +++ b/testautomation/graphics/required/includes/global/id_008.inc @@ -30,46 +30,55 @@ '* short description : '* '\***************************************************************** +sub id_008 + printLog Chr(13) + "--------- id_008 ----------" + + Call tiWindowNewWindow + call tidWindow123 + +end sub +'------------------------------------------------------------------------------- testcase tiWindowNewWindow - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) - '/// Window->New Window ///' + printlog "Window->New Window" WindowNewWindow WaitSlot (2000) - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiWindowNewWindow + +'------------------------------------------------------------------------------- testcase tidWindow123 goto endsub '' testing TBO: 29.03.2002 dim iMenues as integer - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create rectangle ///' + printlog "create rectangle" Call hRechteckErstellen ( 10, 10, 20, 40 ) Kontext "DocumentImpress" - DocumentImpress.UseMenu - iMenues = MenuGetItemCount - warnlog "---- Number of Main menus: " & iMenues - MenuSelect(Menugetitemid(8)) - sleep 1 - iMenues = MenuGetItemCount - printlog "---- Number of Main menus: " & iMenues - ' MenuSelect(Menugetitemid(14)) - sleep 1 - i=1 - printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - i=2 - printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - warnlog "Dynamic entries not accessible ? :-(((((" - ' i=3 - ' printlog "count: " + i + "; of submenue: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" - '/// close application ///' + DocumentImpress.UseMenu + iMenues = MenuGetItemCount + warnlog "---- Number of Main menus: " & iMenues + MenuSelect(Menugetitemid(8)) + sleep 1 + iMenues = MenuGetItemCount + printlog "---- Number of Main menus: " & iMenues + ' MenuSelect(Menugetitemid(14)) + sleep 1 + i=1 + printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" + i=2 + printlog "count: " + i + "; of submenu: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" + warnlog "Dynamic entries not accessible ? :-(((((" + ' i=3 + ' printlog "count: " + i + "; of submenue: " + MenuGetItemCount + "; SID: " + MenuGetItemId (i) + "; Text: " + MenuGetItemText (Menugetitemid(i)) + "; Command: " + MenuGetItemCommand(Menugetitemid(i)) + "; Seperator?: " + MenuIsSeperator(i) + "; Enabled: " + MenuIsItemEnabled(Menugetitemid(i)) + "; Checked: " + MenuIsItemChecked(Menugetitemid(i)) + ";" + printlog "close application" Call hCloseDocument -endcase - +endcase 'tidWindow123
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/global/id_009.inc b/testautomation/graphics/required/includes/global/id_009.inc index 57ff31138cb8..3680dfafbc4f 100644 --- a/testautomation/graphics/required/includes/global/id_009.inc +++ b/testautomation/graphics/required/includes/global/id_009.inc @@ -30,253 +30,251 @@ '* short description : Testcases to test the Help-Menu. '* '\****************************************************************************** -' -testcase tmHelpHelpAgent +sub id_009 - Call hNewDocument + printLog Chr(13) + "--------- id_009 ----------" - hTBOtypeInDoc + call tCheckIfTheHelpExists + Call tmHelpContents + Call tmHelpHelpAgent + Call tmHelpTips + Call tmHelpExtendedTips + Call tmHelpAboutStarOffice +end sub +'------------------------------------------------------------------------------ + +testcase tmHelpHelpAgent + Call hNewDocument + hTBOtypeInDoc HelpHelpAgent ' it's just a switch sleep 2 HelpHelpAgent - Call hCloseDocument -endcase +endcase 'tmHelpHelpAgent -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... +'------------------------------------------------------------------------------ testcase tmHelpTips Call hNewDocument hTBOtypeInDoc - HelpTips Sleep 2 HelpTips - Call hCloseDocument -endcase +endcase 'tmHelpTips -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... +'------------------------------------------------------------------------------ testcase tmHelpExtendedTips Call hNewDocument hTBOtypeInDoc - HelpEntendedHelp Sleep (2) HelpEntendedHelp - Call hCloseDocument -endcase +endcase 'tmHelpExtendedTips -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... +'------------------------------------------------------------------------------ testcase tmHelpAboutStarOffice Call hNewDocument hTBOtypeInDoc - HelpAboutStarOffice Kontext "UeberStarMath" DialogTest (UeberStarMath) UeberStarMath.OK - Call hCloseDocument -endcase +endcase 'tmHelpAboutStarOffice -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... +'------------------------------------------------------------------------------ testcase tmHelpContents - goto endsub '"#i84486# - tmHelpContents outcommented due to crash." - dim i as integer + dim i as integer - '/// open application ///' - Call hNewDocument - '/// Help->Contents ///' - HelpContents - sleep(8) - kontext "StarOfficeHelp" - if Not StarOfficeHelp.Exists then - Warnlog "Help is not up!" - else - '/// get the number of entries in the listbox 'select Help modul' ///' - Printlog "HelpAbout: '" + HelpAbout.GetItemCount +"'" - '################ left half ################ - '/// on the left half of the dialog: ///' - '///+ change to the tabpage 'Contents' ///' - TabControl.SetPage ContentPage - '///+ get the number of entries in the listbox 'MAin help themes' ///' - Printlog "SearchContent: '" + SearchContent.GetItemCount + "'" - '///+ change to the tabpage 'Index' ///' - TabControl.SetPage IndexPage - '///+ get the number of entries in the listbox 'Search term' ///' - Printlog "SearchIndex: '" + SearchIndex.GetItemCount + "'" - sleep 5 - '///+ click on button 'Display' ///' - DisplayIndex.Click - sleep 5 - '///+ change to the tabpage 'Find' ///' - TabControl.SetPage FindPage - '///+ get the number of entries in the listbox 'Search term' ///' - Printlog "SearchFind: '" + SearchFind.GetItemCount + "'" - '/// If the Search-Text-Field is empty - Check that the Find-button is deactivated ///' - if SearchFind.GetSelText = "" then - if FindButton.IsEnabled then - warnlog " The Find-Button should have been inactive, but was active." - endif - else - warnlog " The Search-Text-Field shouldn't contain any text. But contained: " + SearchFind.GetSelText - endif - '/// Insert some irrelevant text to get 0 results from the search. ///' - SearchFind.SetText "Doobbidedooo" - '///+ click on button 'Find' ///' - FindButton.Click - kontext - '///+ Messagebox comes up about: 'No topics found.' say OK ///' - if (active.exists (2) )then - Printlog "active came up: '" + active.gettext + "'" - active.ok + printlog "open application" + Call hNewDocument + printlog "Help->Contents" + HelpContents + sleep(8) + kontext "StarOfficeHelp" + if Not StarOfficeHelp.Exists then + Warnlog "Help is not up!" + else + printlog "get the number of entries in the listbox 'select Help modul'" + Printlog "HelpAbout: '" + HelpAbout.GetItemCount +"'" + printlog "on the left half of the dialog:" + printlog "change to the tabpage 'Contents'" + TabControl.SetPage ContentPage + printlog "get the number of entries in the listbox 'MAin help themes'" + Printlog "SearchContent: '" + SearchContent.GetItemCount + "'" + printlog "change to the tabpage 'Index'" + TabControl.SetPage IndexPage + printlog "get the number of entries in the listbox 'Search term'" + Printlog "SearchIndex: '" + SearchIndex.GetItemCount + "'" + sleep 5 + printlog "click on button 'Display'" + DisplayIndex.Click + sleep 5 + printlog "change to the tabpage 'Find'" + TabControl.SetPage FindPage + printlog "get the number of entries in the listbox 'Search term'" + Printlog "SearchFind: '" + SearchFind.GetItemCount + "'" + printlog "If the Search-Text-Field is empty - Check that the Find-button is deactivated" + if SearchFind.GetSelText = "" then + if FindButton.IsEnabled then + warnlog " The Find-Button should have been inactive, but was active." endif - kontext "StarOfficeHelp" - '///+ check checkbox 'Complete words only' ///' - FindFullWords.Check - '///+ check checkbox 'Find in headings only' ///' - FindInHeadingsOnly.Check - '///+ get the number of entries in the listbox 'List of headings' ///' - Printlog "Result: '" + Result.GetItemCount + "'" - '///+ click on button 'Display' ///' - DisplayFind.Click - '///+ change to the tabpage 'Bookmarks' ///' - TabControl.SetPage BookmarksPage - '///+ get the number of entries in the listbox 'Bookmark list' ///' - Printlog "Bookmarks: '" + Bookmarks.GetItemCount + "'" - '///+ click on button 'Display' ///' - DisplayBookmarks.Click - '################ right half ################ - '/// on the right half of teh dialog: ///' - '################ toolbar ################ - Kontext "TB_Help" - '///+ click on button 'Hide/Show Navigation Pane' ///' - Index.Click + else + warnlog " The Search-Text-Field shouldn't contain any text. But contained: " + SearchFind.GetSelText + endif + printlog "Insert some irrelevant text to get 0 results from the search." + SearchFind.SetText "Doobbidedooo" + printlog "click on button 'Find'" + FindButton.Click + kontext + printlog "Messagebox comes up about: 'No topics found.' say OK" + if (active.exists (2) )then + Printlog "active came up: '" + active.gettext + "'" + active.ok + endif + kontext "StarOfficeHelp" + printlog "check checkbox 'Complete words only' " + FindFullWords.Check + printlog "check checkbox 'Find in headings only' " + FindInHeadingsOnly.Check + printlog "get the number of entries in the listbox 'List of headings'" + Printlog "Result: '" + Result.GetItemCount + "'" + printlog "click on button 'Display'" + DisplayFind.Click + printlog "change to the tabpage 'Bookmarks'" + TabControl.SetPage BookmarksPage + printlog "get the number of entries in the listbox 'Bookmark list'" + Printlog "Bookmarks: '" + Bookmarks.GetItemCount + "'" + printlog "click on button 'Display'" + DisplayBookmarks.Click + printlog "on the right half of teh dialog:" + Kontext "TB_Help" + printlog "click on button 'Hide/Show Navigation Pane'" + Index.Click + sleep 1 + printlog "click on button 'Hide/Show Navigation Pane'" + Index.Click + sleep 1 + printlog "click on button 'First Page'" + GoToStart.Click + sleep 1 + printlog "click on button 'Previous Page'" + Backward.Click + sleep 1 + printlog "click on button 'Next Page'" + Forward.Click + sleep 1 + printlog "click on button 'Print ...'" + PrintButton.Click + sleep (1) + kontext "Active" + if Active.Exists( 2 ) then + qaerrorlog "No default printer defined: " & Active.GetText + Active.Ok + end if + kontext "Printing" + if Printing.Exists( 2 ) then + printlog "In the dialog 'Print' press the button 'Cancel'" + Printing.cancel + else + warnlog "the Print-Dialogue didnt appear." + end if + Kontext "TB_Help" + printlog "click on button 'Add to Bookmarks ...'" + sleep 1 + SetBookmarks.Click + sleep 1 + Kontext "AddBookmark" + printlog "on the dialog 'Add to Bookmarks ...' get the text from the editfield 'Bookmark' and press button 'Cancel'" + Printlog "Bookmarkname: '" + Bookmarkname.GetText + "'" + AddBookmark.Cancel + sleep 1 + '################ help display ################ + kontext "HelpContent" + printlog "open the Context Menu of the Frame 'Help Content' and count the entries" + HelpContent.OpenContextMenu + sleep 1 + Printlog " i: " + hMenuItemGetCount + hMenuClose() + '################ right scroolbar ################ + kontext "HelpContent" + printlog "click on button 'Previous Page'" + if HelpContentUP.IsVisible then + HelpContentUP.Click sleep 1 - '///+ click on button 'Hide/Show Navigation Pane' ///' - Index.Click - sleep 1 - '///+ click on button 'First Page' ///' - GoToStart.Click - sleep 1 - '///+ click on button 'Previous Page' ///' - Backward.Click - sleep 1 - '///+ click on button 'Next Page' ///' - Forward.Click - sleep 1 - '///+ click on button 'Print ...' ///' - PrintButton.Click - sleep (1) - - kontext "Active" - if Active.Exists( 2 ) then - qaerrorlog "No default printer defined: " & Active.GetText - Active.Ok - end if - - kontext "Printing" - if Printing.Exists( 2 ) then - '/// In the dialog 'Print' press the button 'Cancel' ///' - Printing.cancel - else - warnlog "the Print-Dialogue didnt appear." - end if - Kontext "TB_Help" - '///+ click on button 'Add to Bookmarks ...' ///' - sleep 1 - SetBookmarks.Click - sleep 1 - Kontext "AddBookmark" - '///+ on the dialog 'Add to Bookmarks ...' get the text from the editfield 'Bookmark' and press button 'Cancel' ///' - Printlog "Bookmarkname: '" + Bookmarkname.GetText + "'" - AddBookmark.Cancel - sleep 1 - '################ help display ################ - kontext "HelpContent" - '///+ open the Context Menu of the Frame 'Help Content' and count the entries ///' - HelpContent.OpenContextMenu - - sleep 1 - Printlog " i: " + hMenuItemGetCount - hMenuClose() - '################ right scroolbar ################ - kontext "HelpContent" - '///+ click on button 'Previous Page' ///' - if HelpContentUP.IsVisible then - HelpContentUP.Click - sleep 1 - endif - '///+ click on button 'Navigation' ///' - if HelpContentNAVIGATION.IsVisible then - HelpContentNAVIGATION.Click - sleep 1 - endif - kontext "NavigationsFenster" - '/// on the toolbox 'Navigation' press the window close button 'X' ///' - NavigationsFenster.Close - sleep 1 - kontext "HelpContent" - '///+ click on button 'Next Page' ///' - if HelpContentDOWN.IsVisible then - HelpContentDOWN.Click - sleep 1 - endif - kontext "StarOfficeHelp" - '/// close the help with the keys [strg]+[F4] ///' - Printlog "trying to close the help now" - try - StarOfficeHelp.TypeKeys "<Mod1 F4>" ' strg F4 supported since bug #103586# - catch - Warnlog "failed to close the help window :-(" - endcatch - kontext "StarOfficeHelp" - if StarOfficeHelp.Exists then - warnlog "Help still up!" - endif - endif - '/// close application ///' - Call hCloseDocument -endcase + endif + printlog "click on button 'Navigation'" + if HelpContentNAVIGATION.IsVisible then + HelpContentNAVIGATION.Click + sleep 1 + endif + kontext "NavigationsFenster" + printlog "on the toolbox 'Navigation' press the window close button 'X'" + NavigationsFenster.Close + sleep 1 + kontext "HelpContent" + printlog "click on button 'Next Page'" + if HelpContentDOWN.IsVisible then + HelpContentDOWN.Click + sleep 1 + endif + kontext "StarOfficeHelp" + printlog "close the help with the keys [strg]+[F4]" + Printlog "trying to close the help now" + try + StarOfficeHelp.TypeKeys "<Mod1 F4>" ' strg F4 supported since bug #103586# + catch + Warnlog "failed to close the help window :-(" + endcatch + kontext "StarOfficeHelp" + if StarOfficeHelp.Exists then + warnlog "Help still up!" + endif + endif + printlog "close application" + Call hCloseDocument +endcase 'tmHelpContents -'...---....---.-.-.-.-.....---......--.-.-.-.....----..-........................---....... +'------------------------------------------------------------------------------ testcase tCheckIfTheHelpExists - '/// open application ///' - Call hNewDocument - '/// Bring up the help-window ///' - HelpContents - kontext "HelpContent" - sleep (5) - '/// Press "CTRL A" and "CTRL C" to select all and then copy it. ///' - HelpContent.TypeKeys "<MOD1 A>" - sleep (1) - HelpContent.TypeKeys "<MOD1 C>" - '/// If the clipboard now is empty, then nothing were copied, which means we have a bug. ///' - if GetClipBoard = "" then - Warnlog " No content in the Help-Content -view." - else - Printlog " The Help-Content -view contained content. Good." - endif - kontext "StarOfficeHelp" - '/// Press "CTRL F4" to close the help-window. ///' - try - StarOfficeHelp.TypeKeys "<MOD1 F4>" - catch - Warnlog " Failed to close the help window :-(" - endcatch - kontext "StarOfficeHelp" - if StarOfficeHelp.Exists then - warnlog "Help was still visible!" - endif - '/// And a dot into the main window. Making sure kontext and focus is right. ///' - hTypeKeys "." - '/// Close Application ///' - Call hCloseDocument + printlog "open application" + Call hNewDocument + printlog "Bring up the help-window" + HelpContents + kontext "HelpContent" + sleep (5) + printlog "Press CTRL A and CTRL C to select all and then copy it." + HelpContent.TypeKeys "<MOD1 A>" + sleep (1) + HelpContent.TypeKeys "<MOD1 C>" + printlog "If the clipboard now is empty, then nothing were copied, which means we have a bug." + if GetClipBoard = "" then + Warnlog "No content in the Help-Content -view." + else + Printlog "The Help-Content -view contained content. Good." + endif + kontext "StarOfficeHelp" + printlog "Press CTRL F4 to close the help-window." + try + StarOfficeHelp.TypeKeys "<MOD1 F4>" + catch + Warnlog " Failed to close the help window :-(" + endcatch + kontext "StarOfficeHelp" + if StarOfficeHelp.Exists then + warnlog "Help was still visible!" + endif + printlog "And a dot into the main window. Making sure kontext and focus is right." + hTypeKeys "." + printlog "Close Application" + Call hCloseDocument endcase 'tCheckIfTheHelpExists + +'------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/global/id_011.inc b/testautomation/graphics/required/includes/global/id_011.inc index 0bc68567839d..f9ad3f46378b 100644 --- a/testautomation/graphics/required/includes/global/id_011.inc +++ b/testautomation/graphics/required/includes/global/id_011.inc @@ -30,280 +30,283 @@ '* short description : '* '\****************************************************************************** +sub id_011 -testcase tiTextToolbar + printLog Chr(13) + "--------- id_011 ----------" + + call tdBezierToolbar + call tiDrawObjectBar + call tiTextToolbar + call tiGraphicsObjectBar + call tiGluepointToolbar + +end sub +'------------------------------------------------------------------------------- +testcase tiTextToolbar Dim iWaitIndex as integer Dim Zufall as integer Dim i as integer - '/// open application ///' + printlog "open application" Call hNewDocument Call sSelectEmptyLayout - - '/// create a textframe with text ///' + printlog "create a textframe with text" hTextrahmenErstellen ("This is a Text, which will be formatted in several ways", 20,20,40,80) - '/// The 'Object Toolbar' now changes ///' + printlog "The 'Object Toolbar' now changes" sleep 2 - '/// select of the text with <STRG> + <A> ///' + printlog "select of the text with <STRG> + <A>" EditSelectAll sleep 2 - '/// Call the textobjectbar from the View-Toolbars-menu ///' + printlog "Call the textobjectbar from the View-Toolbars-menu" Kontext "TextObjectbar" - if TextObjectbar.Exists <> TRUE then 'isVisible - ViewToolbarsTextFormatting - end if - WaitSlot (3000) 'sleep (3) + if TextObjectbar.Exists <> TRUE then 'isVisible + ViewToolbarsTextFormatting + end if + WaitSlot (3000) 'sleep (3) Kontext "TextObjectbar" - Printlog "- choose random font" - randomize - Zufall=((2*Rnd)+1) ' wird nicht auf den verfuegbaren bereich getreckt :-( TODO TBO! - Schriftart.GetItemcount - Schriftart.GetSelText - Schriftart.Select (Zufall) - '/// select any font you like in the listbox 'Font' on 'Object Toolbar' ///' - Printlog Schriftart.GetSelText + " chosen" - + Printlog "- choose random font" + randomize + Zufall=((2*Rnd)+1) ' wird nicht auf den verfuegbaren bereich getreckt :-( TODO TBO! + Schriftart.GetItemcount + Schriftart.GetSelText + Schriftart.Select (Zufall) + printlog "select any font you like in the listbox 'Font' on 'Object Toolbar'" + Printlog Schriftart.GetSelText + " chosen" Kontext "TextObjectbar" - sleep 2 - Printlog "- Change size of font" - '/// select any font you like in the listbox 'Size' on 'Object Toolbar' ///' - Schriftgroesse.Select (Zufall) - Printlog Schriftgroesse.GetSelText + " chosen" - + sleep 2 + Printlog "- Change size of font" + printlog "select any font you like in the listbox 'Size' on 'Object Toolbar'" + Schriftgroesse.Select (Zufall) + Printlog Schriftgroesse.GetSelText + " chosen" Kontext "TextObjectbar" - Printlog "- Font attribute bold" - '/// click button 'Bold' ///' - Fett.Click - sleep 2 - + Printlog "- Font attribute bold" + printlog "click button 'Bold'" + Fett.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Font attribute cursive" - '/// click button 'Italic' ///' - Kursiv.Click - sleep 2 - + Printlog "- Font attribute cursive" + printlog "click button 'Italic'" + Kursiv.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Font attribute cursiv" - '/// click button 'Underline' ///' - Unterstrichen.Click - sleep 2 - + Printlog "- Font attribute cursiv" + printlog "click button 'Underline'" + Unterstrichen.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- font attribute color" - '/// click button 'Font Color' and tearoff the box ///' - sleep 3 - FontColorGraphics.TearOff - Kontext "TB_Farbe" - TB_Farbe.Move 20, 20 - Sleep 2 - '/// double click in the middle of the box ///' - TB_Farbe.MouseDoubleClick 50, 50 - Sleep 2 - '/// close box 'Font Color' ///' - TB_Farbe.Close + Printlog "- font attribute color" + printlog "click button 'Font Color' and tearoff the box" + sleep 3 + FontColorGraphics.TearOff + Kontext "TB_Farbe" + TB_Farbe.Move 20, 20 + Sleep 2 + printlog "double click in the middle of the box" + TB_Farbe.MouseDoubleClick 50, 50 + Sleep 2 + printlog "close box 'Font Color'" + TB_Farbe.Close Kontext "TextObjectbar" - Printlog "- Allign text left" - '/// click button 'Left' ///' - Linksbuendig.Click - sleep 2 + Printlog "- Allign text left" + printlog "click button 'Left'" + Linksbuendig.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Allign text centered" - '/// click button 'Centered' ///' - Zentriert.Click - sleep 2 + Printlog "- Allign text centered" + printlog "click button 'Centered'" + Zentriert.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- align text to right" - '/// click button 'Right' ///' - Rechtsbuendig.Click - sleep 2 + Printlog "- align text to right" + printlog "click button 'Right'" + Rechtsbuendig.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Justified" - '/// click button 'Justified' ///' - Blocksatz.Click - sleep 2 + Printlog "- Justified" + printlog "click button 'Justified'" + Blocksatz.Click + sleep 2 Kontext "TextObjectbar" - if TextObjectbar.isEnabled <> TRUE then - warnlog "Couldn't access TextObjectbar - known bug with bars - FHA" - ViewToolbarsTextFormatting - end if - WaitSlot (2000) 'sleep 2 - Printlog "- Raising Font spacing" - '/// click button 'Increase Spacing' ///' - + if TextObjectbar.isEnabled <> TRUE then + warnlog "Couldn't access TextObjectbar - known bug with bars - FHA" + ViewToolbarsTextFormatting + end if + WaitSlot (2000) 'sleep 2 + Printlog "- Raising Font spacing" + printlog "click button 'Increase Spacing'" kontext "TextObjectbar" - sleep 1 - '/// Check if the bar is there. If not - wait for maximum 10 seconds) - iWaitIndex = 0 - do while NOT TextObjectbar.isEnabled AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if NOT TextObjectbar.isEnabled AND iWaitIndex = 10 then - warnlog "Dialogue TextObjectbar didnt work. Ending testcase." - Call hCloseDocument - goto endsub - end if - '/// Activate the Font spacing-buttons ///' - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemCheck (13) - sleep 2 - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemCheck (14) - sleep 2 - ZeilenabstandErhoehen.Click - sleep 2 - + sleep 1 + printlog "Check if the bar is there. If not - wait for maximum 10 seconds)" + iWaitIndex = 0 + do while NOT TextObjectbar.isEnabled AND iWaitIndex < 10 + sleep(1) + iWaitIndex = iWaitIndex + 1 + loop + if NOT TextObjectbar.isEnabled AND iWaitIndex = 10 then + warnlog "Dialogue TextObjectbar didnt work. Ending testcase." + Call hCloseDocument + goto endsub + end if + printlog "Activate the Font spacing-buttons" + TextObjectbar.OpenContextMenu + sleep 2 + hMenuselectNr (1) + sleep 2 + hMenuItemCheck (13) + sleep 2 + TextObjectbar.OpenContextMenu + sleep 2 + hMenuselectNr (1) + sleep 2 + hMenuItemCheck (14) + sleep 2 + ZeilenabstandErhoehen.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Decrease Spacing" - '/// click button 'Decrease Spacing' ///' - ZeilenabstandVerringern.Click - sleep 2 + Printlog "- Decrease Spacing" + printlog "click button 'Decrease Spacing'" + ZeilenabstandVerringern.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Numbering and Bullets" - sleep 2 - '/// click button 'Bullets On/Off' ///' - BulletsOnOff.Click - sleep 2 - '/// click button 'Bullets On/Off' ///' - BulletsOnOff.Click - '----------------------------------------------------------------------- + Printlog "- Numbering and Bullets" + sleep 2 + printlog "click button 'Bullets On/Off'" + BulletsOnOff.Click + sleep 2 + printlog "click button 'Bullets On/Off'" + BulletsOnOff.Click + '----------------------------------------------------------------------- Kontext "TextObjectBar" - Printlog "- Increase Font /Reduce Font" - sleep 2 - printlog "- Click on Increase Font" - IncreaseFont.Click - sleep 2 - printlog "- Click on Reduce Font" - ReduceFont.Click - '----------------------------------------------------------------------- + Printlog "- Increase Font /Reduce Font" + sleep 2 + printlog "- Click on Increase Font" + IncreaseFont.Click + sleep 2 + printlog "- Click on Reduce Font" + ReduceFont.Click + '----------------------------------------------------------------------- Kontext "TextObjectbar" - Printlog "- Text direction from left to right" - sleep 2 - Printlog "- click button 'Text direction from left to right'" - try - TextdirectionLeftToRight.Click - printlog "hor does work :-)" - if (gAsianSup = FALSE) then - warnlog " this doesn't have to work if asian lang support is disabled :-)" - end if - catch - if (gAsianSup = TRUE) then - warnlog "hor does NOT work :-(" - end if - endcatch - Printlog "- click button 'Text direction from top to bottom" - try - TextdirectionTopToBottom.Click - printlog "ver does work :-)" - if (gAsianSup = FALSE) then - warnlog " this doesnt have to work if asian lang support is disabled :-)" - end if - catch - if (gAsianSup = TRUE) then - warnlog "ver does NOT work :-( , AsianLanguage support is enabled !" - end if - endcatch + Printlog "- Text direction from left to right" + sleep 2 + Printlog "- click button 'Text direction from left to right'" + try + TextdirectionLeftToRight.Click + printlog "hor does work :-)" + if (gAsianSup = FALSE) then + warnlog " this doesn't have to work if asian lang support is disabled :-)" + end if + catch + if (gAsianSup = TRUE) then + warnlog "hor does NOT work :-(" + end if + endcatch + Printlog "- click button 'Text direction from top to bottom" + try + TextdirectionTopToBottom.Click + printlog "ver does work :-)" + if (gAsianSup = FALSE) then + warnlog " this doesnt have to work if asian lang support is disabled :-)" + end if + catch + if (gAsianSup = TRUE) then + warnlog "ver does NOT work :-( , AsianLanguage support is enabled !" + end if + endcatch Printlog "- open character dialog" Kontext "TextObjectbar" - sleep 2 - '/// click button 'Character' ///' - Zeichenformat.Click - sleep 2 - Kontext - Active.SetPage TabFont - Kontext "TabFont" - sleep 2 - if TabFont.Exists Then - '/// close dialog 'character' ///' - TabFont.Cancel - Printlog "- Tabfont exists" - else - Warnlog "- No dialog exists " - end if + sleep 2 + printlog "click button 'Character'" + Zeichenformat.Click + sleep 2 + Kontext + Active.SetPage TabFont + Kontext "TabFont" + sleep 2 + if TabFont.Exists Then + printlog "close dialog 'character'" + TabFont.Cancel + Printlog "- Tabfont exists" + else + Warnlog "- No dialog exists " + end if Kontext "TextObjectbar" - sleep 2 - Printlog "- call properties for paragraph using text object toolbar" - '/// click button 'Paragraph' ///' - Absatzformat.Click - sleep 2 - Kontext - Active.SetPage TabTabulator - Kontext "TabTabulator" - if TabTabulator.Exists Then - Printlog "- TabTabulator exists" - '/// close dialog 'Paragraph' ///' - TabTabulator.Cancel - else - Warnlog "- TabTabulator does not exist" - end if + sleep 2 + Printlog "- call properties for paragraph using text object toolbar" + printlog "click button 'Paragraph'" + Absatzformat.Click + sleep 2 + Kontext + Active.SetPage TabTabulator + Kontext "TabTabulator" + if TabTabulator.Exists Then + Printlog "- TabTabulator exists" + printlog "close dialog 'Paragraph'" + TabTabulator.Cancel + else + Warnlog "- TabTabulator does not exist" + end if if (UCase(gApplication)) = "IMPRESS" then ' IMPRESS only - '/// if the Application is Impress: ///' + printlog "if the Application is Impress:" Kontext "TextObjectbar" - '/// click button 'Numbering Symbols' ///' - OutlineBullet.Click - kontext - if active.exists (5) then - messagebox.SetPage TabOptionenNumerierung - kontext "TabOptionenNumerierung" - '/// cancel dialog 'Numbering/Bullets' ///' - if (TabOptionenNumerierung.exists (5) ) then - Printlog "Numbering/Bullets window came up :-)" - sleep 2 - TabOptionenNumerierung.cancel - else - warnlog "no Numbering/Bullets window came up :-(" - end if + printlog "click button 'Numbering Symbols'" + OutlineBullet.Click + kontext + if active.exists (5) then + messagebox.SetPage TabOptionenNumerierung + kontext "TabOptionenNumerierung" + printlog "cancel dialog 'Numbering/Bullets'" + if (TabOptionenNumerierung.exists (5) ) then + Printlog "Numbering/Bullets window came up :-)" sleep 2 - else - warnlog "no Numbering/Bullets window came up :-( 2" - end if + TabOptionenNumerierung.cancel + else + warnlog "no Numbering/Bullets window came up :-(" + end if + sleep 2 + else + warnlog "no Numbering/Bullets window came up :-( 2" + end if - Printlog "-change order of outline points" - sleep 3 - '/// View->Master View->Outline View ///' - ViewWorkspaceOutlineView - WaitSlot (2000) 'sleep (3) - Kontext "DocumentImpressOutlineView" - sleep 1 - '/// type something ///' - DocumentImpressOutlineView.TypeKeys "Bla bla bla <RETURN><TAB>bla bla bla bla bla <MOD1 SHIFT LEFT>" - sleep 1 - Kontext "TextObjectbar" - '/// click button 'Promote' ///' - HierachieRunter.Click - sleep 1 - Printlog "- Move back down" - '/// click button 'Denote' ///' - HierachieHoch.Click - sleep 1 - '/// click button 'Denote' ///' - HierachieHoch.Click - sleep 1 - Printlog "- Move paragraph up" - '/// click button 'Move Up', twice to get two slides ///' - AbsatzHoch.Click - sleep 1 - Printlog "- move paragraph back down and switch to drawing view" - '/// click button 'Move Down' ///' - AbsatzRunter.Click - sleep 1 + Printlog "-change order of outline points" + sleep 3 + printlog "View->Master View->Outline View" + ViewWorkspaceOutlineView + WaitSlot (2000) 'sleep (3) + Kontext "DocumentImpressOutlineView" + sleep 1 + printlog "type something" + DocumentImpressOutlineView.TypeKeys "Bla bla bla <RETURN><TAB>bla bla bla bla bla <MOD1 SHIFT LEFT>" + sleep 1 + Kontext "TextObjectbar" + printlog "click button 'Promote'" + HierachieRunter.Click + sleep 1 + Printlog "- Move back down" + printlog "click button 'Denote'" + HierachieHoch.Click + sleep 1 + printlog "click button 'Denote'" + HierachieHoch.Click + sleep 1 + Printlog "- Move paragraph up" + printlog "click button 'Move Up', twice to get two slides" + AbsatzHoch.Click + sleep 1 + Printlog "- move paragraph back down and switch to drawing view" + printlog "click button 'Move Down'" + AbsatzRunter.Click + sleep 1 Kontext "Vorschau" if Vorschau.Exists then @@ -313,80 +316,79 @@ testcase tiTextToolbar else ' DRAW only Kontext "TextObjectbar" - Printlog "- Double" - '/// click button 'Double' ///' - LineSpacing2.Click - sleep 2 + Printlog "- Double" + printlog "click button 'Double'" + LineSpacing2.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- 1.5 lines" - '/// click button '1.5 lines' ///' - LineSpacing15.Click - sleep 2 + Printlog "- 1.5 lines" + printlog "click button '1.5 lines'" + LineSpacing15.Click + sleep 2 Kontext "TextObjectbar" - Printlog "- Single" - '/// click button 'Single' ///' - LineSpacing1.Click - sleep 2 + Printlog "- Single" + printlog "click button 'Single'" + LineSpacing1.Click + sleep 2 end if - '/// Check if the bar is there. If not - wait for maximum 10 seconds) + printlog "Check if the bar is there. If not - wait for maximum 10 seconds)" iWaitIndex = 0 Kontext "TextObjectbar" - do while TextObjectbar.isEnabled = FALSE AND iWaitIndex < 10 - sleep(1) - iWaitIndex = iWaitIndex + 1 - loop - if TextObjectbar.isEnabled = FALSE AND iWaitIndex = 10 then - warnlog "Dialogue TextObjectbar didnt work. Ending testcase." - Call hCloseDocument - goto endsub - end if - '/// Reset the original value of the Font spacing-buttons ///' - sleep 2 + do while TextObjectbar.isEnabled = FALSE AND iWaitIndex < 10 + sleep(1) + iWaitIndex = iWaitIndex + 1 + loop + if TextObjectbar.isEnabled = FALSE AND iWaitIndex = 10 then + warnlog "Dialogue TextObjectbar didnt work. Ending testcase." + Call hCloseDocument + goto endsub + end if + printlog "Reset the original value of the Font spacing-buttons" + sleep 2 Kontext "TextObjectbar" - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (13) - sleep 2 - TextObjectbar.OpenContextMenu - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (14) - sleep 2 - '/// Close the TextFormatting Toolbar ///' - ViewToolbarsTextFormatting - WaitSlot (2000) 'sleep 1 - '/// Clear the document from content ///' + TextObjectbar.OpenContextMenu + sleep 2 + hMenuselectNr (1) + sleep 2 + hMenuItemUnCheck (13) + sleep 2 + TextObjectbar.OpenContextMenu + sleep 2 + hMenuselectNr (1) + sleep 2 + hMenuItemUnCheck (14) + sleep 2 + printlog "Close the TextFormatting Toolbar" + ViewToolbarsTextFormatting + WaitSlot (2000) 'sleep 1 + printlog "Clear the document from content" if (gApplication = "IMPRESS") then Kontext "DocumentImpressOutlineView" - DocumentImpressOutlineView.TypeKeys "<ESCAPE>" - EditSelectAll - DocumentImpressOutlineView.TypeKeys "<DELETE>" - sleep (3) - ViewWorkspaceDrawingView + DocumentImpressOutlineView.TypeKeys "<ESCAPE>" + EditSelectAll + DocumentImpressOutlineView.TypeKeys "<DELETE>" + sleep (3) + ViewWorkspaceDrawingView Kontext "DocumentImpress" - WaitSlot (2000) 'sleep 1 - DocumentImpress.TypeKeys "<ESCAPE>" - EditSelectAll - DocumentImpress.TypeKeys "<DELETE>" + WaitSlot (2000) 'sleep 1 + DocumentImpress.TypeKeys "<ESCAPE>" + EditSelectAll + DocumentImpress.TypeKeys "<DELETE>" else Kontext "DocumentDraw" - DocumentDraw.TypeKeys "<ESCAPE>" - EditSelectAll - DocumentDraw.TypeKeys "<DELETE>" + DocumentDraw.TypeKeys "<ESCAPE>" + EditSelectAll + DocumentDraw.TypeKeys "<DELETE>" end if Printlog "Test ended." - - '/// close application ///' + printlog "close application" Call hCloseDocument -endcase +endcase 'tiTextToolbar -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' +'-------------------------------------------------------------------------------' testcase tiDrawObjectBar Dim a as string @@ -394,764 +396,755 @@ testcase tiDrawObjectBar Dim i as integer Dim x as integer - '/// open application ///' + printlog "open application" Call hNewDocument - - '/// create rectangle to test the part for draw objects ///' + printlog "create rectangle to test the part for draw objects" Call hRechteckErstellen (20,20,70,70) sleep 1 - '--------------------------- format line ------------------------ Printlog "- call format line using graphic object toolbar" Kontext "DrawingObjectbar" - '/// Check if the Graphic-Toolbar is there. Which it should be. ///' - '/// If it's not - then we call it from the View-Toolbars ///' - if DrawingObjectbar.Exists = FALSE then - ViewToolbarsGraphic - end if - if DrawingObjectbar.Exists = FALSE then - warnlog "Drawing-Objectbar should have been opened, but wasnt" - ViewToolbarsGraphic - end if - - sleep 3 - '/// click button 'line' on 'Object Toolbar' ///' - Linie.Click - sleep 2 - Kontext - Active.SetPage TabLinie - Kontext "TabLinie" - if TabLinie.Exists Then - '/// cancel dialog 'line' ///' - TabLinie.Cancel - Printlog "- TabLinie exists " - else - Warnlog "- TabLinie does not exist" - end if + printlog "Check if the Graphic-Toolbar is there. Which it should be." + printlog "If it's not - then we call it from the View-Toolbars" + if DrawingObjectbar.Exists = FALSE then + ViewToolbarsGraphic + end if + if DrawingObjectbar.Exists = FALSE then + warnlog "Drawing-Objectbar should have been opened, but wasnt" + ViewToolbarsGraphic + end if + sleep 3 + printlog "click button 'line' on 'Object Toolbar'" + Linie.Click + sleep 2 + Kontext + Active.SetPage TabLinie + Kontext "TabLinie" + if TabLinie.Exists Then + printlog "cancel dialog 'line'" + TabLinie.Cancel + Printlog "- TabLinie exists " + else + Warnlog "- TabLinie does not exist" + end if '--------------------------- Linienendenstil -------------------- Printlog "- Style of line ends" Kontext "DrawingObjectbar" - sleep 1 - '/// click button 'Arrow Style' and tearoff the box ///' - Linienendenstil.TearOff - sleep 2 - Kontext "Linienenden" - if Linienenden.Exists Then - Printlog "- dialog exists" - '/// close toolbox 'arrowheads' ///' - Linienenden.Close - else - Warnlog "- Arrowheads does not exist" - end if + sleep 1 + printlog "click button 'Arrow Style' and tearoff the box" + Linienendenstil.TearOff + sleep 2 + Kontext "Linienenden" + if Linienenden.Exists Then + Printlog "- dialog exists" + printlog "close toolbox 'arrowheads'" + Linienenden.Close + else + Warnlog "- Arrowheads does not exist" + end if '--------------------------- Linienstil ------------------------- Printlog "- choose style of lines using graphic object toolbar" Kontext "DrawingObjectbar" - sleep 1 - '/// select 2nd entry from the top in listbox 'Line Style' ///' - Linienstil.Select 2 - Printlog Linienstil.GetSelText + " chosen" - '/// select last entry in listbox 'Line Style' ///' - Linienstil.Select Linienstil.GetItemCount - Printlog Linienstil.GetSelText + " chosen" - sleep 2 + sleep 1 + printlog "select 2nd entry from the top in listbox 'Line Style'" + Linienstil.Select 2 + Printlog Linienstil.GetSelText + " chosen" + printlog "select last entry in listbox 'Line Style'" + Linienstil.Select Linienstil.GetItemCount + Printlog Linienstil.GetSelText + " chosen" + sleep 2 '--------------------------- Linienbreite------------------------ Printlog "- check style of lines using graphic object toolbar" Kontext "DrawingObjectbar" - sleep 1 - a = Linienbreite.GetText - SetClipboard a - sleep 1 - '/// set 'Line Width' to "0,5" ///' - Linienbreite.SetText "0,5" - sleep 2 - '/// check if the value is accepted or not ///' - if Linienbreite.GetText = a Then - Warnlog "- changes in edit field did not happen; is: '"+Linienbreite.GetText+"', should be : '"+"0,5"+"'" - else - Printlog "- Width of lines changed" - end if + sleep 1 + a = Linienbreite.GetText + SetClipboard a + sleep 1 + printlog "set 'Line Width' to 0,5" + Linienbreite.SetText "0,5" + sleep 2 + printlog "check if the value is accepted or not" + if Linienbreite.GetText = a Then + Warnlog "- changes in edit field did not happen; is: '"+Linienbreite.GetText+"', should be : '"+"0,5"+"'" + else + Printlog "- Width of lines changed" + end if '--------------------------- Linienfarbe ------------------------ Printlog "- change line color" Kontext "DrawingObjectbar" - sleep 1 - Zaehler = Linienfarbe.GetItemCount - randomize - i = Int(Zaehler*Rnd+1) - '/// select some entry in the listbox 'Line Color' ///' - Linienfarbe.Select i - Printlog Linienfarbe.GetSelText + " chosen" + sleep 1 + Zaehler = Linienfarbe.GetItemCount + randomize + i = Int(Zaehler*Rnd+1) + printlog "select some entry in the listbox 'Line Color'" + Linienfarbe.Select i + Printlog Linienfarbe.GetSelText + " chosen" '--------------------------- Flaechenformatierung --------------- Printlog "- Call Format area using graphic object toolbar" Kontext "DrawingObjectbar" - sleep 1 - '/// click button 'Area' ///' - try - Flaeche.Click - catch - printlog "clicking on area took ages :-(" - endcatch - sleep 5 - Kontext - Active.SetPage TabArea - Kontext "TabArea" - if TabArea.Exists Then - Printlog "- TabArea exists " - '/// cancel dialog 'Area' ///' - TabArea.Cancel - else - Warnlog "- TabArea does not exist" - end if + sleep 1 + printlog "click button 'Area'" + try + Flaeche.Click + catch + printlog "clicking on area took ages :-(" + endcatch + sleep 5 + Kontext + Active.SetPage TabArea + Kontext "TabArea" + if TabArea.Exists Then + Printlog "- TabArea exists " + printlog "cancel dialog 'Area'" + TabArea.Cancel + else + Warnlog "- TabArea does not exist" + end if '--- sleep 1 Kontext "DrawingObjectbar" + sleep 1 + x = AreaStyle.GetItemCount + i = 1 + for i = i to x + AreaStyle.Select i + Printlog "Area Style: (" + i + "/" + x + ") - " + AreaStyle.GetSelText sleep 1 - x = AreaStyle.GetItemCount - i = 1 - for i = i to x - AreaStyle.Select i - Printlog "Area Style: (" + i + "/" + x + ") - " + AreaStyle.GetSelText - sleep 1 - '/// for every item in the listbox 'Area Style' select the last item in the listbox 'Area Filling' ///' - if AreaStyle.GetSelIndex > 1 then - Printlog " Area Filling " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetItemCount - if (i <> 1) AND (AreaFilling.GetItemCount <> 0) then - if (AreaFilling.GetSelIndex = 0) AND (AreaFilling.GetItemCount > 0) then - printlog "default item is 0 => means nothing; NO BUG! 100909" - end if - AreaFilling.Select (AreaFilling.GetItemCount) - Printlog " Selected: " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetSelText + printlog "for every item in the listbox 'Area Style' select the last item in the listbox 'Area Filling'" + if AreaStyle.GetSelIndex > 1 then + Printlog " Area Filling " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetItemCount + if (i <> 1) AND (AreaFilling.GetItemCount <> 0) then + if (AreaFilling.GetSelIndex = 0) AND (AreaFilling.GetItemCount > 0) then + printlog "default item is 0 => means nothing; NO BUG! 100909" end if + AreaFilling.Select (AreaFilling.GetItemCount) + Printlog " Selected: " + AreaFilling.GetSelIndex + " - " + AreaFilling.GetSelText end if - next i + end if + next i '---------------------------- Schatten -------------------------- Printlog "- Assign shadow using graphic object toolbar" Kontext "DrawingObjectbar" - sleep 1 - '/// click button 'Shadow' ///' - Schatten.Click - sleep 1 - Printlog "- shadow assigned" + sleep 1 + printlog "click button 'Shadow'" + Schatten.Click + sleep 1 + Printlog "- shadow assigned" '---------------------------- Praesentationsflyer --------------- - '/// if Application is Impress: ///' - if (UCase(gApplication)) = "IMPRESS" then ' IMPRESS only - Printlog "- Call presentation flyer" - Kontext "CommonTaskbar" ' first check , if presentation flyer is up! if not -> make it up :-) - '///+ if 'Presentation Box' is not visible, click button 'Presentation Box on/off' ///' - if CommonTaskbar.Exists Then - printlog "- flyer is already visible :-)" - else - printlog "- flyer wasn't visible :-( -will be now!" - Kontext "DrawingObjectbar" - sleep 1 - ViewToolbarsPresentation ' put it up again! - end if - end if - '/// Make sure the Graphics-Toolbar is visible ///' - if ((UCase(gApplication)) = "IMPRESS") then ' IMPRESS only + printlog "if Application is Impress:" + if (UCase(gApplication)) = "IMPRESS" then ' IMPRESS only + Printlog "- Call presentation flyer" + Kontext "CommonTaskbar" ' first check , if presentation flyer is up! if not -> make it up :-) + printlog "if 'Presentation Box' is not visible, click button 'Presentation Box on/off'" + if CommonTaskbar.Exists Then + printlog "- flyer is already visible :-)" + else + printlog "- flyer wasn't visible :-( -will be now!" Kontext "DrawingObjectbar" - if DrawingObjectbar.isVisible = FALSE then - ViewToolbarsGraphic - end if + sleep 1 + ViewToolbarsPresentation ' put it up again! + end if + end if + printlog "Make sure the Graphics-Toolbar is visible" + if ((UCase(gApplication)) = "IMPRESS") then ' IMPRESS only + Kontext "DrawingObjectbar" + if DrawingObjectbar.isVisible = FALSE then + ViewToolbarsGraphic end if - '/// close application ///' + end if + printlog "close application" Call hCloseDocument -endcase +endcase 'tiDrawObjectBar -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' +'------------------------------------------------------------------------------' testcase tiGraphicsObjectBar dim i as integer - '/// open application ///' + printlog "open application" Call hNewDocument - '/// insert a graphic "global\input\graf_inp\desp.bmp" ///' + printlog "insert a graphic global\input\graf_inp\desp.bmp" hGrafikeinfuegen ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") + sleep 1 + Kontext "GraphicObjectbar" + if GraphicObjectbar.Exists = FALSE then + ViewToolbarsPicture + end if + sleep 1 + printlog "click button 'Filter' and tearoff the box in the Objectbar" + Filter.TearOff + sleep 1 + Kontext "GraphicFilterBar" + sleep 1 + Printlog "invert" + printlog "click button 'Invert' in window 'Filters'" + Invert.Click + sleep 3 + Printlog "smooth" + printlog "click button 'Smooth' in window 'Filters'" + Smooth.Click + sleep 3 + Printlog "sharpen" + printlog "click button 'Sharpen' in window 'Filters'" + Sharpen.Click + sleep 3 + Printlog "remove noise" + printlog "click button 'RemoveNoise' in window 'Filters'" + Remove.Click + sleep 3 + Printlog "solarization" + printlog "click button 'Solarization' in window 'Filters'" + Solarization.Click + sleep 3 + Kontext "Solarization" + if Solarization.exists (5) then sleep 1 - Kontext "GraphicObjectbar" - if GraphicObjectbar.Exists = FALSE then - ViewToolbarsPicture - end if - sleep 1 - '/// click button 'Filter' and tearoff the box in the Objectbar///' - Filter.TearOff - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "invert" - '/// click button 'Invert' in window 'Filters' ///' - Invert.Click - sleep 3 - Printlog "smooth" - '/// click button 'Smooth' in window 'Filters' ///' - Smooth.Click - sleep 3 - Printlog "sharpen" - '/// click button 'Sharpen' in window 'Filters' ///' - Sharpen.Click - sleep 3 - Printlog "remove noise" - '/// click button 'RemoveNoise' in window 'Filters' ///' - Remove.Click - sleep 3 - Printlog "solarization" - '/// click button 'Solarization' in window 'Filters' ///' - Solarization.Click - sleep 3 - Kontext "Solarization" - if Solarization.exists (5) then - sleep 1 - Call Dialogtest ( Solarization ) - sleep 1 - '/// press 'more' and 'less' in field 'Trashold Value' on dialog 'Solarization' ///' - Value.More - Value.Less - '/// check checkbox 'Invert' on dialog 'Solarization' ///' - Invert.Check - '/// close dialog 'Solarization' with OK ///' - Solarization.OK - else - warnlog "solarization didn't came up :-(" - end if - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "aging" - '/// click button 'Aging' in window 'Filters' ///' - Aging.Click - Kontext "Aging" - sleep 1 - Call Dialogtest ( Aging ) - '/// press 'more' and 'less' in field 'Aging degree' on dialog 'Aging' ///' - AgingDegree.More - AgingDegree.Less - sleep 1 - '/// close dialog 'Aging' with OK ///' - Aging.OK - sleep 1 - Kontext "GraphicFilterBar" - sleep 1 - Printlog "poster" - '/// click button 'Posterize' in window 'Filters' ///' - Posterize.Click - sleep 1 - Kontext "Posterize" - sleep 1 - Call Dialogtest ( Posterize ) - '/// press 'more' and 'less' in field 'Aging degree' on dialog 'Posterize' ///' - PosterColors.More - PosterColors.Less - sleep 1 - '/// close dialog 'Posterize' with OK ///' - Posterize.OK - sleep 2 - kontext "GraphicFilterBar" - sleep 1 - Printlog "pop" - '/// click button 'PopArt' in window 'Filters' ///' - Art.Click - sleep 3 - Printlog "charcoal" - '/// click button 'CharcoalSketch' in window 'Filters' ///' - CharcoalSketch.Click - sleep 3 - Printlog "relief" - '/// click button 'Relief' in window 'Filters' ///' - Relief.Click - Kontext "Relief" - sleep 1 - Call Dialogtest ( Relief ) - LightSource.TypeKeys "<left><up>" - '/// close dialog 'Relief' with OK ///' - Relief.OK - sleep 3 - Kontext "GraphicFilterBar" - Printlog "mos" - '/// click button 'Mosaic' in window 'Filters' ///' - Mosaic.Click - sleep 1 - Kontext "Mosaic" - sleep 1 - Call Dialogtest ( Mosaic ) - '/// press 'more' and 'less' in field 'Width' on dialog 'Mosaic' ///' - Width.More - Width.Less - '/// press 'more' and 'less' in field 'Height' on dialog 'Mosaic' ///' - Height.More - Height.Less - '/// check checkbox 'Enhance Edges' on dialog 'Mosaic' ///' - EnhanceEdges.Check - '/// close dialog 'Mosaic' with OK ///' - Mosaic.OK - sleep 3 - Kontext "GraphicFilterBar" - '/// close dialog 'Filters' ///' - GraphicFilterBar.Close - - Kontext "GraphicObjectbar" - if GraphicObjectbar.Exists = FALSE then ViewToolbarsPicture - sleep 1 - '/// select every entry in the listbox 'Graphics mode' ///' - for i = 1 to Grafikmodus.GetItemCount - Grafikmodus.select i - sleep 1 - next i - - '/// Click on the icon for 'ColorSettings' to open the colorbar ///' - ColorSettings.Click - Kontext "ColorBar" - sleep (2) - - '/// press 'more' and 'less' in field 'Red' on colorbar ///' - try - Rotanteil.More - Rotanteil.Less - catch - warnlog "not working from testtool redvalue "+ rotanteil.GetRT - endcatch - '/// press 'more' and 'less' in field 'Green' on colorbar ///' - try - Gruenanteil.More - Gruenanteil.Less - catch - warnlog "not working from testtool Greenvalue." - endcatch - '/// press 'more' and 'less' in field 'Blue' on colorbar ///' - try - Blauanteil.More - Blauanteil.Less - catch - warnlog "not working from testtool Bluevalue." - endcatch - '/// press 'more' and 'less' in field 'Brightness' on colorbar ///' - try - Helligkeit.More - Helligkeit.Less - catch - warnlog "not working from testtool Brightness." - endcatch - '/// press 'more' and 'less' in field 'Contrast' on colorbar ///' - try - Kontrast.More - Kontrast.Less - catch - warnlog "not working from testtool Contrast." - endcatch - '/// press 'more' and 'less' in field 'Gamma' on colorbar ///' - try - Gamma.More - Gamma.Less - catch - warnlog "not working from testtool Gamma." - endcatch - - ColorBar.Close - Kontext "GraphicObjectbar" - - '/// press 'more' and 'less' in field 'Transparency' on objectbar ///' - try - Transparenz.More - Transparenz.Less - catch - warnlog "Not working from testtool Transparency." - endcatch - - '/// press button 'Crop' on objectbar ///' - Crop.click - '/// Opening Dialog via Slot - FormatCropPicture - - kontext "TabZuschneiden" - '/// check radiobutton 'Keep scale' on dialog 'Crop' ///' - GroesseBeibehalten.Check - '/// check radiobutton 'Keep Image Size' on dialog 'Crop' ///' - MassstabBeibehalten.Check - '/// press 'more' and 'less' in field 'Left' in section 'Crop' on dialog 'Crop' ///' - Links.More - Links.Less - '/// press 'more' and 'less' in field 'Right' in section 'Crop' on dialog 'Crop' ///' - Rechts.More - Rechts.Less - '/// press 'more' and 'less' in field 'Top' in section 'Crop' on dialog 'Crop' ///' - Oben.More - Oben.Less - '/// press 'more' and 'less' in field 'Bottom' in section 'Crop' on dialog 'Crop' ///' - Unten.More - Unten.Less - '/// press 'more' and 'less' in field 'Width' in section 'Scale' on dialog 'Crop' ///' - MassstabBreite.More - MassstabBreite.Less - '/// press 'more' and 'less' in field 'Height' in section 'Scale' on dialog 'Crop' ///' - MassstabHoehe.More - MassstabHoehe.Less - '/// press 'more' and 'less' in field 'Width' in section 'Image size' on dialog 'Crop' ///' - GroesseBreite.More - GroesseBreite.Less - '/// press 'more' and 'less' in field 'Height' in section 'Image size' on dialog 'Crop' ///' - GroesseHoehe.More - GroesseHoehe.Less - '/// click button 'Original Size' on dialog 'Crop' ///' - Originalgroesse.Click - '/// cancel dialog 'Crop' ///' - TabZuschneiden.Cancel + Call Dialogtest ( Solarization ) + sleep 1 + printlog " press 'more' and 'less' in field 'Trashold Value' on dialog 'Solarization'" + Value.More + Value.Less + printlog "check checkbox 'Invert' on dialog 'Solarization'" + Invert.Check + printlog "close dialog 'Solarization' with OK" + Solarization.OK + else + warnlog "solarization didn't came up :-(" + end if + sleep 1 + Kontext "GraphicFilterBar" + sleep 1 + Printlog "aging" + printlog "click button 'Aging' in window 'Filters'" + Aging.Click + Kontext "Aging" + sleep 1 + Call Dialogtest ( Aging ) + printlog " press 'more' and 'less' in field 'Aging degree' on dialog 'Aging'" + AgingDegree.More + AgingDegree.Less + sleep 1 + printlog "close dialog 'Aging' with OK" + Aging.OK + sleep 1 + Kontext "GraphicFilterBar" + sleep 1 + Printlog "poster" + printlog "click button 'Posterize' in window 'Filters'" + Posterize.Click + sleep 1 + Kontext "Posterize" + sleep 1 + Call Dialogtest ( Posterize ) + printlog " press 'more' and 'less' in field 'Aging degree' on dialog 'Posterize'" + PosterColors.More + PosterColors.Less + sleep 1 + printlog "close dialog 'Posterize' with OK" + Posterize.OK + sleep 2 + kontext "GraphicFilterBar" + sleep 1 + Printlog "pop" + printlog "click button 'PopArt' in window 'Filters'" + Art.Click + sleep 3 + Printlog "charcoal" + printlog "click button 'CharcoalSketch' in window 'Filters'" + CharcoalSketch.Click + sleep 3 + Printlog "relief" + printlog "click button 'Relief' in window 'Filters'" + Relief.Click + Kontext "Relief" + sleep 1 + Call Dialogtest ( Relief ) + LightSource.TypeKeys "<left><up>" + printlog "close dialog 'Relief' with OK" + Relief.OK + sleep 3 + Kontext "GraphicFilterBar" + Printlog "mos" + printlog "click button 'Mosaic' in window 'Filters'" + Mosaic.Click + sleep 1 + Kontext "Mosaic" + sleep 1 + Call Dialogtest ( Mosaic ) + printlog " press 'more' and 'less' in field 'Width' on dialog 'Mosaic'" + Width.More + Width.Less + printlog " press 'more' and 'less' in field 'Height' on dialog 'Mosaic'" + Height.More + Height.Less + printlog " check checkbox 'Enhance Edges' on dialog 'Mosaic'" + EnhanceEdges.Check + printlog "close dialog 'Mosaic' with OK" + Mosaic.OK + sleep 3 + Kontext "GraphicFilterBar" + printlog "close dialog 'Filters'" + GraphicFilterBar.Close + + Kontext "GraphicObjectbar" + if GraphicObjectbar.Exists = FALSE then ViewToolbarsPicture + sleep 1 + printlog "select every entry in the listbox 'Graphics mode'" + for i = 1 to Grafikmodus.GetItemCount + Grafikmodus.select i + sleep 1 + next i - '/// close application ///' + printlog " Click on the icon for 'ColorSettings' to open the colorbar" + ColorSettings.Click + Kontext "ColorBar" + sleep (2) + printlog " press 'more' and 'less' in field 'Red' on colorbar" + try + Rotanteil.More + Rotanteil.Less + catch + warnlog "not working from testtool redvalue "+ rotanteil.GetRT + endcatch + printlog " press 'more' and 'less' in field 'Green' on colorbar" + try + Gruenanteil.More + Gruenanteil.Less + catch + warnlog "not working from testtool Greenvalue." + endcatch + printlog " press 'more' and 'less' in field 'Blue' on colorbar" + try + Blauanteil.More + Blauanteil.Less + catch + warnlog "not working from testtool Bluevalue." + endcatch + printlog " press 'more' and 'less' in field 'Brightness' on colorbar" + try + Helligkeit.More + Helligkeit.Less + catch + warnlog "not working from testtool Brightness." + endcatch + printlog " press 'more' and 'less' in field 'Contrast' on colorbar" + try + Kontrast.More + Kontrast.Less + catch + warnlog "not working from testtool Contrast." + endcatch + printlog " press 'more' and 'less' in field 'Gamma' on colorbar" + try + Gamma.More + Gamma.Less + catch + warnlog "not working from testtool Gamma." + endcatch + + ColorBar.Close + Kontext "GraphicObjectbar" + + printlog " press 'more' and 'less' in field 'Transparency' on objectbar" + try + Transparenz.More + Transparenz.Less + catch + warnlog "Not working from testtool Transparency." + endcatch + + printlog "press button 'Crop' on objectbar" + Crop.click + printlog "Opening Dialog via Slot" + FormatCropPicture + + kontext "TabZuschneiden" + printlog " check radiobutton 'Keep scale' on dialog 'Crop'" + GroesseBeibehalten.Check + printlog " check radiobutton 'Keep Image Size' on dialog 'Crop'" + MassstabBeibehalten.Check + printlog " press 'more' and 'less' in field 'Left' in section 'Crop' on dialog 'Crop'" + Links.More + Links.Less + printlog " press 'more' and 'less' in field 'Right' in section 'Crop' on dialog 'Crop'" + Rechts.More + Rechts.Less + printlog " press 'more' and 'less' in field 'Top' in section 'Crop' on dialog 'Crop'" + Oben.More + Oben.Less + printlog " press 'more' and 'less' in field 'Bottom' in section 'Crop' on dialog 'Crop'" + Unten.More + Unten.Less + printlog " press 'more' and 'less' in field 'Width' in section 'Scale' on dialog 'Crop'" + MassstabBreite.More + MassstabBreite.Less + printlog " press 'more' and 'less' in field 'Height' in section 'Scale' on dialog 'Crop'" + MassstabHoehe.More + MassstabHoehe.Less + printlog " press 'more' and 'less' in field 'Width' in section 'Image size' on dialog 'Crop'" + GroesseBreite.More + GroesseBreite.Less + printlog " press 'more' and 'less' in field 'Height' in section 'Image size' on dialog 'Crop'" + GroesseHoehe.More + GroesseHoehe.Less + printlog " click button 'Original Size' on dialog 'Crop'" + Originalgroesse.Click + printlog "cancel dialog 'Crop'" + TabZuschneiden.Cancel + + printlog "close application" Call hCloseDocument -endcase +endcase 'tiGraphicsObjectBar -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' +'-------------------------------------------------------------------------------' testcase tiGluepointToolbar - '/// open application ///' + printlog "open application" Call hNewDocument - '/// create 2 rectangles ///' + printlog "create 2 rectangles" Call hRechteckErstellen 20,20,40,40 Call hRechteckErstellen 60,60,80,80 sleep 2 - '/// View->Toolbars->Option Bar ///' + printlog "View->Toolbars->Option Bar" ViewToolbarsOptionbar - '/// at the bottom of the office has a toolbar to appear ///' + printlog "at the bottom of the office has a toolbar to appear" sleep 2 Kontext "Optionsbar" + if Optionsbar.Exists = False Then + ViewToolbarsOptionbar + Kontext "Optionsbar" if Optionsbar.Exists = False Then - ViewToolbarsOptionbar - Kontext "Optionsbar" - if Optionsbar.Exists = False Then - warnlog "Can't open Optionsbar." - end if + warnlog "Can't open Optionsbar." end if + end if + sleep 2 + Kontext "Toolbar" + sleep 1 + printlog "click button 'Connector' on Toolbar" + Verbinder.Click + printlog "make a line with the mouse" + gMouseMove 30,30,70,70 + sleep 3 + Kontext "Toolbar" + GluePoints.Click + sleep 1 + printlog "open Glue Points Toolbar" + Kontext "Gluepointsobjectbar" + if Gluepointsobjectbar.Exists = False Then + ViewToolbarsGluepoints + end if + sleep 3 + '-------------------------------------- Klebepunkt einfuegen ---- + try + printlog "click button 'Insert Glue Point' on Objecttoolbar" + PunkteEinfuegen.Click sleep 2 - Kontext "Toolbar" - sleep 1 - '/// click button 'Connector' on Toolbar ///' - Verbinder.Click - '/// make a line with the mouse ///' - gMouseMove 30,30,70,70 - sleep 3 - Kontext "Toolbar" - GluePoints.Click - sleep 1 - '/// open Glue Points Toolbar ///' - Kontext "Gluepointsobjectbar" - if Gluepointsobjectbar.Exists = False Then - ViewToolbarsGluepoints - end if - sleep 3 - '-------------------------------------- Klebepunkt einfuegen ---- - try - '/// click button 'Insert Glue Point' on Objecttoolbar ///' - PunkteEinfuegen.Click - sleep 2 - '/// click 2 times onto the created line ///' - gMouseClick 25,30 - sleep 1 - gMouseclick 25,30 - Printlog "- insert gluepoint works" - catch - Warnlog "- gluepoint could not be insert. Following errors might have their reason here" - endcatch - sleep 3 - Kontext "Gluepointsobjectbar" - - '-------------------------------------- Links ------------------- - try - '/// click button 'Exit Direction Left' on Objecttoolbar ///' - Links.Click - Printlog "- gluepoint left works" - catch - Warnlog "- gluepoint left does not work" - endcatch - sleep 1 - '-------------------------------------- Rechts ------------------ - try - '/// click button 'Exit Direction Right' on Objecttoolbar ///' - Rechts.Click - Printlog "- gluepoint right works" - catch - Warnlog "- gluepoint right does not work" - endcatch - sleep 1 - '-------------------------------------- Oben -------------------- - try - '/// click button 'Exit Direction Top' on Objecttoolbar ///' - Oben.Click - Printlog "- gluepoint top works" - catch - Warnlog "- gluepoint top does not work" - endcatch - sleep 1 - '-------------------------------------- Unten ------------------- - try - '/// click button 'Exit Direction Bottom' on Objecttoolbar ///' - Unten.Click - Printlog "- gluepoint bottom works" - catch - Warnlog "- gluepoint bottom does not work" - endcatch - sleep 1 - '---------------------- Position an Objekt anpassen ------------- - try - '/// click button 'Glue Point Relative' on Objecttoolbar ///' - PositionAnObjektAnpassen.Click - Printlog "- align position to object works" - gMouseClick 25,30 ' if you don't click onto an existing point, the state changes back :-[ - catch - Warnlog "- align position to object does not work" - endcatch - Kontext "Gluepointsobjectbar" - sleep 1 - '------------------------------------- Horizontal links --------- - if PositionAnObjektAnpassen.exists then printlog "PositionAnObjektAnpassen = Exists" - if PositionAnObjektAnpassen.GetState(2) <> 0 then PositionAnObjektAnpassen.Click ' make unpressed! - '0 = not pressed. 1 = pressed. - sleep 2 - try - Kontext "Gluepointsobjectbar" - '/// click button 'Glue Point Horizontal Left' on Objecttoolbar ///' - HorizontalLinks.Click - Printlog "- align horizontal left works" - catch - Warnlog "- align horizontal left does not work" - PositionAnObjektAnpassen.Click ' that's the middle button, it has to be UP/not activated! - for i = 1 to Gluepointsobjectbar.GetItemCount - if (Gluepointsobjectbar.GetState ( i, 0 ) <> 0 ) then ' is no seperator - printlog "----------------------------------------------------------------------" - printlog "helpid : " + Gluepointsobjectbar.Getstate ( i, 0 ) + " number in row: " + i - printlog "itemtype: " + Gluepointsobjectbar.GetState ( i, 1 ) - printlog "state : " + Gluepointsobjectbar.GetState ( i, 2 ) - printlog "----------------------------------------------------------------------" - end if - next i - endcatch - sleep 2 - '------------------------------------- Horizontal rechts -------- - try - '/// click button 'Glue Point Horizontal Right' on Objecttoolbar ///' - HorizontalRechts.Click - Printlog "- Align horizontal right does work" - catch - Warnlog "- Align horizontal right does notwork" - endcatch - sleep 1 - '------------------------------------- Horizontal zentriert ----- - try - '/// click button 'Glue Point Horizontal Center' on Objecttoolbar ///' - HorizontalZentriert.Click - Printlog "- align horizontal center does work" - catch - Warnlog "- align horizontal center does work" - endcatch - sleep 1 - '------------------------------------- Vertikal oben ------------ - try - '/// click button 'Glue Point Vertical Top' on Objecttoolbar ///' - VertikalOben.Click - sleep 1 - Printlog "- Align vertical top does work" - catch - Warnlog "- Align vertical top does not work" - endcatch - '------------------------------------- Vertikal unten ----------- - try - '/// click button 'Glue Point Vertical Bottom' on Objecttoolbar ///' - VertikalUnten.Click - sleep 1 - printlog "- Align vertical bottom does work" - catch - Warnlog "- Align vertical bottom does not work" - endcatch - '------------------------------------- Vertikal zentriert ------- - try - '/// click button 'Glue Point Vertical Center' on Objecttoolbar ///' - VertikalZentriert.Click - sleep 1 - Printlog "- Align vertical center does work" - catch - Warnlog "- Align vertical center does not work" - endcatch - - Printlog "- End of testing gluepoints" - - '/// Close the Option Bar via View->Toolbars->Option Bar ///' + printlog "click 2 times onto the created line" + gMouseClick 25,30 + sleep 1 + gMouseclick 25,30 + Printlog "- insert gluepoint works" + catch + Warnlog "- gluepoint could not be insert. Following errors might have their reason here" + endcatch + sleep 3 + Kontext "Gluepointsobjectbar" + + '-------------------------------------- Links ------------------- + try + printlog "click button 'Exit Direction Left' on Objecttoolbar" + Links.Click + Printlog "- gluepoint left works" + catch + Warnlog "- gluepoint left does not work" + endcatch + sleep 1 + '-------------------------------------- Rechts ------------------ + try + printlog "click button 'Exit Direction Right' on Objecttoolbar" + Rechts.Click + Printlog "- gluepoint right works" + catch + Warnlog "- gluepoint right does not work" + endcatch + sleep 1 + '-------------------------------------- Oben -------------------- + try + printlog "click button 'Exit Direction Top' on Objecttoolbar" + Oben.Click + Printlog "- gluepoint top works" + catch + Warnlog "- gluepoint top does not work" + endcatch + sleep 1 + '-------------------------------------- Unten ------------------- + try + printlog "click button 'Exit Direction Bottom' on Objecttoolbar" + Unten.Click + Printlog "- gluepoint bottom works" + catch + Warnlog "- gluepoint bottom does not work" + endcatch + sleep 1 + '---------------------- Position an Objekt anpassen ------------- + try + printlog "click button 'Glue Point Relative' on Objecttoolbar" + PositionAnObjektAnpassen.Click + Printlog "- align position to object works" + gMouseClick 25,30 ' if you don't click onto an existing point, the state changes back :-[ + catch + Warnlog "- align position to object does not work" + endcatch + Kontext "Gluepointsobjectbar" + sleep 1 + '------------------------------------- Horizontal links --------- + if PositionAnObjektAnpassen.exists then printlog "PositionAnObjektAnpassen = Exists" + if PositionAnObjektAnpassen.GetState(2) <> 0 then PositionAnObjektAnpassen.Click ' make unpressed! + '0 = not pressed. 1 = pressed. + sleep 2 + try + Kontext "Gluepointsobjectbar" + printlog "click button 'Glue Point Horizontal Left' on Objecttoolbar" + HorizontalLinks.Click + Printlog "- align horizontal left works" + catch + Warnlog "- align horizontal left does not work" + PositionAnObjektAnpassen.Click ' that's the middle button, it has to be UP/not activated! + for i = 1 to Gluepointsobjectbar.GetItemCount + if (Gluepointsobjectbar.GetState ( i, 0 ) <> 0 ) then ' is no seperator + printlog "----------------------------------------------------------------------" + printlog "helpid : " + Gluepointsobjectbar.Getstate ( i, 0 ) + " number in row: " + i + printlog "itemtype: " + Gluepointsobjectbar.GetState ( i, 1 ) + printlog "state : " + Gluepointsobjectbar.GetState ( i, 2 ) + printlog "----------------------------------------------------------------------" + end if + next i + endcatch + sleep 2 + '------------------------------------- Horizontal rechts -------- + try + printlog "click button 'Glue Point Horizontal Right' on Objecttoolbar" + HorizontalRechts.Click + Printlog "- Align horizontal right does work" + catch + Warnlog "- Align horizontal right does notwork" + endcatch + sleep 1 + '------------------------------------- Horizontal zentriert ----- + try + printlog "click button 'Glue Point Horizontal Center' on Objecttoolbar" + HorizontalZentriert.Click + Printlog "- align horizontal center does work" + catch + Warnlog "- align horizontal center does work" + endcatch + sleep 1 + '------------------------------------- Vertikal oben ------------ + try + printlog "click button 'Glue Point Vertical Top' on Objecttoolbar" + VertikalOben.Click + sleep 1 + Printlog "- Align vertical top does work" + catch + Warnlog "- Align vertical top does not work" + endcatch + '------------------------------------- Vertikal unten ----------- + try + printlog "click button 'Glue Point Vertical Bottom' on Objecttoolbar" + VertikalUnten.Click + sleep 1 + printlog "- Align vertical bottom does work" + catch + Warnlog "- Align vertical bottom does not work" + endcatch + '------------------------------------- Vertikal zentriert ------- + try + printlog "click button 'Glue Point Vertical Center' on Objecttoolbar" + VertikalZentriert.Click + sleep 1 + Printlog "- Align vertical center does work" + catch + Warnlog "- Align vertical center does not work" + endcatch + Printlog "- End of testing gluepoints" + printlog "Close the Option Bar via View->Toolbars->Option Bar" ViewToolbarsOptionbar sleep 2 Kontext "Optionsbar" - if Optionsbar.Exists = True Then - warnlog "Couldnt close Optionsbar." - end if - '/// close application ///' + if Optionsbar.Exists = True Then + warnlog "Couldnt close Optionsbar." + end if + printlog "close application" Call hCloseDocument -endcase +endcase 'tiGluepointToolbar -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' +'----------------------------------------------------------------------------' testcase tdBezierToolbar - '/// Open the Application ///' + printlog "Open the Application" Call hNewDocument - - '/// Create a rectangle. ///' + printlog "Create a rectangle." Call hRechteckErstellen ( 10, 10, 30, 40 ) sleep (1) - - '/// Convert the recttangle to an 'Polygon-object' via the context-menu for the object ///' + printlog "Convert the recttangle to an 'Polygon-object' via the context-menu for the object" Call hOpenContextMenu - Call hMenuSelectNr (11) '/// Convert to ///' - Call hMenuSelectNr (2) '/// Polygon-object ///' + printlog "Convert to" + Call hMenuSelectNr (11) + printlog "Polygon-object" + Call hMenuSelectNr (2) sleep (1) - - '/// In the context-menu, select 'Edit Points" ///' + printlog "In the context-menu, select 'Edit Points" Call hOpenContextMenu - Call hMenuSelectNr (5) '/// Select entry nr 5 (Edit Points) ///' + printlog "Select entry nr 5 (Edit Points)" + Call hMenuSelectNr (5) sleep (2) - Kontext "Bezierobjectbar" + if Bezierobjectbar.Exists <> TRUE then + ViewToolbarsBezier + Sleep (2) if Bezierobjectbar.Exists <> TRUE then - ViewToolbarsBezier - Sleep (2) - if Bezierobjectbar.Exists <> TRUE then - warnlog "Bezierobjectbar did not show up. Check why." - end if + warnlog "Bezierobjectbar did not show up. Check why." end if + end if '----------------------------------- Punkte verschieben ------------------------------------ - '/// Select a part of the object with the keyboard ///' - hTypeKeys "<MOD1 TAB>", 4 '/// Selects the fourth vector. ///' - hTypeKeys "<RIGHT>", 40 '/// Moves the selected vector 40 steps. ///' + printlog "Select a part of the object with the keyboard" + printlog "Selects the fourth vector." + hTypeKeys "<MOD1 TAB>", 4 + printlog "Moves the selected vector 40 steps." + hTypeKeys "<RIGHT>", 40 - '/// The 'Object Toolbar' now changes ///' + printlog "The 'Object Toolbar' now changes" Kontext "Bezierobjectbar" - if Bezierobjectbar.Exists <> TRUE then - ViewToolbarsBezier - Sleep 2 - end if - if Bezierobjectbar.Exists <> TRUE then - Warnlog "The Bezier-Objectbar should have been opened, but wasnt." - ViewToolbarsBezier - Sleep 2 - end if + if Bezierobjectbar.Exists <> TRUE then + ViewToolbarsBezier + Sleep 2 + end if + if Bezierobjectbar.Exists <> TRUE then + Warnlog "The Bezier-Objectbar should have been opened, but wasnt." + ViewToolbarsBezier + Sleep 2 + end if Kontext "Bezierobjectbar" - sleep 1 - Printlog "- Move points" - '/// click button 'Move points' on 'Object Toolbar' ///' - Verschieben.Click - sleep 2 - - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 SHIFT SPACE>" '/// Marks the selected vector. ///' - hTypeKeys "<RIGHT>", 20 '/// Moves the vector 20 with "arrow right", twenty times. ///' - - Printlog "- Insert points" - '/// Click button 'Insert points' on 'Object Toolbar' ///' + sleep 1 + Printlog "- Move points" + printlog "click button 'Move points' on 'Object Toolbar'" + Verschieben.Click + sleep 2 + hTypeKeys "<MOD1 TAB>" + printlog "Marks the selected vector." + hTypeKeys "<MOD1 SHIFT SPACE>" + printlog "Moves the vector 20 with arrow right, twenty times." + hTypeKeys "<RIGHT>", 20 + + Printlog "- Insert points" + printlog "Click button 'Insert points' on 'Object Toolbar'" Kontext "Bezierobjectbar" - Einfuegen.Click - sleep 2 - Bezierobjectbar.Move 20, 20 - sleep (1) - Printlog "- Delete points" - - '/// Select another part of the object with spanning a selection with the mouse ///' - gMouseMove 25,25,45,45 - - hTypeKeys "<MOD1 TAB>", 2 '/// Select the second next vector. ///' - hTypeKeys "<MOD1 SHIFT SPACE>" '/// Mark the selected vector. ///' - hTypeKeys "<MOD1 TAB><SHIFT SPACE>" '/// Select and mark the next vector. ///' + Einfuegen.Click + sleep 2 + Bezierobjectbar.Move 20, 20 + sleep (1) + Printlog "- Delete points" + printlog "Select another part of the object with spanning a selection with the mouse" + gMouseMove 25,25,45,45 + printlog "Select the second next vector." + hTypeKeys "<MOD1 TAB>", 2 + printlog "Mark the selected vector." + hTypeKeys "<MOD1 SHIFT SPACE>" + printlog "Select and mark the next vector." + hTypeKeys "<MOD1 TAB><SHIFT SPACE>" - sleep 2 + sleep 2 Kontext "Bezierobjectbar" - sleep 2 - Printlog "- Convert into curve" - '/// click button 'convert to curve' on 'Object Toolbar' ///' - InKurve.Click - sleep 2 - Printlog "- Place edge point" - '/// click button 'corner point' on 'Object Toolbar' ///' - Ecke.Click - sleep 2 - Printlog "- Smooth transition" - '/// click button 'smooth transition' on 'Object Toolbar' ///' - Glatt.Click - sleep 2 - Printlog "- Symetric transition" - '/// click button 'symmetric transition' on 'Object Toolbar' ///' - Symmetrisch.Click - sleep 2 - - '/// Click button 'Eliminate points' on 'Object Toolbar' ///' + sleep 2 + Printlog "- Convert into curve" + printlog "click button 'convert to curve' on 'Object Toolbar'" + InKurve.Click + sleep 2 + Printlog "- Place edge point" + printlog "click button 'corner point' on 'Object Toolbar'" + Ecke.Click + sleep 2 + Printlog "- Smooth transition" + printlog "click button 'smooth transition' on 'Object Toolbar'" + Glatt.Click + sleep 2 + Printlog "- Symetric transition" + printlog "click button 'symmetric transition' on 'Object Toolbar'" + Symmetrisch.Click + sleep 2 + + printlog "Click button 'Eliminate points' on 'Object Toolbar'" Kontext "Bezierobjectbar" - PunkteReduzieren.Click - sleep 2 - - '/// Mark another point ///' - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 SHIFT SPACE>" + PunkteReduzieren.Click + sleep 2 - '/// click button 'split curve' on 'Object Toolbar' ///' + printlog "Mark another point" + hTypeKeys "<MOD1 TAB>" + hTypeKeys "<MOD1 SHIFT SPACE>" + + printlog "click button 'split curve' on 'Object Toolbar'" Kontext "Bezierobjectbar" - try - Auftrennen.Click - catch - Warnlog "- 'Break' could not be executed" - endcatch - sleep 2 + try + Auftrennen.Click + catch + Warnlog "- 'Break' could not be executed" + endcatch + sleep 2 - '/// Mark all points ///' - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 A>" + printlog "Mark all points" + hTypeKeys "<MOD1 TAB>" + hTypeKeys "<MOD1 A>" - Printlog "- Close bezier" + Printlog "- Close bezier" Kontext "Bezierobjectbar" + try + printlog "click button 'close bezier' on 'Object Toolbar'" + Schliessen.Click + catch + InKurve.Click + sleep 2 try - '/// click button 'close bezier' on 'Object Toolbar' ///' Schliessen.Click catch - InKurve.Click - sleep 2 - try - Schliessen.Click - catch - warnlog "Couldn't push button :-( can't reproduce it now, mostly seen on linux, if i loop this test, it happens only 1/5 of the time ... :-)" - endcatch + warnlog "Couldn't push button :-( can't reproduce it now, mostly seen on linux, if i loop this test, it happens only 1/5 of the time ... :-)" endcatch - sleep 2 + endcatch + sleep 2 - '/// Mark all points ///' - hTypeKeys "<MOD1 TAB>" - hTypeKeys "<MOD1 A>" + printlog "Mark all points" + hTypeKeys "<MOD1 TAB>" + hTypeKeys "<MOD1 A>" - '/// Click button 'Delete points' on 'Object Toolbar' ///' + printlog "Click button 'Delete points' on 'Object Toolbar'" Kontext "Bezierobjectbar" - Printlog "- Break curve" - if ( hClickButton( Loeschen ) = -1 ) then - warnlog( "Unable to click button <Loeschen>" ) - endif - 'try - ' Loeschen.Click - ' sleep 2 - 'catch - ' warnlog "Delete didn't work... why?" - 'endcatch + Printlog "- Break curve" + if ( hClickButton( Loeschen ) = -1 ) then + warnlog( "Unable to click button <Loeschen>" ) + endif - '/// Uncheck on the symbol 'Curve' on the toolbar 'Main Toolbar' ///' + printlog "Uncheck on the symbol 'Curve' on the toolbar 'Main Toolbar'" Kontext "Toolbar" - sleep 2 - Toolbar.OpenContextMenu ' Enable forms button in menuebar - sleep 2 - hMenuselectNr (1) - sleep 2 - hMenuItemUnCheck (7) - sleep 2 - '/// Close application ///' + sleep 2 + Toolbar.OpenContextMenu ' Enable forms button in menuebar + sleep 2 + hMenuselectNr (1) + sleep 2 + hMenuItemUnCheck (7) + sleep 2 + printlog "Close application" Call hCloseDocument -endcase +endcase 'tdBezierToolbar -'------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------' +'------------------------------------------------------------------------------
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/global/id_opt_1.inc b/testautomation/graphics/required/includes/global/id_opt_1.inc index 7ca61a8774b5..35874fe0495f 100644 --- a/testautomation/graphics/required/includes/global/id_opt_1.inc +++ b/testautomation/graphics/required/includes/global/id_opt_1.inc @@ -32,162 +32,170 @@ '\****************************************************************************** testcase tToolsOptionsDrawGeneral (sApplication as string) - dim irgendwas(9) as boolean - dim iMasseinheit as integer - dim sTabAbstand as string - dim iZeichnungsmasstab as integer - dim sTemp as string - dim iTemp as integer - dim sTemp2 as string - dim iTemp2 as integer - dim sMeasUnit as string - - hNewDocument - - printlog "save states" - ToolsOptions - hToolsOptions (sApplication,"General") - - irgendwas(1) = Schnellbearbeitung.IsChecked - irgendwas(2) = TextbereichSelektierbar.IsChecked - - irgendwas(3) = CacheFuerHintergrund.IsChecked - irgendwas(4) = KopieBeimVerschieben.IsChecked - irgendwas(5) = ObjekteImmerVerschiebbar.IsChecked - - if (gApplication = "DRAW") then - irgendwas(6) = SetzenAufKreis.IsChecked ' DRAW - iZeichnungsmasstab = Zeichnungsmasstab.GetSelIndex ' DRAW - else ' IMPRESS - irgendwas(7) = MitAutopilotStarten.IsChecked - irgendwas(8) = MitAktuellerSeite.IsChecked - irgendwas(9) = AlleAbsatzabstaendeAddieren.IsChecked - endif - - iMasseinheit = Masseinheit.GetSelIndex - sTabAbstand = Tabulatorabstand.GetText - - printlog "all states inverting" - - if irgendwas(1) Then Schnellbearbeitung.UnCheck Else Schnellbearbeitung.Check - if irgendwas(2) Then TextbereichSelektierbar.UnCheck Else TextbereichSelektierbar.Check - - if irgendwas(3) Then CacheFuerHintergrund.UnCheck Else CacheFuerHintergrund.Check - if irgendwas(4) Then KopieBeimVerschieben.UnCheck Else KopieBeimVerschieben.Check - if irgendwas(5) Then ObjekteImmerVerschiebbar.UnCheck Else ObjekteImmerVerschiebbar.Check - - Tabulatorabstand.ToMax - sTemp = Tabulatorabstand.GetText - Tabulatorabstand.More + dim irgendwas(9) as boolean + dim iMasseinheit as integer + dim sTabAbstand as string + dim iZeichnungsmasstab as integer + dim sTemp as string + dim iTemp as integer + dim sTemp2 as string + dim iTemp2 as integer + dim sMeasUnit as string - if (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE) Then Warnlog "Something wrong, please check!" - Tabulatorabstand.SetText (sTabAbstand) - - if (gApplication = "DRAW") then - If ( Zeichnungsmasstab.GetItemCount <> iZeichnungsmasstab ) Then Zeichnungsmasstab.Select (Zeichnungsmasstab.GetItemCount) _ - Else Zeichnungsmasstab.Select (1) - iTemp2 = Zeichnungsmasstab.GetSelIndex - if irgendwas(6) Then SetzenAufKreis.UnCheck Else SetzenAufKreis.Check - else ' IMPRESS - if irgendwas(7) Then MitAutopilotStarten.UnCheck Else MitAutopilotStarten.Check - if irgendwas(8) Then MitAktuellerSeite.UnCheck Else MitAktuellerSeite.Check - if irgendwas(9) Then AlleAbsatzabstaendeAddieren.UnCheck Else AlleAbsatzabstaendeAddieren.Check - endif - - printlog "<Meas.Unit> interacts with <Tap stops> and vice versa" - - If ( Masseinheit.GetItemCount <> iMasseinheit ) Then Masseinheit.Select (Masseinheit.GetItemCount) _ - Else Masseinheit.Select (1) - iTemp = Masseinheit.GetSelIndex + hNewDocument - sTemp = Tabulatorabstand.GetText - Tabulatorabstand.ToMax - If ( Tabulatorabstand.GetText = sTemp ) Then Tabulatorabstand.ToMin - sTemp = Tabulatorabstand.GetText + printlog "save states" + ToolsOptions + hToolsOptions (sApplication,"General") - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + irgendwas(1) = Schnellbearbeitung.IsChecked + irgendwas(2) = TextbereichSelektierbar.IsChecked - printlog "Office quit - start" + irgendwas(3) = CacheFuerHintergrund.IsChecked + irgendwas(4) = KopieBeimVerschieben.IsChecked + irgendwas(5) = ObjekteImmerVerschiebbar.IsChecked - ExitRestartTheOffice - printlog "opening new doc to get the Options" - Call hNewDocument - printlog "checking states" - ToolsOptions - hToolsOptions (sApplication,"General") + if (gApplication = "DRAW") then + irgendwas(6) = SetzenAufKreis.IsChecked ' DRAW + iZeichnungsmasstab = Zeichnungsmasstab.GetSelIndex ' DRAW + else ' IMPRESS + irgendwas(7) = MitAutopilotStarten.IsChecked + irgendwas(8) = MitAktuellerSeite.IsChecked + irgendwas(9) = AlleAbsatzabstaendeAddieren.IsChecked + endif - If ( irgendwas(1) = Schnellbearbeitung.IsChecked ) Then WarnLog "Allow Quick Editing state changed" - If ( irgendwas(2) = TextbereichSelektierbar.IsChecked ) Then WarnLog "Only Text Area Selectable state changed" + iMasseinheit = Masseinheit.GetSelIndex + sTabAbstand = Tabulatorabstand.GetText - If ( irgendwas(3) = CacheFuerHintergrund.IsChecked ) Then WarnLog "Use Background Cache state changed" - If ( irgendwas(4) = KopieBeimVerschieben.IsChecked ) Then WarnLog "Copy When Moving state changed" - If ( irgendwas(5) = ObjekteImmerVerschiebbar.IsChecked ) Then WarnLog "Objects Always Movable state changed" + printlog "all states inverting" - if (gApplication = "DRAW") then + if irgendwas(1) Then Schnellbearbeitung.UnCheck Else Schnellbearbeitung.Check + if irgendwas(2) Then TextbereichSelektierbar.UnCheck Else TextbereichSelektierbar.Check + + if irgendwas(3) Then CacheFuerHintergrund.UnCheck Else CacheFuerHintergrund.Check + if irgendwas(4) Then KopieBeimVerschieben.UnCheck Else KopieBeimVerschieben.Check + if irgendwas(5) Then ObjekteImmerVerschiebbar.UnCheck Else ObjekteImmerVerschiebbar.Check + + Tabulatorabstand.ToMax + sTemp = Tabulatorabstand.GetText + Tabulatorabstand.More + + if (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE) Then Warnlog "Something wrong, please check!" + Tabulatorabstand.SetText (sTabAbstand) + + if (gApplication = "DRAW") then + printlog "Index Zeichnungsmasstab= " & iZeichnungsmasstab + printlog "Zeichnungsmasstab Item Count= " & (Zeichnungsmasstab.GetItemCount) + If ( Zeichnungsmasstab.GetItemCount <> iZeichnungsmasstab ) Then + Zeichnungsmasstab.Select (Zeichnungsmasstab.GetItemCount) + Else + Zeichnungsmasstab.Select (1) + endif + iTemp2 = Zeichnungsmasstab.GetSelIndex + printlog "iTemp2= " & iTemp2 + if irgendwas(6) Then SetzenAufKreis.UnCheck Else SetzenAufKreis.Check + else ' IMPRESS + if irgendwas(7) Then MitAutopilotStarten.UnCheck Else MitAutopilotStarten.Check + if irgendwas(8) Then MitAktuellerSeite.UnCheck Else MitAktuellerSeite.Check + if irgendwas(9) Then AlleAbsatzabstaendeAddieren.UnCheck Else AlleAbsatzabstaendeAddieren.Check + endif + + printlog "<Meas.Unit> interacts with <Tap stops> and vice versa" + + If ( Masseinheit.GetItemCount <> iMasseinheit ) Then Masseinheit.Select (Masseinheit.GetItemCount) _ + Else Masseinheit.Select (1) + iTemp = Masseinheit.GetSelIndex + + sTemp = Tabulatorabstand.GetText + Tabulatorabstand.ToMax + If ( Tabulatorabstand.GetText = sTemp ) Then Tabulatorabstand.ToMin + sTemp = Tabulatorabstand.GetText + + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK + + printlog "-------> Office quit - start" + + ExitRestartTheOffice + printlog "opening new doc to get the Options" + Call hNewDocument + printlog "checking states" + ToolsOptions + hToolsOptions (sApplication,"General") + + If ( irgendwas(1) = Schnellbearbeitung.IsChecked ) Then WarnLog "Allow Quick Editing state changed" + If ( irgendwas(2) = TextbereichSelektierbar.IsChecked ) Then WarnLog "Only Text Area Selectable state changed" + + If ( irgendwas(3) = CacheFuerHintergrund.IsChecked ) Then WarnLog "Use Background Cache state changed" + If ( irgendwas(4) = KopieBeimVerschieben.IsChecked ) Then WarnLog "Copy When Moving state changed" + If ( irgendwas(5) = ObjekteImmerVerschiebbar.IsChecked ) Then WarnLog "Objects Always Movable state changed" + + if (gApplication = "DRAW") then + printlog "Index Zeichnungsmasstab= " & (Zeichnungsmasstab.GetSelIndex) + printlog "iTemp2= " & iTemp2 If ( Zeichnungsmasstab.GetSelIndex <> iTemp2 ) Then WarnLog "Drawing Scale state changed BUG #97391 is:"+Zeichnungsmasstab.GetSelIndex+"; should: "+iTemp2 If ( irgendwas(6) = SetzenAufKreis.IsChecked ) Then WarnLog "'Do not disort objects in curve' state changed" - else ' IMPRESS + else ' IMPRESS if ( irgendwas(7) = MitAutopilotStarten.IsChecked ) Then WarnLog "'Start with AutoPilot' state changed." -' + ' if ( irgendwas(8) = MitAktuellerSeite.IsChecked ) Then WarnLog "'Always with current page' changed" if ( irgendwas(9) = AlleAbsatzabstaendeAddieren.IsChecked ) Then WarnLog "'Add spacing between paragraphs in the current document' changed" - endif - - If ( Masseinheit.GetSelIndex <> iTemp ) Then WarnLog "Unit of Measurement state changed" - If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops state changed - watch BugID: 82744 for Status" - - printlog "all UnCheck -> o" - - Schnellbearbeitung.UnCheck - TextbereichSelektierbar.UnCheck - - CacheFuerHintergrund.UnCheck - KopieBeimVerschieben.UnCheck - ObjekteImmerVerschiebbar.UnCheck - - if (gApplication = "DRAW") then - Zeichnungsmasstab.Select (1) - SetzenAufKreis.UnCheck - else ' IMPRESS - MitAutopilotStarten.UnCheck - MitAktuellerSeite.UnCheck - AlleAbsatzabstaendeAddieren.UnCheck - endif - - Masseinheit.Select (1) - Tabulatorabstand.ToMin - sTemp = Tabulatorabstand.GetText - printlog " More test " - Tabulatorabstand.More - if ( sTemp = Tabulatorabstand.GetText ) Then WarnLog "Tab Stops More-Button not working; stemp1: "+sTemp + " =? (2) " +Tabulatorabstand.GetText - sTemp = Tabulatorabstand.GetText - - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK - - printlog "check if all UnChecked" - ToolsOptions - hToolsOptions (sApplication,"General") - - If Schnellbearbeitung.IsChecked Then WarnLog "Allow Quick Editing x" - If TextbereichSelektierbar.IsChecked Then WarnLog "Only Text Area Selectable x" - - If CacheFuerHintergrund.IsChecked Then WarnLog "Use Background Cache x" - If KopieBeimVerschieben.IsChecked Then WarnLog "Copy When Moving x" - If ObjekteImmerVerschiebbar.IsChecked Then WarnLog "Objects Always Movable x" - - if (gApplication = "DRAW") then - If ( Zeichnungsmasstab.GetSelIndex <> 1 ) Then WarnLog "'Drawing Scale' is not item 1" - If SetzenAufKreis.IsChecked Then WarnLog "'Do not disort objects in curve' x" - else ' IMPRESS - if MitAutopilotStarten.IsChecked Then WarnLog "Start with AutoPilot x" - if MitAktuellerSeite.IsChecked Then WarnLog "'Always with current page' x" - if AlleAbsatzabstaendeAddieren.IsChecked Then WarnLog "'Add spacing between paragraphs in the current document' x" - endif - - If ( Masseinheit.GetSelIndex <> 1 ) Then WarnLog "Unit of Measurement is not item 1" - If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops is not min. is: " +Tabulatorabstand.GetText + " should: " +sTemp + endif + + If ( Masseinheit.GetSelIndex <> iTemp ) Then WarnLog "Unit of Measurement state changed" + If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops state changed - watch BugID: 82744 for Status" + + printlog "all UnCheck -> o" + + Schnellbearbeitung.UnCheck + TextbereichSelektierbar.UnCheck + + CacheFuerHintergrund.UnCheck + KopieBeimVerschieben.UnCheck + ObjekteImmerVerschiebbar.UnCheck + + if (gApplication = "DRAW") then + Zeichnungsmasstab.Select (1) + SetzenAufKreis.UnCheck + else ' IMPRESS + MitAutopilotStarten.UnCheck + MitAktuellerSeite.UnCheck + AlleAbsatzabstaendeAddieren.UnCheck + endif + + Masseinheit.Select (1) + Tabulatorabstand.ToMin + sTemp = Tabulatorabstand.GetText + printlog " More test " + Tabulatorabstand.More + if ( sTemp = Tabulatorabstand.GetText ) Then WarnLog "Tab Stops More-Button not working; stemp1: "+sTemp + " =? (2) " +Tabulatorabstand.GetText + sTemp = Tabulatorabstand.GetText + + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK + + printlog "check if all UnChecked" + ToolsOptions + hToolsOptions (sApplication,"General") + + If Schnellbearbeitung.IsChecked Then WarnLog "Allow Quick Editing x" + If TextbereichSelektierbar.IsChecked Then WarnLog "Only Text Area Selectable x" + + If CacheFuerHintergrund.IsChecked Then WarnLog "Use Background Cache x" + If KopieBeimVerschieben.IsChecked Then WarnLog "Copy When Moving x" + If ObjekteImmerVerschiebbar.IsChecked Then WarnLog "Objects Always Movable x" + + if (gApplication = "DRAW") then + If ( Zeichnungsmasstab.GetSelIndex <> 1 ) Then WarnLog "'Drawing Scale' is not item 1" + If SetzenAufKreis.IsChecked Then WarnLog "'Do not disort objects in curve' x" + else ' IMPRESS + if MitAutopilotStarten.IsChecked Then WarnLog "Start with AutoPilot x" + if MitAktuellerSeite.IsChecked Then WarnLog "'Always with current page' x" + if AlleAbsatzabstaendeAddieren.IsChecked Then WarnLog "'Add spacing between paragraphs in the current document' x" + endif + + If ( Masseinheit.GetSelIndex <> 1 ) Then WarnLog "Unit of Measurement is not item 1" + If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops is not min. is: " +Tabulatorabstand.GetText + " should: " +sTemp Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK @@ -198,56 +206,51 @@ testcase tToolsOptionsDrawGeneral (sApplication as string) hNewDocument printlog "set Default Tab Stop to 2,5cm" - ToolsOptions - hToolsOptions (sApplication,"General") - Masseinheit.Select (2) ' cm - sMeasUnit = GetMeasUnit(Tabulatorabstand.GetText) -' printlog "before " + Tabulatorabstand.GetText - Tabulatorabstand.SetText ("2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "50"+ sMeasUnit) -' printlog "after " + Tabulatorabstand.GetText -' printlog "seperator: " + GetDecimalSeperator(Tabulatorabstand.GetText) -' printlog "generated string: " + "2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "50cm" + ToolsOptions + hToolsOptions (sApplication,"General") + Masseinheit.Select (2) ' cm + sMeasUnit = GetMeasUnit(Tabulatorabstand.GetText) + ' printlog "before " + Tabulatorabstand.GetText + Tabulatorabstand.SetText ("2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "50"+ sMeasUnit) + ' printlog "after " + Tabulatorabstand.GetText + ' printlog "seperator: " + GetDecimalSeperator(Tabulatorabstand.GetText) + ' printlog "generated string: " + "2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "50cm" Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK printlog "creating document with tabstops and save it" - if (gApplication = "DRAW") then - kontext "Toolbar" - Textfield.Click - kontext "DocumentDraw" - hMouseClick DocumentDraw,50,50 - else - kontext "Toolbar" - Textfield.Click - kontext "DocumentImpress" - hMouseClick DocumentImpress,20,50 - endif - hTypeKeys "a<Tab>b<Tab>c<Tab>d<Tab>e<Tab>f<Tab>g<Tab>h<Tab>i<Tab>j" - - + if (gApplication = "DRAW") then + kontext "Toolbar" + Textfield.Click + kontext "DocumentDraw" + hMouseClick DocumentDraw,50,50 + else + kontext "Toolbar" + Textfield.Click + kontext "DocumentImpress" + hMouseClick DocumentImpress,20,50 + endif + hTypeKeys "a<Tab>b<Tab>c<Tab>d<Tab>e<Tab>f<Tab>g<Tab>h<Tab>i<Tab>j" if ( gApplication = "IMPRESS" ) then ExtensionString = "odp" else ExtensionString = "odg" end if - hFileSaveAsKill (gOfficePath + "user\work\tab25cm." & ExtensionString ) - - hCloseDocument - sleep (2) - + hCloseDocument + sleep (2) printlog "change tab stops" - hNewDocument + hNewDocument printlog "Changed the Default Tab Stop to 2,9cm" - ToolsOptions - hToolsOptions (sApplication,"General") - Masseinheit.Select (2) ' cm -' printlog "before " + Tabulatorabstand.GetText - Tabulatorabstand.SetText ("2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "90"+sMeasUnit ) -' printlog "after " + Tabulatorabstand.GetText - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK - sleep (2) + ToolsOptions + hToolsOptions (sApplication,"General") + Masseinheit.Select (2) ' cm + ' printlog "before " + Tabulatorabstand.GetText + Tabulatorabstand.SetText ("2" + GetDecimalSeperator(Tabulatorabstand.GetText) + "90"+sMeasUnit ) + ' printlog "after " + Tabulatorabstand.GetText + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK + sleep (2) @@ -271,98 +274,98 @@ testcase tToolsOptionsDrawGeneral (sApplication as string) hCloseDocument '--------------------------------------------------------------------------------- - Printlog ("'/// - all Check -> x ///") + Printlog ("all Check -> x") - printlog "Click in the open impress document to get the focus back to the document" - printlog "Otherwise it sometimes happend that the Tools/Option dialog doesn't display the correct applications" - hNewDocument - if ( sApplication = "IMPRESS") then + printlog "Click in the open impress document to get the focus back to the document" + printlog "Otherwise it sometimes happend that the Tools/Option dialog doesn't display the correct applications" + hNewDocument + if ( sApplication = "IMPRESS") then Kontext "DocumentImpress" - DocumentImpress.MouseDown(50,50) - DocumentImpress.MouseUp(50,50) - else + DocumentImpress.MouseDown(50,50) + DocumentImpress.MouseUp(50,50) + else Kontext "DocumentDraw" - DocumentDraw.MouseDown(50,50) - DocumentDraw.MouseUp(50,50) - endif + DocumentDraw.MouseDown(50,50) + DocumentDraw.MouseUp(50,50) + endif - ToolsOptions - hToolsOptions (sApplication,"General") - kontext "TabSonstigesDraw" - Schnellbearbeitung.Check - TextbereichSelektierbar.Check + ToolsOptions + hToolsOptions (sApplication,"General") + kontext "TabSonstigesDraw" + Schnellbearbeitung.Check + TextbereichSelektierbar.Check - CacheFuerHintergrund.Check - KopieBeimVerschieben.Check - ObjekteImmerVerschiebbar.Check + CacheFuerHintergrund.Check + KopieBeimVerschieben.Check + ObjekteImmerVerschiebbar.Check - if (gApplication = "DRAW") then + if (gApplication = "DRAW") then Zeichnungsmasstab.Select (2) itemp2 = Zeichnungsmasstab.GetSelIndex SetzenAufKreis.Check - else ' IMPRESS -' MitAutopilotStarten.Check + else ' IMPRESS + ' MitAutopilotStarten.Check MitAktuellerSeite.Check AlleAbsatzabstaendeAddieren.Check - endif + endif - Masseinheit.Select (2) - itemp = Masseinheit.GetSelIndex - sTemp = "3" + GetDecimalSeperator(Tabulatorabstand.GetText) + "21"+sMeasUnit - Tabulatorabstand.SetText (sTemp) + Masseinheit.Select (2) + itemp = Masseinheit.GetSelIndex + sTemp = "3" + GetDecimalSeperator(Tabulatorabstand.GetText) + "21"+sMeasUnit + Tabulatorabstand.SetText (sTemp) - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - printlog ("'/// - check if all Checked ///") - ToolsOptions - hToolsOptions (sApplication,"General") + printlog ("check if all Checked") + ToolsOptions + hToolsOptions (sApplication,"General") - If True <> Schnellbearbeitung.IsChecked Then WarnLog "Allow Quick Editing o" - If True <> TextbereichSelektierbar.IsChecked Then WarnLog "Only Text Area Selectable o" + If True <> Schnellbearbeitung.IsChecked Then WarnLog "Allow Quick Editing o" + If True <> TextbereichSelektierbar.IsChecked Then WarnLog "Only Text Area Selectable o" - If True <> CacheFuerHintergrund.IsChecked Then WarnLog "Use Background Cache o i26631" - If True <> KopieBeimVerschieben.IsChecked Then WarnLog "Copy When Moving o" - If True <> ObjekteImmerVerschiebbar.IsChecked Then WarnLog "Objects Always Movable o" + If True <> CacheFuerHintergrund.IsChecked Then WarnLog "Use Background Cache o i26631" + If True <> KopieBeimVerschieben.IsChecked Then WarnLog "Copy When Moving o" + If True <> ObjekteImmerVerschiebbar.IsChecked Then WarnLog "Objects Always Movable o" - if (gApplication = "DRAW") then - If ( Zeichnungsmasstab.GetSelIndex <> iTemp2 ) Then WarnLog "Drawing Scale is not item " + iTemp2 + " it's: " + Zeichnungsmasstab.GetSelIndex - If True <> SetzenAufKreis.IsChecked Then WarnLog "'Do not disort objects in curve' o" - else ' IMPRESS -' If True <> MitAutopilotStarten.IsChecked Then WarnLog "Start with AutoPilot o" - If True <> MitAktuellerSeite.IsChecked Then WarnLog "'Always with current page' o" - If True <> AlleAbsatzabstaendeAddieren.IsChecked Then WarnLog "'Add spacing between paragraphs in the current document' o" - endif + if (gApplication = "DRAW") then + If ( Zeichnungsmasstab.GetSelIndex <> iTemp2 ) Then WarnLog "Drawing Scale is not item " + iTemp2 + " it's: " + Zeichnungsmasstab.GetSelIndex + If True <> SetzenAufKreis.IsChecked Then WarnLog "'Do not disort objects in curve' o" + else ' IMPRESS + ' If True <> MitAutopilotStarten.IsChecked Then WarnLog "Start with AutoPilot o" + If True <> MitAktuellerSeite.IsChecked Then WarnLog "'Always with current page' o" + If True <> AlleAbsatzabstaendeAddieren.IsChecked Then WarnLog "'Add spacing between paragraphs in the current document' o" + endif - If ( Masseinheit.GetSelIndex <> iTemp ) Then WarnLog "Masseinheit is not item " + iTemp + " it's: " + Masseinheit.GetSelIndex - If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops is not " + sTemp + " it's: " + Tabulatorabstand.GetText + If ( Masseinheit.GetSelIndex <> iTemp ) Then WarnLog "Masseinheit is not item " + iTemp + " it's: " + Masseinheit.GetSelIndex + If (LiberalMeasurement (sTemp,Tabulatorabstand.GetText) <> TRUE ) Then WarnLog "Tab stops is not " + sTemp + " it's: " + Tabulatorabstand.GetText - printlog "restore states" + printlog "restore states" - If ( irgendwas(1) = TRUE ) Then Schnellbearbeitung.Check Else Schnellbearbeitung.UnCheck - If ( irgendwas(2) = TRUE ) Then TextbereichSelektierbar.Check Else TextbereichSelektierbar.UnCheck + If ( irgendwas(1) = TRUE ) Then Schnellbearbeitung.Check Else Schnellbearbeitung.UnCheck + If ( irgendwas(2) = TRUE ) Then TextbereichSelektierbar.Check Else TextbereichSelektierbar.UnCheck - If ( irgendwas(3) = TRUE ) Then CacheFuerHintergrund.Check Else CacheFuerHintergrund.UnCheck - If ( irgendwas(4) = TRUE ) Then KopieBeimVerschieben.Check Else KopieBeimVerschieben.UnCheck - If ( irgendwas(5) = TRUE ) Then ObjekteImmerVerschiebbar.Check Else ObjekteImmerVerschiebbar.UnCheck + If ( irgendwas(3) = TRUE ) Then CacheFuerHintergrund.Check Else CacheFuerHintergrund.UnCheck + If ( irgendwas(4) = TRUE ) Then KopieBeimVerschieben.Check Else KopieBeimVerschieben.UnCheck + If ( irgendwas(5) = TRUE ) Then ObjekteImmerVerschiebbar.Check Else ObjekteImmerVerschiebbar.UnCheck - if (gApplication = "DRAW") then - Zeichnungsmasstab.Select (iZeichnungsmasstab) - If ( irgendwas(6) = TRUE ) Then SetzenAufKreis.Check Else SetzenAufKreis.UnCheck - else ' IMPRESS - if ( irgendwas(7) = TRUE ) Then MitAutopilotStarten.Check Else MitAutopilotStarten.UnCheck - if ( irgendwas(8) = TRUE ) Then MitAktuellerSeite.Check Else MitAktuellerSeite.UnCheck - if ( irgendwas(9) = TRUE ) Then AlleAbsatzabstaendeAddieren.Check Else AlleAbsatzabstaendeAddieren.UnCheck - endif + if (gApplication = "DRAW") then + Zeichnungsmasstab.Select (iZeichnungsmasstab) + If ( irgendwas(6) = TRUE ) Then SetzenAufKreis.Check Else SetzenAufKreis.UnCheck + else ' IMPRESS + if ( irgendwas(7) = TRUE ) Then MitAutopilotStarten.Check Else MitAutopilotStarten.UnCheck + if ( irgendwas(8) = TRUE ) Then MitAktuellerSeite.Check Else MitAktuellerSeite.UnCheck + if ( irgendwas(9) = TRUE ) Then AlleAbsatzabstaendeAddieren.Check Else AlleAbsatzabstaendeAddieren.UnCheck + endif - Masseinheit.Select (iMasseinheit) 'sw:ListBox:TP_LAYOUT_O - Tabulatorabstand.SetText (sTabAbstand) ' sw:MetricField:TP_LAYOUT_OPT:MF_TAB + Masseinheit.Select (iMasseinheit) 'sw:ListBox:TP_LAYOUT_O + Tabulatorabstand.SetText (sTabAbstand) ' sw:MetricField:TP_LAYOUT_OPT:MF_TAB - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - hCloseDocument + hCloseDocument endcase 'tToolsOptionsDrawGeneral '------------------------------------------------------------------------------ @@ -406,143 +409,143 @@ testcase tToolsOptionsDrawView (sApplication as string) printlog "all UnCheck -> o" - LinealeSichtbar.UnCheck - HilfslinienBeimBewegen.UnCheck - KontrolpunkteImBezierEditor.UnCheck - KonturFuerIndividuelleObjekte.UnCheck + LinealeSichtbar.UnCheck + HilfslinienBeimBewegen.UnCheck + KontrolpunkteImBezierEditor.UnCheck + KonturFuerIndividuelleObjekte.UnCheck - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - printlog "check if all UnChecked" - ToolsOptions - hToolsOptions (sApplication,"View") + printlog "check if all UnChecked" + ToolsOptions + hToolsOptions (sApplication,"View") - If LinealeSichtbar.IsChecked Then WarnLog "Rulers Visible x" - If HilfslinienBeimBewegen.IsChecked Then WarnLog "Guides When Moving x" - If KontrolpunkteImBezierEditor.IsChecked Then WarnLog "'All Control Points In B�zier Editor' x" - If KonturFuerIndividuelleObjekte.IsChecked Then WarnLog "'Contour of Each Individual Object' x" + If LinealeSichtbar.IsChecked Then WarnLog "Rulers Visible x" + If HilfslinienBeimBewegen.IsChecked Then WarnLog "Guides When Moving x" + If KontrolpunkteImBezierEditor.IsChecked Then WarnLog "'All Control Points In B�zier Editor' x" + If KonturFuerIndividuelleObjekte.IsChecked Then WarnLog "'Contour of Each Individual Object' x" - Printlog "all Check -> x" + Printlog "all Check -> x" - LinealeSichtbar.Check - HilfslinienBeimBewegen.Check - KontrolpunkteImBezierEditor.Check - KonturFuerIndividuelleObjekte.Check + LinealeSichtbar.Check + HilfslinienBeimBewegen.Check + KontrolpunkteImBezierEditor.Check + KonturFuerIndividuelleObjekte.Check - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - printlog "check if all Checked" - ToolsOptions - hToolsOptions (sApplication,"View") + printlog "check if all Checked" + ToolsOptions + hToolsOptions (sApplication,"View") - If True <> LinealeSichtbar.IsChecked Then WarnLog "Rulers Visible o" - If True <> HilfslinienBeimBewegen.IsChecked Then WarnLog "Guides When Moving o" - If True <> KontrolpunkteImBezierEditor.IsChecked Then WarnLog "'All Control Points In B�zier Editor' o" - If True <> KonturFuerIndividuelleObjekte.IsChecked Then WarnLog "'Contour of Each Individual Object' o" + If True <> LinealeSichtbar.IsChecked Then WarnLog "Rulers Visible o" + If True <> HilfslinienBeimBewegen.IsChecked Then WarnLog "Guides When Moving o" + If True <> KontrolpunkteImBezierEditor.IsChecked Then WarnLog "'All Control Points In B�zier Editor' o" + If True <> KonturFuerIndividuelleObjekte.IsChecked Then WarnLog "'Contour of Each Individual Object' o" - printlog "restore states" + printlog "restore states" - If ( irgendwas(1) = TRUE ) Then LinealeSichtbar.Check Else LinealeSichtbar.UnCheck - If ( irgendwas(2) = TRUE ) Then HilfslinienBeimBewegen.Check Else HilfslinienBeimBewegen.UnCheck - If ( irgendwas(3) = TRUE ) Then KontrolpunkteImBezierEditor.Check Else KontrolpunkteImBezierEditor.UnCheck - If ( irgendwas(4) = TRUE ) Then KonturFuerIndividuelleObjekte.Check Else KonturFuerIndividuelleObjekte.UnCheck + If ( irgendwas(1) = TRUE ) Then LinealeSichtbar.Check Else LinealeSichtbar.UnCheck + If ( irgendwas(2) = TRUE ) Then HilfslinienBeimBewegen.Check Else HilfslinienBeimBewegen.UnCheck + If ( irgendwas(3) = TRUE ) Then KontrolpunkteImBezierEditor.Check Else KontrolpunkteImBezierEditor.UnCheck + If ( irgendwas(4) = TRUE ) Then KonturFuerIndividuelleObjekte.Check Else KonturFuerIndividuelleObjekte.UnCheck - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - hCloseDocument + hCloseDocument endcase 'tToolsOptionsDrawView '-------------------------------------------------------------------------------- testcase tToolsOptionsDrawGrid (sApplication as string) - dim irgendwas(10) as boolean - dim sMetricField(7) as string ' MetricField - dim sTempMetricField(7) as string - dim iTry as integer ' some increment variable + dim irgendwas(10) as boolean + dim sMetricField(7) as string ' MetricField + dim sTempMetricField(7) as string + dim iTry as integer ' some increment variable - if ( gApplication = "IMPRESS" ) then + if ( gApplication = "IMPRESS" ) then ExtensionString = "odp" else ExtensionString = "odg" end if - hNewDocument - - printlog "save states" - ToolsOptions - hToolsOptions (sApplication,"Grid") - - irgendwas(1) = FangrasterBenutzen.IsChecked - irgendwas(2) = RasterSichtbar.IsChecked - - irgendwas(3) = AchsenSynchronisieren.IsChecked - - irgendwas(4) = AnFanglinien.IsChecked - irgendwas(5) = AnSeitenraendern.IsChecked - irgendwas(6) = AmObjektrahmen.IsChecked - irgendwas(7) = AnObjektpunkten.IsChecked - - irgendwas(8) = BeimErzeugenUndBewegen.IsChecked - irgendwas(9) = LaengereKantenlaenge.IsChecked - irgendwas(10)= BeimDrehen.IsChecked - if BeimDrehen.IsChecked then sMetricField(7) = Winkel.getText - - sMetricField(1) = RasterAufloesungXAchse.GetText - sMetricField(2) = RasterAufloesungYAchse.GetText - sMetricField(3) = RasterUnterteilungXAchse.GetText - sMetricField(4) = RasterUnterteilungYAchse.GetText - sMetricField(5) = FangenFangbereich.GetText - sMetricField(6) = Punktreduktion.GetText - - printlog "all states inverting" - - if irgendwas(1) Then FangrasterBenutzen.UnCheck Else FangrasterBenutzen.Check - if irgendwas(2) Then RasterSichtbar.UnCheck Else RasterSichtbar.Check - -' if irgendwas(3) Then AchsenSynchronisieren.UnCheck Else AchsenSynchronisieren.Check - ' this CheckBox interacts with the MetricBoxes: - AchsenSynchronisieren.UnCheck - - if irgendwas(4) Then AnFanglinien.UnCheck Else AnFanglinien.Check - if irgendwas(5) Then AnSeitenraendern.UnCheck Else AnSeitenraendern.Check - if irgendwas(6) Then AmObjektrahmen.UnCheck Else AmObjektrahmen.Check - if irgendwas(7) Then AnObjektpunkten.UnCheck Else AnObjektpunkten.Check - - if irgendwas(8) Then BeimErzeugenUndBewegen.UnCheck Else BeimErzeugenUndBewegen.Check - if irgendwas(9) Then LaengereKantenlaenge.UnCheck Else LaengereKantenlaenge.Check - if irgendwas(10)Then BeimDrehen.UnCheck Else BeimDrehen.Check - - sTempMetricField(1) = RasterAufloesungXAchse.GetText - sTempMetricField(2) = RasterAufloesungYAchse.GetText - sTempMetricField(3) = RasterUnterteilungXAchse.GetText - sTempMetricField(4) = RasterUnterteilungYAchse.GetText - sTempMetricField(5) = FangenFangbereich.GetText - sTempMetricField(6) = Punktreduktion.GetText - RasterAufloesungXAchse.ToMax - RasterAufloesungYAchse.ToMin - RasterUnterteilungXAchse.ToMin - RasterUnterteilungYAchse.ToMax - FangenFangbereich.ToMin - Punktreduktion.ToMax - If ( RasterAufloesungXAchse.GetText = sTempMetricField(1) ) Then RasterAufloesungXAchse.ToMin - If ( RasterAufloesungYAchse.GetText = sTempMetricField(2) ) Then RasterAufloesungYAchse.ToMax - If ( RasterUnterteilungXAchse.GetText = sTempMetricField(3) ) Then RasterUnterteilungXAchse.ToMax - If ( RasterUnterteilungYAchse.GetText = sTempMetricField(4) ) Then RasterUnterteilungYAchse.ToMin - If ( FangenFangbereich.GetText = sTempMetricField(5) ) Then FangenFangbereich.ToMax - If ( Punktreduktion.GetText = sTempMetricField(6) ) Then Punktreduktion.ToMin - RasterAufloesungXAchse.More ' because it must greater than the.min value for the subdivisions if they are .tomax! - RasterAufloesungXAchse.More - RasterAufloesungYAchse.More - RasterAufloesungYAchse.More - sTempMetricField(1) = RasterAufloesungXAchse.GetText - sTempMetricField(2) = RasterAufloesungYAchse.GetText - sTempMetricField(3) = RasterUnterteilungXAchse.GetText - sTempMetricField(4) = RasterUnterteilungYAchse.GetText - sTempMetricField(5) = FangenFangbereich.GetText - sTempMetricField(6) = Punktreduktion.GetText + hNewDocument + + printlog "save states" + ToolsOptions + hToolsOptions (sApplication,"Grid") + + irgendwas(1) = FangrasterBenutzen.IsChecked + irgendwas(2) = RasterSichtbar.IsChecked + + irgendwas(3) = AchsenSynchronisieren.IsChecked + + irgendwas(4) = AnFanglinien.IsChecked + irgendwas(5) = AnSeitenraendern.IsChecked + irgendwas(6) = AmObjektrahmen.IsChecked + irgendwas(7) = AnObjektpunkten.IsChecked + + irgendwas(8) = BeimErzeugenUndBewegen.IsChecked + irgendwas(9) = LaengereKantenlaenge.IsChecked + irgendwas(10)= BeimDrehen.IsChecked + if BeimDrehen.IsChecked then sMetricField(7) = Winkel.getText + + sMetricField(1) = RasterAufloesungXAchse.GetText + sMetricField(2) = RasterAufloesungYAchse.GetText + sMetricField(3) = RasterUnterteilungXAchse.GetText + sMetricField(4) = RasterUnterteilungYAchse.GetText + sMetricField(5) = FangenFangbereich.GetText + sMetricField(6) = Punktreduktion.GetText + + printlog "all states inverting" + + if irgendwas(1) Then FangrasterBenutzen.UnCheck Else FangrasterBenutzen.Check + if irgendwas(2) Then RasterSichtbar.UnCheck Else RasterSichtbar.Check + + ' if irgendwas(3) Then AchsenSynchronisieren.UnCheck Else AchsenSynchronisieren.Check + ' this CheckBox interacts with the MetricBoxes: + AchsenSynchronisieren.UnCheck + + if irgendwas(4) Then AnFanglinien.UnCheck Else AnFanglinien.Check + if irgendwas(5) Then AnSeitenraendern.UnCheck Else AnSeitenraendern.Check + if irgendwas(6) Then AmObjektrahmen.UnCheck Else AmObjektrahmen.Check + if irgendwas(7) Then AnObjektpunkten.UnCheck Else AnObjektpunkten.Check + + if irgendwas(8) Then BeimErzeugenUndBewegen.UnCheck Else BeimErzeugenUndBewegen.Check + if irgendwas(9) Then LaengereKantenlaenge.UnCheck Else LaengereKantenlaenge.Check + if irgendwas(10)Then BeimDrehen.UnCheck Else BeimDrehen.Check + + sTempMetricField(1) = RasterAufloesungXAchse.GetText + sTempMetricField(2) = RasterAufloesungYAchse.GetText + sTempMetricField(3) = RasterUnterteilungXAchse.GetText + sTempMetricField(4) = RasterUnterteilungYAchse.GetText + sTempMetricField(5) = FangenFangbereich.GetText + sTempMetricField(6) = Punktreduktion.GetText + RasterAufloesungXAchse.ToMax + RasterAufloesungYAchse.ToMin + RasterUnterteilungXAchse.ToMin + RasterUnterteilungYAchse.ToMax + FangenFangbereich.ToMin + Punktreduktion.ToMax + If ( RasterAufloesungXAchse.GetText = sTempMetricField(1) ) Then RasterAufloesungXAchse.ToMin + If ( RasterAufloesungYAchse.GetText = sTempMetricField(2) ) Then RasterAufloesungYAchse.ToMax + If ( RasterUnterteilungXAchse.GetText = sTempMetricField(3) ) Then RasterUnterteilungXAchse.ToMax + If ( RasterUnterteilungYAchse.GetText = sTempMetricField(4) ) Then RasterUnterteilungYAchse.ToMin + If ( FangenFangbereich.GetText = sTempMetricField(5) ) Then FangenFangbereich.ToMax + If ( Punktreduktion.GetText = sTempMetricField(6) ) Then Punktreduktion.ToMin + RasterAufloesungXAchse.More ' because it must greater than the.min value for the subdivisions if they are .tomax! + RasterAufloesungXAchse.More + RasterAufloesungYAchse.More + RasterAufloesungYAchse.More + sTempMetricField(1) = RasterAufloesungXAchse.GetText + sTempMetricField(2) = RasterAufloesungYAchse.GetText + sTempMetricField(3) = RasterUnterteilungXAchse.GetText + sTempMetricField(4) = RasterUnterteilungYAchse.GetText + sTempMetricField(5) = FangenFangbereich.GetText + sTempMetricField(6) = Punktreduktion.GetText Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK @@ -557,205 +560,203 @@ testcase tToolsOptionsDrawGrid (sApplication as string) ToolsOptions hToolsOptions (sApplication,"Grid") - If ( irgendwas(1) = FangrasterBenutzen.IsChecked ) Then WarnLog "Snap to Grid state changed" - If ( irgendwas(2) = RasterSichtbar.IsChecked ) Then WarnLog "Visible Grid state changed" - -' If ( irgendwas(3) = AchsenSynchronisieren.IsChecked ) Then WarnLog "Synchronize Axes state changed" - if ( AchsenSynchronisieren.IsChecked = TRUE ) Then WarnLog "Synchronize Axes state changed" - - If ( irgendwas(4) = AnFanglinien.IsChecked ) Then WarnLog "To snap lines state changed" - If ( irgendwas(5) = AnSeitenraendern.IsChecked ) Then WarnLog "To the page margins state changed" - If ( irgendwas(6) = AmObjektrahmen.IsChecked ) Then WarnLog "To object frame state changed" - If ( irgendwas(7) = AnObjektpunkten.IsChecked ) Then WarnLog "To object points state changed" - - If ( irgendwas(8) = BeimErzeugenUndBewegen.IsChecked ) Then WarnLog "When creating or moving objects state changed" - If ( irgendwas(9) = LaengereKantenlaenge.IsChecked ) Then WarnLog "Extend Edges state changed" - If ( irgendwas(10)= BeimDrehen.IsChecked ) Then WarnLog "When Rotating state changed" - - If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel state changed" - If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel state changed" - If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel state changed is: "+RasterUnterteilungXAchse.GetText+"; should: "+sTempMetricField(3) - If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel state changed is: "+RasterUnterteilungYAchse.GetText+"; should: "+sTempMetricField(4) - If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "SnapSnap range state changed" - If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Pointreduction state changed" - - printlog "all UnCheck -> o" - - FangrasterBenutzen.UnCheck - RasterSichtbar.UnCheck - - AchsenSynchronisieren.UnCheck - - AnFanglinien.UnCheck - AnSeitenraendern.UnCheck - AmObjektrahmen.UnCheck - AnObjektpunkten.UnCheck - - BeimErzeugenUndBewegen.UnCheck - LaengereKantenlaenge.UnCheck - BeimDrehen.UnCheck - - RasterAufloesungXAchse.ToMin - RasterAufloesungYAchse.ToMin - RasterUnterteilungXAchse.ToMin - RasterUnterteilungYAchse.ToMin - FangenFangbereich.ToMin - Punktreduktion.ToMin - sTempMetricField(1) = RasterAufloesungXAchse.GetText - sTempMetricField(2) = RasterAufloesungYAchse.GetText - sTempMetricField(3) = RasterUnterteilungXAchse.GetText - sTempMetricField(4) = RasterUnterteilungYAchse.GetText - sTempMetricField(5) = FangenFangbereich.GetText - sTempMetricField(6) = Punktreduktion.GetText - printlog "More test" - RasterAufloesungXAchse.More - RasterAufloesungYAchse.More - RasterUnterteilungXAchse.More - RasterUnterteilungYAchse.More - FangenFangbereich.More - Punktreduktion.More - if ( sTempMetricField(1) = RasterAufloesungXAchse.GetText ) Then WarnLog "GridResolutionXAxel More-Button not working" - if ( sTempMetricField(2) = RasterAufloesungYAchse.GetText ) Then WarnLog "GridResolutionYAxel More-Button not working" - if ( sTempMetricField(3) = RasterUnterteilungXAchse.GetText ) Then WarnLog "GridSubdivisionXAxel More-Button not working" - if ( sTempMetricField(4) = RasterUnterteilungYAchse.GetText ) Then WarnLog "GridSubdivisionYAxel More-Button not working" - if ( sTempMetricField(5) = FangenFangbereich.GetText ) Then WarnLog "Snap Snap Range More-Button not working" - if ( sTempMetricField(6) = Punktreduktion.GetText ) Then WarnLog "Pointreduction More-Button not working is: "+Punktreduktion.GetText - sTempMetricField(1) = RasterAufloesungXAchse.GetText - sTempMetricField(2) = RasterAufloesungYAchse.GetText - sTempMetricField(3) = RasterUnterteilungXAchse.GetText - sTempMetricField(4) = RasterUnterteilungYAchse.GetText - sTempMetricField(5) = FangenFangbereich.GetText - sTempMetricField(6) = Punktreduktion.GetText + If ( irgendwas(1) = FangrasterBenutzen.IsChecked ) Then WarnLog "Snap to Grid state changed" + If ( irgendwas(2) = RasterSichtbar.IsChecked ) Then WarnLog "Visible Grid state changed" - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + ' If ( irgendwas(3) = AchsenSynchronisieren.IsChecked ) Then WarnLog "Synchronize Axes state changed" + if ( AchsenSynchronisieren.IsChecked = TRUE ) Then WarnLog "Synchronize Axes state changed" + + If ( irgendwas(4) = AnFanglinien.IsChecked ) Then WarnLog "To snap lines state changed" + If ( irgendwas(5) = AnSeitenraendern.IsChecked ) Then WarnLog "To the page margins state changed" + If ( irgendwas(6) = AmObjektrahmen.IsChecked ) Then WarnLog "To object frame state changed" + If ( irgendwas(7) = AnObjektpunkten.IsChecked ) Then WarnLog "To object points state changed" + + If ( irgendwas(8) = BeimErzeugenUndBewegen.IsChecked ) Then WarnLog "When creating or moving objects state changed" + If ( irgendwas(9) = LaengereKantenlaenge.IsChecked ) Then WarnLog "Extend Edges state changed" + If ( irgendwas(10)= BeimDrehen.IsChecked ) Then WarnLog "When Rotating state changed" + + If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel state changed" + If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel state changed" + If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel state changed is: "+RasterUnterteilungXAchse.GetText+"; should: "+sTempMetricField(3) + If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel state changed is: "+RasterUnterteilungYAchse.GetText+"; should: "+sTempMetricField(4) + If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "SnapSnap range state changed" + If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Pointreduction state changed" + + printlog "all UnCheck -> o" + + FangrasterBenutzen.UnCheck + RasterSichtbar.UnCheck + + AchsenSynchronisieren.UnCheck + + AnFanglinien.UnCheck + AnSeitenraendern.UnCheck + AmObjektrahmen.UnCheck + AnObjektpunkten.UnCheck + + BeimErzeugenUndBewegen.UnCheck + LaengereKantenlaenge.UnCheck + BeimDrehen.UnCheck + + RasterAufloesungXAchse.ToMin + RasterAufloesungYAchse.ToMin + RasterUnterteilungXAchse.ToMin + RasterUnterteilungYAchse.ToMin + FangenFangbereich.ToMin + Punktreduktion.ToMin + sTempMetricField(1) = RasterAufloesungXAchse.GetText + sTempMetricField(2) = RasterAufloesungYAchse.GetText + sTempMetricField(3) = RasterUnterteilungXAchse.GetText + sTempMetricField(4) = RasterUnterteilungYAchse.GetText + sTempMetricField(5) = FangenFangbereich.GetText + sTempMetricField(6) = Punktreduktion.GetText + printlog "More test" + RasterAufloesungXAchse.More + RasterAufloesungYAchse.More + RasterUnterteilungXAchse.More + RasterUnterteilungYAchse.More + FangenFangbereich.More + Punktreduktion.More + if ( sTempMetricField(1) = RasterAufloesungXAchse.GetText ) Then WarnLog "GridResolutionXAxel More-Button not working" + if ( sTempMetricField(2) = RasterAufloesungYAchse.GetText ) Then WarnLog "GridResolutionYAxel More-Button not working" + if ( sTempMetricField(3) = RasterUnterteilungXAchse.GetText ) Then WarnLog "GridSubdivisionXAxel More-Button not working" + if ( sTempMetricField(4) = RasterUnterteilungYAchse.GetText ) Then WarnLog "GridSubdivisionYAxel More-Button not working" + if ( sTempMetricField(5) = FangenFangbereich.GetText ) Then WarnLog "Snap Snap Range More-Button not working" + if ( sTempMetricField(6) = Punktreduktion.GetText ) Then WarnLog "Pointreduction More-Button not working is: "+Punktreduktion.GetText + sTempMetricField(1) = RasterAufloesungXAchse.GetText + sTempMetricField(2) = RasterAufloesungYAchse.GetText + sTempMetricField(3) = RasterUnterteilungXAchse.GetText + sTempMetricField(4) = RasterUnterteilungYAchse.GetText + sTempMetricField(5) = FangenFangbereich.GetText + sTempMetricField(6) = Punktreduktion.GetText + + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - printlog "check if all UnChecked" - ToolsOptions - hToolsOptions (sApplication,"Grid") + printlog "check if all UnChecked" + ToolsOptions + hToolsOptions (sApplication,"Grid") - If FangrasterBenutzen.IsChecked Then WarnLog "Snap to Grid x" - If RasterSichtbar.IsChecked Then WarnLog "Visible Grid x" + If FangrasterBenutzen.IsChecked Then WarnLog "Snap to Grid x" + If RasterSichtbar.IsChecked Then WarnLog "Visible Grid x" - If AchsenSynchronisieren.IsChecked Then WarnLog "Synchronize Axes x" + If AchsenSynchronisieren.IsChecked Then WarnLog "Synchronize Axes x" - If AnFanglinien.IsChecked Then WarnLog "To Snap Lines x" - If AnSeitenraendern.IsChecked Then WarnLog "To The Page Margins x" - If AmObjektrahmen.IsChecked Then WarnLog "To Object Frame x" - If AnObjektpunkten.IsChecked Then WarnLog "To Object Points x" + If AnFanglinien.IsChecked Then WarnLog "To Snap Lines x" + If AnSeitenraendern.IsChecked Then WarnLog "To The Page Margins x" + If AmObjektrahmen.IsChecked Then WarnLog "To Object Frame x" + If AnObjektpunkten.IsChecked Then WarnLog "To Object Points x" - If BeimErzeugenUndBewegen.IsChecked Then WarnLog "When Creating or Moving Objects x" - If LaengereKantenlaenge.IsChecked Then WarnLog "Extend Edges x" - If BeimDrehen.IsChecked Then WarnLog "When Rotating x" + If BeimErzeugenUndBewegen.IsChecked Then WarnLog "When Creating or Moving Objects x" + If LaengereKantenlaenge.IsChecked Then WarnLog "Extend Edges x" + If BeimDrehen.IsChecked Then WarnLog "When Rotating x" - If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel is not min." - If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel is not min." - If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel is not min." - If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel is not min." - If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "Snap Snap Range is not min." - If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Point Reduction is not min." + If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel is not min." + If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel is not min." + If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel is not min." + If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel is not min." + If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "Snap Snap Range is not min." + If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Point Reduction is not min." - Printlog "all Check -> x" + Printlog "all Check -> x" - FangrasterBenutzen.Check - RasterSichtbar.Check + FangrasterBenutzen.Check + RasterSichtbar.Check - AchsenSynchronisieren.Check + AchsenSynchronisieren.Check printlog "Synchronize axes check" - RasterAufloesungXAchse.ToMax - sleep 1 - sTempMetricField(1) = RasterAufloesungXAchse.GetText - if RasterAufloesungYAchse.GetText <> sTempMetricField(1) then Warnlog "Y-axis res. differs from X-axis" - RasterUnterteilungXAchse.ToMax - sleep 1 - sTempMetricField(3) = RasterUnterteilungXAchse.GetText - if RasterUnterteilungYAchse.GetText <> sTempMetricField(3) then Warnlog "Y-axis sub. differs from X-axis" -'-------------------------------------------- - sTempMetricField(2) = RasterAufloesungYAchse.GetText - sTempMetricField(4) = RasterUnterteilungYAchse.GetText - - FangenFangbereich.Less - Punktreduktion.Less - sTempMetricField(5) = FangenFangbereich.GetText - sTempMetricField(6) = Punktreduktion.GetText - - AnFanglinien.Check - AnSeitenraendern.Check - AmObjektrahmen.Check - AnObjektpunkten.Check - - BeimErzeugenUndBewegen.Check - LaengereKantenlaenge.Check - BeimDrehen.Check - Winkel.ToMax - sTempMetricField(7) = Winkel.GetText + RasterAufloesungXAchse.ToMax + sleep 1 + sTempMetricField(1) = RasterAufloesungXAchse.GetText + if RasterAufloesungYAchse.GetText <> sTempMetricField(1) then Warnlog "Y-axis res. differs from X-axis" + RasterUnterteilungXAchse.ToMax + sleep 1 + sTempMetricField(3) = RasterUnterteilungXAchse.GetText + if RasterUnterteilungYAchse.GetText <> sTempMetricField(3) then Warnlog "Y-axis sub. differs from X-axis" + '-------------------------------------------- + sTempMetricField(2) = RasterAufloesungYAchse.GetText + sTempMetricField(4) = RasterUnterteilungYAchse.GetText + + FangenFangbereich.Less + Punktreduktion.Less + sTempMetricField(5) = FangenFangbereich.GetText + sTempMetricField(6) = Punktreduktion.GetText + + AnFanglinien.Check + AnSeitenraendern.Check + AmObjektrahmen.Check + AnObjektpunkten.Check + + BeimErzeugenUndBewegen.Check + LaengereKantenlaenge.Check + BeimDrehen.Check + Winkel.ToMax + sTempMetricField(7) = Winkel.GetText - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - printlog "check if all Checked" - ToolsOptions - hToolsOptions (sApplication,"Grid") + printlog "check if all Checked" + ToolsOptions + hToolsOptions (sApplication,"Grid") - If True <> FangrasterBenutzen.IsChecked Then WarnLog "Snap to Grid o" - If True <> RasterSichtbar.IsChecked Then WarnLog "Visible Grid o" + If True <> FangrasterBenutzen.IsChecked Then WarnLog "Snap to Grid o" + If True <> RasterSichtbar.IsChecked Then WarnLog "Visible Grid o" - If True <> AchsenSynchronisieren.IsChecked Then WarnLog "Synchronize Axes o" + If True <> AchsenSynchronisieren.IsChecked Then WarnLog "Synchronize Axes o" - If True <> AnFanglinien.IsChecked Then WarnLog "to snap lines o" - If True <> AnSeitenraendern.IsChecked Then WarnLog "to the page margins o" - If True <> AmObjektrahmen.IsChecked Then WarnLog "to object frame o" - If True <> AnObjektpunkten.IsChecked Then WarnLog "To object points o" + If True <> AnFanglinien.IsChecked Then WarnLog "to snap lines o" + If True <> AnSeitenraendern.IsChecked Then WarnLog "to the page margins o" + If True <> AmObjektrahmen.IsChecked Then WarnLog "to object frame o" + If True <> AnObjektpunkten.IsChecked Then WarnLog "To object points o" - If True <> BeimErzeugenUndBewegen.IsChecked Then WarnLog "When creating or moving objects o" - If True <> LaengereKantenlaenge.IsChecked Then WarnLog "Extend Edges o" - If True <> BeimDrehen.IsChecked Then WarnLog "When Rotating o" - If ( Winkel.GetText <> sTempMetricField(7) ) Then WarnLog "Angle is not max." + If True <> BeimErzeugenUndBewegen.IsChecked Then WarnLog "When creating or moving objects o" + If True <> LaengereKantenlaenge.IsChecked Then WarnLog "Extend Edges o" + If True <> BeimDrehen.IsChecked Then WarnLog "When Rotating o" + If ( Winkel.GetText <> sTempMetricField(7) ) Then WarnLog "Angle is not max." - If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel is not max.Bug 54934 in 01:" - If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel is not max." - If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel is not max." - If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel is not max." - If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "Snap Snap Range is not max." - If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Pointreduction is not max." + If ( RasterAufloesungXAchse.GetText <> sTempMetricField(1) ) Then WarnLog "GridResolutionXAxel is not max.Bug 54934 in 01:" + If ( RasterAufloesungYAchse.GetText <> sTempMetricField(2) ) Then WarnLog "GridResolutionYAxel is not max." + If ( RasterUnterteilungXAchse.GetText <> sTempMetricField(3) ) Then WarnLog "GridSubdivisionXAxel is not max." + If ( RasterUnterteilungYAchse.GetText <> sTempMetricField(4) ) Then WarnLog "GridSubdivisionYAxel is not max." + If ( FangenFangbereich.GetText <> sTempMetricField(5) ) Then WarnLog "Snap Snap Range is not max." + If ( Punktreduktion.GetText <> sTempMetricField(6) ) Then WarnLog "Pointreduction is not max." - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK '------------------------------------------------------------------------------- printlog "Function Test: Grid Resolution" - printlog "gTesttoolPath + graphics\required\input\gridtst.od?" - - if ( gApplication = "IMPRESS" ) then + printlog "gTesttoolPath + graphics\required\input\gridtst.od?" + if ( gApplication = "IMPRESS" ) then ExtensionString = "odp" else ExtensionString = "odg" end if - - Call hFileOpen ( gTesttoolPath + "graphics\required\input\gridtst."+ExtensionString, False ) - sleep 5 - printlog "If write-protected - open as Temp-file" - Kontext "Standardbar" - if Bearbeiten.GetState(2) <> 1 then + Call hFileOpen ( gTesttoolPath + "graphics\required\input\gridtst."+ExtensionString, False ) + sleep 5 + printlog "If write-protected - open as Temp-file" + Kontext "Standardbar" + if Bearbeiten.GetState(2) <> 1 then Bearbeiten.Click '0 = not pressed. 1 = pressed. Kontext if Active.Exists() then - Active.Yes + Active.Yes else warnlog "No messagebox after making document editable? - Test canceled here" goto endsub endif - endif - sleep (8) - if uCase(gApplication) = "IMPRESS" then + endif + sleep (8) + if uCase(gApplication) = "IMPRESS" then Kontext "DocumentImpress" - else + else Kontext "DocumentDraw" - endif - printlog "select grafik element" - for iTry = 1 to 20 + endif + printlog "select grafik element" + for iTry = 1 to 20 try EditSelectAll printlog "EditSelectAll ready after " & iTry/10 & " seconds" @@ -769,21 +770,21 @@ testcase tToolsOptionsDrawGrid (sApplication as string) ContextPositionAndSize Kontext active.setpage TabPositionAndSize - Kontext "TabPositionAndSize" - sleep 1 - if ( StrToDouble (PositionX.GetText) <> 0 ) Then WarnLog "HorizontalBy wrong presupposition != 0" - if ( StrToDouble (Positiony.GetText) <> 0 ) Then WarnLog "VerticalBy wrong presupposition != 0" - TabPositionAndSize.Cancel - sleep (3) - - printlog "move grafik with <Alt> + <up/down>" + Kontext "TabPositionAndSize" + sleep 1 + if ( StrToDouble (PositionX.GetText) <> 0 ) Then WarnLog "HorizontalBy wrong presupposition != 0" + if ( StrToDouble (Positiony.GetText) <> 0 ) Then WarnLog "VerticalBy wrong presupposition != 0" + TabPositionAndSize.Cancel + sleep (3) + + printlog "move grafik with <Alt> + <up/down>" printlog "resulting step = defined for accessability <> one pixel with cursor traveling" - hTypeKeys "<Mod2 Down>" + hTypeKeys "<Mod2 Down>" sleep (3) - hTypeKeys "<Mod2 Right>" + hTypeKeys "<Mod2 Right>" - printlog "check if @ (1,1) Current-Measure-Unit :-)" - for iTry = 1 to 20 + printlog "check if @ (1,1) Current-Measure-Unit :-)" + for iTry = 1 to 20 try EditSelectAll printlog "EditSelectAll ready after " & iTry/10 & " seconds" @@ -792,18 +793,18 @@ testcase tToolsOptionsDrawGrid (sApplication as string) wait( 100 ) endcatch next iTry - try + try ContextPositionAndSize - catch + catch printlog "Why is format position and size not enabled ? Wrong focus?" - endcatch + endcatch Kontext active.setpage TabPositionAndSize - Kontext "TabPositionAndSize" - Printlog "X difference is: '"+StrToDouble (PositionX.GetText)+"'; "+PositionX.GetText - Printlog "Y difference is: '"+StrToDouble (PositionY.GetText)+"'; "+PositionY.GetText - TabPositionAndSize.Cancel -' sleep (3) + Kontext "TabPositionAndSize" + Printlog "X difference is: '"+StrToDouble (PositionX.GetText)+"'; "+PositionX.GetText + Printlog "Y difference is: '"+StrToDouble (PositionY.GetText)+"'; "+PositionY.GetText + TabPositionAndSize.Cancel + ' sleep (3) hCloseDocument @@ -813,27 +814,27 @@ testcase tToolsOptionsDrawGrid (sApplication as string) ToolsOptions hToolsOptions (sApplication,"Grid") - If ( irgendwas(2) = TRUE ) Then FangrasterBenutzen.Check Else FangrasterBenutzen.UnCheck - If ( irgendwas(3) = TRUE ) Then RasterSichtbar.Check Else RasterSichtbar.UnCheck - - If ( irgendwas(4) = TRUE ) Then AchsenSynchronisieren.Check Else AchsenSynchronisieren.UnCheck - - If ( irgendwas(5) = TRUE ) Then AnFanglinien.Check Else AnFanglinien.UnCheck - If ( irgendwas(6) = TRUE ) Then AnSeitenraendern.Check Else AnSeitenraendern.UnCheck - If ( irgendwas(7) = TRUE ) Then AmObjektrahmen.Check Else AmObjektrahmen.UnCheck - If ( irgendwas(8) = TRUE ) Then AnObjektpunkten.Check Else AnObjektpunkten.UnCheck - - If ( irgendwas(6) = TRUE ) Then BeimErzeugenUndBewegen.Check Else BeimErzeugenUndBewegen.UnCheck - If ( irgendwas(7) = TRUE ) Then LaengereKantenlaenge.Check Else LaengereKantenlaenge.UnCheck - If ( irgendwas(8) = TRUE ) Then BeimDrehen.Check Else BeimDrehen.UnCheck - if BeimDrehen.IsChecked then Winkel.SetText (sMetricField(7)) - - RasterAufloesungXAchse.SetText (sMetricField(1)) - RasterAufloesungYAchse.SetText (sMetricField(2)) - RasterUnterteilungXAchse.SetText (sMetricField(3)) - RasterUnterteilungYAchse.SetText (sMetricField(4)) - FangenFangbereich.SetText (sMetricField(5)) - Punktreduktion.SetText (sMetricField(6)) + If ( irgendwas(2) = TRUE ) Then FangrasterBenutzen.Check Else FangrasterBenutzen.UnCheck + If ( irgendwas(3) = TRUE ) Then RasterSichtbar.Check Else RasterSichtbar.UnCheck + + If ( irgendwas(4) = TRUE ) Then AchsenSynchronisieren.Check Else AchsenSynchronisieren.UnCheck + + If ( irgendwas(5) = TRUE ) Then AnFanglinien.Check Else AnFanglinien.UnCheck + If ( irgendwas(6) = TRUE ) Then AnSeitenraendern.Check Else AnSeitenraendern.UnCheck + If ( irgendwas(7) = TRUE ) Then AmObjektrahmen.Check Else AmObjektrahmen.UnCheck + If ( irgendwas(8) = TRUE ) Then AnObjektpunkten.Check Else AnObjektpunkten.UnCheck + + If ( irgendwas(6) = TRUE ) Then BeimErzeugenUndBewegen.Check Else BeimErzeugenUndBewegen.UnCheck + If ( irgendwas(7) = TRUE ) Then LaengereKantenlaenge.Check Else LaengereKantenlaenge.UnCheck + If ( irgendwas(8) = TRUE ) Then BeimDrehen.Check Else BeimDrehen.UnCheck + if BeimDrehen.IsChecked then Winkel.SetText (sMetricField(7)) + + RasterAufloesungXAchse.SetText (sMetricField(1)) + RasterAufloesungYAchse.SetText (sMetricField(2)) + RasterUnterteilungXAchse.SetText (sMetricField(3)) + RasterUnterteilungYAchse.SetText (sMetricField(4)) + FangenFangbereich.SetText (sMetricField(5)) + Punktreduktion.SetText (sMetricField(6)) Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK @@ -845,58 +846,58 @@ endcase 'tToolsOptionsDrawGrid testcase tToolsOptionsDrawPrint (sApplication as string) - dim irgendwas(11) as boolean - dim bRadioBut(7) as boolean ' RadioButtons - dim bTempRadioBut(7) as boolean - dim iShouldHaveBeenAMultiListBox as integer + dim irgendwas(11) as boolean + dim bRadioBut(7) as boolean ' RadioButtons + dim bTempRadioBut(7) as boolean + dim iShouldHaveBeenAMultiListBox as integer - hNewDocument + hNewDocument - printlog "save states" - ToolsOptions - hToolsOptions (sApplication,"Print") + printlog "save states" + ToolsOptions + hToolsOptions (sApplication,"Print") - Standard.Check - irgendwas(1) = Seitenname.IsChecked - irgendwas(2) = Datum.IsChecked - irgendwas(3) = Zeit.IsChecked - irgendwas(4) = AusgeblendeteSeitenDrucken.IsChecked + Standard.Check + irgendwas(1) = Seitenname.IsChecked + irgendwas(2) = Datum.IsChecked + irgendwas(3) = Zeit.IsChecked + irgendwas(4) = AusgeblendeteSeitenDrucken.IsChecked - Prospekt.Check - irgendwas(5) = Vorderseite.IsChecked - irgendwas(6) = Rueckseite.IsChecked + Prospekt.Check + irgendwas(5) = Vorderseite.IsChecked + irgendwas(6) = Rueckseite.IsChecked - irgendwas(7) = AusDruckereinstellung.IsChecked + irgendwas(7) = AusDruckereinstellung.IsChecked - bRadioBut(1) = StandardAusgabe.IsChecked - bRadioBut(2) = Graustufen.IsChecked - bRadioBut(3) = SchwarzWeiss.IsChecked - bRadioBut(4) = Standard.IsChecked - bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked - bRadioBut(6) = SeitenKacheln.IsChecked + bRadioBut(1) = StandardAusgabe.IsChecked + bRadioBut(2) = Graustufen.IsChecked + bRadioBut(3) = SchwarzWeiss.IsChecked + bRadioBut(4) = Standard.IsChecked + bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked + bRadioBut(6) = SeitenKacheln.IsChecked - printlog "all states inverting" + printlog "all states inverting" - Standard.Check - if irgendwas(1) Then Seitenname.UnCheck Else Seitenname.Check - if irgendwas(2) Then Datum.UnCheck Else Datum.Check - if irgendwas(3) Then Zeit.UnCheck Else Zeit.Check - if irgendwas(4) Then AusgeblendeteSeitenDrucken.UnCheck Else AusgeblendeteSeitenDrucken.Check + Standard.Check + if irgendwas(1) Then Seitenname.UnCheck Else Seitenname.Check + if irgendwas(2) Then Datum.UnCheck Else Datum.Check + if irgendwas(3) Then Zeit.UnCheck Else Zeit.Check + if irgendwas(4) Then AusgeblendeteSeitenDrucken.UnCheck Else AusgeblendeteSeitenDrucken.Check - Prospekt.Check - if irgendwas(5) Then Vorderseite.UnCheck Else Vorderseite.Check - if irgendwas(6) Then Rueckseite.UnCheck Else Rueckseite.Check + Prospekt.Check + if irgendwas(5) Then Vorderseite.UnCheck Else Vorderseite.Check + if irgendwas(6) Then Rueckseite.UnCheck Else Rueckseite.Check - if irgendwas(7) Then AusDruckereinstellung.UnCheck Else AusDruckereinstellung.Check + if irgendwas(7) Then AusDruckereinstellung.UnCheck Else AusDruckereinstellung.Check - if (StandardAusgabe.IsChecked = True) Then Graustufen.Check Else StandardAusgabe.Check - bTempRadioBut(1) = StandardAusgabe.IsChecked - bTempRadioBut(2) = Graustufen.IsChecked - bTempRadioBut(3) = SchwarzWeiss.IsChecked - if (Standard.IsChecked = True) Then AnSeitengroesseAnpassen.Check Else Standard.Check - bRadioBut(4) = Standard.IsChecked - bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked - bRadioBut(6) = SeitenKacheln.IsChecked + if (StandardAusgabe.IsChecked = True) Then Graustufen.Check Else StandardAusgabe.Check + bTempRadioBut(1) = StandardAusgabe.IsChecked + bTempRadioBut(2) = Graustufen.IsChecked + bTempRadioBut(3) = SchwarzWeiss.IsChecked + if (Standard.IsChecked = True) Then AnSeitengroesseAnpassen.Check Else Standard.Check + bRadioBut(4) = Standard.IsChecked + bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked + bRadioBut(6) = SeitenKacheln.IsChecked Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK @@ -910,145 +911,137 @@ testcase tToolsOptionsDrawPrint (sApplication as string) ToolsOptions hToolsOptions (sApplication,"Print") - Standard.Check - If ( irgendwas(1) = Seitenname.IsChecked ) Then WarnLog "Pagename state changed" - If ( irgendwas(2) = Datum.IsChecked ) Then WarnLog "Date state changed" - If ( irgendwas(3) = Zeit.IsChecked ) Then WarnLog "Time state changed" - If ( irgendwas(4) = AusgeblendeteSeitenDrucken.IsChecked ) Then WarnLog "Hidden Pages state changed" + Standard.Check + If ( irgendwas(1) = Seitenname.IsChecked ) Then WarnLog "Pagename state changed" + If ( irgendwas(2) = Datum.IsChecked ) Then WarnLog "Date state changed" + If ( irgendwas(3) = Zeit.IsChecked ) Then WarnLog "Time state changed" + If ( irgendwas(4) = AusgeblendeteSeitenDrucken.IsChecked ) Then WarnLog "Hidden Pages state changed" - Prospekt.Check - If ( irgendwas(5) = Vorderseite.IsChecked ) Then WarnLog "Brochure Front state changed" - If ( irgendwas(6) = Rueckseite.IsChecked ) Then WarnLog "Brochure Back state changed" + Prospekt.Check + If ( irgendwas(5) = Vorderseite.IsChecked ) Then WarnLog "Brochure Front state changed" + If ( irgendwas(6) = Rueckseite.IsChecked ) Then WarnLog "Brochure Back state changed" - If ( irgendwas(7) = AusDruckereinstellung.IsChecked ) Then WarnLog "Paper Tray From Printer Settings state changed" + If ( irgendwas(7) = AusDruckereinstellung.IsChecked ) Then WarnLog "Paper Tray From Printer Settings state changed" - If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked ) Then WarnLog "Quality Default state changed" - If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality Grayscale state changed" - If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality Black & White state changed" - If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page Options Default state changed" - If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page Options Fit to Page state changed" - If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page Options Tile Pages state changed" + If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked ) Then WarnLog "Quality Default state changed" + If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality Grayscale state changed" + If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality Black & White state changed" + If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page Options Default state changed" + If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page Options Fit to Page state changed" + If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page Options Tile Pages state changed" printlog "all UnCheck -> o" - Standard.Check - Seitenname.UnCheck - Datum.UnCheck - Zeit.UnCheck - AusgeblendeteSeitenDrucken.UnCheck - - Prospekt.Check - Vorderseite.UnCheck - Rueckseite.UnCheck - - AusDruckereinstellung.UnCheck - - if (Graustufen.IsChecked = True) Then SchwarzWeiss.Check Else Graustufen.Check - bTempRadioBut(1) = StandardAusgabe.IsChecked - bTempRadioBut(2) = Graustufen.IsChecked - bTempRadioBut(3) = SchwarzWeiss.IsChecked - if (AnSeitengroesseAnpassen.IsChecked = True) Then SeitenKacheln.Check Else AnSeitengroesseAnpassen.Check - bRadioBut(4) = Standard.IsChecked - bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked - bRadioBut(6) = SeitenKacheln.IsChecked - - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Standard.Check + Seitenname.UnCheck + Datum.UnCheck + Zeit.UnCheck + AusgeblendeteSeitenDrucken.UnCheck - printlog "check if all UnChecked" - ToolsOptions - hToolsOptions (sApplication,"Print") + Prospekt.Check + Vorderseite.UnCheck + Rueckseite.UnCheck - Standard.Check - If Seitenname.IsChecked Then WarnLog "Print: Page Name x" - If Datum.IsChecked Then WarnLog "Print: Date x" - If Zeit.IsChecked Then WarnLog "Print: Time x" - If AusgeblendeteSeitenDrucken.IsChecked Then WarnLog "Print: Hidden Pages x" + AusDruckereinstellung.UnCheck - Prospekt.Check - If Vorderseite.IsChecked Then WarnLog "Page options: Brochure: Front x" - If Rueckseite.IsChecked Then WarnLog "Page options: Brochure: Back x" + if (Graustufen.IsChecked = True) Then SchwarzWeiss.Check Else Graustufen.Check + bTempRadioBut(1) = StandardAusgabe.IsChecked + bTempRadioBut(2) = Graustufen.IsChecked + bTempRadioBut(3) = SchwarzWeiss.IsChecked + if (AnSeitengroesseAnpassen.IsChecked = True) Then SeitenKacheln.Check Else AnSeitengroesseAnpassen.Check + bRadioBut(4) = Standard.IsChecked + bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked + bRadioBut(6) = SeitenKacheln.IsChecked - If AusDruckereinstellung.IsChecked Then WarnLog "Page options: Paper tray from printer settings x" - - If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked) Then WarnLog "Quality: Default state changed" - If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality: Grayscale state changed" - If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality: Black & White state changed" - If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page options: Default state changed" - If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page options: Fit to page state changed" - If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page options: Tile Pages state changed" - - Printlog "all Check -> x" - - Standard.Check - Seitenname.Check - Datum.Check - Zeit.Check - AusgeblendeteSeitenDrucken.Check - - Prospekt.Check - Vorderseite.Check - Rueckseite.Check - - AusDruckereinstellung.Check + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - if (SchwarzWeiss.IsChecked = True) Then StandardAusgabe.Check Else SchwarzWeiss.Check - bTempRadioBut(1) = StandardAusgabe.IsChecked - bTempRadioBut(2) = Graustufen.IsChecked - bTempRadioBut(3) = SchwarzWeiss.IsChecked - if (SeitenKacheln.IsChecked = True) Then Standard.Check Else SeitenKacheln.Check - bRadioBut(4) = Standard.IsChecked - bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked - bRadioBut(6) = SeitenKacheln.IsChecked + printlog "check if all UnChecked" + ToolsOptions + hToolsOptions (sApplication,"Print") - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + Standard.Check + If Seitenname.IsChecked Then WarnLog "Print: Page Name x" + If Datum.IsChecked Then WarnLog "Print: Date x" + If Zeit.IsChecked Then WarnLog "Print: Time x" + If AusgeblendeteSeitenDrucken.IsChecked Then WarnLog "Print: Hidden Pages x" + Prospekt.Check + If Vorderseite.IsChecked Then WarnLog "Page options: Brochure: Front x" + If Rueckseite.IsChecked Then WarnLog "Page options: Brochure: Back x" + If AusDruckereinstellung.IsChecked Then WarnLog "Page options: Paper tray from printer settings x" + If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked) Then WarnLog "Quality: Default state changed" + If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality: Grayscale state changed" + If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality: Black & White state changed" + If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page options: Default state changed" + If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page options: Fit to page state changed" + If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page options: Tile Pages state changed" + + Printlog "all Check -> x" + Standard.Check + Seitenname.Check + Datum.Check + Zeit.Check + AusgeblendeteSeitenDrucken.Check + Prospekt.Check + Vorderseite.Check + Rueckseite.Check + AusDruckereinstellung.Check + if (SchwarzWeiss.IsChecked = True) Then StandardAusgabe.Check Else SchwarzWeiss.Check + bTempRadioBut(1) = StandardAusgabe.IsChecked + bTempRadioBut(2) = Graustufen.IsChecked + bTempRadioBut(3) = SchwarzWeiss.IsChecked + if (SeitenKacheln.IsChecked = True) Then Standard.Check Else SeitenKacheln.Check + bRadioBut(4) = Standard.IsChecked + bRadioBut(5) = AnSeitengroesseAnpassen.IsChecked + bRadioBut(6) = SeitenKacheln.IsChecked - printlog "check if all Checked" - ToolsOptions - hToolsOptions (sApplication,"Print") + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK - Standard.Check - If True <> Seitenname.IsChecked Then WarnLog "Print: Page name o" - If True <> Datum.IsChecked Then WarnLog "Print: Date o" - If True <> Zeit.IsChecked Then WarnLog "Print: Time o" - If True <> AusgeblendeteSeitenDrucken.IsChecked Then WarnLog "Print: Hidden pages o" + printlog "check if all Checked" + ToolsOptions + hToolsOptions (sApplication,"Print") - Prospekt.Check - If True <> Vorderseite.IsChecked Then WarnLog "Page options: Brochure: Front o" - If True <> Rueckseite.IsChecked Then WarnLog "Page options: Brochure: Back o" + Standard.Check + If True <> Seitenname.IsChecked Then WarnLog "Print: Page name o" + If True <> Datum.IsChecked Then WarnLog "Print: Date o" + If True <> Zeit.IsChecked Then WarnLog "Print: Time o" + If True <> AusgeblendeteSeitenDrucken.IsChecked Then WarnLog "Print: Hidden pages o" - If True <> AusDruckereinstellung.IsChecked Then WarnLog "Page options: Paper tray from printer settings o" + Prospekt.Check + If True <> Vorderseite.IsChecked Then WarnLog "Page options: Brochure: Front o" + If True <> Rueckseite.IsChecked Then WarnLog "Page options: Brochure: Back o" - If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked) Then WarnLog "Quality: Default state changed" - If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality: Grayscale state changed" - If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality: Black & White state changed" - If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page options: Default state changed" - If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page options: Fit to page state changed" - If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page options: Tile pages state changed" + If True <> AusDruckereinstellung.IsChecked Then WarnLog "Page options: Paper tray from printer settings o" - printlog "restore states" + If ( bTempRadioBut(1) <> StandardAusgabe.IsChecked) Then WarnLog "Quality: Default state changed" + If ( bTempRadioBut(2) <> Graustufen.IsChecked ) Then WarnLog "Quality: Grayscale state changed" + If ( bTempRadioBut(3) <> SchwarzWeiss.IsChecked ) Then WarnLog "Quality: Black & White state changed" + If ( bTempRadioBut(4) <> Standard.IsChecked ) Then WarnLog "Page options: Default state changed" + If ( bTempRadioBut(5) <> AnSeitengroesseAnpassen.IsChecked ) Then WarnLog "Page options: Fit to page state changed" + If ( bTempRadioBut(6) <> SeitenKacheln.IsChecked ) Then WarnLog "Page options: Tile pages state changed" - Standard.Check - If ( irgendwas(1) = TRUE ) Then Seitenname.Check Else Seitenname.UnCheck - If ( irgendwas(2) = TRUE ) Then Datum.Check Else Datum.UnCheck - If ( irgendwas(3) = TRUE ) Then Zeit.Check Else Zeit.UnCheck - If ( irgendwas(4) = TRUE ) Then AusgeblendeteSeitenDrucken.Check Else AusgeblendeteSeitenDrucken.UnCheck + printlog "restore states" - Prospekt.Check - If ( irgendwas(5) = TRUE ) Then Vorderseite.Check Else Vorderseite.UnCheck - If ( irgendwas(6) = TRUE ) Then Rueckseite.Check Else Rueckseite.UnCheck + Standard.Check + If ( irgendwas(1) = TRUE ) Then Seitenname.Check Else Seitenname.UnCheck + If ( irgendwas(2) = TRUE ) Then Datum.Check Else Datum.UnCheck + If ( irgendwas(3) = TRUE ) Then Zeit.Check Else Zeit.UnCheck + If ( irgendwas(4) = TRUE ) Then AusgeblendeteSeitenDrucken.Check Else AusgeblendeteSeitenDrucken.UnCheck - If ( irgendwas(7) = TRUE ) Then AusDruckereinstellung.Check Else AusDruckereinstellung.UnCheck + Prospekt.Check + If ( irgendwas(5) = TRUE ) Then Vorderseite.Check Else Vorderseite.UnCheck + If ( irgendwas(6) = TRUE ) Then Rueckseite.Check Else Rueckseite.UnCheck - If ( bRadioBut(1) = TRUE ) Then StandardAusgabe.Check - If ( bRadioBut(2) = TRUE ) Then Graustufen.Check - If ( bRadioBut(3) = TRUE ) Then SchwarzWeiss.Check - Standard.Check + If ( irgendwas(7) = TRUE ) Then AusDruckereinstellung.Check Else AusDruckereinstellung.UnCheck - Kontext "ExtrasOptionenDlg" - ExtrasOptionenDlg.OK + If ( bRadioBut(1) = TRUE ) Then StandardAusgabe.Check + If ( bRadioBut(2) = TRUE ) Then Graustufen.Check + If ( bRadioBut(3) = TRUE ) Then SchwarzWeiss.Check + Standard.Check - hCloseDocument -endcase 'tToolsOptionsDrawPrint + Kontext "ExtrasOptionenDlg" + ExtrasOptionenDlg.OK + hCloseDocument +endcase 'tToolsOptionsDrawPrint
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/global/id_opt_2.inc b/testautomation/graphics/required/includes/global/id_opt_2.inc index b959b718582c..0d2f050f4916 100644 --- a/testautomation/graphics/required/includes/global/id_opt_2.inc +++ b/testautomation/graphics/required/includes/global/id_opt_2.inc @@ -37,15 +37,15 @@ testcase tToolsOptionsMeasurementUnit (sApplication as string) dim iCount2 as integer dim sUnitOptions as string dim sUnitDialog as string - + hNewDocument - sleep 1 + sleep 1 ToolsOptions hToolsOptions (sApplication,"General") iCount2 = Masseinheit.GetSelIndex printlog "current measurement unit is: " & iCount2 iCount = Masseinheit.GetItemCount - + Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK printlog "----------------------" @@ -56,47 +56,11 @@ testcase tToolsOptionsMeasurementUnit (sApplication as string) for i=1 to iCount ToolsOptions hToolsOptions (sApplication,"General") - Masseinheit.select i sUnitOptions = GetMeasUnit(Tabulatorabstand.getText) ' (1) printlog "(" + i + "/" + iCount + "): '" + Masseinheit.getSelText + "' - " + sUnitOptions + " (1)" - Kontext "ExtrasOptionenDlg" ExtrasOptionenDlg.OK - - FileExport - Kontext "ExportierenDlg" - Dateiname.SetText "adagio" - Dateityp.Select "BMP - Windows Bitmap (.bmp)" - if AutomatischeDateinamenserweiterung.Exists then - AutomatischeDateinamenserweiterung.Check - else - warnlog( "Automatic Filename Extension checkbox is mising" ) - endif - Speichern.Click - kontext "AlienWarning" - if AlienWarning.exists(5) then - warnlog "#i41983# Alien Warning on export not allowed" - AlienWarning.OK - endif - Kontext "Messagebox" - if Messagebox.Exists(2) then - Messagebox.Yes - endif - Sleep 3 - Kontext "BMPOptionen" - Groesse.Check - sUnitDialog = getMeasUnit(Breite.getText) ' (2) - if (getMeasUnit(Hoehe.getText) <> sUnitDialog) then - warnlog " Measurement Unit is different for Width:'" + sUnitDialog + "' and Hight:'" + getMeasUnit(Hoehe.getText) + "'" - else - printlog "Measurement Unit is same for Width:'" + sUnitDialog + "' and Hight:'" + getMeasUnit(Hoehe.getText) + "'" - endif - if (sUnitOptions <> sUnitDialog) then - printlog "#109705# Measurement Unit is different for Options:'" + sUnitOptions + "' and BMP Dialog:'" + sUnitDialog + "' (1) <> (2)" - endif - BMPOptionen.Cancel - Format3D_Effects Kontext "Drei_D_Effekte" Geometrie.Click @@ -107,7 +71,6 @@ testcase tToolsOptionsMeasurementUnit (sApplication as string) printlog "Measurement Unit is same for Options:'" + sUnitOptions + "' and Depth:'" + getMeasUnit(Tiefe.getText) + "' (3)" endif Drei_D_Effekte.close - FormatParagraph Kontext Messagebox.SetPage TabEinzuegeUndAbstaende @@ -119,9 +82,8 @@ testcase tToolsOptionsMeasurementUnit (sApplication as string) printlog "Measurement Unit is same for Options:'" + sUnitOptions + "' and Vonlinks:'" + getMeasUnit(Vonlinks.getText) + "' Paragraph" endif TabEinzuegeUndAbstaende.cancel - next i - + printlog "Setting back measurement to " & iCount2 ToolsOptions hToolsOptions (sApplication,"General") @@ -130,4 +92,4 @@ testcase tToolsOptionsMeasurementUnit (sApplication as string) ExtrasOptionenDlg.OK hCloseDocument -endcase 'tToolsOptionsMeasurementUnit +endcase 'tToolsOptionsMeasurementUnit
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/impress/im_003_.inc b/testautomation/graphics/required/includes/impress/im_003_.inc index 0eec59322e25..4cdd6a595cc6 100644 --- a/testautomation/graphics/required/includes/impress/im_003_.inc +++ b/testautomation/graphics/required/includes/impress/im_003_.inc @@ -130,7 +130,9 @@ testcase tiViewPanes hMenuSelectNr (4) endcase 'tiViewPanes + '--------------------------------------------------------- + testcase tiViewMasterView printlog "open application" Call hNewDocument @@ -150,7 +152,9 @@ testcase tiViewMasterView printlog "close application " Call hCloseDocument endcase 'tiViewMasterView + '--------------------------------------------------------- + testcase tiViewSlideMaster printlog "open application with : File->Autopilot->Presentation; OK; OK " @@ -161,68 +165,57 @@ testcase tiViewSlideMaster else warnlog( "Dialog <AutopilotPraesentation1> did not open" ) endif - Kontext "Seitenlayout" ' aka: Modify Slide - - if ( Seitenlayout.exists( 5 ) ) then - warnlog "Slidelayout has to vanish; moved to sidebar" - hCloseDialog( Seitenlayout, "ok" ) - endif - kontext "DocumentImpress" - printlog "View->Slide " + + printlog "View->Slide" hUseAsyncSlot( "ViewSlide" ) - printlog "View->Master->Drawing " + printlog "View->Master->Drawing" hUseAsyncSlot( "ViewDrawing" ) - printlog "View->Slide " - hUseAsyncSlot( "ViewSlide" ) - - printlog "View->Master->Title " - try - ViewTitle - Errorlog "View - Master - Title Slide Master should NOT be accessable" - catch - printlog "View - Master - Title Slide Master not accessable - good" - endcatch - - printlog "View->Slide " + printlog "View->Slide" hUseAsyncSlot( "ViewSlide" ) - printlog "View->Master->Handout " + printlog "View->Master->Handout" hUseAsyncSlot( "ViewHandout" ) - printlog "View->Master->Notes " + printlog "View->Master->Notes" hUseAsyncSlot( "ViewNotes" ) kontext "DocumentImpress" - printlog "View->Slide " + printlog "View->Slide" hUseAsyncSlot( "ViewSlide" ) + sleep 1 printlog "close application " Call hCloseDocument endcase 'tiViewSlideMaster + '-------------------------------------------------------- + testcase tiViewToolbar_1 const DEFAULT_DELAY = 3 Dim NumberOfGraphicModes as integer Dim iCurrentGraphicsMode as integer - dim TestFile as string + dim i as integer + TestFile = ConvertPath (gTesttoolPath + "global\input\graf_inp\desp.bmp") - printlog "open application " Call hNewDocument - + printlog "use the empty layout" - call sSelectEmptyLayout + Call sSelectEmptyLayout + printlog "delete default content" + hUseAsyncSlot( "EditSelectAll" ) + Kontext "DocumentImpress" + DocumentImpress.typeKeys("<DELETE>",true) printlog "Insert->Graphic... : global\input\graf_inp\desp.bmp " hUseAsyncSlot( "InsertGraphicsFromFile" ) - Kontext "GrafikEinfuegenDlg" if ( GrafikEinfuegenDlg.exists( DEFAULT_DELAY ) ) then Dateiname.SetText( TestFile ) @@ -238,8 +231,17 @@ testcase tiViewToolbar_1 printlog "select graphic " hUseAsyncSlot( "EditSelectAll" ) - Kontext "GraphicObjectbar" printlog "The Graphics Toolbar has to be visible now; If not -> ERROR " + ' workaround for i113609; there should have been a style selected without elements on creating the document - what failed; the elements should have been deleted before inserting the grafik in this test - which failed; so the workaround is to use <tab> to travel to the graphic selection here: + for i=1 to 3 + Kontext "GraphicObjectbar" + if ( not GraphicObjectbar.Exists( DEFAULT_DELAY ) ) Then + hTypeKeys("<tab>") + qaerrorlog "delete default content failed" + end if + next i + + Kontext "GraphicObjectbar" if ( GraphicObjectbar.Exists( DEFAULT_DELAY ) ) Then Printlog "- graphic object toolbar exists" @@ -260,4 +262,4 @@ testcase tiViewToolbar_1 printlog "close application " Call hCloseDocument -endcase 'tiViewToolbar_1 +endcase 'tiViewToolbar_1
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/impress/im_004_.inc b/testautomation/graphics/required/includes/impress/im_004_.inc index 2c55bc4c2f13..38fe040eca56 100644 --- a/testautomation/graphics/required/includes/impress/im_004_.inc +++ b/testautomation/graphics/required/includes/impress/im_004_.inc @@ -41,25 +41,30 @@ end sub testcase tiInsertSlideExpandSummary - printlog "open application " + printlog "open application" Call hNewDocument - printlog "View->Master View->Outline View " + printlog "View->Master View->Outline View" ViewWorkspaceOutlineView - WaitSlot() + Sleep 1 Kontext "DocumentImpressOutlineView" - printlog "Type 2 rows " + printlog "Type 2 rows" DocumentImpressOutlineView.TypeKeys "Herbert<Return>Rudi" - sleep(1) - printlog "View->Master View->Drawing View " + printlog "View->Master View->Drawing View" ViewWorkspaceDrawingView - WaitSlot() - printlog "Insert->Summery Slide " + Sleep 1 + printlog "Insert->Summery Slide" InsertSummerySlide - WaitSlot() - printlog "Insert->Expand Slide " + Sleep 1 + printlog "Making sure we are on the 3rd slide.." + kontext "slides" + SlidesControl.TypeKeys "<PAGEDOWN>", 2 + sleep 1 + kontext "DocumentImpress" + printlog "Insert->Expand Slide" InsertExpandSlide - WaitSlot( 3000 ) - printlog "close application " + Sleep 2 + printlog "close application" Call hCloseDocument -endcase + +endcase 'tiInsertSlideExpandSummary diff --git a/testautomation/graphics/required/includes/impress/im_005_.inc b/testautomation/graphics/required/includes/impress/im_005_.inc index 146d37c0f669..f0703913e068 100644 --- a/testautomation/graphics/required/includes/impress/im_005_.inc +++ b/testautomation/graphics/required/includes/impress/im_005_.inc @@ -43,20 +43,16 @@ testcase tiFormatModifyLayout printlog "open application " Call hNewDocument - printlog( "Format/Page" ) FormatPage - Kontext "SeitenLayout" if ( SeitenLayout.exists( 2 ) ) then DialogTest ( SeitenLayout ) - printlog "cancel dialog 'Page Setup' " hCloseDialog( SeitenLayout, "Cancel" ) else warnlog( "Dialog <SeitenLayout> did not open" ) endif - printlog "close application" Call hCloseDocument diff --git a/testautomation/graphics/required/includes/impress/im_007_.inc b/testautomation/graphics/required/includes/impress/im_007_.inc index 68d271e30d7f..3d6fcbb3f4f5 100644 --- a/testautomation/graphics/required/includes/impress/im_007_.inc +++ b/testautomation/graphics/required/includes/impress/im_007_.inc @@ -95,9 +95,10 @@ testcase tSlideShowSlideShow endcatch printlog "close application " Call hCloseDocument - endcase 'tSlideShowSlideShow + '------------------------------------------------------------------------------- + testcase tSlideShowRehearseTimings goto endsub @@ -139,11 +140,11 @@ testcase tSlideShowRehearseTimings sleep 3 printlog "close application " Call hCloseDocument - endcase 'tSlideShowRehearseTimings + '------------------------------------------------------------------------------- -testcase tSlideShowSlideShowSettings +testcase tSlideShowSlideShowSettings printlog "open application " Call hNewDocument sleep 2 @@ -270,11 +271,11 @@ testcase tSlideShowCustomSlideShow endif printlog "close application " Call hCloseDocument - endcase 'tSlideShowCustomSlideShow + '------------------------------------------------------------------------------ -testcase tSlideShowSlideTransition +testcase tSlideShowSlideTransition dim i as integer dim a as integer dim iCount as integer @@ -326,7 +327,7 @@ testcase tSlideShowSlideTransition if (OeffnenDlg.exists (5)) then printlog "Read all entries in Listbox 'File type' " for i = 1 to Dateityp.getItemCount - printlog "" + i + ":" + Dateityp.getItemText(i) + printlog i + ":" + Dateityp.getItemText(i) next i printlog "cancel dialog 'Open' " OeffnenDlg.cancel @@ -375,7 +376,9 @@ testcase tSlideShowSlideTransition Call hCloseDocument endcase 'tSlideShowSlideTransition + '------------------------------------------------------------------------------- + testcase tSlideShowShowHideSlide printlog "open application " @@ -392,7 +395,9 @@ testcase tSlideShowShowHideSlide SlideShowShowSlide printlog "close application " Call hCloseDocument -endcase +endcase 'tSlideShowShowHideSlide + +'------------------------------------------------------------------------------- testcase tSlideShowAnimation printlog "open application " @@ -478,9 +483,10 @@ testcase tSlideShowAnimation Call hCloseDocument endcase 'tSlideShowShowHideSlide + '------------------------------------------------------------------------------- -testcase tSlideShowCustomAnimation +testcase tSlideShowCustomAnimation dim bError as boolean printlog "open application" @@ -641,7 +647,9 @@ testcase tSlideShowCustomAnimation Call hCloseDocument endcase 'tSlideShowCustomAnimation + '------------------------------------------------------------------------------- + testcase tSlideShowInteraction printlog "open application " @@ -732,4 +740,4 @@ testcase tSlideShowInteraction printlog "close application " Call hCloseDocument -endcase 'tSlideShowInteraction +endcase 'tSlideShowInteraction
\ No newline at end of file diff --git a/testautomation/graphics/required/includes/impress/im_011_.inc b/testautomation/graphics/required/includes/impress/im_011_.inc index 2c505f5facc2..28e58ee2e6e7 100644 --- a/testautomation/graphics/required/includes/impress/im_011_.inc +++ b/testautomation/graphics/required/includes/impress/im_011_.inc @@ -177,4 +177,4 @@ testcase tiDiaLeiste Call hCloseDocument sleep 2 -endcase 'tiDiaLeiste +endcase 'tiDiaLeiste
\ No newline at end of file diff --git a/testautomation/graphics/required/input/recht_1.odg b/testautomation/graphics/required/input/recht_1.odg Binary files differindex 7463fbaf16ef..720c437fad93 100755 --- a/testautomation/graphics/required/input/recht_1.odg +++ b/testautomation/graphics/required/input/recht_1.odg diff --git a/testautomation/graphics/required/input/recht_1.odp b/testautomation/graphics/required/input/recht_1.odp Binary files differindex 24442ce94654..fbad5296d1b1 100755 --- a/testautomation/graphics/required/input/recht_1.odp +++ b/testautomation/graphics/required/input/recht_1.odp diff --git a/testautomation/graphics/required/input/recht_3.odg b/testautomation/graphics/required/input/recht_3.odg Binary files differindex c2f3461b9877..b2df97654ead 100755 --- a/testautomation/graphics/required/input/recht_3.odg +++ b/testautomation/graphics/required/input/recht_3.odg diff --git a/testautomation/graphics/required/input/recht_3.odp b/testautomation/graphics/required/input/recht_3.odp Binary files differindex 768fbad4b780..84ab26098ca7 100644..100755 --- a/testautomation/graphics/required/input/recht_3.odp +++ b/testautomation/graphics/required/input/recht_3.odp diff --git a/testautomation/graphics/required/input/recht_31.odg b/testautomation/graphics/required/input/recht_31.odg Binary files differindex abe6d48edee1..e7b1c456163e 100755 --- a/testautomation/graphics/required/input/recht_31.odg +++ b/testautomation/graphics/required/input/recht_31.odg diff --git a/testautomation/graphics/required/input/recht_31.odp b/testautomation/graphics/required/input/recht_31.odp Binary files differindex 23f5c77c141d..4f74eee30cb4 100644..100755 --- a/testautomation/graphics/required/input/recht_31.odp +++ b/testautomation/graphics/required/input/recht_31.odp diff --git a/testautomation/graphics/required/input/recht_33.odg b/testautomation/graphics/required/input/recht_33.odg Binary files differindex 1288c85f2e97..03b6119a0157 100755 --- a/testautomation/graphics/required/input/recht_33.odg +++ b/testautomation/graphics/required/input/recht_33.odg diff --git a/testautomation/graphics/required/input/recht_33.odp b/testautomation/graphics/required/input/recht_33.odp Binary files differindex c6acada2537e..c49571f517e2 100644..100755 --- a/testautomation/graphics/required/input/recht_33.odp +++ b/testautomation/graphics/required/input/recht_33.odp diff --git a/testautomation/graphics/required/input/recht_34.odg b/testautomation/graphics/required/input/recht_34.odg Binary files differindex b3fd1da6db78..5789dd14fb07 100755 --- a/testautomation/graphics/required/input/recht_34.odg +++ b/testautomation/graphics/required/input/recht_34.odg diff --git a/testautomation/graphics/required/input/recht_34.odp b/testautomation/graphics/required/input/recht_34.odp Binary files differindex 2dcbd561f9e5..fec4da84f204 100644..100755 --- a/testautomation/graphics/required/input/recht_34.odp +++ b/testautomation/graphics/required/input/recht_34.odp diff --git a/testautomation/graphics/required/input/recht_36.odg b/testautomation/graphics/required/input/recht_36.odg Binary files differindex 81951c928e8f..a328b9827ca6 100755 --- a/testautomation/graphics/required/input/recht_36.odg +++ b/testautomation/graphics/required/input/recht_36.odg diff --git a/testautomation/graphics/required/input/recht_36.odp b/testautomation/graphics/required/input/recht_36.odp Binary files differindex 45f7fd3a47cb..318c75fb17d9 100644..100755 --- a/testautomation/graphics/required/input/recht_36.odp +++ b/testautomation/graphics/required/input/recht_36.odp diff --git a/testautomation/graphics/required/input/recht_39.odg b/testautomation/graphics/required/input/recht_39.odg Binary files differindex 0ef147755258..6f0404a13e72 100755 --- a/testautomation/graphics/required/input/recht_39.odg +++ b/testautomation/graphics/required/input/recht_39.odg diff --git a/testautomation/graphics/required/input/recht_39.odp b/testautomation/graphics/required/input/recht_39.odp Binary files differindex bf649b488030..777844272121 100644..100755 --- a/testautomation/graphics/required/input/recht_39.odp +++ b/testautomation/graphics/required/input/recht_39.odp diff --git a/testautomation/graphics/required/input/recht_46.odg b/testautomation/graphics/required/input/recht_46.odg Binary files differindex 1ad25dad2739..35abb966363b 100755 --- a/testautomation/graphics/required/input/recht_46.odg +++ b/testautomation/graphics/required/input/recht_46.odg diff --git a/testautomation/graphics/required/input/recht_46.odp b/testautomation/graphics/required/input/recht_46.odp Binary files differindex e9de83b58c8b..2c73a2a83371 100644..100755 --- a/testautomation/graphics/required/input/recht_46.odp +++ b/testautomation/graphics/required/input/recht_46.odp diff --git a/testautomation/graphics/required/input/recht_48.odg b/testautomation/graphics/required/input/recht_48.odg Binary files differindex 1e3206ffcd7d..ec17c200c483 100755 --- a/testautomation/graphics/required/input/recht_48.odg +++ b/testautomation/graphics/required/input/recht_48.odg diff --git a/testautomation/graphics/required/input/recht_48.odp b/testautomation/graphics/required/input/recht_48.odp Binary files differindex f836b0521f8b..6350630495fb 100644..100755 --- a/testautomation/graphics/required/input/recht_48.odp +++ b/testautomation/graphics/required/input/recht_48.odp diff --git a/testautomation/graphics/required/input/recht_48.sxd b/testautomation/graphics/required/input/recht_48.sxd Binary files differdeleted file mode 100755 index ef01f9ff9b9f..000000000000 --- a/testautomation/graphics/required/input/recht_48.sxd +++ /dev/null diff --git a/testautomation/graphics/required/input/recht_48.sxi b/testautomation/graphics/required/input/recht_48.sxi Binary files differdeleted file mode 100755 index bdbd34003ebb..000000000000 --- a/testautomation/graphics/required/input/recht_48.sxi +++ /dev/null diff --git a/testautomation/graphics/required/input/recht_49.odg b/testautomation/graphics/required/input/recht_49.odg Binary files differindex 0898a8b99a5c..d3bd17ae64b2 100755 --- a/testautomation/graphics/required/input/recht_49.odg +++ b/testautomation/graphics/required/input/recht_49.odg diff --git a/testautomation/graphics/required/input/recht_49.odp b/testautomation/graphics/required/input/recht_49.odp Binary files differindex 88c93c2856b4..d8c6e495c4f5 100644..100755 --- a/testautomation/graphics/required/input/recht_49.odp +++ b/testautomation/graphics/required/input/recht_49.odp diff --git a/testautomation/graphics/required/input/recht_55.odg b/testautomation/graphics/required/input/recht_55.odg Binary files differindex fc21ecba132a..6f4f649b13c0 100755 --- a/testautomation/graphics/required/input/recht_55.odg +++ b/testautomation/graphics/required/input/recht_55.odg diff --git a/testautomation/graphics/required/input/recht_55.odp b/testautomation/graphics/required/input/recht_55.odp Binary files differindex 6e78d94e8c49..001e79a700f7 100644..100755 --- a/testautomation/graphics/required/input/recht_55.odp +++ b/testautomation/graphics/required/input/recht_55.odp diff --git a/testautomation/graphics/tools/id_tools.inc b/testautomation/graphics/tools/id_tools.inc index c774710c89fa..57bac12e8ce8 100644 --- a/testautomation/graphics/tools/id_tools.inc +++ b/testautomation/graphics/tools/id_tools.inc @@ -104,10 +104,10 @@ function LiberalMeasurement ( sShould$, sActual$) as Boolean printlog "took units from http://gsl.openoffice.org/source/browse/gsl/vcl/source/src/units.src" select case GetMeasUnit(sShould$) case "mm", "ミリ", "公厘" : iTolerance = 2.0 '01, 81, 88 - case "cm","センチ","厘米","公分" : iTolerance = 0.5 '01, 81, 86, 88 + case "cm","セン?","厘米","公分" : iTolerance = 0.5 '01, 81, 86, 88 case chr$(34) : iTolerance = 2.5 case "pi","ピクセル" : iTolerance = 2.5 '01, 81 - case "pt", "ポイント" : iTolerance = 2.5 '01, 81 + case "pt", "?イント" : iTolerance = 2.5 '01, 81 case "" : iTolerance = 1.5 ' cm is presubposition in old functions case else iTolerance = 2.5 @@ -264,51 +264,51 @@ function fMakeDocumentWritable() as boolean printlog "Document is already writable." fMakeDocumentWritable = true endif - + sleep(1) end function '------------------------------------------------------------------------------- - -function fGetSizeXY (sX as string, sY as string, bRetrieveOnly as boolean) as Boolean - - const RC_FAILURE = -1 - +function fGetSizeXY (sX as string, sY as string, bGet as boolean) as Boolean dim sTx as string dim sTy as string + dim bReturn as boolean - fGetSizeXY() = True - - if ( hUseAsyncSlot( "ContextPositionAndSize" ) <> RC_FAILURE ) then - - kontext - active.SetPage TabPositionAndSize - - kontext "TabPositionAndSize" - if ( TabPositionAndSize.exists( 2 ) ) then - sTx = Width.GetText() - sTy = Height.GetText() - hCloseDialog( TabPositionAndSize, "ok" ) - else - warnlog "Couldn't switch tab page :-( " + bReturn = True + try + printlog "Trying to open Position and size Dialog.." + ContextPositionAndSize + catch + warnlog "couldn't call 'ContextPositionAndSize' no object selected ?" + endcatch + kontext + active.SetPage TabPositionAndSize + kontext "TabPositionAndSize" + printlog "Getting some sizes from Position and Size dialog." + if TabPositionAndSize.exists (5) then + sTx = Width.GetText + printlog "Width, sTx=" & sTx + sTy = Height.GetText + printlog "Height, sTy=" & sTy + TabPositionAndSize.OK + else + warnlog "Couldn't switch tab page :-( " + endif + if bGet then ' Get the Values only + sY = sTy + printlog "sY=" & sY + sX = sTx + printlog "sX=" & sX + else ' Get the Values and COMPARE them + if (LiberalMeasurement (sX,sTx) <> TRUE) then + warnlog "width is different :-( XXXXXXXXXXXXX should: '"+sX+"' is: '"+sTx+"'" + "eventually a result of i35519" + bReturn = False endif - - if ( bRetrieveOnly ) then ' Get the Values only - sY = sTy - sX = sTx - else ' Get the Values and compare them - if ( not LiberalMeasurement (sX,sTx) ) then - warnlog "width is different :-( should: '"+sX+"' is: '"+sTx+"'" + "eventually a result of i35519" - fGetSizeXY() = False - endif - if (not LiberalMeasurement (sY,sTy) ) then - warnlog "hight is different :-( should: '"+sY+"' is: '"+sTy+"'" + "eventually a result of i35519" - fGetSizeXY() = False - endif + if (LiberalMeasurement (sY,sTy) <> TRUE) then + warnlog "hight is different :-( xxxxxxxxxxxx should: '"+sY+"' is: '"+sTy+"'" + "eventually a result of i35519" + bReturn = False endif - else - warnlog( "Failed to open <Position And Size> dialog" ) + bGet = bReturn endif - end function '------------------------------------------------------------------------- diff --git a/testautomation/graphics/tools/id_tools_2.inc b/testautomation/graphics/tools/id_tools_2.inc index 435e58a73928..60836bdb274a 100644 --- a/testautomation/graphics/tools/id_tools_2.inc +++ b/testautomation/graphics/tools/id_tools_2.inc @@ -181,56 +181,6 @@ sub sPrintCheckOrder (optional bcheck as boolean) Printlog "-----------------------------------" end sub -'--------------------------- Tests for Writer ---------------------------------- -sub writertest - - try - call Make_And_Check_Formatted_Text_Line_From_Application - catch - warnlog "Something went wrong with testing writertest" - endcatch - - try - call Make_Rectangle_From_Application - call Full_test_Draw - call Full_test_Impress - call Full_test_Writer - call Full_test_Calc - catch - warnlog "something wrong with testing writertest" - endcatch -end sub ' big one - -'---------------------------- Tests for Calc ----------------------------------- -sub calctest - - try - call Make_Rectangle_From_Application - call Full_test_Draw - call Full_test_Impress - call Full_test_Writer - call Full_test_Calc - catch - warnlog "something wrong with calctest" - endcatch - printlog "currently no specific tests from Calc" -end sub - -'------------------------------------------------------------------------------- -sub tClipboardFromDrawTest - - EnableQAErrors = false - FromApp2 = gApplication - printlog "gApplication = " + gApplication - - select case( gApplication ) - case "WRITER" : call writertest() - case "CALC" : call calctest() - case else : warnlog( "Unsupported gApplication provided: " & gApplication ) - end select - -end sub - '------------------------------------------------------------------------------- sub Select_Copy @@ -621,212 +571,7 @@ sub GetOnlyGraphics ( OldList() as String, NewList() as String ) end if next i end sub - -'------------------------------------------------------------------------- -sub id_001 - - printLog Chr(13) + "--------- id_001 ----------" - - qaerrorlog "#74988# tiFilePassword outcommented due to bug. -FHA" - call tiFilePassword - call tiFileSaveAs - call tiFileReload - call tiFileVersion - printlog " File->Send not possible to test, because extrnal prg get's called!" - call tiFileTemplates - ' Call tiFileNew instead i call: - call tmFileNewFromTemplate - call tmFileOpen - call tmFileClose - call tmFileSave - call tmFileSaveAs - call tmFileExit - - call tmFileSaveAll - call tmFileProperties - call tdFileExport - call tmFilePrinterSetting - ' special cases - ' Call AutoPilot 'inc\desktop\autopilo.inc - call tmFileExit ' don't test because unpredictable behaviour -end sub - -'------------------------------------------------------------------------------ -sub id_002 - - printLog Chr(13) + "--------- id_002 ----------" - - call tiEditUndoRedo - call tiEditRepeat - call tiEditCutPasteCopySelectall - call tiEditPasteSpecial - call tiEditSearchAndReplace - call tiEditDuplicate - call tEditPoints - call tiEditFields - call tdEditDeleteSlide - call tiEditLinks - call tiEditImageMap - call tiEditObjectProperties - call tiEditObjectEdit - call tiEditPlugIn - call tiEditHyperlink -end sub - -'------------------------------------------------------------------------- -sub id_003 - - printLog Chr(13) + "--------- id_003 ----------" - - call tiViewNavigator - call tiViewZoom - call tiViewToolbar - Call tToolsCustomize 'global\required\include - call tiViewDisplayQuality - call tiViewLayer - call tViewSnapLines - call tViewGrid -end sub - -'------------------------------------------------------------------------- -sub id_004 - - printLog Chr(13) + "--------- id_004 ----------" - - call tiInsertSlide - call tiInsertDuplicateSlide - ' v expand slide - ' v summary slide - call tiInsertField - call tiInsertSpecialCharacter - call tiInsertHyperlink - call tiInsertScan - call tiInsertGraphic - call tiInsertObjectSound - call tiInsertObjectVideo - call tiInsertObjectSound - call tiInsertObjectVideo - call tiInsertChart - call tiInsertObjectOLEObjects - call tiInsertSpreadsheet - call tiInsertFormula - call tiInsertFloatingFrame - call tiInsertFile - call tiInsertPlugin - call tiInsertSnappointLine - call tdInsertLayer ' IMPRESS: Edit->Layer->Insert -end sub - -'------------------------------------------------------------------------------ -sub id_005 - - printLog Chr(13) + "--------- id_005 ----------" - - call tiFormatDefault - call tiFormatLine - call tdFormatArea - call tiFormatText - call tiFormatPositionAndSize - call tiFormatCharacter - call tiFormatControlForm - ' ^ Form - call tiFormatDimensions - call tiFormatConnector - call tiFormat3D_Effects - call tiFormatNumberingBullets - call tiFormatCaseCharacter - call tiFormatParagraph - call tiFormatPage - call tiFormatStylesAndFormatting - call tiFormatStylesSlideDesign - call tiFormatFontwork - call tiFormatGroup - printlog " format->group is also modify->group " - ' tiFormatLayer ' not in impress -end sub - -'------------------------------------------------------------------------------ -sub id_006 - - printLog Chr(13) + "--------- id_006 ----------" - - call tiToolsSpellchecking - call tiToolsSpellcheckingAutomatic - call tiToolsThesaurus - call tiToolsHyphenation - call tiToolsAutoCorrect - call tChineseTranslation - call tiToolsMacro - call tiToolsGallery - call tiToolsEyedropper - call tiToolsOptions ' get just called one time here... - Call tToolsOptionsTest ' global one -end sub - '------------------------------------------------------------------------------- -sub id_007 - - printLog Chr(13) + "--------- id_007 ----------" - ' in imp available via context menu, in draw via modify menu - - call tdModifyFlipVertikal - call tdModifyFlipHorizontal - call tdContextConvertIntoCurve - call tdContextConvertIntoPolygon - call tdContextConvertIntoContour - call tdContextConvertInto3D - call tdContextConvertIntoRotationObject - call tdContextConvertIntoBitmap - call tdContextConvertIntoMetaFile - call tdModifyArrange - call tdModifyArrangeObjects - call tdModifyAlignment - call tdContextDistribution - call tdContextDescriptionObject - call tdContextNameObject - call tdModifyConnectBreak - call tdModifyShapes - call tdModifyCombineSplit -end sub - -'------------------------------------------------------------------------------- -sub id_008 - - printLog Chr(13) + "--------- id_008 ----------" - - Call tiWindowNewWindow - call tidWindow123 -end sub - -'------------------------------------------------------------------------------ -sub id_009 - - printLog Chr(13) + "--------- id_009 ----------" - - call tCheckIfTheHelpExists - Call tmHelpContents - Call tmHelpHelpAgent - Call tmHelpTips - Call tmHelpExtendedTips - Call tmHelpAboutStarOffice - -end sub - -'------------------------------------------------------------------------------ -sub id_011 - - printLog Chr(13) + "--------- id_011 ----------" - - call tdBezierToolbar - call tiDrawObjectBar - call tiTextToolbar - call tiGraphicsObjectBar - call tiGluepointToolbar - -end sub - -'-------------------------------------------------------------------------------' - sub hWalkTheStyles (optional a as integer,optional b as integer) dim i as integer @@ -992,4 +737,4 @@ sub sSelectEmptyLayout else printlog "No change of Layout needed." endif -end sub
\ No newline at end of file +end sub diff --git a/testautomation/graphics/tools/makeLokaleTxt.bas b/testautomation/graphics/tools/makeLokaleTxt.bas index 687822938dd7..59e66af87ff6 100644..100755 --- a/testautomation/graphics/tools/makeLokaleTxt.bas +++ b/testautomation/graphics/tools/makeLokaleTxt.bas @@ -31,9 +31,9 @@ '* '\****************************************************************** -'/// run this script, if you are testing a new language. ///' -'/// it will add all relevant strings to the file qatesttool/graphics/tools/locale_1.txt ///' -'/// you just have to make sure, that every language only appears once in the file! ///' +printlog "Run this script, if you are testing a new language." +printlog "it will add all relevant strings to the file qatesttool/graphics/tools/locale_1.txt " +printlog "you just have to make sure, that every language only appears once in the file! " public glLocale (15*20) as string public S1 as string @@ -54,13 +54,6 @@ sub main warnlog "Locales file doesn't exist: '" + gTesttoolPath + "graphics\tools\locale_1.txt'" endif - 'Handouts - 'Slide - 'Default - 'English (USA) - 'Background - 'German (Germany) - printlog "Current saved strings are: " printlog "O 1: " + glLocale (1) 'Handouts ' im_103.inc::tViewWorkspaceHandoutView printlog "O 2: " + glLocale (2) 'Slide ' impress/slideshow.inc:: @@ -69,7 +62,7 @@ sub main printlog "O 5: " + glLocale (5) 'Background printlog "O 6: " + glLocale (6) 'German (Germany) - '/// LOCALE Slide - 2 ///' + printlog "LOCALE Slide - 2 " S1 = glLocale (2) + " 1" S2 = glLocale (2) + " 2" S3 = glLocale (2) + " 3" @@ -83,14 +76,15 @@ sub main ' hMenuSelectNr(3) ' hMenuSelectNr(11) ' printlog hMenuItemGetText (4) - ' ViewWorkspaceHandoutView '/// view background handout ///' + ' printlog "view background handout" + ' ViewWorkspaceHandoutView ' sleep 2 ' FormatPage sleep 2 glLocale (1) = "Dummy" 'Seitenname.GetText Printlog "L1: '" + glLocale (1) + "'" '3 Seitenlayout.Close - ' ViewWorkspaceDrawingView '/// back to view background drawing ///' + ' ViewWorkspaceDrawingView '(2)tSlideShowInteraction/fGetSlideName Kontext "Navigator" |