Releases: onsi/gomega
Releases · onsi/gomega
v1.24.2
v1.24.1
v1.24.0
v1.23.0
1.23.0
Features
-
Custom formatting on a per-type basis can be provided using
format.RegisterCustomFormatter()
-- see the docs here -
Substantial improvement have been made to
StopTrying()
:- Users can now use
StopTrying().Wrap(err)
to wrap errors andStopTrying().Attach(description, object)
to attach arbitrary objects to theStopTrying()
error StopTrying()
is now always interpreted as a failure. If you are an early adopter ofStopTrying()
you may need to change your code as the prior version would match against the returned value even ifStopTrying()
was returned. Going forward theStopTrying()
api should remain stable.StopTrying()
andStopTrying().Now()
can both be used in matchers - not just polled functions.
- Users can now use
-
TryAgainAfter(duration)
is used likeStopTrying()
but instructsEventually
andConsistently
that the poll should be tried again after the specified duration. This allows you to dynamically adjust the polling duration. -
ctx
can now be passed-in as the first argument toEventually
andConsistently
.
Maintenance
v1.22.1
v1.22.0
1.22.0
Features
Several improvements have been made to Eventually
and Consistently
in this and the most recent releases:
- Eventually and Consistently can take a context.Context [65c01bc]
This enables integration with Ginkgo 2.3.0's interruptible nodes and node timeouts. - Eventually and Consistently that are passed a SpecContext can provide reports when an interrupt occurs [0d063c9]
- Eventually/Consistently will forward an attached context to functions that ask for one [e2091c5]
- Eventually/Consistently supports passing arguments to functions via WithArguments() [a2dc7c3]
- Eventually and Consistently can now be stopped early with StopTrying(message) and StopTrying(message).Now() [52976bb]
These improvements are all documented in Gomega's docs
v1.21.1
v1.21.0
1.21.0
Features
- Eventually and Consistently can take a context.Context [65c01bc]
This enables integration with Ginkgo 2.3.0's interruptible nodes and node timeouts. - Introduces Eventually.Within.ProbeEvery with tests and documentation (#591) [f633800]
- New BeKeyOf matcher with documentation and unit tests (#590) [fb586b3]
Fixes
- Cover the entire gmeasure suite with leak detection [8c54344]
- Fix gmeasure leak [119d4ce]
- Ignore new Ginkgo ProgressSignal goroutine in gleak [ba548e2]