Conversation
testBakeMultiExporters checked the registry, docker store and OCI outputs but left the metadata file untested, with a TODO from the time multiple exporters were not supported. They are now, and a bake with image, docker and OCI outputs writes a metadata file with buildx.build.ref and containerimage.digest, so assert both. image.name is left alone: with several named exporters it still carries one name, so it cannot stand in for the others yet. The TODO now says that rather than pointing at multi exporter support in general. Signed-off-by: SaiPisey2 <piseysai0202@gmail.com>
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.
testBakeMultiExporterschecks the registry, docker store and OCI outputs, but leaves the metadata file untested:// TODO: test metadata file when supported by multi exporters https://github.com/docker/buildx/issues/2181Multiple exporters are supported now, and a bake with image, docker and OCI outputs does write a metadata file, so this asserts
buildx.build.refandcontainerimage.digestfrom it.image.nameis deliberately not asserted. With several named exporters it still reports only one name, so it cannot stand in for the others. The TODO now records that narrower gap instead of pointing at multi exporter support in general.Testing
The integration harness does not come up on my machine, on master as well as on this branch: it fails in
lazyMirrorRunnerFuncbefore any test body runs, so I could not exercisetestBakeMultiExportersitself.What I did check was the behaviour the assertions depend on, by running a bake with the same shape of outputs against buildx 0.32.1:
Both asserted keys are present, and
image.namecarries only thetype=imagename while thetype=dockerone is missing, which is why it is left out of the assertions.