MCPcopy Create free account
hub / github.com/GoogleCloudPlatform/cloud-sql-proxy / TestGcloud

Function TestGcloud

internal/gcloud/gcloud_test.go:23–39  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

21)
22
23func TestGcloud(t *testing.T) {
24 if testing.Short() {
25 t.Skip("skipping gcloud integration tests")
26 }
27
28 // gcloud is configured. Try to obtain a token from gcloud config
29 // helper.
30 ts, err := gcloud.TokenSource()
31 if err != nil {
32 t.Fatalf("failed to get token source: %v", err)
33 }
34
35 _, err = ts.Token()
36 if err != nil {
37 t.Fatalf("failed to get token: %v", err)
38 }
39}

Callers

nothing calls this directly

Calls 2

TokenSourceFunction · 0.92
TokenMethod · 0.45

Tested by

no test coverage detected