1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-04 18:06:22 +03:00
emv 3389667b4c 0023751: Test case bugs modalg bug6334 does not work with new Boolean Operation Algorithm.
Fix for the bug.
Added simple condition:
If the map myShapes (map of the parts of the tool that should be in result shape) is not filled then boolean operation of the given type will be performed.
Modified test case bugs/modalg_4/bug6334.
Small correction test cases
2013-02-15 16:48:17 +04:00

68 lines
1.3 KiB
Plaintext
Executable File

puts "============"
puts "OCC6334"
puts "============"
puts ""
######################################################
# Invalid result of MakeCylindricalHole when input solid is REVERSED
######################################################
set BugNumber OCC6334
# 1. Make box
box b 100 100 100
subshape b f 1
offsetshape t b 10 b_1
decho off
set che_t [checkshape t]
decho on
if {[regexp {Faulty} $che_t]} {
puts "Faulty ${BugNumber} : checkshape is wrong for t"
}
set bnd_t [bounding t]
set ori [lindex [dtyp t] 2]
puts "Orientation of thick solid is $ori"
# 3. Make hole
hole h t 110 50 50 1 0 0 10
set che [checkshape h]
if { [regexp {Faulty} $che] } {
puts "Faulty ${BugNumber} : checkshape is wrong for h"
}
set bnd_h [bounding h]
renamevar h result
set square 117509
set nb_v_good 30
set nb_e_good 51
set nb_w_good 27
set nb_f_good 24
set nb_sh_good 1
set nb_sol_good 1
set nb_compsol_good 0
set nb_compound_good 1
set nb_shape_good 135
# 4. Check thickness of box and hole
set dx_t [expr [lindex $bnd_t 3] - [lindex $bnd_t 0]]
set dx_h [expr [lindex $bnd_h 3] - [lindex $bnd_h 0]]
if { [expr abs($dx_h - $dx_t)] > 1e-5 } {
puts "Thickness of solid = $dx_t"
puts "Thickness of solid with hole = $dx_h"
puts "Invalid result of making a hole"
puts "Faulty ${BugNumber}"
} else {
puts "OK ${BugNumber}"
}
set 2dviewer 0