@@ -190,6 +190,19 @@ def test_multiple_inventories(project_fixtures):
190
190
assert 'host_2' in stdout
191
191
192
192
193
+ def test_default_project_dir (project_fixtures ):
194
+ private_data_dir = project_fixtures / 'project_dir_test'
195
+
196
+ res = run (
197
+ private_data_dir = private_data_dir ,
198
+ playbook = 'debug.yml' ,
199
+ )
200
+ stdout = res .stdout .read ()
201
+
202
+ assert res .rc == 0 , stdout
203
+ assert 'project' in stdout
204
+
205
+
193
206
def test_project_dir (project_fixtures ):
194
207
private_data_dir = project_fixtures / 'project_dir_test'
195
208
@@ -204,6 +217,41 @@ def test_project_dir(project_fixtures):
204
217
assert 'my_project' in stdout
205
218
206
219
220
+ @pytest .mark .test_all_runtimes
221
+ def test_default_project_dir_process_isolation (project_fixtures , runtime ):
222
+ private_data_dir = project_fixtures / 'project_dir_test'
223
+
224
+ res = run (
225
+ private_data_dir = private_data_dir ,
226
+ playbook = 'debug.yml' ,
227
+ process_isolation_executable = runtime ,
228
+ process_isolation = True ,
229
+ container_image = defaults .default_container_image ,
230
+ )
231
+ stdout = res .stdout .read ()
232
+
233
+ assert res .rc == 0 , stdout
234
+ assert 'project' in stdout
235
+
236
+
237
+ @pytest .mark .test_all_runtimes
238
+ def test_project_dir_process_isolation (project_fixtures , runtime ):
239
+ private_data_dir = project_fixtures / 'project_dir_test'
240
+
241
+ res = run (
242
+ private_data_dir = private_data_dir ,
243
+ container_workdir = '/runner/my_project' ,
244
+ playbook = 'debug.yml' ,
245
+ process_isolation_executable = runtime ,
246
+ process_isolation = True ,
247
+ container_image = defaults .default_container_image ,
248
+ )
249
+ stdout = res .stdout .read ()
250
+
251
+ assert res .rc == 0 , stdout
252
+ assert 'my_project' in stdout
253
+
254
+
207
255
def test_inventory_absolute_path (project_fixtures ):
208
256
private_data_dir = project_fixtures / 'debug'
209
257
0 commit comments