Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8785a51 commit eba4289Copy full SHA for eba4289
enterprise/cli/proxyserver_test.go
@@ -59,10 +59,11 @@ func Test_ProxyServer_Headers(t *testing.T) {
59
assert.EqualValues(t, 1, atomic.LoadInt64(&called))
60
}
61
62
+//nolint:paralleltest,tparallel // Test uses a static port.
63
func TestWorkspaceProxy_Server_PrometheusEnabled(t *testing.T) {
- t.Parallel()
64
-
65
- prometheusPort := testutil.RandomPort(t)
+ // Ephemeral ports have a tendency to conflict and fail with `bind: address already in use` error.
+ // This workaround forces a static port for Prometheus that hopefully won't be used by other tests.
66
+ prometheusPort := 32002
67
68
var wg sync.WaitGroup
69
wg.Add(1)
0 commit comments