0031682: Visualization - Prs3d_ShadingAspect::SetTransparency() has no effect with...
[occt.git] / tests / xml / data / ocaf / D3
1 set aTestName "caf100-R1"
2 puts ${aTestName}
3
4 # Set a variables
5 set aV1Label 0:1:1
6 set aV2Label 0:1:2
7 set aV3Label 0:1:3
8
9 Label D ${aV1Label}
10 Label D ${aV2Label}
11 Label D ${aV3Label}
12
13 SetVariable D ${aV1Label} 1 "N"
14 SetVariable D ${aV2Label} 0 "kg"
15 SetVariable D ${aV3Label} 0 "µ/s²"
16
17 # Set an expression
18 set expression "f = m*a"
19
20 # Set a relation
21 set aRLabel 0:1:13
22 Label D ${aRLabel}
23 SetRelation D ${aRLabel} $expression $aV1Label $aV2Label $aV3Label
24
25 # Save a result for check after retrieval
26 set dump_before [DumpRelation D ${aRLabel}]
27
28 # Save the document
29 set aFile $WorkDirectory/${aTestName}.${FileSuffix}
30
31 SaveToFile D $aFile
32
33 # Restore the document
34 Close D
35 Open ${aFile} DD
36
37 # Get a variable from the label
38 set IsDone [catch {set dump_after [DumpRelation DD ${aRLabel}]} aResult]
39 if { ${IsDone} != 0 } {
40     puts "Error : Get a value of TDataStd_Relation attribute from restoring document"
41 } else {
42
43     if { ${dump_after} != ${dump_before} } {
44         puts "Error : Get a value of TDataStd_Relation attribute from restoring document"
45     }
46 }