0030829: BRepExtrema_ShapeProximity crashes with shape from STL/WRL
[occt.git] / tests / bugs / step / bug30189_1
CommitLineData
87efa821 1########################################
2# Wrong export to STEP of located root.
3########################################
4
5pload OCAF
6
7XOpen [locate_data_file bug30189.xbf] D
8WriteStep D $imagedir/${casename}.stp
9ReadStep DD $imagedir/${casename}.stp
10
11# Check location
12XGetOneShape res DD
13set props [lprops res]
14
15if {[lindex $props 9] != "90"} {
16 puts "Error: wrong location on shape."
17}
18if {[lindex $props 12] != "75"} {
19 puts "Error: wrong location on shape."
20}
21if {[lindex $props 15] != "60"} {
22 puts "Error: wrong location on shape."
23}
24
25# Check structure
26set top_level [XGetTopLevelShapes DD]
27if {$top_level != "0:1:1:1 0:1:1:2 0:1:1:3 0:1:1:4 "} {
28 puts "Error: wrong structure of document."
29}
30set nb [XNbComponents DD 0:1:1:1]
31if {$nb != "1"} {
32 puts "Error: wrong structure of document."
33}
34set nb [XNbComponents DD 0:1:1:2]
35if {$nb != "3"} {
36 puts "Error: wrong structure of document."
37}
38
39# Check colors
40set color [XGetShapeColor DD 0:1:1:3 surf]
41if {$color != "RED"} {
42 puts "Error: wrong color."
43}
44set color [XGetShapeColor DD 0:1:1:4 surf]
45if {$color != "DARKORANGE1"} {
46 puts "Error: wrong color."
47}
48
49Close D
50Close DD
51file delete $imagedir/${casename}.stp