refactor: refactor python sdk (#28118)

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
wangxiaolei
2025-11-20 11:10:53 +08:00
committed by GitHub
parent a1b735a4c0
commit 99e9fc751b
14 changed files with 4551 additions and 106 deletions

View File

@@ -152,6 +152,7 @@ class TestHttpxMigrationMocked(unittest.TestCase):
"""Test that json parameter is passed correctly."""
mock_response = Mock()
mock_response.json.return_value = {"result": "success"}
mock_response.status_code = 200 # Add status_code attribute
mock_client_instance = Mock()
mock_client_instance.request.return_value = mock_response
@@ -173,6 +174,7 @@ class TestHttpxMigrationMocked(unittest.TestCase):
"""Test that params parameter is passed correctly."""
mock_response = Mock()
mock_response.json.return_value = {"result": "success"}
mock_response.status_code = 200 # Add status_code attribute
mock_client_instance = Mock()
mock_client_instance.request.return_value = mock_response