Problem
Functional/playback tests need Azure subscription, tenant, and location. Currently developers must manually set env vars (AZD_TEST_AZURE_SUBSCRIPTION_ID, etc.) each session. The non-CI fallback only covers subscription/location via defaults.*, not tenant, and conflates personal defaults with test config.
Proposal
Add defaults.test.* keys to azd config:
azd config set defaults.test.subscription 4d042dc6-fe17-4698-a23f-ec6a8d1e98f4
azd config set defaults.test.tenant 70a036f6-8e4d-4615-bad6-149c02e7720d
azd config set defaults.test.location eastus2
Changes needed
cli/azd/test/functional/cli_test.go - Update cliConfig.init() resolution order: env vars -> defaults.test.* -> defaults.*
cli/azd/magefile.go - Read defaults.test.* from azd config and pass as env vars to test subprocesses (unit + playback)
azd-preflight skill - Document that azd config set defaults.test.* is the recommended one-time setup for local preflight with live test resources
Developer experience
One-time setup:
azd config set defaults.test.subscription 4d042dc6-...
azd config set defaults.test.tenant 70a036f6-...
azd config set defaults.test.location eastus2
Then mage preflight and the azd-preflight skill automatically pick up the TME subscription - no env vars, no .env files.
Problem
Functional/playback tests need Azure subscription, tenant, and location. Currently developers must manually set env vars (
AZD_TEST_AZURE_SUBSCRIPTION_ID, etc.) each session. The non-CI fallback only covers subscription/location viadefaults.*, not tenant, and conflates personal defaults with test config.Proposal
Add
defaults.test.*keys toazd config:Changes needed
cli/azd/test/functional/cli_test.go- UpdatecliConfig.init()resolution order: env vars ->defaults.test.*->defaults.*cli/azd/magefile.go- Readdefaults.test.*from azd config and pass as env vars to test subprocesses (unit + playback)azd-preflightskill - Document thatazd config set defaults.test.*is the recommended one-time setup for local preflight with live test resourcesDeveloper experience
One-time setup:
Then
mage preflightand theazd-preflightskill automatically pick up the TME subscription - no env vars, no.envfiles.