conftest.py 328 Bytes
Newer Older
luxcem's avatar
luxcem committed
1 2 3 4 5 6 7 8
import os

import pytest

import django
from django.conf import settings


luxcem's avatar
luxcem committed
9
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "project.settings")
luxcem's avatar
luxcem committed
10 11 12 13 14 15 16 17 18 19


@pytest.fixture(autouse=True)
def enable_db_access_for_all_tests(db):
    """Adds access to db to all tests"""


def pytest_configure():
    settings.DEBUG = False
    django.setup()