Summary
A full Pester run against the dev branch surfaced 41 pre-existing test failures where the test file's assertions no longer match the cmdlet's actual implementation. These were discovered while validating PR #460 and are unrelated to that change.
The failures cluster into three patterns, all "test drift" — the cmdlet evolved but the test wasn't updated.
Pattern 1 — Stale [OutputType] assertions (10 tests)
Each test asserts $_.OutputType.Name | Should -Be 'X' where X does not match the cmdlet's actual [OutputType()] declaration.
| Test file |
Asserted (wrong) |
Actual cmdlet declares |
tests/lists/Add-TssListOption.Tests.ps1 |
Thycotic.PowerShell.List.ListItem |
Thycotic.PowerShell.List.Item |
tests/authentication/Close-TssSession.Tests.ps1 |
System.Boolean |
(check cmdlet) |
tests/configurations/Get-TssConfigurationBackup.Tests.ps1 |
Thycotic.PowerShell.Configuration.DbBackup |
(check cmdlet) |
tests/distributed-engines/Get-TssDistributedEngineServerCapabilities.Tests.ps1 |
Thycotic.PowerShell.DistributedEngines.ServerCapabilities |
(check cmdlet) |
tests/distributed-engines/New-TssDistributedEngineSiteConnector.Tests.ps1 |
Thycotic.PowerShell.DistributedEngines.SiteConnector |
(check cmdlet) |
tests/ipaddress-restrictions/New-TssIpRestriction.Tests.ps1 |
Thycotic.PowerShell.IpRestrictions.IpAddress |
Thycotic.PowerShell.IpRestrictions.IpRestriction |
tests/distributed-engines/Remove-TssDistributedEngine.Tests.ps1 |
Thycotic.PowerShell.DistributedEngines.EngineActivation |
(check cmdlet) |
tests/configurations/Set-TssConfigurationGeneral.Tests.ps1 |
Thycotic.PowerShell.Configuration.General |
(check cmdlet) |
tests/secret-policies/Set-TssSecretPolicy.Tests.ps1 |
Class name (placeholder, never filled in) |
(check cmdlet) |
tests/metadata/Update-TssMetadataField.Tests.ps1 |
Thycotic.PowerShell.Metadata.Field |
(check cmdlet) |
Pattern 2 — Parameter assertion drift (7 tests)
Each test declares $knownParameters that no longer matches the cmdlet's real parameter set — either a renamed/removed parameter is still asserted, or a new one is missing.
| Test file |
Mismatch |
tests/authentication/New-TssSession.Tests.ps1 |
Missing SkipCertificateCheck (added in v0.62.0) |
tests/configurations/Search-TssAutoExportStorage.Tests.ps1 |
SortBy no longer on cmdlet |
tests/directory-services/New-TssDirectoryService.Tests.ps1 |
Name vs DomainName rename |
tests/distributed-engines/Get-TssDistributedEngineConnectorCredential.Tests.ps1 |
Asserts SiteConnectorId which no longer exists |
tests/distributed-engines/Register-TssDistributedEngine.Tests.ps1 |
Id → EngineId rename |
tests/distributed-engines/Unregister-TssDistributedEngine.Tests.ps1 |
Id → EngineId rename |
tests/distributed-engines/Set-TssDistributedEngineSiteConnector.Tests.ps1 |
7 params (Id, Name, Hostname, UseSsl, Port, TransportType, Enable) no longer match cmdlet |
tests/ipaddress-restrictions/Remove-TssIpRestrictionUser.Tests.ps1 |
UserId no longer on cmdlet |
tests/secrets/Update-TssSecret.Tests.ps1 |
noAutoCheckout no longer on cmdlet |
Pattern 3 — BeforeAll / Context setup failures (2 tests)
Test-TssDistributedEngineSiteConnector and Update-TssList both throw CommandNotFoundException: The term 'Endpoint' is not recognized during their Context "<commandName> functions.Checking" setup. The Endpoint helper either was renamed or removed; the test setup wasn't updated.
Proposed resolution
Single PR that:
- Re-derives each cmdlet's actual
[OutputType()] value and updates the matching Should -Be assertion.
- Re-derives each cmdlet's actual parameter set and rewrites the
$knownParameters arrays.
- Investigates the
Endpoint reference in the two failing context blocks and either restores the helper or rewrites the setup.
Approach: one-pass sweep similar to PR #460. Each test file gets a single-line or small-block change. Expected impact: 41 fewer failures in the runTests.ps1 baseline, no behavior change to any cmdlet.
How discovered
Full Pester suite run via tests/runTests.ps1 on the v0.62.1 branch (PR #460) on 2026-06-29. Local log captured at tempScripts/pester-459-run.log (not committed).
Summary
A full Pester run against the
devbranch surfaced 41 pre-existing test failures where the test file's assertions no longer match the cmdlet's actual implementation. These were discovered while validating PR #460 and are unrelated to that change.The failures cluster into three patterns, all "test drift" — the cmdlet evolved but the test wasn't updated.
Pattern 1 — Stale
[OutputType]assertions (10 tests)Each test asserts
$_.OutputType.Name | Should -Be 'X'whereXdoes not match the cmdlet's actual[OutputType()]declaration.tests/lists/Add-TssListOption.Tests.ps1Thycotic.PowerShell.List.ListItemThycotic.PowerShell.List.Itemtests/authentication/Close-TssSession.Tests.ps1System.Booleantests/configurations/Get-TssConfigurationBackup.Tests.ps1Thycotic.PowerShell.Configuration.DbBackuptests/distributed-engines/Get-TssDistributedEngineServerCapabilities.Tests.ps1Thycotic.PowerShell.DistributedEngines.ServerCapabilitiestests/distributed-engines/New-TssDistributedEngineSiteConnector.Tests.ps1Thycotic.PowerShell.DistributedEngines.SiteConnectortests/ipaddress-restrictions/New-TssIpRestriction.Tests.ps1Thycotic.PowerShell.IpRestrictions.IpAddressThycotic.PowerShell.IpRestrictions.IpRestrictiontests/distributed-engines/Remove-TssDistributedEngine.Tests.ps1Thycotic.PowerShell.DistributedEngines.EngineActivationtests/configurations/Set-TssConfigurationGeneral.Tests.ps1Thycotic.PowerShell.Configuration.Generaltests/secret-policies/Set-TssSecretPolicy.Tests.ps1Class name(placeholder, never filled in)tests/metadata/Update-TssMetadataField.Tests.ps1Thycotic.PowerShell.Metadata.FieldPattern 2 — Parameter assertion drift (7 tests)
Each test declares
$knownParametersthat no longer matches the cmdlet's real parameter set — either a renamed/removed parameter is still asserted, or a new one is missing.tests/authentication/New-TssSession.Tests.ps1SkipCertificateCheck(added in v0.62.0)tests/configurations/Search-TssAutoExportStorage.Tests.ps1SortByno longer on cmdlettests/directory-services/New-TssDirectoryService.Tests.ps1NamevsDomainNamerenametests/distributed-engines/Get-TssDistributedEngineConnectorCredential.Tests.ps1SiteConnectorIdwhich no longer existstests/distributed-engines/Register-TssDistributedEngine.Tests.ps1Id→EngineIdrenametests/distributed-engines/Unregister-TssDistributedEngine.Tests.ps1Id→EngineIdrenametests/distributed-engines/Set-TssDistributedEngineSiteConnector.Tests.ps1Id,Name,Hostname,UseSsl,Port,TransportType,Enable) no longer match cmdlettests/ipaddress-restrictions/Remove-TssIpRestrictionUser.Tests.ps1UserIdno longer on cmdlettests/secrets/Update-TssSecret.Tests.ps1noAutoCheckoutno longer on cmdletPattern 3 —
BeforeAll/Contextsetup failures (2 tests)Test-TssDistributedEngineSiteConnectorandUpdate-TssListboth throwCommandNotFoundException: The term 'Endpoint' is not recognizedduring theirContext "<commandName> functions.Checking"setup. TheEndpointhelper either was renamed or removed; the test setup wasn't updated.Proposed resolution
Single PR that:
[OutputType()]value and updates the matchingShould -Beassertion.$knownParametersarrays.Endpointreference in the two failing context blocks and either restores the helper or rewrites the setup.Approach: one-pass sweep similar to PR #460. Each test file gets a single-line or small-block change. Expected impact: 41 fewer failures in the
runTests.ps1baseline, no behavior change to any cmdlet.How discovered
Full Pester suite run via
tests/runTests.ps1on the v0.62.1 branch (PR #460) on 2026-06-29. Local log captured attempScripts/pester-459-run.log(not committed).