607a96d4 |
1 | if { [string compare $subgroup "ocaf_xml"] == 0 } { |
2 | puts "TODO ?OCC23768 ALL: Error : File is not valid" |
3 | puts "TODO ?OCC23768 ALL: Error at line" |
4 | } |
5 | |
6 | set aTestName "caf100-B1" |
7 | puts ${aTestName} |
8 | |
9 | box aBox1 10 20 30 100 200 300 |
10 | |
11 | # Create a label |
12 | set aLabel 0:2 |
13 | Label D ${aLabel} |
14 | |
15 | # Close/Open transaction |
16 | NewCommand D |
17 | |
18 | # Set a Geometry |
19 | set asettype "pnt" |
20 | SetGeometry D ${aLabel} ${asettype} aBox1 |
21 | |
22 | # Close/Open transaction |
23 | NewCommand D |
24 | |
25 | # Save the document |
26 | set aFile $WorkDirectory/${aTestName}.${FileSuffix} |
27 | |
28 | SaveToFile D $aFile |
29 | |
30 | # Restore the document |
31 | Close D |
32 | Open ${aFile} DD |
33 | |
34 | # Get a geometry type from the label |
35 | set IsDone [catch {GetGeometryType DD ${aLabel}} aResult] |
36 | if { ${IsDone} != 0 } { |
37 | puts "Error : Get a value of TDataStd_Geometry attribute from restoring document" |
38 | } else { |
39 | |
40 | # Check the type |
41 | set atype [GetGeometryType DD ${aLabel}] |
42 | puts "atype = ${atype}" |
43 | |
44 | if { ${atype} != ${asettype} } { |
45 | puts "Error : Get a value of TDataStd_Geometry attribute from restoring document" |
46 | } |
47 | } |