mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-10-27 00:04:23 -04:00
updated models/services/tests to include user_id
This commit is contained in:
6
tests/fixtures/fixture_shopping_lists.py
vendored
6
tests/fixtures/fixture_shopping_lists.py
vendored
@@ -29,7 +29,7 @@ def shopping_lists(database: AllRepositories, unique_user: TestUser):
|
||||
|
||||
for _ in range(3):
|
||||
model = database.group_shopping_lists.create(
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id),
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id, user_id=unique_user.user_id),
|
||||
)
|
||||
|
||||
models.append(model)
|
||||
@@ -46,7 +46,7 @@ def shopping_lists(database: AllRepositories, unique_user: TestUser):
|
||||
@pytest.fixture(scope="function")
|
||||
def shopping_list(database: AllRepositories, unique_user: TestUser):
|
||||
model = database.group_shopping_lists.create(
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id),
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id, user_id=unique_user.user_id),
|
||||
)
|
||||
|
||||
yield model
|
||||
@@ -60,7 +60,7 @@ def shopping_list(database: AllRepositories, unique_user: TestUser):
|
||||
@pytest.fixture(scope="function")
|
||||
def list_with_items(database: AllRepositories, unique_user: TestUser):
|
||||
list_model = database.group_shopping_lists.create(
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id),
|
||||
ShoppingListSave(name=random_string(10), group_id=unique_user.group_id, user_id=unique_user.user_id),
|
||||
)
|
||||
|
||||
for _ in range(10):
|
||||
|
||||
Reference in New Issue
Block a user