conftest.py 328 Bytes
Newer Older
luxcem's avatar
luxcem committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
import os

import pytest

import django
from django.conf import settings


os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'project.settings')


@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()