package
0.9.52
Repository: https://github.com/lainio/err2.git
Documentation: pkg.go.dev

# Functions

No description provided by the author
CLen asserts that the length of the chan is equal to the given.
CLonger asserts that the length of the chan is longer to the given.
CNotNil asserts that the channel is not nil.
CShorter asserts that the length of the chan is shorter to the given.
DeepEqual asserts that the (whatever) values are equal.
You are free to set it according to your current preferences with the SetDefault function.
Empty asserts that the string is empty.
Equal asserts that the values are equal.
Error asserts that the err is not nil.
INil asserts that the interface value IS nil.
INotNil asserts that the interface value is NOT nil.
Len asserts that the length of the string is equal to the given.
Longer asserts that the length of the string is longer to the given.
MKeyExists asserts that the map key exists.
MLen asserts that the length of the map is equal to the given.
MLonger asserts that the length of the map is longer to the given.
MNotEmpty asserts that the map is not empty.
MNotNil asserts that the map is not nil.
MShorter asserts that the length of the map is shorter to the given.
Nil asserts that the pointer IS nil.
NoError asserts that the error is nil.
NotDeepEqual asserts that the (whatever) values are equal.
NotEmpty asserts that the string is not empty.
NotEqual asserts that the values aren't equal.
NotImplemented always panics with 'not implemented' assertion message.
NotNil asserts that the pointer IS NOT nil.
NotZero asserts that the value != 0.
PopTester pops the testing context reference from the memory.
PushTester sets the current testing context for default asserter.
SetDefault set the current default asserter for the package.
Shorter asserts that the length of the string is shorter to the given.
SLen asserts that the length of the slice is equal to the given.
SLonger asserts that the length of the slice is equal to the given.
SNil asserts that the slice IS nil.
SNotEmpty asserts that the slice is not empty.
SNotNil asserts that the slice is not nil.
SShorter asserts that the length of the slice is equal to the given.
That asserts that the term is true.
ThatNot asserts that the term is NOT true.
Zero asserts that the value is 0.

# Constants

AsserterCallerInfo is an asserter flag to add info of the function asserting.
AsserterDebug is the default mode where all asserts are treaded as panics.
AsserterFormattedCallerInfo is an asserter flag to add info of the function asserting.
AsserterStackTrace is Asserter flag to print call stack to stdout OR if in AsserterUnitTesting mode the call stack is printed to test result output if there is any assertion failures.
AsserterToError is Asserter flag to guide asserter to use Go's error type for panics.
AsserterUnitTesting is an asserter only for unit testing.
Debug asserter transforms assertion violations to panic calls where panic object's type is string, i.e., err2 package treats it as a normal panic, not an error.
Development is the best asserter for most development uses.
Plain converts asserts just plain K&D error messages without extra information.
Production (pkg default) is the best asserter for most uses.
Test minimalistic asserter for unit test use.
TestFull asserter (test default).

# Variables

Deprecated: use e.g.
D is a development Asserter that sets panic objects to strings that doesn't by caught by err2 handlers.
P is a production Asserter that sets panic objects to errors which allows err2 handlers to catch them.
Deprecated: use e.g.
Deprecated: use e.g.
Deprecated: use e.g.

# Interfaces

No description provided by the author

# Type aliases

Asserter is type for asserter object guided by its flags.