0028681: UnifySameDomain distorts face boundary when merges a chain of small linear...
[occt.git] / tests / bugs / modalg_7 / bug23610
1 puts "TODO OCC23610 ALL: should be less then or equal to the minimal tolerance value of its sub-shapes"
2
3 puts "========"
4 puts "OCC23610"
5 puts "========"
6 puts ""
7 ########################################################################################################
8 ## checkshape command does not detect mismatch of the tolerance values among the sub-shapes of the shape
9 ########################################################################################################
10
11 restore [locate_data_file buc60462b.brep] b
12
13 foreach Face [explode b f] {
14   if {[checkshape $Face] == "This shape seems to be valid"} {
15      set ToleranceList [tolerance $Face]
16      regexp {FACE +: +MAX=([-0-9.+eE]+) +AVG=([-0-9.+eE]+) +MIN=([-0-9.+eE]+)} $ToleranceList full MaxTol_face AvgTol_face MinTol_face
17      regexp {EDGE +: +MAX=([-0-9.+eE]+) +AVG=([-0-9.+eE]+) +MIN=([-0-9.+eE]+)} $ToleranceList full MaxTol_edge AvgTol_edge MinTol_edge
18      regexp {VERTEX +: +MAX=([-0-9.+eE]+) +AVG=([-0-9.+eE]+) +MIN=([-0-9.+eE]+)} $ToleranceList full MaxTol_vertex AvgTol_vertex MinTol_vertex
19      if {${MaxTol_face} > ${MinTol_edge} || ${MaxTol_face} > ${MinTol_vertex}} {
20         puts "Error: the tolerance value of the FACE $Face should be less then or equal to the minimal tolerance value of its sub-shapes(EDGES and VERTICES)"
21      }
22   }
23 }
24
25 foreach Edge [explode b e] {
26   if {[checkshape $Edge] == "This shape seems to be valid"} {
27      set ToleranceList [tolerance $Edge]
28      regexp {EDGE +: +MAX=([-0-9.+eE]+) +AVG=([-0-9.+eE]+) +MIN=([-0-9.+eE]+)} $ToleranceList full MaxTol_edge AvgTol_edge MinTol_edge
29      regexp {VERTEX +: +MAX=([-0-9.+eE]+) +AVG=([-0-9.+eE]+) +MIN=([-0-9.+eE]+)} $ToleranceList full MaxTol_vertex AvgTol_vertex MinTol_vertex
30      if {${MaxTol_edge} > ${MinTol_vertex}} {
31         puts "Error: the tolerance value of the EDGE $Edge should be less then or equal to the minimal tolerance value of its sub-shapes(VERTICES)"
32      }
33   }
34 }