resource

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2023 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PostgresResource

type PostgresResource struct {
	DB       *sql.DB
	DBDsn    string
	Database string
	Password string
	User     string
	Host     string
	Port     string
}

func SetupPostgres

func SetupPostgres(pool *dockertest.Pool, d cleaner, opts ...func(*postgres.Config)) (*PostgresResource, error)

type PulsarResource

type PulsarResource struct {
	URL      string
	AdminURL string
}

func SetupPulsar

func SetupPulsar(pool *dockertest.Pool, d cleaner, opts ...pulsar.Opt) (*PulsarResource, error)

type RedisOption added in v0.12.0

type RedisOption func(*redisConfig)

func WithRedisCmdArg added in v0.12.0

func WithRedisCmdArg(key, value string) RedisOption

WithRedisCmdArg is used to specify the save argument when running the container.

func WithRedisEnv added in v0.12.0

func WithRedisEnv(envs ...string) RedisOption

WithRedisEnv is used to pass environment variables to the container.

func WithRedisTag added in v0.12.0

func WithRedisTag(tag string) RedisOption

WithRedisTag is used to specify a custom tag that is used when pulling the Redis image from the container registry

type RedisResource added in v0.12.0

type RedisResource struct {
	Addr string
}

func SetupRedis added in v0.12.0

func SetupRedis(ctx context.Context, pool *dockertest.Pool, d cleaner, opts ...RedisOption) (*RedisResource, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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