0023570: Command param in DRAW outputs non-readable symbols
[occt.git] / tests / bugs / xde / bug1747
CommitLineData
3bea4c16 1puts "TODO OCC11111 ALL: Faulty OCC1747"
2
3puts "================"
4puts "OCC1747"
5puts "================"
6puts ""
7#######################################################################################
8# Cannot get entity number for translated shape from STEP in XDE case
9######################################################################################
10
11set BugNumber OCC1747
12
13catch {pload DCAF}
14
15XNewDoc SA
16
17box b1 10 10 10
18box b2 20 10 10
19ttranslate b1 10 0 0
20ttranslate b2 20 0 0
21compound b1 b2 bl
22copy bl nbl
23ttranslate nbl 30 0 0
24compound bl nbl ryad
25copy ryad hryad
26ttranslate hryad -10 0 10
27copy ryad uryad
28ttranslate uryad 0 0 20
29compound ryad hryad uryad stena
30
31XAddShape SA stena 1
32
33SetName SA 0:1:1:1 Wall
34SetName SA 0:1:1:2 Block-Array
35SetName SA 0:1:1:3 Block
36SetName SA 0:1:1:4 Half-Brick
37SetName SA 0:1:1:5 Brick
38
39SetName SA 0:1:1:1:1 base-array
40SetName SA 0:1:1:1:2 next-array
41SetName SA 0:1:1:1:3 top-array
42
43SetName SA 0:1:1:2:1 left-block
44SetName SA 0:1:1:2:2 right-block
45
46SetName SA 0:1:1:3:1 half-brick
47SetName SA 0:1:1:3:2 brick
48
49WriteStep SA $imagedir/${test_image}.stp
50dall
51ReadStep D $imagedir/${test_image}.stp
52
53puts "INFO: get main shape from the XDE document D"
54XGetShape a D 0:1:1:1
55puts "INFO: now try to get translation history for it"
56set info1 [ fromshape a ]
57set index1 [ lsearch $info1 unknown ]
58explode a
59puts "INFO: now try to get translation history for subshape a_1"
60set info2 [ fromshape a_1 ]
61set index2 [ lsearch $info2 unknown ]
62puts "INFO: now try to get translation history for subshape a_2"
63set info3 [fromshape a_2 ]
64set index3 [ lsearch $info3 unknown ]
65
66set exception_status 0
67if {$index1 > -1 || $index2 > -1 || $index3 > -1} {
68 set exception_status 1
69}
70
71if { ${exception_status} == 0 } {
72 puts "OK ${BugNumber}"
73} else {
74 puts "Faulty ${BugNumber}"
75}
76
77set 3dviewer 0