Skip to content

Commit f2e09ae

Browse files
author
Ulysses Souza
authored
Merge pull request #2485 from thaJeztah/fix_ImageCollectionTest_test_pull_multiple
Fix ImageCollectionTest.test_pull_multiple flakiness
2 parents 6010527 + 940805d commit f2e09ae

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/integration/models_images_test.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,10 @@ def test_pull_with_sha(self):
8787
def test_pull_multiple(self):
8888
client = docker.from_env(version=TEST_API_VERSION)
8989
images = client.images.pull('hello-world')
90-
assert len(images) == 1
91-
assert 'hello-world:latest' in images[0].attrs['RepoTags']
90+
assert len(images) >= 1
91+
assert any([
92+
'hello-world:latest' in img.attrs['RepoTags'] for img in images
93+
])
9294

9395
def test_load_error(self):
9496
client = docker.from_env(version=TEST_API_VERSION)

0 commit comments

Comments
 (0)