diff --git a/tests/fixtures/config/early-failure/git/common-config/zuul.yaml b/tests/fixtures/config/early-failure/git/common-config/zuul.yaml index 2d1790d4fc..d6ea50a7dd 100644 --- a/tests/fixtures/config/early-failure/git/common-config/zuul.yaml +++ b/tests/fixtures/config/early-failure/git/common-config/zuul.yaml @@ -48,6 +48,11 @@ - job: name: pre-failure + # Set attempts to a value less than the default of three but greater + # than 1 which results in no retries. This ensures testing covers code + # paths for retries without extra unnecesasry retries which make the + # tests run longer. + attempts: 2 files: - pre-failure.txt pre-run: diff --git a/tests/unit/test_v3.py b/tests/unit/test_v3.py index bb398f75f6..aeb56185ec 100644 --- a/tests/unit/test_v3.py +++ b/tests/unit/test_v3.py @@ -6281,7 +6281,7 @@ class TestEarlyFailure(AnsibleZuulTestCase): self.log.debug("Wait for all jobs to finish") for _ in iterate_timeout(30, 'all jobs finished'): - if len(self.builds) == 1 and len(self.history) == 4: + if len(self.builds) == 1 and len(self.history) == 3: break for b in self.builds[:]: if b.name == 'pre-failure': @@ -6320,7 +6320,6 @@ class TestEarlyFailure(AnsibleZuulTestCase): self.waitUntilSettled() self.assertHistory([ - dict(name='pre-failure', result=None, changes='1,1'), dict(name='pre-failure', result=None, changes='1,1'), dict(name='pre-failure', result=None, changes='1,1'), dict(name='wait', result='ABORTED', changes='1,1 2,1'),