Documentation ¶
Index ¶
- Variables
- type GeneralOptions
- type Options
- func NewOracleDatabase(t *testing.T) (Options, func())
- func NewOracleOptions() Options
- func NewPostgresDatabase(t *testing.T) (Options, func())
- func NewPostgresOptions() Options
- func StartOracle(t *testing.T, opts Options) (Options, func())
- func StartPostgres(t *testing.T, opts Options) (Options, func())
- type OracleOptions
- type PostgresOptions
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidAttr = errors.New("Invalid DatabaseOption attribute")
)
Functions ¶
This section is empty.
Types ¶
type GeneralOptions ¶ added in v0.2.0
type GeneralOptions struct { ContainerEnv map[string]string ContainerImage string ContainerLabels map[string]string ContainerName string ContainerNetworks map[string][]string ContainerNetworkLabels map[string]map[string]string ContainerPort string Driver string DSN string }
func (*GeneralOptions) Validate ¶ added in v0.2.0
func (opts *GeneralOptions) Validate() error
Validate the options if all required attributes are valid
type Options ¶ added in v0.2.0
type Options interface { Get() *GeneralOptions Validate() error }
func NewOracleDatabase ¶ added in v0.2.0
NewOracleDatabase starts a new oracle database based on default values
func NewOracleOptions ¶ added in v0.2.0
func NewOracleOptions() Options
NewOracleOptions returns a new OracleOptions structs with default values
func NewPostgresDatabase ¶
NewPostgresDatabase starts a new postgres database based on default values
func NewPostgresOptions ¶
func NewPostgresOptions() Options
NewPostgresOptions returns a new PostgresOptions structs with default values
func StartOracle ¶ added in v0.2.0
StartOracle starts a oracle container image based on the OracleOption struct
type OracleOptions ¶ added in v0.2.0
type OracleOptions struct {
*GeneralOptions
}
func (*OracleOptions) Get ¶ added in v0.2.0
func (opts *OracleOptions) Get() *GeneralOptions
Get returns the defined options
func (*OracleOptions) Validate ¶ added in v0.2.0
func (opts *OracleOptions) Validate() error
Validate the options if all required attributes are valid
type PostgresOptions ¶
type PostgresOptions struct {
*GeneralOptions
}
func (*PostgresOptions) Get ¶ added in v0.2.0
func (opts *PostgresOptions) Get() *GeneralOptions
Get returns the defined options
func (*PostgresOptions) Validate ¶
func (opts *PostgresOptions) Validate() error
Validate the options if all required attributes are valid
Click to show internal directories.
Click to hide internal directories.