692decba |
1 | puts "================" |
2 | puts "0031825: Data Exchange, STEP - NULL dereference while re-exporting model with empty Datum description" |
3 | puts "================" |
4 | puts "" |
5 | |
6 | pload OCAF |
7 | param write.step.schema AP242DIS |
395d00e0 |
8 | Close D_First D_Sec -silent |
692decba |
9 | |
10 | # Read file |
11 | set Path ${imagedir}/${casename}.stp |
12 | ReadStep D_First [locate_data_file bug26689_nist_ctc_04_asme1_ap242.stp] |
13 | set baseDGTDump [XDumpNbDGTs D_First f] |
14 | |
15 | WriteStep D_First $Path |
16 | ReadStep D_Sec $Path |
17 | file delete $Path |
18 | set newDGTDump [XDumpNbDGTs D_Sec f] |
19 | XGetOneShape res D_Sec |
20 | |
21 | # Checking |
22 | checkshape res |
23 | checknbshapes res -face 518 -wire 623 -compound 1 |
24 | |
25 | set isOK 1 |
26 | set nb_ref [llength $newDGTDump] |
27 | for { set i 0 } { $i < $nb_ref } { incr i } { |
28 | set refstr [lindex $baseDGTDump $i] |
29 | set curstr [lindex $newDGTDump $i] |
30 | if {[string equal $refstr $curstr] == 0} { |
31 | set isOK 0 |
32 | } |
33 | } |
34 | if {$isOK == 0} { |
35 | puts "Error: wrong export DGT and PMI" |
36 | } |
37 | |
38 | # set default parameter |
39 | param write.step.schema AP214IS |