diff --git a/src/Mod/CAM/CAMTests/TestPathHelix.py b/src/Mod/CAM/CAMTests/TestPathHelix.py index f1561851d3..18d0df432f 100644 --- a/src/Mod/CAM/CAMTests/TestPathHelix.py +++ b/src/Mod/CAM/CAMTests/TestPathHelix.py @@ -25,6 +25,7 @@ import pathlib import Draft import FreeCAD import Path +import Path.Base.SetupSheetOpPrototype as PathSetupSheetOpPrototype import Path.Main.Job as PathJob import Path.Op.Helix as PathHelix import CAMTests.PathTestUtils as PathTestUtils @@ -55,6 +56,12 @@ class TestPathHelix(PathTestUtils.PathTestBase): op = PathHelix.Create("Helix") op.Proxy.execute(op) + def testCreateWithPrototype(self): + """Verify a Helix can be created on a SetupSheet's prototype instead of a real document object""" + + ptt = PathSetupSheetOpPrototype.OpPrototype("Helix") + op = PathHelix.Create("OpPrototype.Helix", ptt) + def test01(self): """Verify Helix generates proper holes from model""" diff --git a/src/Mod/CAM/Path/Base/SetupSheetOpPrototype.py b/src/Mod/CAM/Path/Base/SetupSheetOpPrototype.py index 7052494f5a..c6cfb52958 100644 --- a/src/Mod/CAM/Path/Base/SetupSheetOpPrototype.py +++ b/src/Mod/CAM/Path/Base/SetupSheetOpPrototype.py @@ -224,6 +224,9 @@ class OpPrototype(object): def setEditorMode(self, name, mode): self.properties[name].setEditorMode(mode) + def setPropertyStatus(self, name, status): + pass + def getProperty(self, name): return self.properties[name]