internal

package
v6.2.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2018 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ElasticsearchDefaultHost is the default host for elasticsearch.
	ElasticsearchDefaultHost = "localhost"
	// ElasticsearchDefaultPort is the default port for elasticsearch.
	ElasticsearchDefaultPort = "9200"
)

Variables

This section is empty.

Functions

func GetEsHost

func GetEsHost() string

GetEsHost returns the Elasticsearch testing host.

func GetEsPort

func GetEsPort() string

GetEsPort returns the Elasticsearch testing port.

func GetPass

func GetPass() string

GetPass returns the Elasticsearch testing user's password.

func GetURL

func GetURL() string

GetURL return the Elasticsearch testing URL.

func GetUser

func GetUser() string

GetUser returns the Elasticsearch testing user.

func InitClient

func InitClient(t TestLogger, client Connectable, err error)

InitClient initializes a new client if the no error value from creating the client instance is reported. The test logger will be used if an error is found.

Types

type Connectable

type Connectable interface {
	Connect() error
}

Connectable defines the minimum interface required to initialize a connected client.

type TestLogger

type TestLogger interface {
	Fatal(args ...interface{})
}

TestLogger is used to report fatal errors to the testing framework.

Jump to

Keyboard shortcuts

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