@@ -28,6 +28,7 @@ def test_splitfile_preprocessor_escaping():
28
28
assert 'tag-v1-whatever' in commands
29
29
30
30
31
+ @pytest .mark .mounting
31
32
def test_basic_splitfile (pg_repo_local , mg_repo_local ):
32
33
execute_commands (load_splitfile ('create_table.splitfile' ), output = OUTPUT )
33
34
log = list (reversed (OUTPUT .head .get_log ()))
@@ -42,6 +43,7 @@ def test_basic_splitfile(pg_repo_local, mg_repo_local):
42
43
assert OUTPUT .run_sql ("SELECT * FROM my_fruits" ) == [(1 , 'pineapple' ), (2 , 'banana' )]
43
44
44
45
46
+ @pytest .mark .mounting
45
47
def test_update_without_import_splitfile (pg_repo_local , mg_repo_local ):
46
48
# Test that correct commits are produced by executing an splitfile (both against newly created and already
47
49
# existing tables on an existing mountpoint)
@@ -55,6 +57,7 @@ def test_update_without_import_splitfile(pg_repo_local, mg_repo_local):
55
57
assert OUTPUT .run_sql ("SELECT * FROM my_fruits" ) == [(1 , 'pineapple' )]
56
58
57
59
60
+ @pytest .mark .mounting
58
61
def test_local_import_splitfile (pg_repo_local , mg_repo_local ):
59
62
execute_commands (load_splitfile ('import_local.splitfile' ), output = OUTPUT )
60
63
head = OUTPUT .head
@@ -69,6 +72,7 @@ def test_local_import_splitfile(pg_repo_local, mg_repo_local):
69
72
assert not OUTPUT .engine .table_exists (OUTPUT .to_schema (), 'fruits' )
70
73
71
74
75
+ @pytest .mark .mounting
72
76
def test_advanced_splitfile (pg_repo_local , mg_repo_local ):
73
77
execute_commands (load_splitfile ('import_local_multiple_with_queries.splitfile' ), output = OUTPUT )
74
78
@@ -86,6 +90,7 @@ def test_advanced_splitfile(pg_repo_local, mg_repo_local):
86
90
assert OUTPUT .run_sql ("SELECT * FROM my_fruits" ) == [(2 , 'orange' )]
87
91
88
92
93
+ @pytest .mark .mounting
89
94
def test_splitfile_cached (pg_repo_local , mg_repo_local ):
90
95
# Check that no new commits/snaps are created if we rerun the same splitfile
91
96
execute_commands (load_splitfile ('import_local_multiple_with_queries.splitfile' ), output = OUTPUT )
@@ -144,6 +149,7 @@ def test_import_updating_splitfile_with_uploading(local_engine_empty, remote_eng
144
149
assert OUTPUT .run_sql ("SELECT fruit_id, name FROM my_fruits" ) == [(1 , 'apple' ), (2 , 'orange' ), (3 , 'mayonnaise' )]
145
150
146
151
152
+ @pytest .mark .mounting
147
153
def test_splitfile_end_to_end_with_uploading (local_engine_empty , remote_engine ,
148
154
pg_repo_remote_multitag , mg_repo_remote ):
149
155
# An end-to-end test:
@@ -171,6 +177,7 @@ def test_splitfile_end_to_end_with_uploading(local_engine_empty, remote_engine,
171
177
assert stage_2 .run_sql ("SELECT id, name, fruit, vegetable FROM diet" ) == [(2 , 'James' , 'orange' , 'carrot' )]
172
178
173
179
180
+ @pytest .mark .mounting
174
181
def test_splitfile_schema_changes (pg_repo_local , mg_repo_local ):
175
182
execute_commands (load_splitfile ('schema_changes.splitfile' ), output = OUTPUT )
176
183
old_output_head = OUTPUT .head
@@ -189,6 +196,7 @@ def test_splitfile_schema_changes(pg_repo_local, mg_repo_local):
189
196
assert OUTPUT .run_sql ("SELECT * FROM spirit_fruits" ) == [('James' , 'orange' , 12 ), ('Alex' , 'mayonnaise' , 22 )]
190
197
191
198
199
+ @pytest .mark .mounting
192
200
def test_import_with_custom_query (pg_repo_local , mg_repo_local ):
193
201
# Mostly a lazy way for the test to distinguish between the importer storing the results of a query as a snap
194
202
# and pointing the commit history to the diff for unchanged objects.
@@ -224,6 +232,7 @@ def test_import_with_custom_query(pg_repo_local, mg_repo_local):
224
232
assert OUTPUT .objects .get_object_meta (objects )[objects [0 ]].parent_id is not None
225
233
226
234
235
+ @pytest .mark .mounting
227
236
def test_import_mount (local_engine_empty ):
228
237
execute_commands (load_splitfile ('import_from_mounted_db.splitfile' ), output = OUTPUT )
229
238
@@ -246,6 +255,7 @@ def test_import_mount(local_engine_empty):
246
255
assert OUTPUT .objects .get_object_meta (objects )[objects [0 ]].parent_id is None
247
256
248
257
258
+ @pytest .mark .mounting
249
259
def test_import_all (local_engine_empty ):
250
260
execute_commands (load_splitfile ('import_all_from_mounted.splitfile' ), output = OUTPUT )
251
261
@@ -331,6 +341,7 @@ def test_from_local(pg_repo_local):
331
341
assert OUTPUT .run_sql ("SELECT * FROM join_table" ) == [(1 , 'apple' , 'potato' ), (2 , 'orange' , 'carrot' )]
332
342
333
343
344
+ @pytest .mark .mounting
334
345
def test_splitfile_with_external_sql (pg_repo_local , pg_repo_remote , mg_repo_local ):
335
346
# Tests are running from root so we pass in the path to the SQL manually to the splitfile.
336
347
execute_commands (load_splitfile ('external_sql.splitfile' ),
0 commit comments