21 lines
450 B
Python
21 lines
450 B
Python
import pytest
|
|
import django_webtest
|
|
|
|
|
|
@pytest.fixture
|
|
def app(request, db):
|
|
wtm = django_webtest.WebTestMixin()
|
|
wtm._patch_settings()
|
|
request.addfinalizer(wtm._unpatch_settings)
|
|
return django_webtest.DjangoTestApp(extra_environ={'HTTP_HOST': 'localhost'})
|
|
|
|
|
|
@pytest.fixture
|
|
def fc_settings(settings):
|
|
settings.A2_FC_ENABLE = True
|
|
settings.A2_FC_CLIENT_ID = 'xxx'
|
|
settings.A2_FC_CLIENT_SECRET = 'yyy'
|
|
return settings
|
|
|
|
|