diff --git a/arm/.global/global.module.tests.ps1 b/arm/.global/global.module.tests.ps1 index d391938fb1..52fd8a4fb3 100644 --- a/arm/.global/global.module.tests.ps1 +++ b/arm/.global/global.module.tests.ps1 @@ -719,7 +719,7 @@ Describe 'Deployment template tests' -Tag Template { $primaryResourceType = (Split-Path $TemplateFilePath -Parent).Replace('\', '/').split('/arm/')[1] $primaryResourceTypeResource = $templateContent.resources | Where-Object { $_.type -eq $primaryResourceType } - if ($primaryResourceTypeResource.keys -contains 'location') { + if ($primaryResourceTypeResource.keys -contains 'location' -and $primaryResourceTypeResource.location -ne 'global') { # If the main resource has a location property, an output should be returned too $outputs.keys | Should -Contain 'location'