Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include documentation for assertComplete and assertFailure methods #140

Open
ThorodanBrom opened this issue Dec 2, 2024 · 1 comment
Open

Comments

@ThorodanBrom
Copy link

Describe the feature

  • Since Vert.x 5.0 is deprecating the callback model, I was wondering if the callbacks used in methods like succeeding and failing would stop working in 5.0 (or maybe I have not understood the deprecation properly)
  • I found out about the existence of the methods assertComplete and assertFailed developed by @slinkydeveloper from their blog, which allow for testing with the help of Futures instead of the callbacks
  • However, there isn't any official documentation about these methods in the official docs

Use cases

  • Including documentation for this may help those who are looking to move away from Handler<AsyncResult> -style callbacks in JUnit tests
  • If succeeding, failing are getting deprecated, then assertComplete and assertFailing would be the only methods usable (I think I am wrong here)

Contribution

@tsegismont
Copy link
Contributor

No, these methods won't stop working, it's perfectly fine to use them, for example, at the the end of a future composition chain.

Note that in Vert.x 5 you can create Future expectations with Future.expecting

It would be great if you could contribute a doc update about test context methods related to futures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants