puts "============"
puts "OCC22771"
puts "============"
puts ""
#######################################################################
# An extra vertex produced in result of Boolean section for the cases of closed intersection curves.
#######################################################################

set BugNumber OCC22771

puts "Load first shape ..."
restore [locate_data_file bug22771_Box_1.brep] b1 

puts "Load second shape ..."
restore [locate_data_file bug22771_Cylinder_1.brep] b2 

puts "Prepare boolean operation ..."
explode b1 f
copy b1_5 b1
copy b2_1 b2

bop b1 b2

puts "Start boolean operation ..."
bopsection result
puts "Finish boolean operation ..."

checkprops result -l 314.159 
checkshape result 
checksection result

checknbshapes result -vertex 1 -edge 1 -wire 0 -face 0 -shell 0 -solid 0 -compsolid 0 -compound 1 -shape 3
checkview -display result -3d -path ${imagedir}/${test_image}.png
