From 9f7685bc638c25e85ade96e911b715e57d1e064e Mon Sep 17 00:00:00 2001 From: amstee Date: Fri, 26 Jul 2024 21:51:56 +0100 Subject: [PATCH] chore: lint --- tests/unit/test_schema_registry_api.py | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/tests/unit/test_schema_registry_api.py b/tests/unit/test_schema_registry_api.py index f09009fe8..6d850f5fc 100644 --- a/tests/unit/test_schema_registry_api.py +++ b/tests/unit/test_schema_registry_api.py @@ -17,22 +17,15 @@ async def test_validate_schema_request_body(): controller = KarapaceSchemaRegistryController(config=set_config_defaults(DEFAULTS)) - controller._validate_schema_request_body("application/json", { - "schema": "{}", - "schemaType": "JSON", - "references": [], - "metadata": {}, - "ruleSet": {} - }) + controller._validate_schema_request_body( # pylint: disable=W0212 + "application/json", {"schema": "{}", "schemaType": "JSON", "references": [], "metadata": {}, "ruleSet": {}} + ) with pytest.raises(HTTPResponse) as exc_info: - controller._validate_schema_request_body("application/json", { - "schema": "{}", - "schemaType": "JSON", - "references": [], - "unexpected_field_name": {}, - "ruleSet": {} - }) + controller._validate_schema_request_body( # pylint: disable=W0212 + "application/json", + {"schema": "{}", "schemaType": "JSON", "references": [], "unexpected_field_name": {}, "ruleSet": {}}, + ) assert exc_info.type is HTTPResponse assert str(exc_info.value) == "HTTPResponse 422"