Skip to content

Commit 4d11933

Browse files
seligj95Copilot
andcommitted
Fix test_webapp_authentication recording for v2 auth probe
The get_auth_settings and update_auth_settings functions now probe the v2 auth endpoint before falling back to v1. The existing test recording was missing the v2 GET authsettingsV2/list responses, causing CI playback failures on instance3 (Python 3.12 and 3.13). Added two v2 auth settings GET responses to the recording (one for 'webapp auth show', one for 'webapp auth update'). Both return empty v2 settings, causing the code to correctly fall back to v1 as before. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent fe6b5a2 commit 4d11933

1 file changed

Lines changed: 89 additions & 0 deletions

File tree

src/azure-cli/azure/cli/command_modules/appservice/tests/latest/recordings/test_webapp_authentication.yaml

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -785,6 +785,49 @@ interactions:
785785
status:
786786
code: 200
787787
message: OK
788+
- request:
789+
body: null
790+
headers:
791+
Accept:
792+
- application/json
793+
Accept-Encoding:
794+
- gzip, deflate
795+
CommandName:
796+
- webapp auth show
797+
Connection:
798+
- keep-alive
799+
ParameterSetName:
800+
- -g -n
801+
User-Agent:
802+
- AZURECLI/2.79.0 azsdk-python-core/1.35.0 Python/3.13.9 (Windows-11-10.0.26200-SP0)
803+
method: GET
804+
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_webapp_authentication000001/providers/Microsoft.Web/sites/webapp-authentication-test000002/config/authsettingsV2/list?api-version=2024-11-01
805+
response:
806+
body:
807+
string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_webapp_authentication000001/providers/Microsoft.Web/sites/webapp-authentication-test000002/config/authsettingsV2","name":"authsettingsV2","type":"Microsoft.Web/sites/config","location":"West
808+
Europe","properties":{"platform":null,"globalValidation":null,"identityProviders":null,"login":null,"httpSettings":null}}'
809+
headers:
810+
cache-control:
811+
- no-cache
812+
content-type:
813+
- application/json
814+
date:
815+
- Thu, 30 Oct 2025 22:14:28 GMT
816+
expires:
817+
- '-1'
818+
pragma:
819+
- no-cache
820+
strict-transport-security:
821+
- max-age=31536000; includeSubDomains
822+
x-aspnet-version:
823+
- 4.0.30319
824+
x-content-type-options:
825+
- nosniff
826+
x-powered-by:
827+
- ASP.NET
828+
status:
829+
code: 200
830+
message: OK
788831
- request:
789832
body: null
790833
headers:
@@ -840,6 +883,52 @@ interactions:
840883
status:
841884
code: 200
842885
message: OK
886+
- request:
887+
body: null
888+
headers:
889+
Accept:
890+
- application/json
891+
Accept-Encoding:
892+
- gzip, deflate
893+
CommandName:
894+
- webapp auth update
895+
Connection:
896+
- keep-alive
897+
ParameterSetName:
898+
- -g -n --enabled --action --token-store --token-refresh-extension-hours --runtime-version
899+
--aad-client-id --aad-client-secret --aad-client-secret-certificate-thumbprint
900+
--aad-allowed-token-audiences --aad-token-issuer-url --facebook-app-id --facebook-app-secret
901+
--facebook-oauth-scopes
902+
User-Agent:
903+
- AZURECLI/2.79.0 azsdk-python-core/1.35.0 Python/3.13.9 (Windows-11-10.0.26200-SP0)
904+
method: GET
905+
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_webapp_authentication000001/providers/Microsoft.Web/sites/webapp-authentication-test000002/config/authsettingsV2/list?api-version=2024-11-01
906+
response:
907+
body:
908+
string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_webapp_authentication000001/providers/Microsoft.Web/sites/webapp-authentication-test000002/config/authsettingsV2","name":"authsettingsV2","type":"Microsoft.Web/sites/config","location":"West
909+
Europe","properties":{"platform":null,"globalValidation":null,"identityProviders":null,"login":null,"httpSettings":null}}'
910+
headers:
911+
cache-control:
912+
- no-cache
913+
content-type:
914+
- application/json
915+
date:
916+
- Thu, 30 Oct 2025 22:14:29 GMT
917+
expires:
918+
- '-1'
919+
pragma:
920+
- no-cache
921+
strict-transport-security:
922+
- max-age=31536000; includeSubDomains
923+
x-aspnet-version:
924+
- 4.0.30319
925+
x-content-type-options:
926+
- nosniff
927+
x-powered-by:
928+
- ASP.NET
929+
status:
930+
code: 200
931+
message: OK
843932
- request:
844933
body: null
845934
headers:

0 commit comments

Comments
 (0)