0027300: Boolean operation produces invalid shape in terms of "bopargcheck" command
[occt.git] / tests / bugs / modalg_6 / bug26841_1
1 puts "============"
2 puts "OCC26841"
3 puts "============"
4 puts ""
5 ###############################
6 ## Wrong result obtained by intersection algorithm.
7 ###############################
8
9 restore [locate_data_file bug26841c1-prism.brep] p1
10 restore [locate_data_file bug26841c1-deck.brep] a1
11
12 bsection result a1 p1 -n2d2
13
14 smallview
15 donly result
16 fit
17 display a1 p1
18
19 set nbshapes_expected "
20 Number of shapes in shape
21  VERTEX    : 5
22  EDGE      : 5
23  WIRE      : 0
24  FACE      : 0
25  SHELL     : 0
26  SOLID     : 0
27  COMPSOLID : 0
28  COMPOUND  : 1
29  SHAPE     : 11
30 "
31
32 checknbshapes result -ref ${nbshapes_expected} -t -m "SECTION"
33
34 regexp {Tolerance +MAX=([-0-9.+eE]+)} [tolerance result] full MaxTolerance
35 puts "MaxTolerance=$MaxTolerance"
36
37 set expected_MaxTolerance 4.8861509475438473e-005
38 set tol_abs_MaxTolerance 0.0
39 set tol_rel_MaxTolerance 0.01
40 checkreal "MaxTolerance" ${MaxTolerance} ${expected_MaxTolerance} ${tol_abs_MaxTolerance} ${tol_rel_MaxTolerance}
41
42 set log [checksection result]
43
44 if { [string compare -nocase $log " nb alone Vertices : 0\n\n"] } {
45   puts "ERROR: the section is not closed"
46 } else {
47   puts "The section is OK"
48 }
49
50 checkview -screenshot -2d -path ${imagedir}/${test_image}.png