Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
15 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions sdk/compute/azure-mgmt-compute/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
from dotenv import load_dotenv

from devtools_testutils import test_proxy, add_general_regex_sanitizer, add_body_key_sanitizer
from devtools_testutils import add_header_regex_sanitizer, add_body_key_sanitizer

# Ignore async tests for Python < 3.5
collect_ignore_glob = []
Expand All @@ -46,6 +47,6 @@ def add_sanitizers(test_proxy):
tenant_id = os.environ.get("AZURE_TENANT_ID", "00000000-0000-0000-0000-000000000000")
add_general_regex_sanitizer(regex=subscription_id, value="00000000-0000-0000-0000-000000000000")
add_general_regex_sanitizer(regex=tenant_id, value="00000000-0000-0000-0000-000000000000")
add_general_regex_sanitizer(regex='eyJ0eXAiOiJKV.*?"', value='access_token"')
add_general_regex_sanitizer(regex='fpc=.*?;', value='fpc=fpc;')
add_body_key_sanitizer(json_path="$..accessSAS")
add_header_regex_sanitizer(key="Set-Cookie", value="[set-cookie;]")
add_header_regex_sanitizer(key="Cookie", value="cookie;")
add_body_key_sanitizer(json_path="$..access_token", value="access_token")
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"Accept": "*/*",
"Accept-Encoding": "gzip, deflate",
"Connection": "keep-alive",
"User-Agent": "azsdk-python-identity/1.8.0b2 Python/3.8.8 (Windows-10-10.0.19041-SP0)"
"User-Agent": "azsdk-python-identity/1.9.0b2 Python/3.6.2 (Windows-10-10.0.19041-SP0)"
},
"RequestBody": null,
"StatusCode": 200,
Expand All @@ -17,18 +17,13 @@
"Cache-Control": "max-age=86400, private",
"Content-Length": "1753",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:18 GMT",
"Date": "Wed, 09 Mar 2022 12:35:04 GMT",
"P3P": "CP=\u0022DSP CUR OTPi IND OTRi ONL FIN\u0022",
"Set-Cookie": [
"fpc=fpc; expires=Fri, 01-Apr-2022 03:01:18 GMT; path=/; secure; HttpOnly; SameSite=None",
"esctx=AQABAAAAAAD--DLA3VO7QrddgJg7WevrilfC6CpFwDCJp8MIo2nsY9jI-Ybt0tJt9Mf-4XVVzWyk0bFIOjFyUEApw_1aUdn7h-vmu1G4x5f-S2UohO-6JzVazFIynY00BvV6yUYRArAlba-MbOSMMWedRzh9NbWDAj3XpFC-XdF6miHzamKvna5p68QfLwh8Yoew2-h7mLkgAA; domain=.login.microsoftonline.com; path=/; secure; HttpOnly; SameSite=None",
"x-ms-gateway-slice=estsfd; path=/; secure; samesite=none; httponly",
"stsservicecookie=estsfd; path=/; secure; samesite=none; httponly"
],
"Set-Cookie": "[set-cookie;]",
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"X-Content-Type-Options": "nosniff",
"x-ms-ests-server": "2.1.12507.17 - NCUS ProdSlices",
"x-ms-request-id": "9460e8b4-3927-46ea-8c0a-3c12e7410300"
"x-ms-ests-server": "2.1.12529.17 - NCUS ProdSlices",
"x-ms-request-id": "9e1bce42-1cd8-45a4-a548-d36b5130bf00"
},
"ResponseBody": {
"token_endpoint": "https://login.microsoftonline.com/00000000-0000-0000-0000-000000000000/oauth2/v2.0/token",
Expand Down Expand Up @@ -105,8 +100,8 @@
"Accept": "application/json",
"Accept-Encoding": "gzip, deflate",
"Connection": "keep-alive",
"Cookie": "fpc=fpc; stsservicecookie=estsfd; x-ms-gateway-slice=estsfd",
"User-Agent": "azsdk-python-identity/1.8.0b2 Python/3.8.8 (Windows-10-10.0.19041-SP0)"
"Cookie": "cookie;",
"User-Agent": "azsdk-python-identity/1.9.0b2 Python/3.6.2 (Windows-10-10.0.19041-SP0)"
},
"RequestBody": null,
"StatusCode": 200,
Expand All @@ -116,17 +111,13 @@
"Cache-Control": "max-age=86400, private",
"Content-Length": "945",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:18 GMT",
"Date": "Wed, 09 Mar 2022 12:35:04 GMT",
"P3P": "CP=\u0022DSP CUR OTPi IND OTRi ONL FIN\u0022",
"Set-Cookie": [
"fpc=fpc; expires=Fri, 01-Apr-2022 03:01:19 GMT; path=/; secure; HttpOnly; SameSite=None",
"x-ms-gateway-slice=estsfd; path=/; secure; samesite=none; httponly",
"stsservicecookie=estsfd; path=/; secure; samesite=none; httponly"
],
"Set-Cookie": "[set-cookie;]",
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"X-Content-Type-Options": "nosniff",
"x-ms-ests-server": "2.1.12529.16 - SEASLR2 ProdSlices",
"x-ms-request-id": "d2d17ebf-f1d8-4d7c-a1de-669105642800"
"x-ms-ests-server": "2.1.12559.5 - SEASLR1 ProdSlices",
"x-ms-request-id": "41f57ba3-5d47-4571-9dab-0b3ac0570700"
},
"ResponseBody": {
"tenant_discovery_endpoint": "https://login.microsoftonline.com/common/.well-known/openid-configuration",
Expand Down Expand Up @@ -181,41 +172,37 @@
"RequestHeaders": {
"Accept": "application/json",
"Accept-Encoding": "gzip, deflate",
"client-request-id": "d284d3f8-045d-498b-9190-7395a9b6279e",
"client-request-id": "9f39083c-88ab-4aa8-a157-6430bb777b2e",
"Connection": "keep-alive",
"Content-Length": "289",
"Content-Length": "291",
"Content-Type": "application/x-www-form-urlencoded",
"Cookie": "fpc=fpc; stsservicecookie=estsfd; x-ms-gateway-slice=estsfd",
"User-Agent": "azsdk-python-identity/1.8.0b2 Python/3.8.8 (Windows-10-10.0.19041-SP0)",
"Cookie": "cookie;",
"User-Agent": "azsdk-python-identity/1.9.0b2 Python/3.6.2 (Windows-10-10.0.19041-SP0)",
"x-client-cpu": "x64",
"x-client-current-telemetry": "4|730,0|",
"x-client-last-telemetry": "4|0|||",
"x-client-os": "win32",
"x-client-sku": "MSAL.Python",
"x-client-ver": "1.16.0",
"x-client-ver": "1.17.0",
"x-ms-lib-capability": "retry-after, h429"
},
"RequestBody": "client_id=a2df54d5-ab03-4725-9b80-9a00b3b1967f\u0026grant_type=client_credentials\u0026client_info=1\u0026client_secret=0vj7Q~IsFayrD0V_8oyOfygU-GE3ELOabq95a\u0026claims=%7B%22access_token%22%3A\u002B%7B%22xms_cc%22%3A\u002B%7B%22values%22%3A\u002B%5B%22CP1%22%5D%7D%7D%7D\u0026scope=https%3A%2F%2Fmanagement.azure.com%2F.default",
"RequestBody": "client_id=a2df54d5-ab03-4725-9b80-9a00b3b1967f\u0026grant_type=client_credentials\u0026client_info=1\u0026client_secret=0vj7Q%7EIsFayrD0V_8oyOfygU-GE3ELOabq95a\u0026claims=%7B%22access_token%22%3A\u002B%7B%22xms_cc%22%3A\u002B%7B%22values%22%3A\u002B%5B%22CP1%22%5D%7D%7D%7D\u0026scope=https%3A%2F%2Fmanagement.azure.com%2F.default",
"StatusCode": 200,
"ResponseHeaders": {
"Cache-Control": "no-store, no-cache",
"client-request-id": "d284d3f8-045d-498b-9190-7395a9b6279e",
"client-request-id": "9f39083c-88ab-4aa8-a157-6430bb777b2e",
"Content-Length": "93",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:19 GMT",
"Date": "Wed, 09 Mar 2022 12:35:04 GMT",
"Expires": "-1",
"P3P": "CP=\u0022DSP CUR OTPi IND OTRi ONL FIN\u0022",
"Pragma": "no-cache",
"Set-Cookie": [
"fpc=fpc; expires=Fri, 01-Apr-2022 03:01:19 GMT; path=/; secure; HttpOnly; SameSite=None",
"x-ms-gateway-slice=estsfd; path=/; secure; samesite=none; httponly",
"stsservicecookie=estsfd; path=/; secure; samesite=none; httponly"
],
"Set-Cookie": "[set-cookie;]",
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"X-Content-Type-Options": "nosniff",
"x-ms-clitelem": "1,0,0,,",
"x-ms-ests-server": "2.1.12507.17 - NCUS ProdSlices",
"x-ms-request-id": "9460e8b4-3927-46ea-8c0a-3c12f4410300"
"x-ms-ests-server": "2.1.12529.17 - SCUS ProdSlices",
"x-ms-request-id": "d22fb100-cf87-4582-831f-10617002e600"
},
"ResponseBody": {
"token_type": "Bearer",
Expand All @@ -234,8 +221,8 @@
"Connection": "keep-alive",
"Content-Length": "102",
"Content-Type": "application/json",
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.8.8 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "07a079d8-99d5-11ec-93ab-70b5e82527ff"
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.6.2 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "57e0a38c-9fa5-11ec-b53a-c0b6f9946f2d"
},
"RequestBody": {
"location": "eastus",
Expand All @@ -249,7 +236,7 @@
"Cache-Control": "no-cache",
"Content-Encoding": "gzip",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:27 GMT",
"Date": "Wed, 09 Mar 2022 12:35:13 GMT",
"Expires": "-1",
"Pragma": "no-cache",
"Server": [
Expand All @@ -260,11 +247,11 @@
"Transfer-Encoding": "chunked",
"Vary": "Accept-Encoding",
"X-Content-Type-Options": "nosniff",
"x-ms-correlation-request-id": "650b737e-1f45-4a4d-8652-a373ef065bdf",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/PutVM3Min;745,Microsoft.Compute/PutVM30Min;3725",
"x-ms-correlation-request-id": "da0c45d3-b40b-45eb-8cfb-4452bf252487",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/PutVM3Min;745,Microsoft.Compute/PutVM30Min;3729",
"x-ms-ratelimit-remaining-subscription-writes": "1199",
"x-ms-request-id": "1533d5df-402d-4d68-b571-28dc827bf3fe",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220302T030128Z:650b737e-1f45-4a4d-8652-a373ef065bdf"
"x-ms-request-id": "f73f4fed-4be1-42b4-b381-a116beb8a561",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220309T123514Z:da0c45d3-b40b-45eb-8cfb-4452bf252487"
},
"ResponseBody": {
"name": "availabilitysetse8d12c44",
Expand All @@ -288,16 +275,16 @@
"Accept-Encoding": "gzip, deflate",
"Authorization": "Sanitized",
"Connection": "keep-alive",
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.8.8 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "0e25621e-99d5-11ec-af46-70b5e82527ff"
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.6.2 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "5e512b80-9fa5-11ec-adfd-c0b6f9946f2d"
},
"RequestBody": null,
"StatusCode": 200,
"ResponseHeaders": {
"Cache-Control": "no-cache",
"Content-Encoding": "gzip",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:27 GMT",
"Date": "Wed, 09 Mar 2022 12:35:14 GMT",
"Expires": "-1",
"Pragma": "no-cache",
"Server": [
Expand All @@ -308,11 +295,11 @@
"Transfer-Encoding": "chunked",
"Vary": "Accept-Encoding",
"X-Content-Type-Options": "nosniff",
"x-ms-correlation-request-id": "e5132b27-1d92-47ab-885d-4a208b2f9a6c",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/LowCostGet3Min;3999,Microsoft.Compute/LowCostGet30Min;31993",
"x-ms-correlation-request-id": "38199358-0806-4c4b-b0e0-94f8feb0ece3",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/LowCostGet3Min;3999,Microsoft.Compute/LowCostGet30Min;31999",
"x-ms-ratelimit-remaining-subscription-reads": "11999",
"x-ms-request-id": "95480f69-14ce-401b-ade0-b94e29eb650d",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220302T030128Z:e5132b27-1d92-47ab-885d-4a208b2f9a6c"
"x-ms-request-id": "70fc2ec3-ed31-4f68-9e1b-7945dd5f2b28",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220309T123514Z:38199358-0806-4c4b-b0e0-94f8feb0ece3"
},
"ResponseBody": {
"name": "availabilitysetse8d12c44",
Expand All @@ -339,8 +326,8 @@
"Connection": "keep-alive",
"Content-Length": "80",
"Content-Type": "application/json",
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.8.8 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "0f089796-99d5-11ec-bf23-70b5e82527ff"
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.6.2 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "5e84152c-9fa5-11ec-8d98-c0b6f9946f2d"
},
"RequestBody": {
"properties": {
Expand All @@ -353,7 +340,7 @@
"Cache-Control": "no-cache",
"Content-Encoding": "gzip",
"Content-Type": "application/json; charset=utf-8",
"Date": "Wed, 02 Mar 2022 03:01:28 GMT",
"Date": "Wed, 09 Mar 2022 12:35:14 GMT",
"Expires": "-1",
"Pragma": "no-cache",
"Server": [
Expand All @@ -364,11 +351,11 @@
"Transfer-Encoding": "chunked",
"Vary": "Accept-Encoding",
"X-Content-Type-Options": "nosniff",
"x-ms-correlation-request-id": "9c375c91-9324-4475-b02f-cbf407a93642",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/PutVM3Min;744,Microsoft.Compute/PutVM30Min;3724",
"x-ms-correlation-request-id": "24316763-9a8d-4a60-8c87-8f49b3db6a77",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/PutVM3Min;744,Microsoft.Compute/PutVM30Min;3728",
"x-ms-ratelimit-remaining-subscription-writes": "1198",
"x-ms-request-id": "526eb979-78bc-4fa7-8d75-6779f2d2dc75",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220302T030129Z:9c375c91-9324-4475-b02f-cbf407a93642"
"x-ms-request-id": "19f5f6ed-c56c-4d00-9001-527b8043131f",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220309T123515Z:24316763-9a8d-4a60-8c87-8f49b3db6a77"
},
"ResponseBody": {
"name": "availabilitysetse8d12c44",
Expand All @@ -393,15 +380,15 @@
"Authorization": "Sanitized",
"Connection": "keep-alive",
"Content-Length": "0",
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.8.8 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "0f42b815-99d5-11ec-96ce-70b5e82527ff"
"User-Agent": "azsdk-python-azure-mgmt-compute/26.1.0 Python/3.6.2 (Windows-10-10.0.19041-SP0)",
"x-ms-client-request-id": "5ec9613a-9fa5-11ec-8677-c0b6f9946f2d"
},
"RequestBody": null,
"StatusCode": 200,
"ResponseHeaders": {
"Cache-Control": "no-cache",
"Content-Length": "0",
"Date": "Wed, 02 Mar 2022 03:01:35 GMT",
"Date": "Wed, 09 Mar 2022 12:35:20 GMT",
"Expires": "-1",
"Pragma": "no-cache",
"Server": [
Expand All @@ -410,11 +397,11 @@
],
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"X-Content-Type-Options": "nosniff",
"x-ms-correlation-request-id": "9bafbac0-5aba-42fc-8acd-c6cd4b883d84",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/DeleteVM3Min;239,Microsoft.Compute/DeleteVM30Min;1197",
"x-ms-correlation-request-id": "dbd18b43-20d8-4e22-9144-04f1a7fc5c53",
"x-ms-ratelimit-remaining-resource": "Microsoft.Compute/DeleteVM3Min;239,Microsoft.Compute/DeleteVM30Min;1199",
"x-ms-ratelimit-remaining-subscription-deletes": "14999",
"x-ms-request-id": "dd5da8bc-7015-4d1e-ad99-dd1297c484cc",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220302T030136Z:9bafbac0-5aba-42fc-8acd-c6cd4b883d84"
"x-ms-request-id": "0a6af0af-b182-405c-a56a-4b1596b88e83",
"x-ms-routing-request-id": "SOUTHEASTASIA:20220309T123521Z:dbd18b43-20d8-4e22-9144-04f1a7fc5c53"
},
"ResponseBody": null
}
Expand Down
Loading