Usure
A tiny and simple testing library
Example
Output
Install
import "github.com/stelmanjones/termtools/usure"
Features
- Nil Check: Checks if the provided value is nil.
result := usure.Nil(value)
- Not Nil Check: Checks if the provided value is not nil.
result := usure.NotNil(value)
- Instance Check: Checks if the two provided values are of the same type.
result := usure.IsInstance(value1, value2)
- Equality Check: Checks if the two provided values are equal.
result := usure.Equal(value1, value2)
- Inequality Check: Checks if the two provided values are not equal.
result := usure.NotEqual(value1, value2)
- Expect Equality: Logs an error message if the two provided values are not equal.
usure.ExpectEqual("Values should be equal", value1, value2)