Skip to content

TestDial is flaky

Found in: https://gitlab.com/gitlab-org/gitaly/-/jobs/948635467.

Failure:

=== RUN   TestDial_Correlation
=== RUN   TestDial_Correlation/unary
=== RUN   TestDial_Correlation/stream
--- PASS: TestDial_Correlation (0.03s)
    --- PASS: TestDial_Correlation/unary (0.01s)
    --- PASS: TestDial_Correlation/stream (0.02s)
=== RUN   TestDial_Tracing
=== RUN   TestDial_Tracing/unary
=== RUN   TestDial_Tracing/stream
    dial_test.go:355: 
        	Error Trace:	dial_test.go:355
        	Error:      	Not equal: 
        	            	expected: "stub"
        	            	actual  : ""
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1 +1 @@
        	            	-stub
        	            	+
        	Test:       	TestDial_Tracing/stream
--- FAIL: TestDial_Tracing (0.02s)
    --- PASS: TestDial_Tracing/unary (0.01s)
    --- FAIL: TestDial_Tracing/stream (0.01s)

Code:

		spans := reporter.GetSpans()
		require.Len(t, spans, 3)
		require.Equal(t, "stub", spans[0].BaggageItem("service"))  // <-- failure on this line
		require.Equal(t, "", spans[1].BaggageItem("service"))
		require.Equal(t, "stub", spans[2].BaggageItem("service"))
Edited by Toon Claes
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information