Skip to content

Commit 6d74446

Browse files
bmoore-msftazure-quickstart-templates pipeline
and
azure-quickstart-templates pipeline
authored
704 (#705)
Co-authored-by: azure-quickstart-templates pipeline <[email protected]>
1 parent b98c036 commit 6d74446

File tree

2 files changed

+28
-1
lines changed

2 files changed

+28
-1
lines changed

arm-ttk/testcases/deploymentTemplate/apiVersions-Should-Be-Recent-In-Reference-Functions.test.ps1

+10-1
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,18 @@ param(
2828
# Test Run Date - date to use when doing comparisons, if not current date (used for unit testing against and old cache)
2929
[Parameter(Mandatory = $false, Position = 3)]
3030
[datetime]
31-
$TestDate = [DateTime]::Now
31+
$TestDate = [DateTime]::Now,
32+
33+
[Parameter(Mandatory = $true)]
34+
[PSCustomObject]
35+
$TemplateMetadata
3236
)
3337

38+
# bicep - if this is a bicep file, skip since the apiVersions are implicit (most of the time)
39+
if( $TemplateMetadata._generator.name -eq 'bicep') {
40+
continue
41+
}
42+
3443
$foundReferences = $TemplateText |
3544
?<ARM_Template_Function> -FunctionName 'reference|list\w{0,}'
3645

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
3+
"contentVersion": "1.0.0.0",
4+
"metadata": {
5+
"_generator": {
6+
"name": "bicep",
7+
"version": "0.5.6.12127",
8+
"templateHash": "16815708176905569328"
9+
}
10+
},
11+
"parameters": {},
12+
"functions": [],
13+
"variables": {},
14+
"resources": [],
15+
"outputs": {
16+
"oldIPReference": "[reference(resourceId('Microsoft.Network/publicIPAddresses', 'test'), '2015-06-15', 'Full')]"
17+
}
18+
}

0 commit comments

Comments
 (0)