test_executors

Crates.iotest_executors
lib.rstest_executors
version0.2.0
sourcesrc
created_at2024-10-14 19:18:29.840055
updated_at2024-11-07 21:29:08.364645
descriptionSimple async executors for testing.
homepagehttps://sealedabstract.com/code/test_executors
repositoryhttps://github.com/drewcrawford/test_executors
max_upload_size
id1408577
size100,500
Drew Crawford (drewcrawford)

documentation

README

test_executors

logo

This crate provides extremely simple, yet useful, async executors. They are primarily useful for writing unit tests without bringing in a full-blown executor such as tokio.

The executors are:

  • spin_on: polls a future in a busyloop on the current thread.
  • sleep_on: polls a future on the current thread, sleeping between polls.
  • spawn_on: spawns a future on a new thread, polling it there.

some_executor

This crate implements the some_executor trait for all executors, allowing them to be used in executor-agnostic code.

Commit count: 31

cargo fmt