Conversation
| Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates Azure PowerShell live test scripts to reduce flakiness in Websites and Storage live tests by adjusting the default region for web app scenarios and relaxing job-state assertions for Storage file operations.
Changes:
- Updated Websites live tests to default web app location from
westustoeastus. - Commented out assertions that require background jobs to end in
"Completed"for Storage file upload/download operations, while still asserting no job errors.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/Websites/LiveTests/Websites/TestLiveScenarios.ps1 | Switches default web app deployment location to eastus across scenarios. |
| src/Storage/LiveTests/Storage.Management/FileTests.ps1 | Removes strict job state equality assertions after file operations to reduce transient failures. |
Comments suppressed due to low confidence (2)
src/Websites/LiveTests/Websites/TestLiveScenarios.ps1:12
- Within this scenario block,
$webLocationis defined butNew-AzAppServicePlanuses$weblocation. PowerShell is case-insensitive, but mixing variable casing/names makes the script harder to read and can confuse tooling; use the same$webLocationvariable consistently for the-Locationargument.
$webLocation = "eastus"
$whpName = New-LiveTestResourceName
$tier = "Shared"
$serverFarm = New-AzAppServicePlan -ResourceGroupName $rgName -Name $whpName -Location $weblocation -Tier $tier
$actual = New-AzWebApp -ResourceGroupName $rgName -Name $webAppName -Location $webLocation -AppServicePlan $whpName
src/Websites/LiveTests/Websites/TestLiveScenarios.ps1:30
- Same as above:
$webLocationis defined, butNew-AzAppServicePlanuses$weblocationfor-Location. Please standardize on$webLocationfor clarity and consistency.
$webLocation = "eastus"
$whpName = New-LiveTestResourceName
$tier = "Shared"
$serverFarm = New-AzAppServicePlan -ResourceGroupName $rgName -Name $whpName -Location $weblocation -Tier $tier
$null = New-AzWebApp -ResourceGroupName $rgName -Name $webAppName -Location $webLocation -AppServicePlan $whpName
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull request updates test scripts for both Storage and Websites live tests. The main changes involve switching the default test location for web app scenarios and modifying assertions in file operation tests.
Web App Test Location Updates:
$webLocationfrom"westus"to"eastus"in all relevant web app live test scenarios withinTestLiveScenarios.ps1.File Operation Test Assertion Updates:
"Completed"after file operations inFileTests.ps1, likely to prevent test failures due to transient job state issues, while still ensuring no errors occurred.Mandatory Checklist
Please choose the target release of Azure PowerShell. (⚠️ Target release is a different concept from API readiness. Please click below links for details.)
Check this box to confirm: I have read the Submitting Changes section of
CONTRIBUTING.mdand reviewed the following information:ChangeLog.mdfile(s) appropriatelysrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.## Upcoming Releaseheader in the past tense.ChangeLog.mdif no new release is required, such as fixing test case only.