Documentation
¶
Overview ¶
Package assert provides simple assertion utilities for internal unit tests. It is designed for use within the internal codebase and is not intended to be imported or used by external packages.
Index ¶
- func AssertEqual[T comparable](t *testing.T, actual, expected T)
- func AssertIsClose(t *testing.T, actual, expected, tolerance float64)
- func AssertNil(t *testing.T, value any)
- func AssertNotEqual[T comparable](t *testing.T, actual, unexpected T)
- func AssertPanic(t *testing.T, f func())
- func AssertTrue(t *testing.T, condition bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertEqual ¶
func AssertEqual[T comparable](t *testing.T, actual, expected T)
AssertEqual checks if two values are equal
func AssertIsClose ¶
AssertIsClose checks if a value is close to another value within a tolerance
func AssertNotEqual ¶
func AssertNotEqual[T comparable](t *testing.T, actual, unexpected T)
AssertNotEqual checks if two values are not equal
func AssertPanic ¶
AssertTrue checks if a condition is true
func AssertTrue ¶
AssertTrue checks if a condition is true
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.