Deleted unnecessary TODOs in test cases with improvements on MacOS platform. Small...
[occt.git] / tests / bugs / modalg_5 / bug24696
CommitLineData
0d19eb34 1puts "========="
2puts "OCC24696"
3puts "========="
4puts ""
5###########################################################
6# Lower performance of the new Edge/Edge intersection algorithm
7###########################################################
8
9pload QAcommands
10
11dchrono h reset
12dchrono h start
13
14restore [locate_data_file bug24696_cx_e1200_nurbs.brep] cx
15
16bclearobjects
17bcleartools
18
19set edges [explode cx e]
20set nbe [llength $edges]
21for {set i 1} {$i <= $nbe} {incr i} {baddobjects cx_$i}
22bfillds
23bbuild result
24
25dchrono h stop
26set q [dchrono h show]
27
28regexp {CPU user time: ([-0-9.+eE]+) seconds} $q full z
29puts "$z"
30
0a58bfe2 31if { [regexp {Debug mode} [dversion]] } {
32 if { [regexp {Windows} [dversion]] } {
33 set max_time 100.0
34 } else {
35 set max_time 200.0
36 }
0d19eb34 37} else {
0a58bfe2 38 if { [regexp {Windows} [dversion]] } {
39 set max_time 20.0
40 } else {
0d19eb34 41 set max_time 40.0
0a58bfe2 42 }
0d19eb34 43}
44
5dc2ede9 45if {[string compare $os "MacOS"] == 0} {
46 set max_time 100.0
47}
48
0d19eb34 49if { $z > ${max_time} } {
50 puts "Elapsed time is more than ${max_time} seconds - Faulty"
51} else {
52 puts "Elapsed time is less than ${max_time} seconds - OK"
53}
54
55set 2dviewer 1