testutil

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package testutil implements functions for filtering and configuring tests.

Index

Constants

This section is empty.

Variables

View Source
var (
	UserAdmin              = "uAdmin"
	UserAdminPassword      = "password"
	CreatedUserNameEnv     = "TOOLS_TESTING_AUTH_USERNAME"
	CreatedUserPasswordEnv = "TOOLS_TESTING_AUTH_PASSWORD"
)

Functions

func CompareFCV

func CompareFCV(x, y string) (int, error)

CompareFCV compares two strings as dot-delimited tuples of integers

func GetAuthArgs

func GetAuthArgs() []string

func GetAuthOptions

func GetAuthOptions() options.Auth

func GetBareArgs

func GetBareArgs() []string

func GetBareSession

func GetBareSession() (*mongo.Client, error)

GetBareSession returns an mgo.Session from the environment or from a default host and port.

func GetBareSessionProvider

func GetBareSessionProvider() (*db.SessionProvider, *options.ToolOptions, error)

GetBareSessionProvider returns a session provider from the environment or from a default host and port.

func GetFCV

func GetFCV(s *mongo.Client) string

GetFCV returns the featureCompatibilityVersion string for an mgo Session or the empty string if it can't be found.

func GetSSLArgs

func GetSSLArgs() []string

func GetSSLOptions

func GetSSLOptions() commonOpts.SSL

func MergeOplogStreams

func MergeOplogStreams(input [][]db.Oplog) []db.Oplog

MergeOplogStreams combines oplog arrays such that the order of entries is random, but order-preserving with respect to each initial stream.

Types

This section is empty.

Jump to

Keyboard shortcuts

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