Skip to content

Commit

Permalink
Fix Connect Health check logic for TestProxySslBindings (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
ehunter1878 authored and madhavpatel6 committed Mar 1, 2019
1 parent f96cc46 commit 22d5a61
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
6 changes: 5 additions & 1 deletion diagnosticsModule/Private/TestUtilities.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -270,9 +270,13 @@ Function TestAdfsProxyHealth()
"TestNonSelfSignedCertificatesInRootStore", `
"TestSelfSignedCertificatesInIntermediateCaStore");

if ([string]::IsNullOrWhiteSpace($sslThumbprint) -and -not (IsExecutedByConnectHealth))
if ([string]::IsNullOrWhiteSpace($sslThumbprint))
{
# If Connect Health executed this test there is no way to find this thumbprint so we skip the test
if (-not (IsExecutedByConnectHealth))
{
$functionsToRun += "TestProxySslBindings"
}
}
else
{
Expand Down
8 changes: 3 additions & 5 deletions diagnosticsModule/Test/Private/AdfsHealthChecks.Test.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -380,11 +380,9 @@ InModuleScope ADFSDiagnosticsModule {
# Assert
$ret.Result | should beexactly Fail
$ret.Detail | should beexactly "There were missing certificates on some of the secondary servers. There may be an issue with proxy trust propogation."\
$_adfsServers | ForEach-Object {
$server = $_
$_missingCertificates | ForEach-Object {
$ret.Output.ErroneousCertificates[$server] | should contain $_
}
Foreach ($server in $_adfsServers)
{
$ret.Output.ErroneousCertificates[$server] | should be $_missingCertificates
}
}

Expand Down

0 comments on commit 22d5a61

Please sign in to comment.