test_helpers

package
v0.24.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 2, 2020 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	BoshDeployment    boshdir.Deployment
	BoshCredhubPrefix string
)
View Source
var HttpClient = http.DefaultClient

Functions

func ActiveProxyBackend added in v0.4.0

func ActiveProxyBackend(proxyUsername, proxyPassword, proxyHost string, client *http.Client) (string, error)

func BoshCaCert

func BoshCaCert() string

func BoshClient

func BoshClient() string

func BoshClientSecret

func BoshClientSecret() string

func BoshDeploymentName added in v0.15.0

func BoshDeploymentName() string

func BoshEnvironment

func BoshEnvironment() string

func BuildBoshDirector

func BuildBoshDirector() (boshdir.Director, error)

func CheckForRequiredEnvVars

func CheckForRequiredEnvVars(envs []string)

func DbCleanup added in v0.4.0

func DbCleanup(db *sql.DB)

func DbConnWithUser added in v0.13.0

func DbConnWithUser(mysqlUsername, mysqlPassword, mysqlHost string) *sql.DB

func DbSetup added in v0.4.0

func DbSetup(db *sql.DB, tableName string) string

func ExecuteBosh added in v0.16.0

func ExecuteBosh(args []string, timeout time.Duration) *gexec.Session

func ExecuteMysqlQuery added in v0.16.0

func ExecuteMysqlQuery(deploymentName, instanceIndex, userName, password, sqlQuery string) *gexec.Session

ExecuteMysqlQuery executes sqlQuery against the MySQL deployment denoted by deploymentName and instance instanceIndex, using credentials in userName and password. It returns a pointer to a gexec.Session to be consumed.

func ExecuteMysqlQueryAsAdmin added in v0.16.0

func ExecuteMysqlQueryAsAdmin(deploymentName, instanceIndex, sqlQuery string) string

func FirstProxyHost added in v0.15.0

func FirstProxyHost(boshDeployment boshdir.Deployment) (string, error)

func GetDeploymentCertificateByName added in v0.17.0

func GetDeploymentCertificateByName(name string) (tls.Certificate, error)

func GetGaleraAgentPassword added in v0.15.0

func GetGaleraAgentPassword() (string, error)

func GetMySQLAdminPassword added in v0.15.0

func GetMySQLAdminPassword() (string, error)

func GetProxyPassword added in v0.15.0

func GetProxyPassword() (string, error)

func HostsForInstanceGroup added in v0.15.0

func HostsForInstanceGroup(deployment boshdir.Deployment, instanceGroupName string) ([]string, error)

func MustSucceed added in v0.16.0

func MustSucceed(session *gexec.Session) *gexec.Session

func MySQLHosts added in v0.15.0

func MySQLHosts(boshDeployment boshdir.Deployment) ([]string, error)

func NewCredhubClient added in v0.15.0

func NewCredhubClient() (*credhub.CredHub, error)

func NewSocks5Dialer added in v0.15.0

func NewSocks5Dialer(proxyURL string, logger *log.Logger) (proxy.DialFunc, error)

func SetupBoshDeployment added in v0.15.0

func SetupBoshDeployment()

func SetupSocks5Proxy added in v0.15.0

func SetupSocks5Proxy()

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL