mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-11 04:19:25 +00:00
Only run full procfile on runserver
This commit is contained in:
@ -3,7 +3,7 @@ import atexit
|
||||
import pytest
|
||||
|
||||
from .composer import start_composer, stop_composer
|
||||
from .settings import PROCFILE_PYTEST
|
||||
from .settings import PROCFILE_MINIMAL
|
||||
|
||||
# it's the first hook loaded by pytest and can only
|
||||
# be defined in a proper pytest plugin
|
||||
@ -15,6 +15,6 @@ from .settings import PROCFILE_PYTEST
|
||||
@pytest.hookimpl(tryfirst=True)
|
||||
def pytest_load_initial_conftests(early_config, parser, args):
|
||||
"""Hook that loads the composer before the pytest-django plugin"""
|
||||
if PROCFILE_PYTEST is not None:
|
||||
start_composer(PROCFILE_PYTEST)
|
||||
if PROCFILE_MINIMAL is not None:
|
||||
start_composer(PROCFILE_MINIMAL)
|
||||
_ = atexit.register(stop_composer)
|
||||
|
Reference in New Issue
Block a user