MCPcopy
hub / github.com/grpc/grpc-go / newTest

Function newTest

stats/stats_test.go:229–237  ·  view source on GitHub ↗

newTest returns a new test using the provided testing.T and environment. It is returned with default values. Tests should modify it before calling its startServer and clientConn methods.

(t *testing.T, tc *testConfig, chs []stats.Handler, shs []stats.Handler)

Source from the content-addressed store, hash-verified

227// environment. It is returned with default values. Tests should
228// modify it before calling its startServer and clientConn methods.
229func newTest(t *testing.T, tc *testConfig, chs []stats.Handler, shs []stats.Handler) *test {
230 te := &test{
231 t: t,
232 compress: tc.compress,
233 clientStatsHandlers: chs,
234 serverStatsHandlers: shs,
235 }
236 return te
237}
238
239// startServer starts a gRPC server listening. Callers should defer a
240// call to te.tearDown to clean up.

Callers 4

testServerStatsFunction · 0.70
testClientStatsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected