Skip to content

Update test utility to remove default resource group - #33853

Open
Matthew Metcalf (mrm9084) wants to merge 1 commit into
Azure:devfrom
mrm9084:patch-2
Open

Update test utility to remove default resource group#33853
Matthew Metcalf (mrm9084) wants to merge 1 commit into
Azure:devfrom
mrm9084:patch-2

Conversation

@mrm9084

@mrm9084 Matthew Metcalf (mrm9084) commented Aug 5, 2026

Copy link
Copy Markdown
Member

🤖 PR Validation — ❌ Action needed

Breaking Changes Tests
️✔️ None ❌ 128/130
❌AzureCLI-FullTest
️✔️acr
️✔️latest
️✔️3.12
️✔️3.14
️✔️acs
️✔️latest
️✔️3.12
️✔️3.14
️✔️advisor
️✔️latest
️✔️3.12
️✔️3.14
️✔️ams
️✔️latest
️✔️3.12
️✔️3.14
️✔️apim
️✔️latest
️✔️3.12
️✔️3.14
❌appconfig
❌latest
❌3.12
Type Test Case Error Message Line
Failed test_azconfig_feature self = <azure.cli.testsdk.base.ExecutionResult object at 0x7ff073e82d50>
cli_ctx = <azure.cli.core.mock.DummyCli object at 0x7ff07506c110>
command = 'appconfig create -n featuretest000001 -g None -l eastus --sku standard --retention-days 1 --disable-local-auth true'
expect_failure = False

    def in_process_execute(self, cli_ctx, command, expect_failure=False):
        from io import StringIO
        from vcr.errors import CannotOverwriteExistingCassetteException
    
        if command.startswith('az '):
            command = command[3:]
    
        stdout_buf = StringIO()
        logging_buf = StringIO()
        try:
            # issue: stderr cannot be redirect in this form, as a result some failure information
            # is lost when command fails.
>           self.exit_code = cli_ctx.invoke(shlex.split(command), out_file=stdout_buf) or 0
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/azure-cli-testsdk/azure/cli/testsdk/base.py:303: 
                                        
env/lib/python3.12/site-packages/knack/cli.py:245: in invoke
    exit_code = self.exception_handler(ex)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/init.py:153: in exception_handler
    return handle_exception(ex)
           ^^^^^^^^^^^^^^^^^^^^
src/azure-cli-testsdk/azure/cli/testsdk/patches.py:33: in handle_main_exception
    raise ex
env/lib/python3.12/site-packages/knack/cli.py:233: in invoke
    cmd_result = self.invocation.execute(args)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:677: in execute
    raise ex
