jl165 merging heads
[LibreOffice.git] / testautomation / xml / optional / includes / sxi7_01.inc
blob43ebe8a8c99c5e7f60e9188b8f08693e9921264d
1 'encoding UTF-8  Do not remove or change this line!
2 '**************************************************************************
3 ' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 ' Copyright 2000, 2010 Oracle and/or its affiliates.
7 ' OpenOffice.org - a multi-platform office productivity suite
9 ' This file is part of OpenOffice.org.
11 ' OpenOffice.org is free software: you can redistribute it and/or modify
12 ' it under the terms of the GNU Lesser General Public License version 3
13 ' only, as published by the Free Software Foundation.
15 ' OpenOffice.org is distributed in the hope that it will be useful,
16 ' but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 ' GNU Lesser General Public License version 3 for more details
19 ' (a copy is included in the LICENSE file that accompanied this code).
21 ' You should have received a copy of the GNU Lesser General Public License
22 ' version 3 along with OpenOffice.org.  If not, see
23 ' <http://www.openoffice.org/license.html>
24 ' for a copy of the LGPLv3 License.
26 '/************************************************************************
28 '* owner : wolfram.garten@oracle.com
30 '* short description : XML Impress Include File
32 '\***********************************************************************************
33    Dim Isliste(250) as string
34    Dim OutputPath as string
36 sub sxi7_01
38    printlog "------------------- sxi_01.inc ---------------------"
39    printlog "----------------------------------------------------"
40    call talien_attributes
41    printlog "---------------------- C J K -----------------------"
42    call tchinese
43    call tjapan
44    call tkorean
45    call tradchinese
46    printlog "----------------------------------------------------"      
47    call tAutolayout   
48    call tText
49    call tObjects
50    call tEffects_text_objects
51    call tEffects_slides   
53 end sub
55 '-------------------------------------------------------------------------
57 testcase talien_attributes
58     Dim i as integer
59     Dim AttrNameInDOM as string
60     Dim AttributeSearch(9) as string
61     Dim AttributeValue(9) as string
62     printlog "+- Impress: alien.sxi"
63     '/// Opening alien.sxi. ///
64     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\ooo10\alien.sxi"))
65     '/// Saving document. ///
66     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\alien.sxi") , "StarOffice XML (Impress)") then
67         '/// Closing document. ///
68         call hCloseDocument
69         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\alien.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\") )
70         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\styles.xml")) = FALSE then
71             warnlog "XML-file 'styles.xml' not well formed!"
72         end if
73         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\meta.xml")) = FALSE then
74             warnlog "XML-file 'meta.xml' not well formed!"
75         end if
76         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\content.xml")) = FALSE then
77             warnlog "XML-file 'content.xml' not well formed!"
78         else
79             '/// Opening exported document (GPF check). ///
80             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\alien.sxi")
81             sleep(2)
82             '/// Closing document. ///
83             call hCloseDocument
84             sleep(2)
85             SAXReadFile(gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\content.xml"))
86             printlog "-----------------"
87             printlog "Hidden Namespaces"
88             printlog "-----------------"
89             '/// <u><b>content.xml</u></b>
90             '/// <u>Hidden attributes in namespaces</u>
91             '///+ Searching for: xmlns:alien=&quot;http://openoffice.org/2000/alien&quot;
92             '-------------------------------------------------------------------------
93             AttributeSearch(1) = "xmlns:alien"
94             AttributeValue(1) = "http://openoffice.org/2000/alien"
95             printlog "++ Feature(s) to be searched for:"
96             printlog " |"
97             '-------------------------------------------------------------------------
98             SAXSeekElement("office:document-content")
99             printlog " +- " & AttributeSearch(1)
100             if SAXGetAttributeValue(AttributeSearch(1)) <> AttributeValue(1) then
101                 warnlog "Hidden attributes (in namespace): " & AttributeSearch(1) & " is not " & AttributeValue(1) & "!"
102             end if
103             printlog "    * * *"
104             SAXSeekElement("/")
105             '/// <u>hidden attributes</u>
106             '///+<ol><li><b>in a drawing-page style</b></li>
107             '///+<li><b>in a graphics style</b></li>
108             '///+<li><b>in a paragraph style (twice)</b></li>
109             '///+<li><b>in a text style</b></li></ol>
110             '///+ Searching for: alien:key=&quot;page&quot;
111             '///+ Searching for: alien:key=&quot;shape&quot;
112             '///+ Searching for: alien:key=&quot;para&quot;
113             '///+ Searching for: alien:key=&quot;shape-text&quot;
114             '///+ Searching for: alien:key=&quot;text&quot;
115             AttributeSearch(1) = "alien:key"
116             AttributeValue(1) = "page"
117             
118             AttributeSearch(3) = "alien:key"
119             AttributeValue(3) = "shape"
120             
121             AttributeSearch(6) = "alien:key"
122             AttributeValue(6) = "para"
123             
124             AttributeSearch(7) = "alien:key"
125             AttributeValue(7) = "shape-text"
126             
127             AttributeSearch(9) = "alien:key"
128             AttributeValue(9) = "text"
129             '-------------------------------------------------------------------------
130             printlog "++ Feature(s) to be searched for:"
131             printlog " |"
132             '-------------------------------------------------------------------------
133             for i = 1 to 9
134                 if i = 1 then
135                     printlog "-----------------------------------------"
136                     printlog "Hidden attributes in a drawing-page style"
137                     printlog "-----------------------------------------"
138                 end if
139                 if i = 3 then
140                     printlog "-------------------------------------"
141                     printlog "Hidden attributes in a graphics style"
142                     printlog "-------------------------------------"
143                 end if
144                 if i = 6 or i = 7 then
145                     printlog "-------------------------------------------"
146                     printlog "Hidden attributes in a paragraph style (" & i-5 & ")"
147                     printlog "-------------------------------------------"
148                 end if
149                 if i = 9 then
150                     printlog "---------------------------------"
151                     printlog "Hidden attributes in a text style"
152                     printlog "---------------------------------"
153                 end if
154                 if i = 1 or i = 3 or i = 6 or i = 7 or i = 8 then
155                     'The hidden attributes are in a known sequence included,
156                     'so the same routine will be used for different styles!
157                     SAXSeekElement("/")
158                     SAXSeekElement("office:document-content")
159                     SAXSeekElement("office:automatic-styles")
160                     SAXSeekElement("style:style" , i )
161                     AttrNameInDOM = SAXGetAttributeValue("style:name")
162                     printlog " + Style name (" & i & "): " & AttrNameInDOM
163                     printlog " |"
164                     SAXSeekElement("style:properties")
165                     printlog " +- " & AttributeSearch(i)
166                     if SAXGetAttributeValue(AttributeSearch(i)) <> AttributeValue(i) then
167                         'i = <nr> means <nr>'th style:style in DOM tree
168                         if i = 1 then 
169                             warnlog "Hidden attributes (in a drawing-page style): " & AttributeSearch(i) & " is not " & AttributeValue(i) & "!"
170                         end if
171                         if i = 3 then 
172                             warnlog "Hidden attributes (in a graphics style): " & AttributeSearch(i) & " is not " & AttributeValue(i) & "!"
173                         end if
174                         if i = 5 or i = 6 then 
175                             warnlog "Hidden attributes (in a paragraph style): " & AttributeSearch(i) & " is not " & AttributeValue(i) & "!"
176                         end if
177                         if i = 8 then 
178                             warnlog "Hidden attributes (in a text style): " & AttributeSearch(i) & " is not " & AttributeValue(i) & "!"
179                         end if
180                     end if
181                 end if
182             next i
183             SAXSeekElement("/")
184             printlog "    * * *"
185             '-------------------------------------------------------------------------
186             SAXRelease()
187             SAXReadFile(gOfficePath & ConvertPath("user\work\xml\impress\level1\alien\styles.xml"))
188             '-------------------------------------------------------------------------
189             printlog "    -------------------"
190             printlog "    s t y l e s . x m l"
191             printlog "    -------------------"
192             printlog "-----------------"
193             printlog "Hidden Namespaces"
194             printlog "-----------------"
195             '/// <u><b>styles.xml</u></b>
196             '/// <u>Hidden attributes in namespaces</u>
197             '///+ Searching for: xmlns:alien=&quot;http://openoffice.org/2000/alien&quot;
198             '-------------------------------------------------------------------------
199             AttributeSearch(1) = "xmlns:alien"
200             AttributeValue(1) = "http://openoffice.org/2000/alien"
201             printlog "++ Feature(s) to be searched for:"
202             printlog " |"
203             '-------------------------------------------------------------------------
204             SAXSeekElement("office:document-styles")
205             printlog " +- " & AttributeSearch(1)
206             if SAXGetAttributeValue(AttributeSearch(1)) <> AttributeValue(1) then
207                 warnlog "Hidden attributes (in namespace): " & AttributeSearch(1) & " is not " & AttributeValue(1) & "!"
208             end if
209             printlog "    * * *"
210             SAXSeekElement("/")
211             printlog "----------------------------------------"
212             printlog "Hidden attributes in a master-page style"
213             printlog "----------------------------------------"
214             '-------------------------------------------------------------------------
215             '/// <u>hidden attributes</u>
216             '///+<ol><li><b>in a master-page style</b></li></ol>
217             '///+ Searching for: alien:key=&quot;master-page&quot;
218             '-------------------------------------------------------------------------
219             AttributeSearch(1) = "alien:key"
220             AttributeValue(1) = "master-page"
221             printlog "++ Feature(s) to be searched for:"
222             printlog " |"
223             '-------------------------------------------------------------------------
224             SAXSeekElement("office:document-styles")
225             SAXSeekElement("office:automatic-styles")
226             SAXSeekElement("style:style")
227             SAXSeekElement("style:properties")
228             printlog " +- " & AttributeSearch(1)
229             if SAXGetAttributeValue(AttributeSearch(1)) <> AttributeValue(1) then
230                 warnlog "Hidden attributes (in master-page style): " & AttributeSearch(1) & " is not " & AttributeValue(1) & "!"
231             end if
232             printlog "    * * *"
233             '-------------------------------------------------------------------------
234             SAXRelease()
235         end if
236     else
237         call hCloseDocument
238     end if
239 endcase
241 '-------------------------------------------------------------------------
243 testcase tchinese
244     printlog "+- Impress: chin.sxi"
245     '/// Opening chin.sxi which includes chinese characters. ///
246     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\ooo10\chin.sxi"))
247     '/// Saving document. ///
248     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\chin.sxi") , "StarOffice XML (Impress)") then
249         '/// Closing document. ///
250         call hCloseDocument
251         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\chin.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\chin\") )
252         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
253         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\chin\styles.xml")) = FALSE then
254             warnlog "XML-file 'styles.xml' not well formed!"
255         end if
256         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\chin\meta.xml")) = FALSE then
257             warnlog "XML-file 'meta.xml' not well formed!"
258         end if
259         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\chin\content.xml")) = FALSE then
260             warnlog "XML-file 'content.xml' not well formed!"
261         else
262             '/// Opening the exported document again (GPF check). ///
263             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\chin.sxi")
264             sleep(2)
265             '/// Closing document. ///
266             call hCloseDocument
267             sleep(2)
268         end if
269     else
270         call hCloseDocument
271     end if
272 endcase
274 '-------------------------------------------------------------------------
276 testcase tjapan
277     printlog "+- Impress: japan.sxi"
278     '/// Opening japan.sxi which includes japanese characters. ///
279     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\ooo10\japan.sxi"))
280     '/// Saving document. ///
281     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\japan.sxi") , "StarOffice XML (Impress)") then
282         '/// Closing document. ///
283         call hCloseDocument
284         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\japan.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\japan\") )
285         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
286         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\japan\styles.xml")) = FALSE then
287             warnlog "XML-file 'styles.xml' not well formed!"
288         end if
289         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\japan\meta.xml")) = FALSE then
290             warnlog "XML-file 'meta.xml' not well formed!"
291         end if
292         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\japan\content.xml")) = FALSE then
293             warnlog "XML-file 'content.xml' not well formed!"
294         else
295             '/// Opening the exported document again (GPF check). ///
296             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\japan.sxi")
297             sleep(2)
298             '/// Closing document. ///
299             call hCloseDocument
300             sleep(2)
301         end if
302     else
303         call hCloseDocument
304     end if
305 endcase
307 '-------------------------------------------------------------------------
309 testcase tkorean
310     printlog "+- Impress: korean.sxi"
311     '/// Opening korean.sxi which includes korean characters. ///
312     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\ooo10\korean.sxi"))
313     '/// Saving document. ///
314     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\korean.sxi") , "StarOffice XML (Impress)") then
315         '/// Closing document. ///
316         call hCloseDocument
317         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\korean.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\korean\") )
318         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
319         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\korean\styles.xml")) = FALSE then
320             warnlog "XML-file 'styles.xml' not well formed!"
321         end if
322         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\korean\meta.xml")) = FALSE then
323             warnlog "XML-file 'meta.xml' not well formed!"
324         end if
325         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\korean\content.xml")) = FALSE then
326             warnlog "XML-file 'content.xml' not well formed!"
327         else
328             '/// Opening the exported document again (GPF check). ///
329             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\korean.sxi")
330             sleep(2)
331             '/// Closing document. ///
332             call hCloseDocument
333             sleep(2)
334         end if
335     else
336         call hCloseDocument
337     end if
338 endcase
340 '-------------------------------------------------------------------------
342 testcase tradchinese
343     printlog "+- Impress: trad_chin.sxi"
344     '/// Opening trad_chin.sxi which includes traditional chinese characters. ///
345     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\ooo10\trad_chin.sxi"))
346     '/// Saving document. ///
347     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin.sxi") , "StarOffice XML (Impress)") then
348         '/// Closing document. ///
349         call hCloseDocument
350         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin\") )
351         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
352         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin\styles.xml")) = FALSE then
353             warnlog "XML-file 'styles.xml' not well formed!"
354         end if
355         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin\meta.xml")) = FALSE then
356             warnlog "XML-file 'meta.xml' not well formed!"
357         end if
358         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin\content.xml")) = FALSE then
359             warnlog "XML-file 'content.xml' not well formed!"
360         else
361             '/// Opening the exported document again (GPF check). ///
362             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\trad_chin.sxi")
363             sleep(2)
364             '/// Closing document. ///
365             call hCloseDocument
366             sleep(2)
367         end if
368     else
369         call hCloseDocument
370     end if
371 endcase
373 '-------------------------------------------------------------------------
375 testcase tAutolayout
376     Dim AttributeSearch(8) as string
377     Dim AttributeValue(8) as string
378     printlog "+- Impress: Autolayout.sdd"
379     '/// Opening Autolayout.sdd. ///
380     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\so_bin\Autolayout.sdd"))
381     '/// Saving document. ///
382     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout.sxi") , "StarOffice XML (Impress)") then
383         '/// Closing document. ///
384         call hCloseDocument
385         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout\") )
386         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
387         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout\styles.xml")) = FALSE then
388             warnlog "XML-file 'styles.xml' not well formed!"
389         end if
390         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout\meta.xml")) = FALSE then
391             warnlog "XML-file 'meta.xml' not well formed!"
392         end if
393         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout\content.xml")) = FALSE then
394             warnlog "XML-file 'content.xml' not well formed!"
395         else
396             '/// Opening the exported document again (GPF check). ///
397             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout.sxi")
398             sleep(2)
399             '/// Closing document. ///
400             call hCloseDocument
401             sleep(2)
402             SAXReadFile(gOfficePath & ConvertPath("user\work\xml\impress\level1\Autolayout\content.xml"))
403             printlog "-----------------"
404             printlog "Slide names"
405             printlog "-----------------"
406             '/// <u><b>content.xml</u></b>
407             '/// <u>Slide names</u>
408             '///+ Searching for: draw:name="Title subtitle"
409             '-------------------------------------------------------------------------
410             AttributeSearch(1) = "draw:name"
411             AttributeValue(1) = "Title subtitle"
412             printlog "++ Feature(s) to be searched for:"
413             printlog " |"
414             '-------------------------------------------------------------------------
415             SAXSeekElement("office:document-content")
416             SAXSeekElement("office:body")
417             SAXSeekElement(2)
418             printlog " +- " & AttributeSearch(1) & " = " & AttributeValue(1)
419             if SAXGetAttributeValue(AttributeSearch(1)) <> AttributeValue(1) then
420                 warnlog "draw:name: " & AttributeSearch(1) & " is not " & AttributeValue(1) & "!"
421             end if            
422             '-------------------------------------------------------------------------
423             SAXRelease()    
424         end if
425     else
426         call hCloseDocument
427     end if
428 endcase
430 '-------------------------------------------------------------------------
432 testcase tText
433     printlog "+- Impress: Text.sdd"
434     QAErrorLog "#i38739# tText PERFORMANCE issue."
435     goto endsub
436     '/// Opening Text.sdd. ///
437     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\so_bin\Text.sdd"))
438     '/// Saving document. ///
439     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\Text.sxi") , "StarOffice XML (Impress)") then
440         '/// Closing document. ///
441         call hCloseDocument
442         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\Text.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\Text\") )
443         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
444         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Text\styles.xml")) = FALSE then
445             warnlog "XML-file 'styles.xml' not well formed!"
446         end if
447         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Text\meta.xml")) = FALSE then
448             warnlog "XML-file 'meta.xml' not well formed!"
449         end if
450         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Text\content.xml")) = FALSE then
451             warnlog "XML-file 'content.xml' not well formed!"
452         else
453             '/// Opening the exported document again (GPF check). ///
454             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\Text.sxi")
455             sleep(2)
456             '/// Closing document. ///
457             call hCloseDocument
458             sleep(2)
459         end if
460     else
461         call hCloseDocument
462     end if
463 endcase
465 '-------------------------------------------------------------------------
467 testcase tObjects
468     printlog "+- Impress: Objects.sdd"
469     '/// Opening Objects.sdd. ///
470     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\so_bin\Objects.sdd"))
471     '/// Saving document. ///
472     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects.sxi") , "StarOffice XML (Impress)") then
473         '/// Closing document. ///
474         call hCloseDocument
475         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects\") )
476         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
477         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects\styles.xml")) = FALSE then
478             warnlog "XML-file 'styles.xml' not well formed!"
479         end if
480         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects\meta.xml")) = FALSE then
481             warnlog "XML-file 'meta.xml' not well formed!"
482         end if
483         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects\content.xml")) = FALSE then
484             warnlog "XML-file 'content.xml' not well formed!"
485         else
486             '/// Opening the exported document again (GPF check). ///
487             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\Objects.sxi")
488             sleep(2)
489             '/// Closing document. ///
490             call hCloseDocument
491             sleep(2)
492         end if
493     else
494         call hCloseDocument
495     end if
496 endcase
498 '-------------------------------------------------------------------------
500 testcase tEffects_text_objects
501     printlog "+- Impress: Effects_text_objects.sdd"
502     '/// Opening Effects_text_objects.sdd. ///
503     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\so_bin\Effects_text_objects.sdd"))
504     '/// Saving document. ///
505     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects.sxi") , "StarOffice XML (Impress)") then
506         '/// Closing document. ///
507         call hCloseDocument
508         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects\") )
509         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
510         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects\styles.xml")) = FALSE then
511             warnlog "XML-file 'styles.xml' not well formed!"
512         end if
513         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects\meta.xml")) = FALSE then
514             warnlog "XML-file 'meta.xml' not well formed!"
515         end if
516         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects\content.xml")) = FALSE then
517             warnlog "XML-file 'content.xml' not well formed!"
518         else
519             '/// Opening the exported document again (GPF check). ///
520             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_text_objects.sxi")
521             sleep(2)
522             '/// Closing document. ///
523             call hCloseDocument
524             sleep(2)
525         end if
526     else
527         call hCloseDocument
528     end if
529 endcase
531 '-------------------------------------------------------------------------
533 testcase tEffects_slides
534     printlog "+- Impress: Effects_slides.sdd"
535     '/// Opening Effects_slides.sdd. ///
536     call hFileOpen (gTesttoolPath & ConvertPath("xml\optional\input\graphics\so_bin\Effects_slides.sdd"))
537     '/// Saving document. ///
538     if hFileSaveAsWithFilterKill (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides.sxi") , "StarOffice XML (Impress)") then
539         '/// Closing document. ///
540         call hCloseDocument
541         UnpackStorage( gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides.sxi") , gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides\") )
542         '/// Checking well formness of meta.xml, styles.xml and content.xml. ///
543         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides\styles.xml")) = FALSE then
544             warnlog "XML-file 'styles.xml' not well formed!"
545         end if
546         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides\meta.xml")) = FALSE then
547             warnlog "XML-file 'meta.xml' not well formed!"
548         end if
549         if XMLWellformed (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides\content.xml")) = FALSE then
550             warnlog "XML-file 'content.xml' not well formed!"
551         else
552             '/// Opening the exported document again (GPF check). ///
553             call hFileOpen (gOfficePath & ConvertPath("user\work\xml\impress\level1\Effects_slides.sxi")
554             sleep(2)
555             '/// Closing document. ///
556             call hCloseDocument
557             sleep(2)
558         end if
559     else
560         call hCloseDocument
561     end if
562 endcase