Coverage for mlos_bench/mlos_bench/tests/services/remote/mock/__init__.py: 75%

4 statements  

« prev     ^ index     » next       coverage.py v7.6.7, created at 2024-11-22 01:18 +0000

1# 

2# Copyright (c) Microsoft Corporation. 

3# Licensed under the MIT License. 

4# 

5"""Mock remote services for testing purposes.""" 

6 

7from typing import Any, Tuple 

8 

9from mlos_bench.environments.status import Status 

10 

11 

12def mock_operation(*_args: Any, **_kwargs: Any) -> Tuple[Status, dict]: 

13 """ 

14 Mock VM operation that always succeeds. 

15 

16 Returns 

17 ------- 

18 result : (Status, dict) 

19 A pair of Status and result, always (SUCCEEDED, {}). 

20 """ 

21 return Status.SUCCEEDED, {}