0001-misc-remove-pickle-auto-tests-from-admin_pages-65241.patch
tests/admin_pages/test_all.py | ||
---|---|---|
8 | 8 |
from ..utilities import clean_temporary_pub, create_temporary_pub, get_app, login |
9 | 9 | |
10 | 10 | |
11 |
def pytest_generate_tests(metafunc): |
|
12 |
if 'pub' in metafunc.fixturenames: |
|
13 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
14 | ||
15 | ||
16 | 11 |
@pytest.fixture |
17 | 12 |
def pub(request): |
18 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
13 |
pub = create_temporary_pub(sql_mode=True)
|
|
19 | 14 | |
20 | 15 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
21 | 16 |
pub.set_app_dir(req) |
tests/admin_pages/test_api_access.py | ||
---|---|---|
23 | 23 |
from .test_all import create_superuser |
24 | 24 | |
25 | 25 | |
26 |
def pytest_generate_tests(metafunc): |
|
27 |
if 'pub' in metafunc.fixturenames: |
|
28 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
29 | ||
30 | ||
31 | 26 |
@pytest.fixture |
32 | 27 |
def pub(request): |
33 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
28 |
pub = create_temporary_pub(sql_mode=True)
|
|
34 | 29 | |
35 | 30 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
36 | 31 |
pub.set_app_dir(req) |
tests/admin_pages/test_block.py | ||
---|---|---|
15 | 15 |
from .test_all import create_role, create_superuser |
16 | 16 | |
17 | 17 | |
18 |
def pytest_generate_tests(metafunc): |
|
19 |
if 'pub' in metafunc.fixturenames: |
|
20 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
21 | ||
22 | ||
23 | 18 |
@pytest.fixture |
24 | 19 |
def pub(request): |
25 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
20 |
pub = create_temporary_pub(sql_mode=True)
|
|
26 | 21 | |
27 | 22 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
28 | 23 |
pub.set_app_dir(req) |
tests/admin_pages/test_card.py | ||
---|---|---|
19 | 19 |
from .test_all import create_superuser |
20 | 20 | |
21 | 21 | |
22 |
def pytest_generate_tests(metafunc): |
|
23 |
if 'pub' in metafunc.fixturenames: |
|
24 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
25 | ||
26 | ||
27 |
@pytest.fixture |
|
28 |
def pub(request): |
|
29 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param)) |
|
22 |
def pub_fixture(**kwargs): |
|
23 |
pub = create_temporary_pub(**kwargs) |
|
30 | 24 | |
31 | 25 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
32 | 26 |
pub.set_app_dir(req) |
... | ... | |
37 | 31 |
return pub |
38 | 32 | |
39 | 33 | |
34 |
@pytest.fixture |
|
35 |
def pub(request, emails): |
|
36 |
return pub_fixture(sql_mode=True) |
|
37 | ||
38 | ||
39 |
@pytest.fixture |
|
40 |
def nosql_pub(request, emails): |
|
41 |
return pub_fixture() |
|
42 | ||
43 | ||
40 | 44 |
def teardown_module(module): |
41 | 45 |
clean_temporary_pub() |
42 | 46 | |
... | ... | |
141 | 145 |
app = login(get_app(pub)) |
142 | 146 |
resp = app.get('http://example.net/backoffice/cards/1/') |
143 | 147 |
resp = resp.click('Delete') |
144 |
if pub.is_using_postgresql(): |
|
145 |
assert 'Deletion is not possible as there are cards.' in resp |
|
146 |
carddef.data_class().wipe() |
|
147 |
resp = app.get('http://example.net/backoffice/cards/1/') |
|
148 |
resp = resp.click('Delete') |
|
148 |
assert 'Deletion is not possible as there are cards.' in resp |
|
149 |
carddef.data_class().wipe() |
|
150 |
resp = app.get('http://example.net/backoffice/cards/1/') |
|
151 |
resp = resp.click('Delete') |
|
149 | 152 | |
150 | 153 |
resp = resp.form.submit('submit') |
151 | 154 |
assert CardDef.count() == 1 |
... | ... | |
157 | 160 |
carddata.remove_self() # don't keep leftovers |
158 | 161 | |
159 | 162 | |
163 |
def test_cards_delete_nosql(nosql_pub): |
|
164 |
pub = nosql_pub |
|
165 |
create_superuser(pub) |
|
166 | ||
167 |
CardDef.wipe() |
|
168 |
carddef = CardDef() |
|
169 |
carddef.name = 'card title' |
|
170 |
carddef.fields = [] |
|
171 |
carddef.store() |
|
172 | ||
173 |
carddata = carddef.data_class()() |
|
174 |
carddata.just_created() |
|
175 |
carddata.data = {} |
|
176 |
carddata.store() |
|
177 | ||
178 |
app = login(get_app(pub)) |
|
179 |
resp = app.get('http://example.net/backoffice/cards/1/') |
|
180 |
resp = resp.click('Delete') |
|
181 |
assert 'Deletion is not possible as there are cards.' not in resp |
|
182 |
assert 'delete-button' in resp.text |
|
183 | ||
184 | ||
160 | 185 |
def test_cards_in_use_delete(pub): |
161 | 186 |
CardDef.wipe() |
162 | 187 |
carddef = CardDef() |
tests/admin_pages/test_carddefcategory.py | ||
---|---|---|
9 | 9 |
from .test_all import create_superuser |
10 | 10 | |
11 | 11 | |
12 |
def pytest_generate_tests(metafunc): |
|
13 |
if 'pub' in metafunc.fixturenames: |
|
14 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
15 | ||
16 | ||
17 | 12 |
@pytest.fixture |
18 | 13 |
def pub(request): |
19 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
14 |
pub = create_temporary_pub(sql_mode=True)
|
|
20 | 15 | |
21 | 16 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
22 | 17 |
pub.set_app_dir(req) |
tests/admin_pages/test_category.py | ||
---|---|---|
8 | 8 |
from .test_all import create_superuser |
9 | 9 | |
10 | 10 | |
11 |
def pytest_generate_tests(metafunc): |
|
12 |
if 'pub' in metafunc.fixturenames: |
|
13 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
14 | ||
15 | ||
16 | 11 |
@pytest.fixture |
17 | 12 |
def pub(request): |
18 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
13 |
pub = create_temporary_pub(sql_mode=True)
|
|
19 | 14 | |
20 | 15 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
21 | 16 |
pub.set_app_dir(req) |
tests/admin_pages/test_datasource.py | ||
---|---|---|
21 | 21 |
from .test_all import create_superuser |
22 | 22 | |
23 | 23 | |
24 |
def pytest_generate_tests(metafunc): |
|
25 |
if 'pub' in metafunc.fixturenames: |
|
26 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
27 | ||
28 | ||
29 | 24 |
def pub_fixture(**kwargs): |
30 | 25 |
pub = create_temporary_pub(**kwargs) |
31 | 26 | |
... | ... | |
40 | 35 | |
41 | 36 |
@pytest.fixture |
42 | 37 |
def pub(request, emails): |
43 |
return pub_fixture(sql_mode=bool('sql' in request.param))
|
|
38 |
return pub_fixture(sql_mode=True)
|
|
44 | 39 | |
45 | 40 | |
46 | 41 |
@pytest.fixture |
47 |
def sql_pub(request, emails): |
|
48 |
return pub_fixture(sql_mode=True)
|
|
42 |
def nosql_pub(request, emails):
|
|
43 |
return pub_fixture() |
|
49 | 44 | |
50 | 45 | |
51 | 46 |
def teardown_module(module): |
... | ... | |
150 | 145 |
) |
151 | 146 | |
152 | 147 | |
153 |
def test_data_sources_users(pub): |
|
148 |
def test_data_sources_users_no_sql(nosql_pub): |
|
149 |
pub = nosql_pub |
|
154 | 150 |
create_superuser(pub) |
155 | 151 |
NamedDataSource.wipe() |
156 | 152 | |
157 | 153 |
app = login(get_app(pub)) |
158 | 154 |
resp = app.get('/backoffice/settings/data-sources/') |
159 | 155 | |
160 |
if not pub.is_using_postgresql(): |
|
161 |
assert 'Users Data Sources' not in resp |
|
162 |
assert 'new-users' not in resp |
|
163 |
return |
|
156 |
assert 'Users Data Sources' not in resp |
|
157 |
assert 'new-users' not in resp |
|
158 | ||
159 | ||
160 |
def test_data_sources_users(pub): |
|
161 |
create_superuser(pub) |
|
162 |
NamedDataSource.wipe() |
|
163 | ||
164 |
app = login(get_app(pub)) |
|
165 |
resp = app.get('/backoffice/settings/data-sources/') |
|
164 | 166 | |
165 | 167 |
assert 'Users Data Sources' in resp |
166 | 168 |
assert 'There are no users data sources defined.' in resp |
... | ... | |
218 | 220 |
assert NamedDataSource.count() == 2 |
219 | 221 | |
220 | 222 | |
221 |
def test_data_sources_users_new(sql_pub): |
|
222 |
pub = sql_pub |
|
223 |
def test_data_sources_users_new(pub): |
|
223 | 224 |
create_superuser(pub) |
224 | 225 |
NamedDataSource.wipe() |
225 | 226 |
DataSourceCategory.wipe() |
... | ... | |
418 | 419 |
data_source.store() |
419 | 420 |
resp = app.get('/backoffice/settings/data-sources/%s/' % data_source.id) |
420 | 421 |
assert 'Preview' not in resp.text |
421 |
if pub.is_using_postgresql(): |
|
422 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
422 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
423 | 423 | |
424 | 424 |
# check geojson |
425 | 425 |
geojson_file_path = os.path.join(pub.app_dir, 'test.geojson') |
tests/admin_pages/test_form.py | ||
---|---|---|
23 | 23 |
from .test_all import create_role, create_superuser |
24 | 24 | |
25 | 25 | |
26 |
def pytest_generate_tests(metafunc): |
|
27 |
if 'pub' in metafunc.fixturenames: |
|
28 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
29 | ||
30 | ||
31 |
@pytest.fixture |
|
32 |
def pub(request): |
|
33 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param)) |
|
26 |
def pub_fixture(**kwargs): |
|
27 |
pub = create_temporary_pub(**kwargs) |
|
34 | 28 | |
35 | 29 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
36 | 30 |
pub.set_app_dir(req) |
... | ... | |
41 | 35 |
return pub |
42 | 36 | |
43 | 37 | |
38 |
@pytest.fixture |
|
39 |
def pub(request, emails): |
|
40 |
return pub_fixture(sql_mode=True) |
|
41 | ||
42 | ||
43 |
@pytest.fixture |
|
44 |
def nosql_pub(request, emails): |
|
45 |
return pub_fixture() |
|
46 | ||
47 | ||
44 | 48 |
def teardown_module(module): |
45 | 49 |
clean_temporary_pub() |
46 | 50 | |
... | ... | |
693 | 697 |
assert '/backoffice/workflows/%s/' % workflow.id not in resp.text |
694 | 698 | |
695 | 699 | |
696 |
def test_form_workflow_remapping(pub): |
|
700 |
def _test_form_workflow_remapping(pub):
|
|
697 | 701 |
create_superuser(pub) |
698 | 702 |
create_role(pub) |
699 | 703 | |
... | ... | |
781 | 785 |
FormDef.get(formdef.id).data_class().select() |
782 | 786 | |
783 | 787 | |
788 |
def test_form_workflow_remapping(pub): |
|
789 |
_test_form_workflow_remapping(pub) |
|
790 | ||
791 | ||
792 |
def test_form_workflow_remapping_nosql(nosql_pub): |
|
793 |
_test_form_workflow_remapping(nosql_pub) |
|
794 | ||
795 | ||
784 | 796 |
def test_form_submitter_roles(pub): |
785 | 797 |
create_superuser(pub) |
786 | 798 |
create_role(pub) |
... | ... | |
1184 | 1196 | |
1185 | 1197 |
resp = app.get('/backoffice/forms/%s/' % formdef.id) |
1186 | 1198 |
resp = resp.click(href='delete') |
1187 |
if pub.is_using_postgresql(): |
|
1188 |
assert 'Deletion is not possible' in resp |
|
1199 |
assert 'Deletion is not possible' in resp |
|
1189 | 1200 | |
1190 | 1201 |
formdata.status = 'draft' |
1191 | 1202 |
formdata.store() |
... | ... | |
1200 | 1211 |
assert 'Deletion is not possible' not in resp |
1201 | 1212 | |
1202 | 1213 | |
1214 |
def test_form_delete_with_data_nosql(nosql_pub): |
|
1215 |
pub = nosql_pub |
|
1216 |
create_superuser(pub) |
|
1217 |
create_role(pub) |
|
1218 | ||
1219 |
FormDef.wipe() |
|
1220 |
formdef = FormDef() |
|
1221 |
formdef.name = 'form title' |
|
1222 |
formdef.fields = [] |
|
1223 |
formdef.store() |
|
1224 | ||
1225 |
formdata = formdef.data_class()() |
|
1226 |
formdata.just_created() |
|
1227 |
formdata.store() |
|
1228 | ||
1229 |
app = login(get_app(pub)) |
|
1230 | ||
1231 |
resp = app.get('/backoffice/forms/%s/' % formdef.id) |
|
1232 |
resp = resp.click(href='delete') |
|
1233 |
assert 'Deletion is not possible' not in resp |
|
1234 | ||
1235 | ||
1203 | 1236 |
def test_form_duplicate(pub): |
1204 | 1237 |
create_superuser(pub) |
1205 | 1238 |
create_role(pub) |
... | ... | |
2094 | 2127 |
resp.form.submit('submit').follow() |
2095 | 2128 |
resp = app.get('/backoffice/forms/1/') |
2096 | 2129 |
assert FormDef.get(formdef.id).fields[0].data_source == {'type': 'foobar'} |
2097 |
if pub.is_using_postgresql(): |
|
2098 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
2130 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
2099 | 2131 | |
2100 | 2132 |
carddef = CardDef() |
2101 | 2133 |
carddef.name = 'Baz' |
... | ... | |
2920 | 2952 |
assert 'backoffice/management/form-title/' in resp |
2921 | 2953 | |
2922 | 2954 | |
2923 |
def test_form_archive(pub): |
|
2955 |
def test_form_archive(nosql_pub): |
|
2956 |
# this doesn't exist in SQL |
|
2957 |
pub = nosql_pub |
|
2924 | 2958 |
create_superuser(pub) |
2925 | 2959 |
create_role(pub) |
2926 | 2960 | |
2927 |
if pub.is_using_postgresql(): |
|
2928 |
# this doesn't exist in SQL |
|
2929 |
pytest.skip('no archive in SQL mode') |
|
2930 |
return |
|
2931 | ||
2932 | 2961 |
FormDef.wipe() |
2933 | 2962 |
formdef = FormDef() |
2934 | 2963 |
formdef.name = 'form title' |
... | ... | |
3081 | 3110 |
# check existing data |
3082 | 3111 |
data = FormDef.get(formdef_id).data_class().get(formdata.id).data |
3083 | 3112 |
assert data.get('2') == 'bar' |
3084 |
if pub.is_using_postgresql(): |
|
3085 |
# in SQL, check data with different type has been removed |
|
3086 |
assert data.get('3') is None |
|
3113 |
# in SQL, check data with different type has been removed |
|
3114 |
assert data.get('3') is None |
|
3087 | 3115 | |
3088 | 3116 | |
3089 | 3117 |
def test_form_export_import_export_overwrite(pub): |
... | ... | |
3230 | 3258 |
app = login(get_app(pub)) |
3231 | 3259 |
resp = app.get('/backoffice/forms/%s/' % formdef.id) |
3232 | 3260 |
assert 'x [webservice.xxx.foobar] x' in resp.text |
3233 |
if pub.is_using_postgresql(): |
|
3234 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
3261 |
assert pub.loggederror_class.count() == 0 # error not recorded |
|
3235 | 3262 | |
3236 | 3263 | |
3237 | 3264 |
def test_form_new_computed_field(pub): |
tests/admin_pages/test_role.py | ||
---|---|---|
7 | 7 |
from .test_all import create_superuser |
8 | 8 | |
9 | 9 | |
10 |
def pytest_generate_tests(metafunc): |
|
11 |
if 'pub' in metafunc.fixturenames: |
|
12 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
13 | ||
14 | ||
15 | 10 |
@pytest.fixture |
16 | 11 |
def pub(request): |
17 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
12 |
pub = create_temporary_pub(sql_mode=True)
|
|
18 | 13 | |
19 | 14 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
20 | 15 |
pub.set_app_dir(req) |
tests/admin_pages/test_settings.py | ||
---|---|---|
31 | 31 |
from .test_all import create_superuser |
32 | 32 | |
33 | 33 | |
34 |
def pytest_generate_tests(metafunc): |
|
35 |
if 'pub' in metafunc.fixturenames: |
|
36 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
37 | ||
38 | ||
39 | 34 |
@pytest.fixture |
40 | 35 |
def pub(request): |
41 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
36 |
pub = create_temporary_pub(sql_mode=True)
|
|
42 | 37 | |
43 | 38 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
44 | 39 |
pub.set_app_dir(req) |
... | ... | |
869 | 864 | |
870 | 865 | |
871 | 866 |
def test_postgresql_settings(pub): |
872 |
if not pub.is_using_postgresql(): |
|
873 |
pytest.skip('this requires SQL') |
|
874 |
return |
|
875 | ||
876 | 867 |
create_superuser(pub) |
877 | 868 | |
878 | 869 |
database = pub.cfg['postgresql']['database'] |
tests/admin_pages/test_studio.py | ||
---|---|---|
17 | 17 |
from .test_all import create_superuser |
18 | 18 | |
19 | 19 | |
20 |
def pytest_generate_tests(metafunc): |
|
21 |
if 'pub' in metafunc.fixturenames: |
|
22 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
23 | ||
24 | ||
25 | 20 |
def pub_fixture(**kwargs): |
26 | 21 |
pub = create_temporary_pub(**kwargs) |
27 | 22 | |
... | ... | |
36 | 31 | |
37 | 32 |
@pytest.fixture |
38 | 33 |
def pub(request): |
39 |
return pub_fixture(sql_mode=(request.param == 'sql'))
|
|
34 |
return pub_fixture(sql_mode=True)
|
|
40 | 35 | |
41 | 36 | |
42 | 37 |
@pytest.fixture |
tests/admin_pages/test_user.py | ||
---|---|---|
9 | 9 |
from .test_all import create_role, create_superuser |
10 | 10 | |
11 | 11 | |
12 |
def pytest_generate_tests(metafunc): |
|
13 |
if 'pub' in metafunc.fixturenames: |
|
14 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
15 | ||
16 | ||
17 | 12 |
@pytest.fixture |
18 | 13 |
def pub(request): |
19 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
14 |
pub = create_temporary_pub(sql_mode=True)
|
|
20 | 15 | |
21 | 16 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
22 | 17 |
pub.set_app_dir(req) |
tests/admin_pages/test_workflow.py | ||
---|---|---|
30 | 30 |
from .test_all import create_superuser |
31 | 31 | |
32 | 32 | |
33 |
def pytest_generate_tests(metafunc): |
|
34 |
if 'pub' in metafunc.fixturenames: |
|
35 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
36 | ||
37 | ||
38 | 33 |
@pytest.fixture |
39 | 34 |
def pub(request): |
40 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
35 |
pub = create_temporary_pub(sql_mode=True)
|
|
41 | 36 | |
42 | 37 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
43 | 38 |
pub.set_app_dir(req) |
... | ... | |
1951 | 1946 |
assert Workflow.get(1).backoffice_fields_formdef.fields[0].key == 'string' |
1952 | 1947 |
assert Workflow.get(1).backoffice_fields_formdef.fields[0].label == 'foobar' |
1953 | 1948 | |
1954 |
if pub.is_using_postgresql(): |
|
1955 |
assert 'New backoffice field "foobar"' in [ |
|
1956 |
x.comment for x in pub.snapshot_class.select_object_history(workflow) |
|
1957 |
] |
|
1949 |
assert 'New backoffice field "foobar"' in [ |
|
1950 |
x.comment for x in pub.snapshot_class.select_object_history(workflow) |
|
1951 |
] |
|
1958 | 1952 | |
1959 | 1953 |
backoffice_field_id = Workflow.get(1).backoffice_fields_formdef.fields[0].id |
1960 | 1954 |
formdef = FormDef.get(formdef.id) |
... | ... | |
3135 | 3129 | |
3136 | 3130 | |
3137 | 3131 |
def test_workflows_wscall_status_error(pub): |
3138 |
if not pub.is_using_postgresql(): |
|
3139 |
pytest.skip('this requires SQL') |
|
3140 |
return |
|
3141 | ||
3142 | 3132 |
create_superuser(pub) |
3143 | 3133 | |
3144 | 3134 |
Workflow.wipe() |
tests/admin_pages/test_wscall.py | ||
---|---|---|
11 | 11 |
from .test_all import create_superuser |
12 | 12 | |
13 | 13 | |
14 |
def pytest_generate_tests(metafunc): |
|
15 |
if 'pub' in metafunc.fixturenames: |
|
16 |
metafunc.parametrize('pub', ['pickle', 'sql'], indirect=True) |
|
17 | ||
18 | ||
19 | 14 |
@pytest.fixture |
20 | 15 |
def pub(request): |
21 |
pub = create_temporary_pub(sql_mode=bool('sql' in request.param))
|
|
16 |
pub = create_temporary_pub(sql_mode=True)
|
|
22 | 17 | |
23 | 18 |
req = HTTPRequest(None, {'SCRIPT_NAME': '/', 'SERVER_NAME': 'example.net'}) |
24 | 19 |
pub.set_app_dir(req) |
25 |
- |