Skip to content

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

Description

@github-actions

Summary

Reviewed all markdown files under doc/ and doc/dev/ for inconsistencies with the current source code. One file had outdated API references.

Changes in doc/dev/mgmt/tests.md

Issue Fix
ClientSecretCredential(secret=...) Changed to client_secret= (correct parameter name per azure-identity)
ClientSecretCredential(tenant=...) Changed to tenant_id= (correct parameter name per azure-identity)
get_azure_core_credential() (singular) Changed to get_azure_core_credentials() (plural) — matches mgmt_settings_fake.py
get_credential() (singular) Changed to get_credentials() (plural) — matches actual helper function name
AzureTestCase class reference Changed to AzureMgmtRecordedTestCaseAzureTestCase no longer exists

Files verified clean (no changes needed)

  • doc/README.md, doc/dev/README.md, doc/tool_usage_guide.md
  • doc/dev/tests.md, doc/dev/dev_setup.md, doc/dev/release.md
  • doc/dev/pylint_checking.md, doc/dev/static_type_checking.md, doc/dev/static_type_checking_cheat_sheet.md
  • All other doc/ and doc/dev/ markdown files

No stale tox references were found (docs already use azpysdk). No broken internal links. No setup.py vs pyproject.toml mismatches.

Generated by Documentation Consistency Check · 262.9 AIC · ⌖ 12.2 AIC · ⊞ 5.8K ·


Note

This was originally intended as a pull request, but GitHub Actions is not permitted to create or approve pull requests in this repository.
The changes have been pushed to branch doc/fix-mgmt-tests-api-references-b4c97c893c05f6c0.

Click here to create the pull request

To fix the permissions issue, go to SettingsActionsGeneral and enable Allow GitHub Actions to create and approve pull requests. See also: gh-aw FAQ

Show patch preview (62 of 62 lines)
From d395145311ea7297a2733317323e2dcefbc2e155 Mon Sep 17 00:00:00 2001
From: "github-actions[bot]" <github-actions[bot]@users.noreply.github.com>
Date: Mon, 3 Aug 2026 06:05:28 +0000
Subject: [PATCH] Fix outdated API references in doc/dev/mgmt/tests.md

- Fix ClientSecretCredential parameter names: secret= -> client_secret=, tenant= -> tenant_id=
- Fix function name references: get_azure_core_credential -> get_azure_core_credentials, get_credential -> get_credentials
- Fix class reference: AzureTestCase -> AzureMgmtRecordedTestCase

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
 doc/dev/mgmt/tests.md | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/doc/dev/mgmt/tests.md b/doc/dev/mgmt/tests.md
index 7f7bfdd4..44e71108 100644
--- a/doc/dev/mgmt/tests.md
+++ b/doc/dev/mgmt/tests.md
@@ -77,8 +77,8 @@ from azure.identity import ClientSecretCredential
 
 credentials = ClientSecretCredential(
     client_id = os.environ['AZURE_CLIENT_ID'],
-    secret = os.environ['AZURE_CLIENT_SECRET'],
-    tenant = os.environ['AZURE_TENANT_ID']
+    client_secret = os.environ['AZURE_CLIENT_SECRET'],
+    tenant_id = os.environ['AZURE_TENANT_ID']
 )

Or you can use DefaultAzureCredential, which we prefer.
@@ -98,9 +98,9 @@ In live mode, you need to use real credentials like those you obtained in the pr
Then make the following changes:

  • Change the value of the SUBSCRIPTION_ID constant to your subscription ID. (If you don't have it, you can find it in the "Overview" section of the "Subscriptions" blade in the [Azure portal][azure_portal].)
    -* Change the get_azure_core_credential() function to construct and return a ClientSecretCredential:
    +* Change the get_azure_core_credentials() function to construct and return a ClientSecretCredential:
-def get_azure_core_credential(**kwargs):
+def get_azure_core_credentials(**kwargs):
    from azure.identity import ClientSecretCredential
    import os
    
... (truncated)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions