summaryrefslogtreecommitdiff
path: root/testautomation/framework/optional/includes/ole_1.inc
diff options
context:
space:
mode:
authorskotti <skotti@buster.gleitmeier.de>2009-11-26 15:39:08 +0100
committerskotti <skotti@buster.gleitmeier.de>2009-11-26 15:39:08 +0100
commitd839e25d30e4dbb2400ab07eca19b1b4e45d1287 (patch)
tree96117ee63a88d6d220d882f7ada1b77976a8853e /testautomation/framework/optional/includes/ole_1.inc
parentf38a1aaef3b8eb830078d68de6f8db7f3fab2950 (diff)
sb111: <no issue> remove some sleep statements, resolve potential timing issues, add slots to hUseAsyncSlot()
Diffstat (limited to 'testautomation/framework/optional/includes/ole_1.inc')
-rwxr-xr-xtestautomation/framework/optional/includes/ole_1.inc74
1 files changed, 41 insertions, 33 deletions
diff --git a/testautomation/framework/optional/includes/ole_1.inc b/testautomation/framework/optional/includes/ole_1.inc
index 050a78b0fc6c..8a17a233f5d6 100755
--- a/testautomation/framework/optional/includes/ole_1.inc
+++ b/testautomation/framework/optional/includes/ole_1.inc
@@ -47,13 +47,13 @@ testcase tOLEWriter
Call hNewDocument
PrintLog "- Writer : Chart without table"
- InsertObjectChart
- sleep(4)
+ hUseAsyncSlot( "InsertObjectChart" )
+
Kontext "DocumentChart"
- if DocumentChart.Exists(5) then
+ if ( DocumentChart.Exists( 5 ) ) then
FormatChartType
Kontext "ChartType"
- if ChartType.Exists(5) then
+ if ( ChartType.Exists( 5 ) ) then
ChartType.Cancel
else
warnlog "Chart Type dialog did bot occour."
@@ -62,18 +62,22 @@ testcase tOLEWriter
DocumentChart.TypeKeys "<ESCAPE>"
Kontext "DocumentWriter"
DocumentWriter.TypeKeys "<DELETE>"
- sleep(1)
else
warnlog "Chart has not been inserted."
end if
- sleep(4)
+
PrintLog "- Writer : Chart out of a table only with numbers"
- InsertTableWriter
+ hUseAsyncSlot( "InsertTableWriter" )
Kontext "TabelleEinfuegenWriter"
- Spalten.SetText "3"
- Zeilen.SetText "10"
- TabelleEinfuegenWriter.OK
+ if ( TabelleEinfuegenWriter.exists( 1 ) ) then
+ Spalten.SetText "3"
+ Zeilen.SetText "10"
+ TabelleEinfuegenWriter.OK
+ TabelleEinfuegenWriter.notExists( 2 )
+ else
+ warnlog( "Dialog <TabelleEinfuegenWriter> did not open" )
+ endif
Kontext "DocumentWriter"
for i%=1 to 10
@@ -86,7 +90,7 @@ testcase tOLEWriter
DocumentWriter.TypeKeys "<Left>", 3
next i%
- InsertObjectChart
+ hUseAsyncSlot( "InsertObjectChart" )
hStepThroughChartWizard()
Kontext "DocumentChart"
@@ -96,16 +100,19 @@ testcase tOLEWriter
Sleep 1
DocumentWriter.TypeKeys "<Down>", 20
DocumentWriter.TypeKeys "<Return>", 2
- Sleep 1
-
PrintLog "- Writer : Chart out of a table only with chars"
- InsertTableWriter
+ hUseAsyncSlot( "InsertTableWriter" )
Kontext "TabelleEinfuegenWriter"
- Spalten.SetText "3"
- Zeilen.SetText "10"
- TabelleEinfuegenWriter.OK
+ if ( TabelleEinfuegenWriter.exists( 1 ) ) then
+ Spalten.SetText "3"
+ Zeilen.SetText "10"
+ TabelleEinfuegenWriter.OK
+ TabelleEinfuegenWriter.notExists( 2 )
+ else
+ warnlog( "Dialog <TabelleEinfuegenWriter> did not open" )
+ endif
Kontext "DocumentWriter"
for i%=1 to 10
@@ -118,8 +125,7 @@ testcase tOLEWriter
DocumentWriter.TypeKeys "<Left>", 3
next i%
- InsertObjectChart
-
+ hUseAsyncSlot( "InsertObjectChart" )
hStepThroughChartWizard()
Kontext "DocumentChart"
@@ -129,30 +135,32 @@ testcase tOLEWriter
Sleep 1
DocumentWriter.TypeKeys "<Down>", 20
DocumentWriter.TypeKeys "<Return>", 2
- Sleep 1
PrintLog "- Writer : Math"
- InsertObjectFormulaWriter
+ hUseAsyncSlot( "InsertObjectFormulaWriter" )
gMouseClick ( 1, 1)
Kontext "DocumentWriter"
DocumentWriter.TypeKeys "<Delete>"
- Sleep 1
PrintLog "- Writer : floating frame"
+ hUseAsyncSlot( "InsertFloatingFrame" )
- 'warnlog( "#148094# - Crash when deselecting floating frame in Writer" )
-
- InsertFloatingFrame
-
+ printlog( "Properties dialog for floating frame should open" )
Kontext "TabEigenschaften"
- FrameName.SetText "Hallo"
- Inhalt.SetText ConvertPath ( gTesttoolPath+"global\input\graf_inp\borabora.jpg" )
-
- TabEigenschaften.OK
- Sleep 2
+ if ( TabEigenschaften.exists( 1 ) and TabEigenschaften.isVisible() ) then
+
+ printlog( "Name the floating frame, close the dialog" )
+ FrameName.SetText "Hallo"
+ Inhalt.SetText ConvertPath ( gTesttoolPath+"global\input\graf_inp\borabora.jpg" )
+
+ TabEigenschaften.OK
+ TabEigenSchaften.notExists( 2 )
+
+ endif
+ printlog( "Close the writer document" )
Kontext "DocumentWriter"
DocumentWriter.TypeKeys "<Delete>"
Sleep 1
@@ -333,7 +341,7 @@ testcase tOLEDraw
MenuSelect(0)
try
- InsertObjectChart
+ hUseAsyncSlot( "InsertObjectChart" )
Sleep ( 2 )
Kontext "DocumentChart"
@@ -413,7 +421,7 @@ testcase tOLEImpress
PrintLog "- Impress : Chart"
try
- InsertObjectChart
+ hUseAsyncSlot( "InsertObjectChart" )
sleep 2
gMouseClick ( 1 , 1 )