# Packages
Package testfail provides testing helpers for expected tests failures.
Package teststress provides a helper for stress testing.
Package testtb provides a common testing interface.
# Functions
AssertEqual asserts that two BSON values are equal.
AssertEqualSlices asserts that two BSON slices are equal.
AssertNotEqual asserts that two BSON values are not equal.
AssertNotEqualSlices asserts that two BSON slices are not equal.
CollectionName returns a stable FerretDB collection name for that test.
CompareAndSetByPathNum asserts that two values with the same path in two objects (documents or arrays) are within a given numerical delta, then updates the expected object with the actual value.
CompareAndSetByPathTime asserts that two values with the same path in two objects (documents or arrays) are within a given time delta, then updates the expected object with the actual value.
Ctx returns test context.
DatabaseName returns a stable FerretDB database name for that test.
DirectoryName returns a stable directory name for that test.
Dump returns string representation for debugging.
DumpSlice returns string representation for debugging.
GetByPath returns a value by path - a sequence of indexes and keys.
IndentJSON returns an indented form of the JSON input.
LevelLogger returns zap test logger with given level and valid configuration.
Logger returns zap test logger with valid configuration.
MustParseDumpFile panics if fails to parse file input to byte array.
ParseDump parses string to bytes, in tests.
ParseDumpFile parses file input to bytes, in tests.
SetByPath sets the value by path - a sequence of indexes and keys.
TestHanaURI returns a HANA Database URL for testing.
TestMySQLURI returns MySQL URI with test-specific database.
TestPostgreSQLURI returns PostgreSQL URI with test-specific database.
TestSQLiteURI returns SQLite URI with test-specific directory.