docker-py: skip broken ImageCollectionTest::test_pull_multiple, and re-enable fixed tests#40343
Merged
tianon merged 2 commits intomoby:masterfrom Jan 3, 2020
Merged
Conversation
Signed-off-by: Sebastiaan van Stijn <[email protected]>
The ImageCollectionTest.test_pull_multiple test performs a `docker pull` without
a `:tag` specified) to pull all tags of the given repository (image).
After pulling the image, the image(s) pulled are checked to verify if the list
of images contains the `:latest` tag.
However, the test assumes that all tags of the image are tags for the same
version of the image (same digest), and thus a *single* image is returned, which
is not always the case.
Currently, the `hello-world:latest` and `hello-world:linux` tags point to a
different digest, therefore the `client.images.pull()` returns multiple images:
one image for digest, making the test fail:
=================================== FAILURES ===================================
____________________ ImageCollectionTest.test_pull_multiple ____________________
tests/integration/models_images_test.py:90: in test_pull_multiple
assert len(images) == 1
E AssertionError: assert 2 == 1
E + where 2 = len([<Image: 'hello-world:linux'>, <Image: 'hello-world:latest'>])
This patch temporarily skips the broken test until it is fixed upstream.
Signed-off-by: Sebastiaan van Stijn <[email protected]>
This was referenced Jan 3, 2020
Member
Author
|
yay, green now @AkihiroSuda @cpuguy83 @tianon ptal 🤗 |
AkihiroSuda
approved these changes
Jan 3, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
re-enable tests that were fixed:
docker/docker-py#2369, docker/docker-py#2380, and docker/docker-py#2382 are included in docker-py v4.1.0, so we can re-enable these tests
docker-py: skip broken ImageCollectionTest::test_pull_multiple
The ImageCollectionTest.test_pull_multiple test performs a
docker pullwithouta
:tagspecified) to pull all tags of the given repository (image).After pulling the image, the image(s) pulled are checked to verify if the list
of images contains the
:latesttag.However, the test assumes that all tags of the image are tags for the same
version of the image (same digest), and thus a single image is returned, which
is not always the case.
Currently, the
hello-world:latestandhello-world:linuxtags point to adifferent digest, therefore the
client.images.pull()returns multiple images:one image for digest, making the test fail:
This patch temporarily skips the broken test until it is fixed upstream (PR: docker/docker-py#2485).