Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/awaitility/awaitility

Awaitility is a small Java DSL for synchronizing asynchronous operations
https://github.com/awaitility/awaitility

asynchronous awaitility java testing

Last synced: about 1 month ago
JSON representation

Awaitility is a small Java DSL for synchronizing asynchronous operations

Awesome Lists containing this project

README

        

![Awaitility](resources/Awaitility_logo_red_small.png)

[![Build Status](https://github.com/awaitility/awaitility/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/awaitility/awaitility/actions/workflows/ci.yml)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.awaitility/awaitility/badge.svg)](https://search.maven.org/#search%7Cgav%7C1%7Cg%3A"org.awaitility"%20AND%20a%3A"awaitility")

Testing asynchronous systems is hard. Not only does it require handling threads, timeouts, and concurrency issues, but the intent of the test code can be obscured by all these details. Awaitility is a DSL that allows you to express expectations of an asynchronous system in a concise and easy-to-read manner. For example:

```java
@Test
public void updatesCustomerStatus() {
// Publish an asynchronous message to a broker (e.g. RabbitMQ):
messageBroker.publishMessage(updateCustomerStatusMessage);
// Awaitility lets you wait until the asynchronous operation completes:
await().atMost(5, SECONDS).until(customerStatusIsUpdated());
...
}
```

## News
* 2024-03-15: Awaitility `4.2.1` is released. It allows for easier use of logging and some bug fixes and improvements. See [changelog](https://raw.githubusercontent.com/awaitility/awaitility/master/changelog.txt) for details.
* 2022-03-04: Awaitility `4.2.0` is released. It allows the use of assertion libraries such as Hamcrest or Assertj in [fail-fast conditions](https://github.com/awaitility/awaitility/wiki/Usage#fail-fast-conditions) as well as various improvements and bug fixes. See [changelog](https://raw.githubusercontent.com/awaitility/awaitility/master/changelog.txt) for details.
* 2021-10-25: Awaitility `4.1.1` is released. This release includes some bug fixes and small improvements. See [changelog](https://raw.githubusercontent.com/awaitility/awaitility/master/changelog.txt) for details.

[Older news](https://github.com/awaitility/awaitility/wiki/OldNews)

## Documentation

* [Getting started](https://github.com/awaitility/awaitility/wiki/Getting_started)
* [Usage Guide](https://github.com/awaitility/awaitility/wiki/Usage)
* [Awaitility Javadoc](http://www.javadoc.io/doc/org.awaitility/awaitility/4.2.1)

## Links
* [Change log](https://github.com/awaitility/awaitility/raw/master/changelog.txt)
* Awaitility on [Open Hub](https://www.openhub.net/p/awaitility)
* [Mailing list](http://groups.google.com/group/awaitility) for questions and support

Buy Me A Coffee