diff --git a/sdk/timeseriesinsights/Azure.Iot.TimeSeriesInsights/tests/prerequisites/setup.ps1 b/sdk/timeseriesinsights/Azure.Iot.TimeSeriesInsights/tests/prerequisites/setup.ps1 index bded8c149248..7f91ea000d14 100644 --- a/sdk/timeseriesinsights/Azure.Iot.TimeSeriesInsights/tests/prerequisites/setup.ps1 +++ b/sdk/timeseriesinsights/Azure.Iot.TimeSeriesInsights/tests/prerequisites/setup.ps1 @@ -124,7 +124,7 @@ az deployment group create --resource-group $ResourceGroup --name $($Environment # Even though the output variable names are all capital letters in the script, ARM turns them into a strange casing # and we have to use that casing in order to get them from the deployment outputs. -$dataAccessFqdn = az deployment group show -g $ResourceGroup -n $($EnvironmentName.ToLower()) --query 'properties.outputs.dataAccessFQDN.value' --output tsv +$dataAccessFqdn = az deployment group show -g $ResourceGroup -n $($EnvironmentName.ToLower()) --query 'properties.outputs.TIMESERIESINSIGHTS_URL.value' --output tsv Write-Host("`nSet a new client secret for $appId`n") $appSecret = az ad app credential reset --id $appId --years 2 --query 'password' --output tsv diff --git a/sdk/timeseriesinsights/test-resources.bicep b/sdk/timeseriesinsights/test-resources.bicep index 7376519c3dd8..4cebea54f1f9 100644 --- a/sdk/timeseriesinsights/test-resources.bicep +++ b/sdk/timeseriesinsights/test-resources.bicep @@ -23,6 +23,7 @@ param environmentName string { description: 'Name of the environment. The name cannot include: \'<\', \'>\', \'%\', \'&\', \':\', \'\\\', \'?\', \'/\' and any control characters. All other characters are allowed.' } maxLength: 90 + default: concat(az.resourceGroup().name, '-TSI') } param consumerGroupName string { @@ -173,4 +174,4 @@ resource storageaccount 'Microsoft.Storage/storageAccounts@2018-11-01' = { properties: {} } -output dataAccessFQDN string = '${environment.properties.dataAccessFqdn}' \ No newline at end of file +output TIMESERIESINSIGHTS_URL string = '${environment.properties.dataAccessFqdn}' \ No newline at end of file diff --git a/sdk/timeseriesinsights/test-resources.json b/sdk/timeseriesinsights/test-resources.json index 5109d1ca78f0..18385eb79206 100644 --- a/sdk/timeseriesinsights/test-resources.json +++ b/sdk/timeseriesinsights/test-resources.json @@ -27,7 +27,8 @@ "maxLength": 90, "metadata": { "description": "Name of the environment. The name cannot include: '<', '>', '%', '&', ':', '\\', '?', '/' and any control characters. All other characters are allowed." - } + }, + "defaultValue": "[concat(resourceGroup().name, '-TSI')]" }, "consumerGroupName": { "type": "string", @@ -190,7 +191,7 @@ } ], "outputs": { - "dataAccessFQDN": { + "TIMESERIESINSIGHTS_URL": { "type": "string", "value": "[reference(resourceId('Microsoft.TimeSeriesInsights/environments', parameters('environmentName'))).dataAccessFqdn]" }