mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-08-03 04:25:24 +02:00
chore(deps): update dependency ruff to ^0.9.0 (#4871)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Michael Genson <71845777+michael-genson@users.noreply.github.com> Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
This commit is contained in:
parent
ea0bec2336
commit
2c2de1e95b
22 changed files with 124 additions and 138 deletions
|
@ -6,7 +6,6 @@ import sqlalchemy
|
|||
from fastapi.testclient import TestClient
|
||||
|
||||
from mealie.core.dependencies.dependencies import validate_file_token
|
||||
from mealie.repos.repository_factory import AllRepositories
|
||||
from mealie.schema.recipe.recipe_bulk_actions import ExportTypes
|
||||
from mealie.schema.recipe.recipe_category import CategorySave, TagSave
|
||||
from tests import utils
|
||||
|
@ -137,7 +136,7 @@ def test_bulk_export_recipes(api_client: TestClient, unique_user: TestUser, ten_
|
|||
assert validate_file_token(response_data["fileToken"]) == Path(export_path)
|
||||
|
||||
# Use Export Token to download export
|
||||
response = api_client.get(f'/api/utils/download?token={response_data["fileToken"]}')
|
||||
response = api_client.get(f"/api/utils/download?token={response_data['fileToken']}")
|
||||
|
||||
assert response.status_code == 200
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
from datetime import datetime, timezone
|
||||
from datetime import UTC, datetime
|
||||
|
||||
import pytest
|
||||
from fastapi.testclient import TestClient
|
||||
|
@ -242,7 +242,7 @@ def test_user_can_update_last_made_on_other_household(
|
|||
assert recipe["id"] == str(h2_recipe_id)
|
||||
old_last_made = recipe["lastMade"]
|
||||
|
||||
now = datetime.now(timezone.utc).isoformat().replace("+00:00", "Z")
|
||||
now = datetime.now(UTC).isoformat().replace("+00:00", "Z")
|
||||
response = api_client.patch(
|
||||
api_routes.recipes_slug_last_made(h2_recipe_slug), json={"timestamp": now}, headers=unique_user.token
|
||||
)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
from datetime import datetime, timezone
|
||||
from datetime import UTC, datetime
|
||||
|
||||
from fastapi.testclient import TestClient
|
||||
|
||||
|
@ -106,7 +106,7 @@ def test_user_update_last_made(api_client: TestClient, user_tuple: list[TestUser
|
|||
response = api_client.put(api_routes.recipes + f"/{recipe_name}", json=recipe, headers=usr_1.token)
|
||||
|
||||
# User 2 should be able to update the last made timestamp
|
||||
last_made_json = {"timestamp": datetime.now(timezone.utc).isoformat().replace("+00:00", "Z")}
|
||||
last_made_json = {"timestamp": datetime.now(UTC).isoformat().replace("+00:00", "Z")}
|
||||
response = api_client.patch(
|
||||
api_routes.recipes_slug_last_made(recipe_name), json=last_made_json, headers=usr_2.token
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue