From 732ae0b92b9d0973d12f9020a4eb6aae0cae016e Mon Sep 17 00:00:00 2001 From: "Wolfram Garten [wg]" Date: Wed, 19 Jan 2011 10:49:18 +0100 Subject: i116396: [Automation]: adapt the Impress/Draw autotests for removed binfilter export --- .../graphics/optional/includes/global/g_clipboard.inc | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'testautomation/graphics') diff --git a/testautomation/graphics/optional/includes/global/g_clipboard.inc b/testautomation/graphics/optional/includes/global/g_clipboard.inc index d43c49610..d3ff4cdcf 100644 --- a/testautomation/graphics/optional/includes/global/g_clipboard.inc +++ b/testautomation/graphics/optional/includes/global/g_clipboard.inc @@ -30,15 +30,6 @@ '* short description : '* '************************************************************************************** -' #1 tiEditUndo -' #1 tiEditRedo -' #1 tiEditClipboard -' #1 tiEditPasteSpecial_HTML -' #1 tdEditPasteSpecial_Text -' #1 tdEditPasteSpecial_Graphic -' #1 tdEditPasteSpecial_Circle -' #1 tiEditPasteSpecial -'\************************************************************************************* testcase tiEditUndo @@ -128,6 +119,7 @@ testcase tiEditUndo end if TabPositionAndSize.Cancel printlog "Close document" + Call hCloseDocument sLocaltestfile = hFileGetLocalPath( gTesttoolPath + "leer."+ExtensionString ) printlog sLocaltestfile if (FileExists (sLocaltestfile)) then @@ -137,8 +129,7 @@ testcase tiEditUndo warnlog "File is missing." endif - printlog "Close document" - Call hCloseDocument + printlog "Close document" endcase 'tiEditUndo -- cgit v1.2.3 From aead8870a450761db8aab5b76d16e09361a3d7a3 Mon Sep 17 00:00:00 2001 From: "Wolfram Garten [wg]" Date: Wed, 19 Jan 2011 10:50:24 +0100 Subject: i116396: [Automation]: adapt the Impress/Draw autotests for removed binfilter export --- .../graphics/required/includes/global/id_001.inc | 162 ++++++++++++++------- 1 file changed, 108 insertions(+), 54 deletions(-) (limited to 'testautomation/graphics') diff --git a/testautomation/graphics/required/includes/global/id_001.inc b/testautomation/graphics/required/includes/global/id_001.inc index fee150c83..b87827896 100644 --- a/testautomation/graphics/required/includes/global/id_001.inc +++ b/testautomation/graphics/required/includes/global/id_001.inc @@ -105,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 - 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 "" - DateiAuswahl.TypeKeys "" - if i <> 1 then - DateiAuswahl.TypeKeys "", (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 "" + DateiAuswahl.TypeKeys "" + if i <> 1 then + DateiAuswahl.TypeKeys "", (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 "" + DateiAuswahl.TypeKeys "" + if i <> 1 then + DateiAuswahl.TypeKeys "", (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 -- cgit v1.2.3