From 4677709d1355d827f50d6e4ebaf9d1f764bb09c0 Mon Sep 17 00:00:00 2001 From: Dmitriy Zayakin Date: Thu, 14 Nov 2024 15:01:26 +0300 Subject: [PATCH] [#310] Added classmethod decorator in Http client Signed-off-by: Dmitriy Zayakin --- src/frostfs_testlib/http/http_client.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/frostfs_testlib/http/http_client.py b/src/frostfs_testlib/http/http_client.py index 261b2a6..4d24cfb 100644 --- a/src/frostfs_testlib/http/http_client.py +++ b/src/frostfs_testlib/http/http_client.py @@ -50,6 +50,7 @@ class HttpClient: return response + @classmethod def _attach_response(self, response: httpx.Response): request = response.request @@ -88,6 +89,7 @@ class HttpClient: reporter.attach(report, "Requests Info") reporter.attach(curl_request, "CURL") + @classmethod def _create_curl_request(self, url: str, method: str, headers: httpx.Headers, data: str) -> str: headers = " ".join(f'-H "{name.title()}: {value}"' for name, value in headers.items()) data = f" -d '{data}'" if data else ""