fix(webhook): correct JSON response in aiohttp_server (dev-3.x)

- Removed unused import 'to_json' from pydantic_core module.
- Fixed the json_response by adding 'dumps=form_serialize'.

test(api): fix remove_unset method in test_base (dev-3.x)

- Modified tests to call remove_unset without '.wrapped'.
This commit is contained in:
zemf4you 2024-05-20 16:05:39 +07:00
parent 534221a30a
commit 7cfb82674d
2 changed files with 4 additions and 4 deletions

View file

@ -20,12 +20,12 @@ class TestTelegramMethodRemoveUnset:
)
@pytest.mark.parametrize("obj", [TelegramMethod, TelegramObject])
def test_remove_unset(self, values, names, obj):
validated = obj.remove_unset.wrapped(values)
validated = obj.remove_unset(values)
assert set(validated.keys()) == names
@pytest.mark.parametrize("obj", [TelegramMethod, TelegramObject])
def test_remove_unset_non_dict(self, obj):
assert obj.remove_unset.wrapped("") == ""
assert obj.remove_unset("") == ""
class TestTelegramMethodModelDumpJson: