How to override Awaitility error messages
Awaitility is an excellent Java library. It's especially useful for working with eventually consistent APIs. For instance, when a client sends a POST, PUT, or DELETE request, you might need to make several GET requests before observing the changes, which is terrible for automated tests. A common solution to this problem is to use Awatility. You can ask it to execute code for n seconds until the request succeeds or the timer expires.
await()
.atMost(Duration.ofSeconds(5))
.until(() -> apiClient().get(id).getStatus().equals("expected"));
Unfortunately, the default error messages could use some work.