package
1.3.1
Repository: https://github.com/maxbreida/mongo-go-driver.git
Documentation: pkg.go.dev

# Functions

CreateCommandErrorResponse creates a response with a command error.
CreateCursorResponse creates a response for a cursor command.
CreateSuccessResponse creates a response for a successful operation with the given elements.
CreateWriteConcernErrorResponse creates a response with a write concern error.
CreateWriteErrorsResponse creates a response with one or more write errors.
New creates a new T instance with the given options.
NewOptions creates an empty Options instance.
Setup initializes the current testing context.
Teardown cleans up resources initialized by Setup.

# Constants

Default specifies a client to the connection string in the MONGODB_URI env variable with command monitoring enabled.
These constants specify valid values for BatchIdentifier.
Mock specifies a client that communicates with a mock deployment.
These constants specify valid values for BatchIdentifier.
Pinned specifies a client that is pinned to a single mongos in a sharded cluster.
These constants specify valid values for TopologyKind.
These constants specify valid values for TopologyKind.
These constants specify valid values for TopologyKind.
TestDb specifies the name of default test database.

# Variables

Background is a no-op context.
LocalRc is the local read concern.
MajorityRc is the majority read concern.
MajorityWc is the majority write concern.
PrimaryRp is the primary read preference.

# Structs

Collection is used to configure a new collection created during a test.
CommandError is a representation of a command error from the server.
FailPoint is a representation of a server fail point.
FailPointData is a representation of the FailPoint.Data field.
FailPointMode is a representation of the Failpoint.Mode field.
Options is the type used to configure a new T instance.
RunOnBlock describes a constraint for a test.
T is a wrapper around testing.T.
WriteConcernError is a representation of a write concern error from the server.
WriteConcernErrorData is a representation of the FailPoint.Data.WriteConcern field.
WriteError is a representation of a write error from the server.

# Type aliases

BatchIdentifier specifies the keyword to identify the batch in a cursor response.
ClientType specifies the type of Client that should be created for a test.
TopologyKind describes the topology that a test is run on.