mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-19 13:40:49 +03:00
grids:
- heal drop_small_edges,
fix_face_size,
fix_gaps,
split_angle_advanced,
surface_to_bspline.
Correction of tolerances in input shapes was made for tests:
- bugs heal bug329,
- bugs modalg buc60462_1,
buc60463,
bug292,
bug317,
bug330,
bug452_2,
bug452_3,
bug625,
bug697_1,
bug698,
bug774_1,
bug776_1,
bug776_2,
bug80,
bug919,
- bugs moddata buc60652_2,
buc60652_3,
buc60707,
bug368,
bug75_2,
fra62476_2,
ger61235,
pro20333,
- bugs step buc60948,
- bugs step bug630,
- bugs vis buc60661,
- bugs vis bug288_1,
- bugs vis bug288_4,
- bugs xde bug859,
- bugs xde bug861,
- feat featlf B8,
featprism L2,
L8,
M1,
O6,
O9,
R1,
S1,
S2,
- sewing tol_0_01 T1.
79 lines
2.1 KiB
Plaintext
Executable File
79 lines
2.1 KiB
Plaintext
Executable File
if { [isdraw result] } {
|
|
#check if result is valid
|
|
|
|
EnsureTolRule result result
|
|
puts "checkshape"
|
|
set ch [checkshape result]
|
|
puts $ch
|
|
|
|
if { [info exists square] } {
|
|
set prop "square"
|
|
set mass $square
|
|
regexp {Mass +: +([-0-9.+eE]+)} [sprops result] full m
|
|
}
|
|
if { [info exists length] } {
|
|
set prop "length"
|
|
set mass $length
|
|
regexp {Mass +: +([-0-9.+eE]+)} [lprops result] full m
|
|
|
|
puts "checksection"
|
|
puts [checksection result]
|
|
}
|
|
|
|
#if mass (length or square) is empty in test case then result should be an empty shape.
|
|
if { [string compare "$mass" "empty"] != 0 } {
|
|
if { $m == 0 } {
|
|
puts "Error : The $command is not valid. The $prop is 0."
|
|
}
|
|
if { $mass > 0 } {
|
|
puts "The expected $prop is $mass"
|
|
}
|
|
#check of change of square is < 1%
|
|
if { ($mass != 0 && [expr 1.*abs($mass - $m)/$mass] > 0.01) || ($mass == 0 && $m != 0) } {
|
|
puts "Error : The $prop of result shape is $m"
|
|
}
|
|
|
|
if { [info exists nbsh_v ] } {
|
|
set arr_v [explode result v]
|
|
set nb_v [ llength $arr_v ]
|
|
if { $nb_v != $nbsh_v } {
|
|
puts "Error : Result shape is WRONG because it must contain $nbsh_v vertexes instead of $nb_v"
|
|
} else {
|
|
puts "Result shape contains $nb_v vertexes"
|
|
}
|
|
|
|
}
|
|
|
|
if { [info exists nbsh_e ] } {
|
|
set arr_e [explode result e]
|
|
set nb_e [ llength $arr_e ]
|
|
if { $nb_e != $nbsh_e } {
|
|
puts "Error : Result shape is WRONG because it must contain $nbsh_e edges instead of $nb_e"
|
|
} else {
|
|
puts "Result shape contains $nb_e edges"
|
|
}
|
|
}
|
|
} else {
|
|
if { $m != 0 } {
|
|
puts "Error : The $command is not valid. The $prop is $m"
|
|
}
|
|
}
|
|
|
|
smallview
|
|
if { $m > 0 } {
|
|
donly result
|
|
if { [info exists nbsh_v ] } {
|
|
explode result v
|
|
}
|
|
} else {
|
|
donly a b
|
|
}
|
|
fit
|
|
xwd $imagedir/${test_image}.png
|
|
} else {
|
|
puts "Error : The $command can not be build."
|
|
}
|
|
|
|
# to end a test script
|
|
puts "TEST COMPLETED"
|