[AKS] az aks update: Test stability fix for test_aks_update_with_enable_disable_azure_monitor_app_monitoring#33261
[AKS] az aks update: Test stability fix for test_aks_update_with_enable_disable_azure_monitor_app_monitoring#33261
az aks update: Test stability fix for test_aks_update_with_enable_disable_azure_monitor_app_monitoring#33261Conversation
️✔️AzureCLI-FullTest
|
|
Hi @tokaplan, |
️✔️AzureCLI-BreakingChangeTest
|
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
a3590c5 to
df405fb
Compare
az aks update: Test stability fix for test_aks_update_with_enable_disable_azure_monitor_app_monitoring
|
/azp run |
|
Commenter does not have sufficient privileges for PR 33261 in repo Azure/azure-cli |
There was a problem hiding this comment.
Pull request overview
This PR stabilizes AKS scenario testing by converting the flaky az aks update scenario for enabling/disabling Azure Monitor Application Monitoring to run only in live mode (bypassing VCR playback/recording issues).
Changes:
- Mark
test_aks_update_with_enable_disable_azure_monitor_app_monitoringas@live_only()to avoid VCR nondeterminism. - Replace the previous subprocess-based wait workaround with an in-test
aks waitcall and add a retry loop around the disable operation. - Remove the now-unused VCR recording YAML for the live-only test.
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py |
Makes the app-monitoring enable/disable update scenario live-only and adjusts wait/retry behavior to reduce transient failures. |
src/azure-cli/azure/cli/command_modules/acs/tests/latest/recordings/test_aks_update_with_enable_disable_azure_monitor_app_monitoring.yaml |
Deletes the VCR recording since the test no longer runs under playback/recording. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
|
@yanzhudd please merge, this has been approved and all checks have passed. Thank you! |
Back-to-back AKS update tests are inherently incompatible with VCR cassette recording — the CI runs against real Azure without setting AZURE_TEST_RUN_LIVE, causing VCR to replay stale cassette responses that don't match the actual cluster state. Mark the test @live_only() to match the pattern used by the analogous metrics enable/disable test, and simplify the wait to use self.cmd() directly since VCR is no longer involved. Delete the recording file. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
{AKS} az aks update: test stability fix for test_aks_update_with_enable_disable_azure_monitor_app_monitoring.
Passing run is here: passing run.
Making a test that involves creation and a subsequent update of a managed cluster live-only. Waiting for operation completions creates a lot of issues for VCR recording/playback due to unpredictability of the exact recording between runs, so we are moving this test to the same live-only pattern as test_aks_update_with_azuremonitormetrics.
Related command
This checklist is used to make sure that common guidelines for a pull request are followed.
[x ] The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.