0024927: Getting rid of "Persistent" functionality -- Tests
[occt.git] / tests / bugs / caf / bug159
1 puts "==========="
2 puts "OCC159"
3 puts "==========="
4
5 pload QAcommands
6
7 NewDocument D BinOcaf
8
9 set log [OCC159 D]
10
11 set list [split ${log}]
12 set ll [llength ${list}]
13
14 if { ${ll} < 13} then {
15    puts "OCC159: Error"
16 } else {
17    set DocRefCount1 [lindex ${list} 2]
18    set DocOwner1    [lindex ${list} 5]
19    set DocOwner2    [lindex ${list} 8]
20    set DocRefCount2 [lindex ${list} 11]
21    set deltaRefCount [expr ${DocRefCount1} - ${DocRefCount2}]
22    if { ${DocOwner2} == "NULL" && ${deltaRefCount} >= 1 } then {
23       puts "OCC159: OK"
24    } else {
25       puts "OCC159: Error"
26    }
27 }
28