From d149ffbe72a983f8d959c7b68f6b02c2eddf02c8 Mon Sep 17 00:00:00 2001 From: Jorge Beauregard Date: Mon, 8 Mar 2021 10:46:19 -0700 Subject: [PATCH] Changed user-agent in response --- .../communication/phonenumbers/_version.py | 2 +- .../test/_shared/testcase.py | 6 +-- ...stration_client.test_get_phone_number.yaml | 10 ++--- ...ient.test_list_acquired_phone_numbers.yaml | 36 ++++++++++------ ...d_phone_numbers_from_managed_identity.yaml | 18 ++++---- ...on_client.test_purchase_phone_numbers.yaml | 12 +++--- ...test_update_phone_number_capabilities.yaml | 42 +++++++++---------- ...on_client_async.test_get_phone_number.yaml | 10 ++--- ...sync.test_list_acquired_phone_numbers.yaml | 36 ++++++++++------ ...d_phone_numbers_from_managed_identity.yaml | 16 +++---- ...ent_async.test_purchase_phone_numbers.yaml | 12 +++--- ...test_update_phone_number_capabilities.yaml | 18 ++++---- ...test_phone_number_administration_client.py | 1 - ...hone_number_administration_client_async.py | 1 - 14 files changed, 121 insertions(+), 99 deletions(-) diff --git a/sdk/communication/azure-communication-phonenumbers/azure/communication/phonenumbers/_version.py b/sdk/communication/azure-communication-phonenumbers/azure/communication/phonenumbers/_version.py index a01196623d45..a598e66bd549 100644 --- a/sdk/communication/azure-communication-phonenumbers/azure/communication/phonenumbers/_version.py +++ b/sdk/communication/azure-communication-phonenumbers/azure/communication/phonenumbers/_version.py @@ -6,4 +6,4 @@ VERSION = "1.0.0b4" -SDK_MONIKER = "communication-administration/{}".format(VERSION) # type: str +SDK_MONIKER = "communication-phonenumbers/{}".format(VERSION) # type: str diff --git a/sdk/communication/azure-communication-phonenumbers/test/_shared/testcase.py b/sdk/communication/azure-communication-phonenumbers/test/_shared/testcase.py index 5ec27d644d24..fa09dc67deb0 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/_shared/testcase.py +++ b/sdk/communication/azure-communication-phonenumbers/test/_shared/testcase.py @@ -25,14 +25,14 @@ def process_response(self, response): if isinstance(item, str): body["phoneNumbers"] = [self._replacement] break - elif "phoneNumber" in item: + if "phoneNumber" in item: item['phoneNumber'] = self._replacement - elif "id" in item: + if "id" in item: item['id'] = self._replacement response['body']['string'] = json.dumps(body) response['url'] = self._replacement return response - except (KeyError, ValueError): + except (KeyError, ValueError, TypeError): return response class BodyReplacerProcessor(RecordingProcessor): diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_get_phone_number.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_get_phone_number.yaml index 542ecd2ce24e..6a35e9fc4835 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_get_phone_number.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_get_phone_number.yaml @@ -9,9 +9,9 @@ interactions: Connection: - keep-alive Date: - - Fri, 05 Mar 2021 22:19:58 GMT + - Mon, 08 Mar 2021 17:41:35 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -26,15 +26,15 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Fri, 05 Mar 2021 22:20:00 GMT + - Mon, 08 Mar 2021 17:41:36 GMT ms-cv: - - aa2xk97xc06kIOakrLVlZQ.0 + - gk4Y2l2T2UO9cLNf+5ptrw.0 request-context: - appId= transfer-encoding: - chunked x-processing-time: - - 1617ms + - 1829ms status: code: 200 message: OK diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers.yaml index 949938277bd2..8bd5e173b891 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers.yaml @@ -9,48 +9,60 @@ interactions: Connection: - keep-alive Date: - - Fri, 05 Mar 2021 22:20:00 GMT + - Mon, 08 Mar 2021 17:41:37 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET uri: https://sanitized.communication.azure.com/phoneNumbers?skip=0&top=100&api-version=2021-03-07 response: body: - string: '{"phoneNumbers": [{"id": "16194895581", "phoneNumber": "sanitized", - "countryCode": "US", "phoneNumberType": "Geographic", "capabilities": {"calling": - "outbound", "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:01:52.0795301+00:00", + string: '{"phoneNumbers": [{"id": "sanitized", "phoneNumber": "sanitized", "countryCode": + "US", "phoneNumberType": "Geographic", "capabilities": {"calling": "outbound", + "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:01:52.0795301+00:00", "cost": {"amount": 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "16194895593", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "Geographic", "capabilities": {"calling": "outbound", "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:57:24.5482566+00:00", "cost": {"amount": - 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "18332143261", + 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2020-11-30T17:51:21.2991518+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": - "18443281555", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2020-11-12T21:53:12.2088187+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18445492606", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-03-04T19:24:10.3004481+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:24:46.5160739+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:30:37.0532427+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:27:26.3166637+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}]}' headers: content-type: - application/json; charset=utf-8 date: - - Fri, 05 Mar 2021 22:20:04 GMT + - Mon, 08 Mar 2021 17:41:46 GMT ms-cv: - - PcsdnL23aEGt6Y89OREU2w.0 + - zv0HSHVuUUi1JsCXB5qJ2w.0 request-context: - appId= transfer-encoding: - chunked x-processing-time: - - 3504ms + - 9259ms status: code: 200 message: OK diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers_from_managed_identity.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers_from_managed_identity.yaml index 4c5dc58319b5..f745ab0476fa 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers_from_managed_identity.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_list_acquired_phone_numbers_from_managed_identity.yaml @@ -9,41 +9,41 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) method: GET uri: https://sanitized.communication.azure.com/phoneNumbers?skip=0&top=100&api-version=2021-03-07 response: body: - string: '{"phoneNumbers": [{"id": "18332272412", "phoneNumber": "sanitized", + string: '{"phoneNumbers": [{"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T23:00:10.4372681+00:00", "cost": {"amount": 2.0, "currencyCode": - "USD", "billingFrequency": "Monthly"}}, {"id": "18332272430", "phoneNumber": + "USD", "billingFrequency": "Monthly"}}, {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T22:58:41.2504122+00:00", "cost": {"amount": 2.0, - "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "18332272445", + "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T23:03:57.6969271+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": - "18332321209", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T17:51:13.4876763+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18332321221", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T17:52:41.818335+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18332321226", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T18:01:46.4199999+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18335260208", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2000-01-01T00:00:00+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18336369501", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound+outbound", "sms": "none"}, "assignmentType": "Application", "purchaseDate": "2020-09-18T15:03:19.5370985+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}]}' diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_purchase_phone_numbers.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_purchase_phone_numbers.yaml index bc4181a1e29c..cc21b374a3b7 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_purchase_phone_numbers.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_purchase_phone_numbers.yaml @@ -16,7 +16,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:37:27 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST @@ -58,7 +58,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:38:00 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -99,7 +99,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:38:01 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -144,7 +144,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:38:02 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST @@ -186,7 +186,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:38:34 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -227,7 +227,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:38:34 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_update_phone_number_capabilities.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_update_phone_number_capabilities.yaml index 47a2ab186c0a..78275b885907 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_update_phone_number_capabilities.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client.test_update_phone_number_capabilities.yaml @@ -13,37 +13,37 @@ interactions: Content-Type: - application/merge-patch+json Date: - - Fri, 05 Mar 2021 22:20:43 GMT + - Mon, 08 Mar 2021 17:41:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: PATCH uri: https://sanitized.communication.azure.com/phoneNumbers/sanitized/capabilities?api-version=2021-03-07 response: body: - string: '{"capabilitiesUpdateId": "a8589969-1d09-4ad3-9b5a-39ce067ea535"}' + string: '{"capabilitiesUpdateId": "5aa2069a-dd2b-4348-9f16-314acb37d2f6"}' headers: access-control-expose-headers: - Operation-Location,Location,operation-id,capabilities-id capabilities-id: - - a8589969-1d09-4ad3-9b5a-39ce067ea535 + - 5aa2069a-dd2b-4348-9f16-314acb37d2f6 content-type: - application/json; charset=utf-8 date: - - Fri, 05 Mar 2021 22:20:44 GMT + - Mon, 08 Mar 2021 17:41:49 GMT ms-cv: - - KjGZkSHB5kCrsxscH9ibgQ.0 + - pNZwMhI3IUiVz657e2a3DQ.0 operation-id: - - capabilities_a8589969-1d09-4ad3-9b5a-39ce067ea535 + - capabilities_5aa2069a-dd2b-4348-9f16-314acb37d2f6 operation-location: - - /phoneNumbers/operations/capabilities_a8589969-1d09-4ad3-9b5a-39ce067ea535?api-version=2021-03-07 + - /phoneNumbers/operations/capabilities_5aa2069a-dd2b-4348-9f16-314acb37d2f6?api-version=2021-03-07 request-context: - appId= transfer-encoding: - chunked x-processing-time: - - 987ms + - 943ms status: code: 202 message: Accepted @@ -58,17 +58,17 @@ interactions: Connection: - keep-alive Date: - - Fri, 05 Mar 2021 22:21:14 GMT + - Mon, 08 Mar 2021 17:42:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET - uri: https://sanitized.communication.azure.com/phoneNumbers/operations/capabilities_a8589969-1d09-4ad3-9b5a-39ce067ea535?api-version=2021-03-07 + uri: https://sanitized.communication.azure.com/phoneNumbers/operations/capabilities_5aa2069a-dd2b-4348-9f16-314acb37d2f6?api-version=2021-03-07 response: body: string: '{"status": "Succeeded", "resourceLocation": "/phoneNumbers/+18332143261?api-version=2021-03-07", - "createdDateTime": "2021-03-05T22:20:44.5342481+00:00", "id": "sanitized", + "createdDateTime": "2021-03-08T17:41:49.3163011+00:00", "id": "sanitized", "operationType": "UpdatePhoneNumberCapabilities", "lastActionDateTime": "0001-01-01T00:00:00+00:00"}' headers: access-control-expose-headers: @@ -76,15 +76,15 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Fri, 05 Mar 2021 22:21:14 GMT + - Mon, 08 Mar 2021 17:42:19 GMT ms-cv: - - I5gz/NLH7kWVu9cfp44HpQ.0 + - RSJdlEmKe0O0AkxOkYF91g.0 request-context: - appId= transfer-encoding: - chunked x-processing-time: - - 254ms + - 253ms status: code: 200 message: OK @@ -99,9 +99,9 @@ interactions: Connection: - keep-alive Date: - - Fri, 05 Mar 2021 22:21:14 GMT + - Mon, 08 Mar 2021 17:42:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -116,15 +116,15 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Fri, 05 Mar 2021 22:21:15 GMT + - Mon, 08 Mar 2021 17:42:20 GMT ms-cv: - - VbgvUURuDkyiQ4llLoXMPA.0 + - R7OdWLUtxE2LScLoCsO/MQ.0 request-context: - appId= transfer-encoding: - chunked x-processing-time: - - 1201ms + - 1145ms status: code: 200 message: OK diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_get_phone_number.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_get_phone_number.yaml index dbc6f9dcbe97..09887bf38bea 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_get_phone_number.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_get_phone_number.yaml @@ -5,9 +5,9 @@ interactions: Accept: - application/json Date: - - Fri, 05 Mar 2021 22:21:16 GMT + - Mon, 08 Mar 2021 17:42:21 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -20,11 +20,11 @@ interactions: "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}' headers: content-type: application/json; charset=utf-8 - date: Fri, 05 Mar 2021 22:21:18 GMT - ms-cv: jkDUEFxq6E2BFPuvbj9mvw.0 + date: Mon, 08 Mar 2021 17:42:22 GMT + ms-cv: p8LAzJzR9E+kJFtKVtPS4w.0 request-context: appId= transfer-encoding: chunked - x-processing-time: 1670ms + x-processing-time: 1101ms status: code: 200 message: OK diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers.yaml index 3ec83d977845..8d7a686aa2ba 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers.yaml @@ -5,42 +5,54 @@ interactions: Accept: - application/json Date: - - Fri, 05 Mar 2021 22:21:18 GMT + - Mon, 08 Mar 2021 17:42:22 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET uri: https://sanitized.communication.azure.com/phoneNumbers?skip=0&top=100&api-version=2021-03-07 response: body: - string: '{"phoneNumbers": [{"id": "16194895581", "phoneNumber": "sanitized", - "countryCode": "US", "phoneNumberType": "Geographic", "capabilities": {"calling": - "outbound", "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:01:52.0795301+00:00", + string: '{"phoneNumbers": [{"id": "sanitized", "phoneNumber": "sanitized", "countryCode": + "US", "phoneNumberType": "Geographic", "capabilities": {"calling": "outbound", + "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:01:52.0795301+00:00", "cost": {"amount": 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "16194895593", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "Geographic", "capabilities": {"calling": "outbound", "sms": "none"}, "assignmentType": "Person", "purchaseDate": "2021-01-13T20:57:24.5482566+00:00", "cost": {"amount": - 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "18332143261", + 1.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2020-11-30T17:51:21.2991518+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": - "18443281555", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2020-11-12T21:53:12.2088187+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18445492606", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-03-04T19:24:10.3004481+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:24:46.5160739+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:30:37.0532427+00:00", + "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, + "assignmentType": "Application", "purchaseDate": "2021-03-05T22:27:26.3166637+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}]}' headers: content-type: application/json; charset=utf-8 - date: Fri, 05 Mar 2021 22:21:22 GMT - ms-cv: US5P4qB/KEOB9kd4FEf70w.0 + date: Mon, 08 Mar 2021 17:42:28 GMT + ms-cv: FPXwjKPyG0OmBOaX0j7/6Q.0 request-context: appId= transfer-encoding: chunked - x-processing-time: 4347ms + x-processing-time: 5851ms status: code: 200 message: OK diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers_from_managed_identity.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers_from_managed_identity.yaml index 67e3898a0d3a..494a183cb4b7 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers_from_managed_identity.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_list_acquired_phone_numbers_from_managed_identity.yaml @@ -5,12 +5,12 @@ interactions: Accept: - application/json User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) method: GET uri: https://sanitized.communication.azure.com/phoneNumbers?skip=0&top=100&api-version=2021-03-07 response: body: - string: '{"phoneNumbers": [{"id": "18332272412", "phoneNumber": "sanitized", + string: '{"phoneNumbers": [{"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T23:00:10.4372681+00:00", "cost": {"amount": 2.0, "currencyCode": @@ -18,28 +18,28 @@ interactions: "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T22:58:41.2504122+00:00", "cost": {"amount": 2.0, - "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "18332272445", + "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-09T23:03:57.6969271+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, {"id": - "18332321209", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T17:51:13.4876763+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18332321221", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T17:52:41.818335+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18332321226", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "none", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2021-02-10T18:01:46.4199999+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18335260208", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound", "sms": "inbound+outbound"}, "assignmentType": "Application", "purchaseDate": "2000-01-01T00:00:00+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}, - {"id": "18336369501", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": + {"id": "sanitized", "phoneNumber": "sanitized", "countryCode": "US", "phoneNumberType": "TollFree", "capabilities": {"calling": "inbound+outbound", "sms": "none"}, "assignmentType": "Application", "purchaseDate": "2020-09-18T15:03:19.5370985+00:00", "cost": {"amount": 2.0, "currencyCode": "USD", "billingFrequency": "Monthly"}}]}' diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_purchase_phone_numbers.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_purchase_phone_numbers.yaml index 3d0180913d84..13ee4680c957 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_purchase_phone_numbers.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_purchase_phone_numbers.yaml @@ -12,7 +12,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:35:23 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST @@ -40,7 +40,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:35:57 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -68,7 +68,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:35:58 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -102,7 +102,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:35:59 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST @@ -130,7 +130,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:36:31 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: GET @@ -159,7 +159,7 @@ interactions: Date: - Fri, 05 Mar 2021 22:36:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE diff --git a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_update_phone_number_capabilities.yaml b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_update_phone_number_capabilities.yaml index 1871eac99f84..4ce5bf57e322 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_update_phone_number_capabilities.yaml +++ b/sdk/communication/azure-communication-phonenumbers/test/recordings/test_phone_number_administration_client_async.test_update_phone_number_capabilities.yaml @@ -9,27 +9,27 @@ interactions: Content-Type: - application/merge-patch+json Date: - - Fri, 05 Mar 2021 22:21:26 GMT + - Mon, 08 Mar 2021 17:42:29 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-phonenumbers/1.0.0b4 Python/3.8.5 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: PATCH uri: https://sanitized.communication.azure.com/phoneNumbers/sanitized/capabilities?api-version=2021-03-07 response: body: - string: '{"capabilitiesUpdateId": "d44aa3e8-32ba-4ee4-b887-842c24752059"}' + string: '{"capabilitiesUpdateId": "05493504-fa96-42aa-a485-cbd0a64deda7"}' headers: access-control-expose-headers: Operation-Location,Location,operation-id,capabilities-id - capabilities-id: d44aa3e8-32ba-4ee4-b887-842c24752059 + capabilities-id: 05493504-fa96-42aa-a485-cbd0a64deda7 content-type: application/json; charset=utf-8 - date: Fri, 05 Mar 2021 22:21:27 GMT - ms-cv: ABRb4DZXnkOpl1LmEQgSmQ.0 - operation-id: capabilities_d44aa3e8-32ba-4ee4-b887-842c24752059 - operation-location: /phoneNumbers/operations/capabilities_d44aa3e8-32ba-4ee4-b887-842c24752059?api-version=2021-03-07 + date: Mon, 08 Mar 2021 17:42:30 GMT + ms-cv: UthRNs7tGkOXQVG2ozIVkQ.0 + operation-id: capabilities_05493504-fa96-42aa-a485-cbd0a64deda7 + operation-location: /phoneNumbers/operations/capabilities_05493504-fa96-42aa-a485-cbd0a64deda7?api-version=2021-03-07 request-context: appId= transfer-encoding: chunked - x-processing-time: 1084ms + x-processing-time: 1146ms status: code: 202 message: Accepted diff --git a/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client.py b/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client.py index f9becc7e332a..e6935e71d857 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client.py +++ b/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client.py @@ -42,7 +42,6 @@ def test_get_phone_number(self): phone_number = self.phone_number_client.get_phone_number(self.phone_number) assert phone_number.phone_number == self.phone_number - @pytest.mark.skipif(SKIP_PURCHASE_PHONE_NUMBER_TESTS, reason=PURCHASE_PHONE_NUMBER_TEST_SKIP_REASON) def test_search_available_phone_numbers(self): capabilities = PhoneNumberCapabilities( calling = PhoneNumberCapabilityType.INBOUND, diff --git a/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client_async.py b/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client_async.py index ad74a2a1a284..f7abb447a307 100644 --- a/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client_async.py +++ b/sdk/communication/azure-communication-phonenumbers/test/test_phone_number_administration_client_async.py @@ -55,7 +55,6 @@ async def test_get_phone_number(self): phone_number = await self.phone_number_client.get_phone_number(self.phone_number) assert phone_number.phone_number == self.phone_number - @pytest.mark.skipif(SKIP_PURCHASE_PHONE_NUMBER_TESTS, reason=PURCHASE_PHONE_NUMBER_TEST_SKIP_REASON) @AsyncCommunicationTestCase.await_prepared_test async def test_search_available_phone_numbers(self): capabilities = PhoneNumberCapabilities(