Skip to content

[docs] Fix outdated API references in management tests documentation - #48418

Open
Ali Satwat Khan (alisatwat3) wants to merge 7 commits into
Azure:mainfrom
alisatwat3:fix/48400-mgmt-tests-doc-references
Open

[docs] Fix outdated API references in management tests documentation#48418
Ali Satwat Khan (alisatwat3) wants to merge 7 commits into
Azure:mainfrom
alisatwat3:fix/48400-mgmt-tests-doc-references

Conversation

@alisatwat3

@alisatwat3 Ali Satwat Khan (alisatwat3) commented Aug 4, 2026

Copy link
Copy Markdown

Description

Fixes #48400.

Updates doc/dev/mgmt/tests.md to match the current credential and management-test implementation:

  • Use client_secret and tenant_id with ClientSecretCredential.
  • Replace the obsolete mgmt_settings_real.py workflow with the environment-variable-based live-test setup, including AZURE_SUBSCRIPTION_ID.
  • Clarify that AzureMgmtRecordedTestCase uses fake credentials during playback and environment-based credentials in live mode.

All SDK Contribution checklist:

  • The pull request does not introduce [breaking changes]
  • CHANGELOG is updated for new features, bug fixes or other significant changes. Not applicable; documentation-only correction.
  • I have read the contribution guidelines.

General Guidelines and Best Practices

  • Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message.

Testing Guidelines

  • Pull request includes test coverage for the included changes. Not applicable; documentation-only change validated with git diff --check and cross-checked against the current test framework implementation.

@github-actions github-actions Bot added Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization. labels Aug 4, 2026
@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Thank you for your contribution Ali Satwat Khan (@alisatwat3)! We will review the pull request and get back to you soon.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
8 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

@alisatwat3
Ali Satwat Khan (alisatwat3) marked this pull request as ready for review August 4, 2026 09:06
Copilot AI balanced review requested due to automatic review settings August 4, 2026 09:06
@alisatwat3
Ali Satwat Khan (alisatwat3) requested a review from a team as a code owner August 4, 2026 09:06
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
8 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates management testing documentation to use current credential parameter, helper, and base-class names.

Changes:

  • Corrects ClientSecretCredential keyword arguments.
  • Updates credential helper and test base-class references.

Comment thread doc/dev/mgmt/tests.md Outdated
Copilot AI review requested due to automatic review settings August 4, 2026 09:48

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Suppressed comments (1)

doc/dev/mgmt/tests.md:172

  • create_mgmt_client() does not perform checks that verify the client was created successfully; it only constructs the client, applies playback configuration, and returns it (azure_recorded_testcase.py:100-122). This wording can incorrectly imply failures will be detected before the first service operation, so remove the validation claim.
3. The `create_mgmt_client()` helper method of `AzureMgmtRecordedTestCase` creates a client object using fake credentials during playback or credentials from environment variables in live mode, with some checks to make sure it's created successfully and cause the unit test to fail if not. You should use it for any clients you create.

Copilot AI review requested due to automatic review settings August 4, 2026 11:38

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Copilot AI review requested due to automatic review settings August 4, 2026 18:34

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Copilot AI review requested due to automatic review settings August 4, 2026 20:47

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Suppressed comments (1)

doc/dev/mgmt/tests.md:102

  • These two commands are not copyable as written: both CMD and POSIX shells interpret the unquoted </> placeholder characters as redirection operators rather than part of the value. Quote the assignment so readers can run the documented commands and then replace the placeholder safely.
set AZURE_SUBSCRIPTION_ID=<value>           # Windows CMD
export AZURE_SUBSCRIPTION_ID=<value>        # Linux shell only

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[docs] Fix outdated API references in doc/dev/mgmt/tests.md

2 participants