Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bake: fix testing json formatted output #2584

Merged
merged 1 commit into from
Jul 9, 2024

Conversation

tonistiigi
Copy link
Member

Because the test checked for combinedoutput, it
could contain internal warning messages in stderr. JSON output is guaranteed in stdout.

Fixes #2575

This was the debug output:

=== FAIL: tests TestIntegration/TestBakeCallCheckFlag/worker=docker-container (3.96s)
    bake.go:1086: 
        	Error Trace:	/src/tests/bake.go:1086
        	            				/src/vendor/github.com/moby/buildkit/util/testutil/integration/run.go:96
        	            				/src/vendor/github.com/moby/buildkit/util/testutil/integration/run.go:211
        	Error:      	Received unexpected error:
        	            	invalid character '/' after top-level value
        	Test:       	TestIntegration/TestBakeCallCheckFlag/worker=docker-container
        	Messages:   	2024/07/09 00:57:04 http2: server connection error from localhost: connection error: PROTOCOL_ERROR
        	            	{
        	            	  "group": {
        	            	    "default": {
        	            	      "targets": [
        	            	        "build",
        	            	        "another"
        	            	      ]
        	            	    }

Because the test checked for combinedoutput, it
could contain internal warning messages in stderr.
JSON output is guaranteed in stdout.

Signed-off-by: Tonis Tiigi <[email protected]>
@tonistiigi tonistiigi merged commit 06d96d6 into docker:master Jul 9, 2024
103 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Flaky: TestBakeCallCheckFlag
2 participants