Adjusting testing cases for current state of OCCT
[occt.git] / tests / bugs / vis / bug232
CommitLineData
a87752f3 1puts "========"
2puts "OCC232"
3puts "Pick filter does NOT work for TopAbs_COMPSOLID topology"
4puts "========"
5
6vinit
7OCC232
8vfit
9
10# selected point of first CompSolid
11set x1 69
12set y1 204
13
14set x2 116
15set y2 231
16
17#set x3 160; set y3 257 - it's bad for lin,aki.
18set x3 159
19set y3 256
20
21# selected point of second CompSolid
22set x4 298
23set y4 76
24
25set x5 339
26set y5 100
27
28set x6 381
29set y6 124
30
31set Cyan_R 0
32set Cyan_G 1
33set Cyan_B 1
34
35set Yellow_R 1
36set Yellow_G 1
37set Yellow_B 0
38
39# There is not selection
40puts "There is not selection"
41catch {QAGetPixelColor $x1 $y1 $Yellow_R $Yellow_G $Yellow_B} result11
42catch {QAGetPixelColor $x2 $y2 $Yellow_R $Yellow_G $Yellow_B} result12
43catch {QAGetPixelColor $x3 $y3 $Yellow_R $Yellow_G $Yellow_B} result13
44catch {QAGetPixelColor $x4 $y4 $Yellow_R $Yellow_G $Yellow_B} result14
45catch {QAGetPixelColor $x5 $y5 $Yellow_R $Yellow_G $Yellow_B} result15
46catch {QAGetPixelColor $x6 $y6 $Yellow_R $Yellow_G $Yellow_B} result16
47
48# Move a mouse
49puts "Move a mouse"
50QAMoveTo $x2 $y2
51QAMoveTo $x2 $y2
52
53# Second box of first CompSolid is selected
54puts "Second box of first CompSolid is selected"
55catch {QAGetPixelColor $x1 $y1 $Yellow_R $Yellow_G $Yellow_B} result21
56catch {QAGetPixelColor $x3 $y3 $Yellow_R $Yellow_G $Yellow_B} result22
57catch {QAGetPixelColor $x4 $y4 $Yellow_R $Yellow_G $Yellow_B} result23
58catch {QAGetPixelColor $x5 $y5 $Yellow_R $Yellow_G $Yellow_B} result24
59catch {QAGetPixelColor $x6 $y6 $Yellow_R $Yellow_G $Yellow_B} result25
60
d27ea0ef 61if { [array get env os_type] != "" } {
62 set os $env(os_type)
63}
64if { [string compare $os "windows"] != 0 } {
65 QAUpdateLights
66 catch {QAGetPixelColor $x2 $y2 $Cyan_R $Cyan_G $Cyan_B} result31
67}
a87752f3 68
69set IsFaulty 0
70if { [regexp "Faulty" $result11] == 1 } {
71 set IsFaulty 1
72}
73if { [regexp "Faulty" $result12] == 1 } {
74 set IsFaulty 1
75}
76if { [regexp "Faulty" $result13] == 1 } {
77 set IsFaulty 1
78}
79if { [regexp "Faulty" $result14] == 1 } {
80 set IsFaulty 1
81}
82if { [regexp "Faulty" $result15] == 1 } {
83 set IsFaulty 1
84}
85if { [regexp "Faulty" $result16] == 1 } {
86 set IsFaulty 1
87}
88if { [regexp "Faulty" $result21] == 1 } {
89 set IsFaulty 1
90}
91if { [regexp "Faulty" $result22] == 1 } {
92 set IsFaulty 1
93}
94if { [regexp "Faulty" $result23] == 1 } {
95 set IsFaulty 1
96}
97if { [regexp "Faulty" $result24] == 1 } {
98 set IsFaulty 1
99}
100if { [regexp "Faulty" $result25] == 1 } {
101 set IsFaulty 1
102}
d27ea0ef 103
104if { [string compare $os "windows"] != 0 } {
105 if { [regexp "Faulty" $result31] == 1 } {
106 set IsFaulty 1
107 }
a87752f3 108}
109
110if {$IsFaulty != 0} {
111 puts "Error : OCC232"
112}
113
114set only_screen 1