mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-03-03 10:45:49 +03:00
* Update ruff from 0.5.7 to 0.6.0 * Update ruff from 0.5.7 to 0.6.0 * Update Ruff pre-commit hook * Update pytest style to match update Ruff rules * Switch Ruff setting from exclude to extend-exclude * Omit default Ruff settings --------- Co-authored-by: Bruno Alla <alla.brunoo@gmail.com>
15 lines
339 B
Python
15 lines
339 B
Python
import pytest
|
|
|
|
from {{ cookiecutter.project_slug }}.users.models import User
|
|
from {{ cookiecutter.project_slug }}.users.tests.factories import UserFactory
|
|
|
|
|
|
@pytest.fixture(autouse=True)
|
|
def _media_storage(settings, tmpdir) -> None:
|
|
settings.MEDIA_ROOT = tmpdir.strpath
|
|
|
|
|
|
@pytest.fixture
|
|
def user(db) -> User:
|
|
return UserFactory()
|