8
8
from requests import Response
9
9
10
10
from azure .ai .ml import load_batch_endpoint
11
- from azure .ai .ml ._restclient .v2022_05_01 .models import BatchEndpointData
12
- from azure .ai .ml ._restclient .v2022_05_01 .models import BatchEndpointDetails as RestBatchEndpoint
11
+ from azure .ai .ml ._restclient .v2023_10_01 .models import BatchEndpoint as BatchEndpointData
12
+ from azure .ai .ml ._restclient .v2023_10_01 .models import BatchEndpointProperties as RestBatchEndpoint
13
13
from azure .ai .ml ._scope_dependent_operations import OperationConfig , OperationScope
14
14
from azure .ai .ml .constants ._common import AssetTypes , AzureMLResourceType
15
15
from azure .ai .ml .constants ._endpoint import EndpointYamlFields
@@ -138,7 +138,7 @@ def mock_local_endpoint_helper() -> Mock:
138
138
def mock_batch_endpoint_operations (
139
139
mock_workspace_scope : OperationScope ,
140
140
mock_operation_config : OperationConfig ,
141
- mock_aml_services_2022_05_01 : Mock ,
141
+ mock_aml_services_2023_10_01 : Mock ,
142
142
mock_aml_services_2020_09_01_dataplanepreview : Mock ,
143
143
mock_machinelearning_client : Mock ,
144
144
mock_environment_operations : Mock ,
@@ -158,7 +158,7 @@ def mock_batch_endpoint_operations(
158
158
yield BatchEndpointOperations (
159
159
operation_scope = mock_workspace_scope ,
160
160
operation_config = mock_operation_config ,
161
- service_client_05_2022 = mock_aml_services_2022_05_01 ,
161
+ service_client_10_2023 = mock_aml_services_2023_10_01 ,
162
162
all_operations = mock_machinelearning_client ._operation_container ,
163
163
requests_pipeline = mock_machinelearning_client ._requests_pipeline ,
164
164
** kwargs ,
@@ -310,10 +310,10 @@ def test_list_deployment_jobs(
310
310
def test_batch_get (
311
311
self ,
312
312
mock_batch_endpoint_operations : BatchEndpointOperations ,
313
- mock_aml_services_2022_05_01 : Mock ,
313
+ mock_aml_services_2023_10_01 : Mock ,
314
314
) -> None :
315
315
random_name = "random_name"
316
- mock_aml_services_2022_05_01 .batch_endpoints .get .return_value = BatchEndpointData (
316
+ mock_aml_services_2023_10_01 .batch_endpoints .get .return_value = BatchEndpointData (
317
317
name = random_name ,
318
318
location = "eastus" ,
319
319
properties = RestBatchEndpoint (auth_mode = "AADToken" ),
@@ -324,11 +324,11 @@ def test_batch_get(
324
324
def test_delete_batch_endpoint (
325
325
self ,
326
326
mock_batch_endpoint_operations : BatchEndpointOperations ,
327
- mock_aml_services_2022_05_01 : Mock ,
327
+ mock_aml_services_2023_10_01 : Mock ,
328
328
mocker : MockFixture ,
329
329
mock_delete_poller : LROPoller ,
330
330
) -> None :
331
331
random_name = "random_name"
332
- mock_aml_services_2022_05_01 .batch_endpoints .begin_delete .return_value = mock_delete_poller
332
+ mock_aml_services_2023_10_01 .batch_endpoints .begin_delete .return_value = mock_delete_poller
333
333
mock_batch_endpoint_operations .begin_delete (name = random_name )
334
334
mock_batch_endpoint_operations ._batch_operation .begin_delete .assert_called_once ()
0 commit comments