👷 Add pre-commit to check typos (#15482)

This commit is contained in:
Sebastián Ramírez
2026-05-05 11:44:36 +02:00
committed by GitHub
parent 3efd86c1fd
commit fb7429378d
6 changed files with 50 additions and 4 deletions

View File

@@ -154,13 +154,16 @@ def test_post_missing_required_field_in_item(client: TestClient):
def test_post_missing_required_field_in_user(client: TestClient):
response = client.put(
"/items/5",
json={"item": {"name": "Foo", "price": 50.5}, "user": {"ful_name": "John Doe"}},
json={
"item": {"name": "Foo", "price": 50.5},
"user": {"full_name": "John Doe"},
},
)
assert response.status_code == 422
assert response.json() == {
"detail": [
{
"input": {"ful_name": "John Doe"},
"input": {"full_name": "John Doe"},
"loc": [
"body",
"user",

View File

@@ -82,7 +82,7 @@ def test_post_no_body(client: TestClient):
}
def test_post_like_not_embeded(client: TestClient):
def test_post_like_not_embedded(client: TestClient):
response = client.put(
"/items/5",
json={