Write the first slice of cmdlet-binding tests against VisioPowerShell/Commands/. The audit at #154 (closed) established that ~56 of 70 cmdlets have no dedicated test, the same regression class as the four bugs that shipped in module 4.6.1 (Lock-VisioShape / Unlock-VisioShape switch binding, Export-VisioShape inverted file-existence check, New-VisioShape polyline / Bezier minimum-point validation).
Scope (first slice)
Suggested in docs/futures/test-coverage-gaps.md:
Approach
The harness is already in place: VisioPSSession.InvokeScript<T> hosts a real PowerShell runspace with the module loaded. Add fixture-style tests, one file per cmdlet group.
Why
Cmdlet-binding tests catch a distinct regression class from the underlying-library tests: parameter binding (positional, mandatory, switches), ParameterSetName resolution, pipeline binding, output piping. The 4.6.1 bugs all sit in this layer.
Out of scope
Closing the entire ~56-cmdlet gap. The audit suggested a capped first slice rather than chasing the whole list. Subsequent slices can be filed as follow-ups once this lands.
Cross-refs
Effort
M.
Write the first slice of cmdlet-binding tests against
VisioPowerShell/Commands/. The audit at #154 (closed) established that ~56 of 70 cmdlets have no dedicated test, the same regression class as the four bugs that shipped in module 4.6.1 (Lock-VisioShape/Unlock-VisioShapeswitch binding,Export-VisioShapeinverted file-existence check,New-VisioShapepolyline / Bezier minimum-point validation).Scope (first slice)
Suggested in
docs/futures/test-coverage-gaps.md:Lock-VisioShape,Unlock-VisioShape,Export-VisioShape,New-VisioShape(polyline / Bezier validation paths).Connect-VisioShape(couples to Add ValueFromPipeline parameter set to Connect-VisioShape #163 / Investigate switching VisioCmdlet base from Cmdlet to PSCmdlet #164).Scripting_LockTests.csandScripting_LayerTests.cscovering command-set classes that have no dedicated test.VTest.Models\FormsTests.cs(the only sub-package ofVisioAutomation.Modelswith zero direct coverage).Approach
The harness is already in place:
VisioPSSession.InvokeScript<T>hosts a real PowerShell runspace with the module loaded. Add fixture-style tests, one file per cmdlet group.Why
Cmdlet-binding tests catch a distinct regression class from the underlying-library tests: parameter binding (positional, mandatory, switches),
ParameterSetNameresolution, pipeline binding, output piping. The 4.6.1 bugs all sit in this layer.Out of scope
Closing the entire ~56-cmdlet gap. The audit suggested a capped first slice rather than chasing the whole list. Subsequent slices can be filed as follow-ups once this lands.
Cross-refs
docs/futures/test-coverage-gaps.md, gap list with priority calls.Effort
M.