src/azure-cli-core/azure/cli/core/commands/init.py:820: in run_jobs_serially
    results.append(self.run_job(expanded_arg, cmd_copy))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:789: in run_job
    result = cmd_copy(params)
             ^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:335: in call
    return self.handler(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/command_operation.py:120: in handler
    return op(**command_args)
           ^^^^^^^^^^^^^^^^^^
src/azure-cli/azure/cli/command_modules/appconfig/custom.py:108: in create_configstore
    config_store = client.begin_create(resource_group_name, name, configstore_params)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/tracing/decorator.py:119: in wrapper_use_tracer
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/mgmt/appconfiguration/operations/operations.py:1274: in begin_create
    raw_result = self.create_initial(
env/lib/python3.12/site-packages/azure/mgmt/appconfiguration/operations/operations.py:1124: in create_initial
    pipeline_response: PipelineResponse = self.client.pipeline.run(  # pylint: disable=protected-access
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:242: in run
    return first_node.send(pipeline_request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/mgmt/core/policies/base.py:95: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/policies/redirect.py:205: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/policies/retry.py:545: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/policies/authentication.py:194: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/base.py:130: in send
    self.sender.send(request.http_request, **request.context.options),
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/azure/core/pipeline/transport/requests_basic.py:375: in send
    response = self.session.request(  # type: ignore
env/lib/python3.12/site-packages/requests/sessions.py:592: in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/requests/sessions.py:706: in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.12/site-packages/requests/adapters.py:645: in send
    resp = conn.urlopen(
env/lib/python3.12/site-packages/urllib3/connectionpool.py:788: in urlopen
    response = self.make_request(
env/lib/python3.12/site-packages/urllib3/connectionpool.py:534: in make_request
    response = conn.getresponse()
               ^^^^^^^^^^^^^^^^^^
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
          

self = <VCRRequestsHTTPSConnection/mnt/vss/work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml(host='management.azure.com', port=443) at 0x7ff074365640>
 = False, kwargs = {}

    def getresponse(self, 
=False, **kwargs):
        """Retrieve the response"""
        # Check to see if the cassette has a response for this request. If so,
        # then return it
        if self.cassette.can_play_response_for(self.vcr_request):
            log.info(f"Playing response for {self.vcr_request} from cassette")
            response = self.cassette.play_response(self.vcr_request)
            return VCRHTTPResponse(response, self.vcr_request.uri)
        else:
            if self.cassette.write_protected and self.cassette.filter_request(self.vcr_request):
>               raise CannotOverwriteExistingCassetteException(
                    cassette=self.cassette,
                    failed_request=self.vcr_request,
                )
E               vcr.errors.CannotOverwriteExistingCassetteException: Can't overwrite existing cassette ('/mnt/vss/work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml') in your current record mode (RecordMode.ONCE: 'once').
E               No match for the request (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>)&nbsp;was&nbsp;found.
E               Found 1 similar requests with 1 different matcher(s) :
E               
E               1 - (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>).
E               Matchers succeeded : ['method', 'scheme', 'host', 'port', 'case_insensitive_query_matcher']
E               Matchers failed :
E               path - assertion failure :
E               /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001 != /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001

env/lib/python3.12/site-packages/vcr/stubs/init.py:279: CannotOverwriteExistingCassetteException

During handling of the above exception, another exception occurred:

self = <azure.cli.command_modules.appconfig.tests.latest.test_appconfig_feature_commands.AppConfigFeatureScenarioTest testMethod=test_azconfig_feature>

    @AllowLargeResponse()
    # Uses Entra ID auth (store created with local auth disabled); target a resource group where the
    # recording principal holds "App Configuration Data Owner". Override via AZURE_CLI_APPCONFIG_TEST_RG.
    def test_azconfig_feature(self):
        feature_test_store_prefix = get_resource_name_prefix('featuretest')
        config_store_name = self.create_random_name(prefix=feature_test_store_prefix, length=24)
    
        location = 'eastus'
        sku = 'standard'
        self.kwargs.update({
            'config_store_name': config_store_name,
            'rg_loc': location,
            'rg': get_test_resource_group(),
            'sku': sku,
            'endpoint': 'https://' + config_store_name + '.azconfig.io'
        })
>       create_config_store(self, self.kwargs, disable_local_auth=True)

src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:42: 
 
 
 
 
 
 
 
                                 
src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/test_utils.py:21: in create_config_store
    test.cmd(command)
src/azure-cli-testsdk/azure/cli/testsdk/base.py:177: in cmd
    return execute(self.cli_ctx, command, expect_failure=expect_failure).assert_with_checks(checks)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-testsdk/azure/cli/testsdk/base.py:252: in init
    self.in_process_execute(cli_ctx, command, expect_failure=expect_failure)
 
                                       

self = <azure.cli.testsdk.base.ExecutionResult object at 0x7ff073e82d50>
cli_ctx = <azure.cli.core.mock.DummyCli object at 0x7ff07506c110>
command = 'appconfig create -n featuretest000001 -g None -l eastus --sku standard --retention-days 1 --disable-local-auth true'
expect_failure = False

    def _in_process_execute(self, cli_ctx, command, expect_failure=False):
        from io import StringIO
        from vcr.errors import CannotOverwriteExistingCassetteException
    
        if command.startswith('az '):
            command = command[3:]
    
        stdout_buf = StringIO()
        logging_buf = StringIO()
        try:
            # issue: stderr cannot be redirect in this form, as a result some failure information
            # is lost when command fails.
            self.exit_code = cli_ctx.invoke(shlex.split(command), out_file=stdout_buf) or 0
            self.output = stdout_buf.getvalue()
            self.applog = logging_buf.getvalue()
    
        except CannotOverwriteExistingCassetteException as ex:
>           raise AssertionError(ex)
E           AssertionError: Can't overwrite existing cassette ('/mnt/vss/_work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml') in your current record mode (RecordMode.ONCE: 'once').
E           No match for the request (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>)&nbsp;was&nbsp;found.
E           Found 1 similar requests with 1 different matcher(s) :
E           
E           1 - (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>).
E           Matchers succeeded : ['method', 'scheme', 'host', 'port', '_case_insensitive_query_matcher']
E           Matchers failed :
E           path - assertion failure :
E           /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001 != /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001

src/azure-cli-testsdk/azure/cli/testsdk/base.py:308: AssertionError
azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:25
Failed test_azconfig_feature_namespacing The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:467
Failed test_azconfig_feature_telemetry The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:569
Failed test_azconfig_feature_filter The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:661
Failed test_azconfig_json_content_type The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_json_content_type.py:28
Failed test_azconfig_key_validation The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_key_validation.py:24
Failed test_azconfig_kv The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_commands.py:26
Failed test_azconfig_kv_revision_list The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_commands.py:367
Failed test_azconfig_import_export The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:28
Failed test_azconfig_import_export_kvset The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:400
Failed test_azconfig_import_export_new_fm_schema The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:290
Failed test_azconfig_strict_import The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:455
Failed test_azconfig_import_export_naming_conventions The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:760
Failed test_azconfig_import_export_respect_both_schemas_naming_conventions The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:845
Failed test_appconfig_to_appconfig_import_export The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:1001
Failed test_azconfig_kv_list_resolve_snapshot_references The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_snapshot_reference_commands.py:88
Failed test_azconfig_kv_set_snapshot_reference The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_snapshot_reference_commands.py:23
Failed test_azconfig_snapshot_filtering The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_snapshot_commands.py:183
Failed test_azconfig_snapshot_mgmt The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_snapshot_commands.py:23
❌3.14
Type Test Case Error Message Line
Failed test_azconfig_feature self = <azure.cli.testsdk.base.ExecutionResult object at 0x7f2ada7c27b0>
cli_ctx = <azure.cli.core.mock.DummyCli object at 0x7f2ada746d50>
command = 'appconfig create -n featuretest000001 -g None -l eastus --sku standard --retention-days 1 --disable-local-auth true'
expect_failure = False

    def in_process_execute(self, cli_ctx, command, expect_failure=False):
        from io import StringIO
        from vcr.errors import CannotOverwriteExistingCassetteException
    
        if command.startswith('az '):
            command = command[3:]
    
        stdout_buf = StringIO()
        logging_buf = StringIO()
        try:
            # issue: stderr cannot be redirect in this form, as a result some failure information
            # is lost when command fails.
>           self.exit_code = cli_ctx.invoke(shlex.split(command), out_file=stdout_buf) or 0
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/azure-cli-testsdk/azure/cli/testsdk/base.py:303: 
                                        
env/lib/python3.14/site-packages/knack/cli.py:245: in invoke
    exit_code = self.exception_handler(ex)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/init.py:153: in exception_handler
    return handle_exception(ex)
           ^^^^^^^^^^^^^^^^^^^^
src/azure-cli-testsdk/azure/cli/testsdk/patches.py:33: in handle_main_exception
    raise ex
env/lib/python3.14/site-packages/knack/cli.py:233: in invoke
    cmd_result = self.invocation.execute(args)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:677: in execute
    raise ex
src/azure-cli-core/azure/cli/core/commands/init.py:820: in run_jobs_serially
    results.append(self.run_job(expanded_arg, cmd_copy))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:789: in run_job
    result = cmd_copy(params)
             ^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/init.py:335: in call
    return self.handler(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-core/azure/cli/core/commands/command_operation.py:120: in handler
    return op(**command_args)
           ^^^^^^^^^^^^^^^^^^
src/azure-cli/azure/cli/command_modules/appconfig/custom.py:108: in create_configstore
    config_store = client.begin_create(resource_group_name, name, configstore_params)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/tracing/decorator.py:119: in wrapper_use_tracer
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/mgmt/appconfiguration/operations/operations.py:1274: in begin_create
    raw_result = self.create_initial(
env/lib/python3.14/site-packages/azure/mgmt/appconfiguration/operations/operations.py:1124: in create_initial
    pipeline_response: PipelineResponse = self.client.pipeline.run(  # pylint: disable=protected-access
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:242: in run
    return first_node.send(pipeline_request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/mgmt/core/policies/base.py:95: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/policies/redirect.py:205: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/policies/retry.py:545: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/policies/authentication.py:194: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:98: in send
    response = self.next.send(request)
               ^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/base.py:130: in send
    self.sender.send(request.http_request, **request.context.options),
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/azure/core/pipeline/transport/requests_basic.py:375: in send
    response = self.session.request(  # type: ignore
env/lib/python3.14/site-packages/requests/sessions.py:592: in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/requests/sessions.py:706: in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
env/lib/python3.14/site-packages/requests/adapters.py:645: in send
    resp = conn.urlopen(
env/lib/python3.14/site-packages/urllib3/connectionpool.py:788: in urlopen
    response = self.make_request(
env/lib/python3.14/site-packages/urllib3/connectionpool.py:534: in make_request
    response = conn.getresponse()
               ^^^^^^^^^^^^^^^^^^
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
          

self = <VCRRequestsHTTPSConnection/mnt/vss/work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml(host='management.azure.com', port=443) at 0x7f2ad984c440>
 = False, kwargs = {}

    def getresponse(self, 
=False, **kwargs):
        """Retrieve the response"""
        # Check to see if the cassette has a response for this request. If so,
        # then return it
        if self.cassette.can_play_response_for(self.vcr_request):
            log.info(f"Playing response for {self.vcr_request} from cassette")
            response = self.cassette.play_response(self.vcr_request)
            return VCRHTTPResponse(response, self.vcr_request.uri)
        else:
            if self.cassette.write_protected and self.cassette.filter_request(self.vcr_request):
>               raise CannotOverwriteExistingCassetteException(
                    cassette=self.cassette,
                    failed_request=self.vcr_request,
                )
E               vcr.errors.CannotOverwriteExistingCassetteException: Can't overwrite existing cassette ('/mnt/vss/work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml') in your current record mode (RecordMode.ONCE: 'once').
E               No match for the request (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>)&nbsp;was&nbsp;found.
E               Found 1 similar requests with 1 different matcher(s) :
E               
E               1 - (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>).
E               Matchers succeeded : ['method', 'scheme', 'host', 'port', 'case_insensitive_query_matcher']
E               Matchers failed :
E               path - assertion failure :
E               /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001 != /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001

env/lib/python3.14/site-packages/vcr/stubs/init.py:279: CannotOverwriteExistingCassetteException

During handling of the above exception, another exception occurred:

self = <azure.cli.command_modules.appconfig.tests.latest.test_appconfig_feature_commands.AppConfigFeatureScenarioTest testMethod=test_azconfig_feature>

    @AllowLargeResponse()
    # Uses Entra ID auth (store created with local auth disabled); target a resource group where the
    # recording principal holds "App Configuration Data Owner". Override via AZURE_CLI_APPCONFIG_TEST_RG.
    def test_azconfig_feature(self):
        feature_test_store_prefix = get_resource_name_prefix('featuretest')
        config_store_name = self.create_random_name(prefix=feature_test_store_prefix, length=24)
    
        location = 'eastus'
        sku = 'standard'
        self.kwargs.update({
            'config_store_name': config_store_name,
            'rg_loc': location,
            'rg': get_test_resource_group(),
            'sku': sku,
            'endpoint': 'https://' + config_store_name + '.azconfig.io'
        })
>       create_config_store(self, self.kwargs, disable_local_auth=True)

src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:42: 
 
 
 
 
 
 
 
                                 
src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/test_utils.py:21: in create_config_store
    test.cmd(command)
src/azure-cli-testsdk/azure/cli/testsdk/base.py:177: in cmd
    return execute(self.cli_ctx, command, expect_failure=expect_failure).assert_with_checks(checks)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/azure-cli-testsdk/azure/cli/testsdk/base.py:252: in init
    self.in_process_execute(cli_ctx, command, expect_failure=expect_failure)
 
                                       

self = <azure.cli.testsdk.base.ExecutionResult object at 0x7f2ada7c27b0>
cli_ctx = <azure.cli.core.mock.DummyCli object at 0x7f2ada746d50>
command = 'appconfig create -n featuretest000001 -g None -l eastus --sku standard --retention-days 1 --disable-local-auth true'
expect_failure = False

    def _in_process_execute(self, cli_ctx, command, expect_failure=False):
        from io import StringIO
        from vcr.errors import CannotOverwriteExistingCassetteException
    
        if command.startswith('az '):
            command = command[3:]
    
        stdout_buf = StringIO()
        logging_buf = StringIO()
        try:
            # issue: stderr cannot be redirect in this form, as a result some failure information
            # is lost when command fails.
            self.exit_code = cli_ctx.invoke(shlex.split(command), out_file=stdout_buf) or 0
            self.output = stdout_buf.getvalue()
            self.applog = logging_buf.getvalue()
    
        except CannotOverwriteExistingCassetteException as ex:
>           raise AssertionError(ex)
E           AssertionError: Can't overwrite existing cassette ('/mnt/vss/_work/1/s/src/azure-cli/azure/cli/command_modules/appconfig/tests/latest/recordings/test_azconfig_feature.yaml') in your current record mode (RecordMode.ONCE: 'once').
E           No match for the request (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>)&nbsp;was&nbsp;found.
E           Found 1 similar requests with 1 different matcher(s) :
E           
E           1 - (<Request (PUT) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001?api-version=2025-08-01-preview>).
E           Matchers succeeded : ['method', 'scheme', 'host', 'port', '_case_insensitive_query_matcher']
E           Matchers failed :
E           path - assertion failure :
E           /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/None/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001 != /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mametcal-python/providers/Microsoft.AppConfiguration/configurationStores/featuretest000001

src/azure-cli-testsdk/azure/cli/testsdk/base.py:308: AssertionError
azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:25
Failed test_azconfig_feature_namespacing The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:467
Failed test_azconfig_feature_telemetry The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:569
Failed test_azconfig_feature_filter The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_feature_commands.py:661
Failed test_azconfig_json_content_type The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_json_content_type.py:28
Failed test_azconfig_key_validation The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_key_validation.py:24
Failed test_azconfig_kv The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_commands.py:26
Failed test_azconfig_kv_revision_list The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_commands.py:367
Failed test_azconfig_import_export The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:28
Failed test_azconfig_import_export_kvset The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:400
Failed test_azconfig_import_export_new_fm_schema The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:290
Failed test_azconfig_strict_import The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:455
Failed test_azconfig_import_export_naming_conventions The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:760
Failed test_azconfig_import_export_respect_both_schemas_naming_conventions The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:845
Failed test_appconfig_to_appconfig_import_export The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_import_export_commands.py:1001
Failed test_azconfig_kv_list_resolve_snapshot_references The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_snapshot_reference_commands.py:88
Failed test_azconfig_kv_set_snapshot_reference The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_kv_snapshot_reference_commands.py:23
Failed test_azconfig_snapshot_filtering The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_snapshot_commands.py:183
Failed test_azconfig_snapshot_mgmt The error message is too long, please check the pipeline log for details. azure/cli/command_modules/appconfig/tests/latest/test_appconfig_snapshot_commands.py:23
️✔️appservice
️✔️latest
️✔️3.12
️✔️3.14
️✔️aro
️✔️latest
️✔️3.12
️✔️3.14
️✔️backup
️✔️latest
️✔️3.12
️✔️3.14
️✔️batch
️✔️latest
️✔️3.12
️✔️3.14
️✔️batchai
️✔️latest
️✔️3.12
️✔️3.14
️✔️billing
️✔️latest
️✔️3.12
️✔️3.14
️✔️botservice
️✔️latest
️✔️3.12
️✔️3.14
️✔️cloud
️✔️latest
️✔️3.12
️✔️3.14
️✔️cognitiveservices
️✔️latest
️✔️3.12
️✔️3.14
️✔️compute_recommender
️✔️latest
️✔️3.12
️✔️3.14
️✔️computefleet
️✔️latest
️✔️3.12
️✔️3.14
️✔️config
️✔️latest
️✔️3.12
️✔️3.14
️✔️configure
️✔️latest
️✔️3.12
️✔️3.14
️✔️consumption
️✔️latest
️✔️3.12
️✔️3.14
️✔️container
️✔️latest
️✔️3.12
️✔️3.14
️✔️containerapp
️✔️latest
️✔️3.12
️✔️3.14
️✔️core
️✔️latest
️✔️3.12
️✔️3.14
️✔️cosmosdb
️✔️latest
️✔️3.12
️✔️3.14
️✔️databoxedge
️✔️latest
️✔️3.12
️✔️3.14
️✔️dls
️✔️latest
️✔️3.12
️✔️3.14
️✔️dms
️✔️latest
️✔️3.12
️✔️3.14
️✔️eventgrid
️✔️latest
️✔️3.12
️✔️3.14
️✔️eventhubs
️✔️latest
️✔️3.12
️✔️3.14
️✔️feedback
️✔️latest
️✔️3.12
️✔️3.14
️✔️find
️✔️latest
️✔️3.12
️✔️3.14
️✔️hdinsight
️✔️latest
️✔️3.12
️✔️3.14
️✔️identity
️✔️latest
️✔️3.12
️✔️3.14
️✔️iot
️✔️latest
️✔️3.12
️✔️3.14
️✔️keyvault
️✔️latest
️✔️3.12
️✔️3.14
️✔️lab
️✔️latest
️✔️3.12
️✔️3.14
️✔️managedservices
️✔️latest
️✔️3.12
️✔️3.14
️✔️maps
️✔️latest
️✔️3.12
️✔️3.14
️✔️marketplaceordering
️✔️latest
️✔️3.12
️✔️3.14
️✔️monitor
️✔️latest
️✔️3.12
️✔️3.14
️✔️mysql
️✔️latest
️✔️3.12
️✔️3.14
️✔️netappfiles
️✔️latest
️✔️3.12
️✔️3.14
️✔️network
️✔️latest
️✔️3.12
️✔️3.14
️✔️policyinsights
️✔️latest
️✔️3.12
️✔️3.14
️✔️postgresql
️✔️latest
️✔️3.12
️✔️3.14
️✔️privatedns
️✔️latest
️✔️3.12
️✔️3.14
️✔️profile
️✔️latest
️✔️3.12
️✔️3.14
️✔️rdbms
️✔️latest
️✔️3.12
️✔️3.14
️✔️redis
️✔️latest
️✔️3.12
️✔️3.14
️✔️relay
️✔️latest
️✔️3.12
️✔️3.14
️✔️resource
️✔️latest
️✔️3.12
️✔️3.14
️✔️role
️✔️latest
️✔️3.12
️✔️3.14
️✔️search
️✔️latest
️✔️3.12
️✔️3.14
️✔️security
️✔️latest
️✔️3.12
️✔️3.14
️✔️servicebus
️✔️latest
️✔️3.12
️✔️3.14
️✔️serviceconnector
️✔️latest
️✔️3.12
️✔️3.14
️✔️servicefabric
️✔️latest
️✔️3.12
️✔️3.14
️✔️signalr
️✔️latest
️✔️3.12
️✔️3.14
️✔️sql
️✔️latest
️✔️3.12
️✔️3.14
️✔️sqlvm
️✔️latest
️✔️3.12
️✔️3.14
️✔️storage
️✔️latest
️✔️3.12
️✔️3.14
️✔️synapse
️✔️latest
️✔️3.12
️✔️3.14
️✔️telemetry
️✔️latest
️✔️3.12
️✔️3.14
️✔️util
️✔️latest
️✔️3.12
️✔️3.14
️✔️vm
️✔️latest
️✔️3.12
️✔️3.14

Remove default resource group value for tests.

Related command

Description

Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change
[Component Name 2] az command b: Add some customer-facing feature


This checklist is used to make sure that common guidelines for a pull request are followed.

Remove default resource group value for tests.
@mrm9084
Matthew Metcalf (mrm9084) requested a review from a team as a code owner August 5, 2026 16:15
Copilot AI lite review requested due to automatic review settings August 5, 2026 16:15
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
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

This PR updates the App Configuration test utilities to stop using a hard-coded default resource group name, relying instead on an environment variable to supply the resource group for data-plane tests.

Changes:

  • Removed the default fallback value from get_test_resource_group() so it only reads AZURE_CLI_APPCONFIG_TEST_RG.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).

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.

4 participants