Skip to content

Move smoke tests to Azure DevOps with Entra ID auth - #2641

Open
Dayenne Souza (dayesouza) wants to merge 6 commits into
mainfrom
ado-entra-ci-tests
Open

Dayenne Souza (dayesouza) wants to merge 6 commits into
mainfrom
ado-entra-ci-tests

Conversation

@dayesouza

@dayesouza Dayenne Souza (dayesouza) commented Nov 25, 2026 •

Copy link
Copy Markdown
Contributor

Description

Move the Azure OpenAI-backed smoke tests from GitHub Actions to Azure DevOps, and switch them from API-key auth to Entra ID auth.

The Azure OpenAI resource used by CI no longer accepts key auth, which is why the smoke tests currently fail on main. Entra ID login from GitHub-hosted Actions runners is blocked by the tenant's Conditional Access policy (see #2640), but it works from Azure DevOps through a workload-identity service connection.

Related Issues

Replaces #2640. The notebook tests move separately in #2645.

Proposed Changes

  • Smoke test fixtures (min-csv, text): replace api_key with auth_method: azure_managed_identity.
  • text fixture: drop the Azure AI Search api_key, so the vector store uses DefaultAzureCredential. The smoke test harness no longer requires the AZURE_AI_SEARCH_* variables for every fixture.
  • Add .azure-pipelines/python-smoke-tests.yml. It keeps the GitHub workflow's rules: pushes to main, PRs targeting main, draft PRs skipped, only the latest commit runs, markdown and .semversioner changes ignored, Ubuntu and Windows.
  • Remove .github/workflows/python-smoke-tests.yml.

Checklist

  • I have tested these changes locally.
  • I have reviewed the code changes.
  • I have updated the documentation (if necessary).
  • I have added appropriate unit tests (if applicable).

Additional Notes

Results from the latest full run of the smoke pipeline on this PR:

Pipeline Ubuntu Windows
GraphRAG Smoke Tests: min-csv passed passed
GraphRAG Smoke Tests: text passed passed

Earlier runs failed a timing assertion on generate_text_embeddings (400s limit) because the text-embedding-3-large deployment was limited to 20K tokens per minute. Its capacity has been raised to 300K tokens per minute; no test change was needed.

Known gaps:

  • The GitHub "Python Notebook Tests" check fails on this PR. It still uses key auth; it is replaced in Move notebook tests to Azure DevOps with Entra ID auth #2645.
  • The "only when Python files changed" step filter is not replicated; the tests run on any non-doc change.
  • Fork PRs build without the service connection, so these checks fail for them (the GitHub workflows could not read the secrets for forks either).
  • Logs are in a private Azure DevOps project, so external contributors see pass/fail but cannot open them.

🤖 Generated with Claude Code

Switch the min-csv and text fixtures from api_key to
auth_method: azure_managed_identity.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
Run the Azure OpenAI-backed tests in Azure DevOps with Entra ID auth
through a workload-identity service connection, with the same branch,
draft, and path rules as the GitHub workflows.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
These tests now run in Azure DevOps (.azure-pipelines/), where Entra ID
auth for Azure OpenAI is available.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
Drop the search api_key from the text fixture so the vector store uses
DefaultAzureCredential, stop the smoke harness from requiring the search
env vars for every fixture, and run all fixtures in the Azure DevOps
smoke pipeline.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
The notebook tests move to Azure DevOps separately in #2645, so restore
the GitHub notebook workflow and drop the notebook pipeline from this
branch.

Co-Authored-By: Claude Fable 5.2 <[email protected]>
@dayesouza Dayenne Souza (dayesouza) changed the title Run notebook and smoke tests in Azure DevOps with Entra ID auth Move smoke tests to Azure DevOps with Entra ID auth Nov 27, 2026

@BichengWang Bicheng (BichengWang) left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Reviewed 52904e3933266dae02bea55dfcf6ae57c3dea0b3 against current main.

The key removal is consistent across both smoke fixtures and the credential consumers. With only dummy endpoint variables and no API keys, both fixtures parse successfully; mocked sync/async completion and embedding calls receive the Azure token provider and no API key, and both Azure Search clients select DefaultAzureCredential.

With both AZURE_AI_SEARCH_* variables unset, invoking the decorated smoke test on main raises TypeError: str expected, not NoneType; this head reaches a stubbed indexer instead. No indexer or model call was executed. Both versions collect the smoke tests successfully. The existing configuration tests pass (10 tests), and local YAML assertions confirm both OS jobs invoke the smoke command inside AzureCLI@2 with both endpoint variables forwarded.

These are offline configuration and mocked wiring checks, not live Azure runs. I could not validate the service connection, tenant policy, RBAC, or private pipeline logs, and the failing hosted smoke checks still need resolution before merge. I found no additional code-level blocker in the changed files.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants