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

Function clearEnv

stats/opentelemetry/csm/pluginoption_test.go:53–59  ·  view source on GitHub ↗

clearEnv unsets all the environment variables relevant to the csm pluginOption.

()

Source from the content-addressed store, hash-verified

51// clearEnv unsets all the environment variables relevant to the csm
52// pluginOption.
53func clearEnv() {
54 os.Unsetenv(envconfig.XDSBootstrapFileContentEnv)
55 os.Unsetenv(envconfig.XDSBootstrapFileNameEnv)
56
57 os.Unsetenv("CSM_CANONICAL_SERVICE_NAME")
58 os.Unsetenv("CSM_WORKLOAD_NAME")
59}
60
61func (s) TestGetLabels(t *testing.T) {
62 clearEnv()

Callers 2

TestGetLabelsMethod · 0.85
TestSetLabelsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected