]> OCCT Git - occt-copy.git/commitdiff
Non-regression test for new OCAF attribute TDataStd_Mesh is improved a little. CR25936_2
authorvro <vro@opencascade.com>
Mon, 19 Sep 2016 11:38:25 +0000 (14:38 +0300)
committervro <vro@opencascade.com>
Mon, 19 Sep 2016 11:38:25 +0000 (14:38 +0300)
src/TKBinL/EXTERNLIB
tests/caf/basic/N1
tests/caf/basic/N2 [deleted file]

index b39644fd46a17889ba9c5a989ec662d4369fa2c9..e66b6abef48f6e7f4b4cadf449b0332d9036d47e 100644 (file)
@@ -1,3 +1,4 @@
 TKCDF
 TKernel
 TKLCAF
+TKMath
\ No newline at end of file
index 03b327b75a93388696ed1889bbdbee935f056d07..0805edca79dc82bdeee55de92ad55db5de42c6da 100644 (file)
 puts "caf001-N1"
 
 # Make a sphere and produce triangulation
-psphere s 100
-vdisplay s
+box s 100 200 300
 explode s f
-
-# Create a XML document
-NewDocument D XmlXCAF
+incmesh s_1 0.1
 
 # Set mesh from the spherical face
+NewCommand D
 SetMesh D 0:1 s_1
+NewCommand D
+
+# Test Undo/Redo.
+Undo D
+Redo D
 
 # Print the mesh data
 set dump1 [DumpMesh D 0:1]
 
 # Save document on disk.
-SaveAs D "test.xml"
+SaveAs D test.cbf
 
 # Close and open the document again.
-Close D
-Open test.xml DD
+#Close D
+Open test.cbf DD
 
 # Print mesh data
 set dump2 [DumpMesh DD 0:1]
 
+Close DD
+
 # Check data
 if { ${dump1}!=${dump2} } {
        puts "TDataStd_Mesh(XML) attribute: Error"
diff --git a/tests/caf/basic/N2 b/tests/caf/basic/N2
deleted file mode 100644 (file)
index e2e91fa..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-#INTERFACE CAF
-# Basic attributes
-#
-# Testing attribute: TDataStd_Mesh
-#
-# Testing command:   SetMesh
-# Testing command:   DumpMesh
-# Test           :   Binary file format
-#
-
-puts "caf001-N2"
-
-# Make a sphere and produce triangulation
-psphere s 100
-vdisplay s
-explode s f
-
-# Create a binary document
-NewDocument D BinXCAF
-
-# Set mesh from the spherical face
-SetMesh D 0:1 s_1
-
-# Print the mesh data
-set dump1 [DumpMesh D 0:1]
-
-# Save document on disk.
-SaveAs D "test.xbf"
-
-# Close and open the document again.
-Close D
-Open test.xbf DD
-
-# Print mesh data
-set dump2 [DumpMesh DD 0:1]
-
-# Check data
-if { ${dump1}!=${dump2} } {
-       puts "TDataStd_Mesh(BIN) attribute: Error"
-       return
-}
-puts "TDataStd_Mesh(BIN) attribute: OK"