summaryrefslogtreecommitdiff
path: root/tests/integration/service_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/integration/service_test.py')
-rw-r--r--tests/integration/service_test.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/integration/service_test.py b/tests/integration/service_test.py
index 260867fe..d8f4d094 100644
--- a/tests/integration/service_test.py
+++ b/tests/integration/service_test.py
@@ -1123,6 +1123,20 @@ class ServiceTest(DockerClientTestCase):
service.build(gzip=True)
assert service.image()
+ @v2_1_only()
+ def test_build_with_isolation(self):
+ base_dir = tempfile.mkdtemp()
+ self.addCleanup(shutil.rmtree, base_dir)
+ with open(os.path.join(base_dir, 'Dockerfile'), 'w') as f:
+ f.write('FROM busybox\n')
+
+ service = self.create_service('build_isolation', build={
+ 'context': text_type(base_dir),
+ 'isolation': 'default',
+ })
+ service.build()
+ assert service.image()
+
def test_start_container_stays_unprivileged(self):
service = self.create_service('web')
container = create_and_start_container(service).inspect()