github.com/huaweicloud/golangsdk@v0.0.0-20210831081626-d823fe11ceba/testhelper/client/fake.go (about)

     1  package client
     2  
     3  import (
     4  	"github.com/huaweicloud/golangsdk"
     5  	"github.com/huaweicloud/golangsdk/testhelper"
     6  )
     7  
     8  // Fake token to use.
     9  const TokenID = "cbc36478b0bd8e67e89469c7749d4127"
    10  
    11  // ServiceClient returns a generic service client for use in tests.
    12  func ServiceClient() *golangsdk.ServiceClient {
    13  	return &golangsdk.ServiceClient{
    14  		ProviderClient: &golangsdk.ProviderClient{TokenID: TokenID},
    15  		Endpoint:       testhelper.Endpoint(),
    16  	}
    17  }