]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/FeaturesAPI/Test/APIParam_Translation.py
Salome HOME
Debug.
[modules/shaper.git] / src / FeaturesAPI / Test / APIParam_Translation.py
index 53b1767811eeb964d8368fb62090e1c9eec13eb5..f5ad81dce0ba99ce1b7c0bd1233406d1fe544614 100644 (file)
@@ -32,4 +32,12 @@ assert (aTranslation1 is not None)
 aSession.startOperation()
 aTranslation2 = model.addTranslation(aDocument, [model.selection("SOLID", "Box_1_1")], 10, 10, 10).result()
 aSession.finishOperation()
-assert (aTranslation2 is not None)
\ No newline at end of file
+assert (aTranslation2 is not None)
+
+# Perform a translation by two points
+aSession.startOperation()
+aPoint1 = model.addPoint(aDocument, 0, 0, 0).result()
+aPoint2 = model.addPoint(aDocument, 10, 10, 0).result()
+aTranslation3 = model.addTranslation(aDocument, [model.selection("SOLID", "Box_1_1")], aPoint1, aPoint2).result()
+aSession.finishOperation()
+assert (aTranslation3 is not None)
\ No newline at end of file