Releases: fluentassert/verify
1.3.0
Deprecate the whole library.
Avoid using assertion libraries.
Use the standard library and github.com/google/go-cmp/cmp instead.
Follow the official Go Test Comments.
1.2.0
1.1.0
1.0.0
This release contains breaking changes.
The repository is moved to github.com/fluentassert/verify and the f package is renamed to verify.
The main additions are the new assertions for bool, constraints.Ordered, constraints.Float, constraints.Integer, string, error, []T, map[K]V, func() types.
Added
- Add
True,False, assertion functions. - Add
Nil,NotNil, assertion functions. - Add
NoError,IsErrorassertion functions. - Add
Panics,NoPanicassertion functions. - Add
Eventually,EventuallyChanassertion functions. - Add
Orderedfunction which provides following assertions, in addition toComparable, viaFluentOrderedtype:LesserLesserOrEqualGreaterOrEqualGreater
- Add
Stringfunction which provides following assertions, in addition toOrdered, viaFluentStringtype:EmptyNotEmptyContainNotContainPrefixNoPrefixSufixNoSufixEqualFoldNotEqualFoldMatchRegexNotMatchRegex
- Add
Numberfunction which provides following assertions, in addition toOrdered, viaFluentNumbertype:InDeltaNotInDeltaInEpsilonNotInEpsilon
- Add
Errorfunction which provides following assertions, in addition toAnyandString(for error message), viaFluentObjandFluentStringtypes:IsIsNotAsNotAs
- Add
Slicefunction which provides following assertions, in addition toAny, viaFluentSlicetype:EmptyNotEmptyEquivalentNotEquivalentContainNotContainAnyAllNone
- Add
Mapfunction which provides following assertions, in addition toAny, viaFlientMaptype:EmptyNotEmptyContainNotContainContainPairNotContainPairAnyAllNone
- Add
FailureMessage.Prefixmethod together withAndandOrfunctions to facilitate creating complex assertions.
Changed
- The
fpackage is renamed toverify. - Rename
ObjandFluentObjtoAnyandFluentAny. - Rename
ComparableandFluentComparabletoObjandFluentObj. - Change the
Checkassertion foranyobject so that the provided function has to returnFailureMessageinstead of astring. ZeroandNonZeromethods are moved toFluentComparable.- Better failure messages.
1.0.0-rc.3
Removed
- Remove
constraintspackage.
1.0.0-rc.2
Changed
- Rename
NumberFloattoFluentNumber.
1.0.0-rc.1
This release contains breaking changes.
The repository is moved to github.com/fluentassert/verify and the f package is renamed to verify.
The main additions are the new assertions for bool, constraints.Ordered, constraints.Float, constraints.Integer, string, error, []T, map[K]V, func() types.
Added
- Add
True,False, assertion functions. - Add
Nil,NotNil, assertion functions. - Add
NoError,IsErrorassertion functions. - Add
Panics,NoPanicassertion functions. - Add
Eventually,EventuallyChanassertion functions. - Add
Orderedfunction which provides following assertions, in addition toComparable, viaFluentOrderedtype:LesserLesserOrEqualGreaterOrEqualGreater
- Add
Stringfunction which provides following assertions, in addition toOrdered, viaFluentStringtype:EmptyNotEmptyContainNotContainPrefixNoPrefixSufixNoSufixEqualFoldNotEqualFoldMatchRegexNotMatchRegex
- Add
Numberfunction which provides following assertions, in addition toOrdered, viaFluentNumbertype:InDeltaNotInDeltaInEpsilonNotInEpsilon
- Add
Errorfunction which provides following assertions, in addition toAnyandString(for error message), viaFluentObjandFluentStringtypes:IsIsNotAsNotAs
- Add
Slicefunction which provides following assertions, in addition toAny, viaFluentSlicetype:EmptyNotEmptyEquivalentNotEquivalentContainNotContainAnyAllNone
- Add
Mapfunction which provides following assertions, in addition toAny, viaFlientMaptype:EmptyNotEmptyContainNotContainContainPairNotContainPairAnyAllNone
- Add
FailureMessage.Prefixmethod together withAndandOrfunctions to facilitate creating complex assertions.
Changed
- The
fpackage is renamed toverify. - Rename
ObjandFluentObjtoAnyandFluentAny. - Rename
ComparableandFluentComparabletoObjandFluentObj. - Change the
Checkassertion foranyobject so that the provided function has to returnFailureMessageinstead of astring. ZeroandNonZeromethods are moved toFluentComparable.- Better failure messages.
0.2.0
This release is a complete rewrite. It is not compatible with the previous release.
The new API is type-safe and easier to extend.
The next release is supposed to provide assertions for constraints.Ordered, string, error, []T, map[K]V, func().
Added
- Add
FailureMessagewhich encapsulates the failure message and methods for error reporting. - Add
Objfunction which provides following assertions viaFluentObjecttype:CheckShouldShouldNotDeepEqualNotDeepEqualZeroNonZero
- Add
Comparablefunction which provides following assertions,
in addition toObj, viaFluentComparabletype:EqualNotEqual
Changed
- Require Go 1.18.
Fixed
- Fix error reporting line (use
t.Helper()when available).
Removed
- Remove all previous functions and types (API rewrite).
0.1.0
First release after the experiential phase.
Added
- Add
f.Assertthat can be used instead oft.Errormethods. - Add
f.Requirethat can be used instead oft.Fatalmethods. - Add
Shouldassertion that can be used with custom predicates. - Add
Eqassertion that checks ifgotis deeply equal towant. - Add
Nilassertion that checks ifgotisnil. - Add
Errassertion that checks ifgotis anerror. - Add
Panicassertion that checks if callinggotresults in a panic. - Add
NoPanicassertion that checks if callinggotreturns without panicking.