puts "============"
puts "CR25378"
puts "============"
puts ""
###################################################################################
# Building of triangulation for distored surfaces can take very long using BRepMesh_IncrementalMesh
#
# Test case was created to control bad situation, building of triangulation takes
# very long time and it is expected by the meaning of issue #25378.
# Case when it is passed too fast should be considered as failure.
###################################################################################

cpulimit 2000

restore [locate_data_file bug25378_Blower_bad.brep] b
trinfo b

tclean b
set t_001 [expr [lindex [time {incmesh b 0.001}] 0]/1000000]
puts "t_001=${t_001}"
trinfo b

if { [regexp {Debug mode} [dversion]] } {
    cpulimit 2000
    set max_t_001 600
} else {
  if { [regexp {Windows} [dversion]] } {
    set max_t_001 189
  } else {
    set max_t_001 182
  }
}

# this test case is redundant, as we must not set lower limit for computation time
#if {${max_t_001} > ${t_001}} {
#   puts "Error. Time of building of triangulation, ${t_001} seconds, is less than expected minimum time - ${max_t_001} seconds"
#}