Fix aspnet e2e tests

- add `-CliManifestName` option to run-tests.ps1 command
- pass `-CliManifestName` and more from YAML to run-tests.ps1
  - pass access token suffix
This commit is contained in:
Matt Mitchell 2019-05-02 08:44:51 -07:00 committed by Doug Bunting
parent c7287509a0
commit 11ab4bd196
2 changed files with 5 additions and 4 deletions

View File

@ -37,7 +37,7 @@ jobs:
inputs:
versionSpec: $(Node.Version)
- powershell: |
test/Cli.FunctionalTests/run-tests.ps1 -ci -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
test/Cli.FunctionalTests/run-tests.ps1 -ci -CliManifestName $(CliManifestName) -RestoreSources $(PB_RestoreSource) -AccessTokenSuffix '$(AccessTokenSuffix)' -AssetRootUrl $(PB_AssetRootUrl) -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
condition: ne(variables['PB_SkipTests'], 'true')
displayName: Run E2E tests
@ -73,7 +73,7 @@ jobs:
inputs:
versionSpec: $(Node.Version)
- powershell: |
test/Cli.FunctionalTests/run-tests.ps1 -ci -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
test/Cli.FunctionalTests/run-tests.ps1 -ci -CliManifestName $(CliManifestName) -RestoreSources $(PB_RestoreSource) -AccessTokenSuffix '$(AccessTokenSuffix)' -AssetRootUrl $(PB_AssetRootUrl) -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
condition: ne(variables['PB_SkipTests'], 'true')
displayName: Run E2E tests
@ -119,7 +119,7 @@ jobs:
inputs:
versionSpec: $(Node.Version)
- powershell: |
test/Cli.FunctionalTests/run-tests.ps1 -ci -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
test/Cli.FunctionalTests/run-tests.ps1 -ci -CliManifestName $(CliManifestName) -RestoreSources $(PB_RestoreSource) -AccessTokenSuffix '$(AccessTokenSuffix)' -AssetRootUrl $(PB_AssetRootUrl) -ProdConManifestUrl $env:PRODCONMANIFESTURL -TestRuntimeIdentifier $(Test.RuntimeIdentifier) -AdditionalRestoreSources $env:ADDITIONALRESTORESOURCES
condition: ne(variables['PB_SkipTests'], 'true')
displayName: Run E2E tests

View File

@ -44,6 +44,7 @@ param(
$HostRid,
$ProdConManifestUrl,
$ProdConChannel = 'release/2.1',
$CliManifestName = "cli.xml",
$AdditionalRestoreSources
)
@ -115,7 +116,7 @@ try {
Write-Error "Missing required parameter: AssetRootUrl"
}
$AssetRootUrl = $AssetRootUrl.TrimEnd('/')
$cliMetadataUrl = "$AssetRootUrl/orchestration-metadata/manifests/cli.xml${AccessTokenSuffix}"
$cliMetadataUrl = "$AssetRootUrl/orchestration-metadata/manifests/${CliManifestName}${AccessTokenSuffix}"
Write-Host "CliMetadataUrl: $cliMetadataUrl"
[xml] $cli = Invoke-RestMethod $cliMetadataUrl
$sdkVersion = $cli.Build.ProductVersion