feat: wire Part Design task parameters

This commit is contained in:
2026-08-02 19:44:54 -04:00
parent ed3d1cddc5
commit 288260b1e2
3 changed files with 22 additions and 8 deletions

View File

@@ -758,7 +758,7 @@ test('Part Design feature tasks commit a document object and remain undoable', (
const before = facade.app.document.getActive()
facade.gui.command.execute({ commandId: 'pad' })
assert.equal(facade.task.getActive()?.commandId, 'pad')
facade.task.update({ length: 42, reversed: false })
facade.task.update({ length: 55, reversed: true, midplane: true })
facade.task.apply()
const committed = facade.app.document.getActive()
@@ -767,6 +767,9 @@ test('Part Design feature tasks commit a document object and remain undoable', (
assert.equal(committed.version, before.version + 1)
assert.equal(facade.selection.getObjectId(), 'pad001')
assert.equal(committed.dirty, true)
assert.equal(committed.objects.find((object) => object.id === 'pad001')?.properties.find((property) => property.name === 'Length')?.value, 55)
assert.equal(committed.objects.find((object) => object.id === 'pad001')?.properties.find((property) => property.name === 'Reversed')?.value, true)
assert.equal(committed.objects.find((object) => object.id === 'pad001')?.properties.find((property) => property.name === 'Midplane')?.value, true)
facade.history.undo()
assert.equal(facade.app.document.getActive().tree.some((item) => item.id === 'pad001'), false)