summaryrefslogtreecommitdiff
path: root/testautomation/writer
diff options
context:
space:
mode:
Diffstat (limited to 'testautomation/writer')
-rw-r--r--testautomation/writer/optional/includes/drawing/w_drawing_tools2.inc37
-rw-r--r--testautomation/writer/optional/includes/fields/w_fields1.inc12
-rw-r--r--testautomation/writer/required/includes/w_001b_.inc1
-rwxr-xr-xtestautomation/writer/tools/includes/w_tools.inc24
4 files changed, 56 insertions, 18 deletions
diff --git a/testautomation/writer/optional/includes/drawing/w_drawing_tools2.inc b/testautomation/writer/optional/includes/drawing/w_drawing_tools2.inc
index 25a762297df7..08ebbfed45d4 100644
--- a/testautomation/writer/optional/includes/drawing/w_drawing_tools2.inc
+++ b/testautomation/writer/optional/includes/drawing/w_drawing_tools2.inc
@@ -283,7 +283,7 @@ testcase tGroup_6
Sleep 2
Call gMouseClick(80,80)
- Call wObjektSelektieren ( 28, 28, 70, 80 )
+ Call wObjektSelektieren ( 31, 31, 70, 80 )
Sleep 2
FormatGroupGroup
Sleep 1
@@ -351,7 +351,7 @@ testcase tGroup_7
Sleep 2
Call gMouseClick(80,80)
- Call wObjektSelektieren ( 28, 28, 70, 80 )
+ Call wObjektSelektieren ( 31, 31, 70, 80 )
Sleep 2
FormatGroupGroup
Sleep 1
@@ -667,7 +667,7 @@ testcase tEncapsulatedGroup_1
Sleep 1
Call wZeichenobjektEinfuegen("ELLIPSE", 40, 45, 60, 70, false)
Sleep 1
- Call wObjektSelektieren ( 28, 28, 70, 80 )
+ Call wObjektSelektieren ( 31, 31, 70, 80 )
Sleep 1
FormatGroupGroup
@@ -677,20 +677,37 @@ testcase tEncapsulatedGroup_1
PrintLog "- insert 2 drawing objects (rectangle and ellipse) in the group"
Call wZeichenobjektEinfuegen("RECHTECK", 35, 40, 38, 45, false)
- Call wZeichenobjektEinfuegen("ELLIPSE", 52, 40, 78, 45, false)
- Call wObjektSelektieren ( 28, 38, 80, 48 )
+ Call wZeichenobjektEinfuegen("ELLIPSE", 40, 40, 58, 45, false, true)
+ Call wObjektSelektieren ( 31, 31, 80, 80 )
+
+ Sleep 1
+ PrintLog "- generate a new group"
try
- PrintLog "- generate a new group"
FormatGroupGroup
- PrintLog "- edit the new group"
+ catch
+ Warnlog "Unable to execute Format / Group"
+ endcatch
+
+ PrintLog "- edit the new group"
+ try
FormatGroupEditGroup
- PrintLog "- leave the new group"
+ catch
+ Warnlog "Unable to execute Group / Enter Group"
+ endcatch
+
+ PrintLog "- leave the new group"
+ try
FormatGroupExitGroup
- PrintLog "- Undo the new group"
+ catch
+ Warnlog "Unable to exceute Format / Exit Group"
+ endcatch
+
+ PrintLog "- Undo the new group"
+ try
FormatGroupUnGroup
catch
- Warnlog "Something wrong where operating the Encapsulated group!"
+ Warnlog "Unable to execute Format / Ungroup"
endcatch
Call hCloseDocument
diff --git a/testautomation/writer/optional/includes/fields/w_fields1.inc b/testautomation/writer/optional/includes/fields/w_fields1.inc
index 2f727260b6c2..c6caf2c5fade 100644
--- a/testautomation/writer/optional/includes/fields/w_fields1.inc
+++ b/testautomation/writer/optional/includes/fields/w_fields1.inc
@@ -151,13 +151,23 @@ testcase tInsertFieldsTime
if NOT Len(sTime2) > 7 then Warnlog "Time-format is wrong !"
printlog "Stop for a while ..."
+
'/// Stop for a while , check if the time is still correct
Sleep 2
+ ' update fields
+ Call wTypeKeys "<F9>"
+ ' read field content
Call wTypeKeys "<MOD1 Home>"
Call wTypeKeys "<Shift Right>"
EditCopy
if GetClipboard <> sTime1 then Warnlog "Fixed time is wrong !"
-
+
+ '/// Stop for a while , check if the time is still correct
+ Sleep 2
+ ' update fields
+ Call wTypeKeys "<F9>"
+ ' read field content
+ Call wTypeKeys "<MOD1 Home>"
Call wTypeKeys "<Down><Home>"
Call wTypeKeys "<Shift Right>"
EditCopy
diff --git a/testautomation/writer/required/includes/w_001b_.inc b/testautomation/writer/required/includes/w_001b_.inc
index 297d04b579bb..4d8e6883891a 100644
--- a/testautomation/writer/required/includes/w_001b_.inc
+++ b/testautomation/writer/required/includes/w_001b_.inc
@@ -198,6 +198,7 @@ testcase tFileSendOutlineToClipboard
PrintLog "Paste outline in new document"
hUseAsyncSlot( "EditPaste" )
+ WaitSlot(1000)
Call wTypeKeys("<Up>", 6)
Call wTypeKeys("<Home><Shift End>")
hUseAsyncSlot( "EditCopy" )
diff --git a/testautomation/writer/tools/includes/w_tools.inc b/testautomation/writer/tools/includes/w_tools.inc
index e6bd4f92afa0..cfe0aa6e07f3 100755
--- a/testautomation/writer/tools/includes/w_tools.inc
+++ b/testautomation/writer/tools/includes/w_tools.inc
@@ -141,11 +141,14 @@ end function
' -----------------------------------------------------------------------
-sub wZeichenobjektEinfuegen ( Objekt$, xStart%, yStart%, xEnde%, yEnde%, optional sCloseToolbar as boolean )
+sub wZeichenobjektEinfuegen ( Objekt$, xStart%, yStart%, xEnde%, yEnde%, optional sCloseToolbar as boolean, optional bLeaveSelected as boolean )
Kontext "DrawBar"
if Not DrawBar.Exists then Call hToolbarSelect("Drawing", true)
Sleep 2
+ if IsMissing(bLeaveSelected) then
+ bLeaveSelected = false
+ endif
Objekt = UCase( Objekt )
select case Objekt
@@ -187,8 +190,10 @@ sub wZeichenobjektEinfuegen ( Objekt$, xStart%, yStart%, xEnde%, yEnde%, optiona
end if
if Objekt <> "TEXT" and Objekt <> "VTEXT" then
Kontext "DocumentWriter"
- Call gMouseClick (10, 10)
- wait 100
+ if bLeaveSelected = false then
+ Call gMouseClick (10, 10)
+ wait 100
+ endif
end if
Case "MASTERDOCUMENT"
@@ -205,8 +210,10 @@ sub wZeichenobjektEinfuegen ( Objekt$, xStart%, yStart%, xEnde%, yEnde%, optiona
end if
if Objekt <> "TEXT" and Objekt <> "VTEXT" then
Kontext "DocumentMasterDoc"
- Call gMouseClick (10, 10)
- wait 100
+ if bLeaveSelected = false then
+ Call gMouseClick (10, 10)
+ wait 100
+ endif
end if
end select
sleep (1)
@@ -215,18 +222,21 @@ end sub
' -----------------------------------------------------------------------
sub wObjektSelektieren ( xStart%, yStart%, xEnde%, yEnde% )
- ' Call gMouseClick(90,90)
Call hToolbarSelect("DRAWING",true)
- Auswahl.Click
+ if Auswahl.Getstate(2) = 0 then
+ Auswahl.Click
+ endif
Select Case gApplication
Case "WRITER"
Kontext "DocumentWriter"
DocumentWriter.MouseDown xStart%, yStart%
+ wait 500
DocumentWriter.MouseMove xEnde%, yEnde%
DocumentWriter.MouseUp xEnde%, yEnde%
Case "MASTERDOCUMENT"
Kontext "DocumentMasterDoc"
DocumentMasterDoc.MouseDown xStart%, yStart%
+ wait 500
DocumentMasterDoc.MouseMove xEnde%, yEnde%
DocumentMasterDoc.MouseUp xEnde%, yEnde%
end select