]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/SketchAPI/Test/TestSketch.py
Salome HOME
Add SketchAPI and Line feature. Also fix tests.
[modules/shaper.git] / src / SketchAPI / Test / TestSketch.py
diff --git a/src/SketchAPI/Test/TestSketch.py b/src/SketchAPI/Test/TestSketch.py
new file mode 100644 (file)
index 0000000..5f1576c
--- /dev/null
@@ -0,0 +1,26 @@
+import unittest
+
+import ModelAPI
+import ExchangeAPI
+
+class PointTestCase(unittest.TestCase):
+
+    def setUp(self):
+        self.session = ModelAPI.ModelAPI_Session.get()
+        self.doc = self.session.moduleDocument()
+
+    def tearDown(self):
+        self.session.closeAll()
+
+    def test_addImport(self):
+        self.session.startOperation()
+        self.feature = ExchangeAPI.addImport(self.doc, "file_path")
+        self.session.finishOperation()
+
+    def test_addExport(self):
+        self.session.startOperation()
+        self.feature = ExchangeAPI.exportToFile(self.doc, "file_path", "file_format", [])
+        self.session.finishOperation()
+
+if __name__ == "__main__":
+    unittest.main()