--- /dev/null
+puts "==========="
+puts "OCC114"
+puts "==========="
+
+# Max number of iterations for computing memory leackage
+set i_max 20
+puts "Amount of iterations is $i_max"
+
+NewDocument D MDTV-Standard
+UndoLimit D 10
+
+restore [locate_data_file OCC114.brep] s
+
+set listmem {}
+for {set i 1} {${i} <= ${i_max}} {incr i} {
+
+ OpenCommand D
+ SetShape D 0:1 s
+ AbortCommand D
+
+ # check memory usage (with tolerance equal to half page size)
+ lappend listmem [expr [meminfo w] / 1024]
+ if { [checktrend $listmem 0 1 "Memory leak detected"] } {
+ puts "No memory leak, $i iterations"
+ break
+ }
+}