From 091ef5a5cb7460e162eb66908df316b9bd790cf1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Martin=20Andr=C3=A9?= <martin.andre@kvhasia.com>
Date: Thu, 25 Jun 2015 22:21:04 +0900
Subject: [PATCH] Have test retry building failed images

The image build test now retries 3 times before declaring an image as
failing. This should help the gate in case of unreliable network
connectivity to the mirrors.

We expect the penalty of retrying to build failed images to be low
thanks to docker cache. Only the failing layer should be retried.

Change-Id: I15fd4926019590a150eb22dc885d0ef8cd31e7cc
Closes-Bug: #1466677
---
 tests/test_images.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/test_images.py b/tests/test_images.py
index b3821fcf5..13b5bdb09 100644
--- a/tests/test_images.py
+++ b/tests/test_images.py
@@ -26,7 +26,8 @@ class ImagesTest(base.BaseTestCase):
 
     def test_builds(self):
         proc = Popen(['tools/build-all-docker-images',
-                      '--testmode'],
+                      '--testmode',
+                      '--retry 3'],
                      stdout=PIPE, stderr=STDOUT, bufsize=1)
         with proc.stdout:
             for line in iter(proc.stdout.readline, b''):
-- 
GitLab