Skip to content

test: replace tokio-test with local polling helpers - #455

Merged
tisonkun merged 1 commit into
mainfrom
test/remove-tokio-test
Nov 22, 2026
Merged

tisonkun merged 1 commit into
mainfrom
test/remove-tokio-test

Conversation

@tisonkun

Copy link
Copy Markdown
Member

Summary

barrier_test, rwlock_test, and upgradable_rwlock_test were the last integration test suites pulling in tokio-test (and transitively tokio-stream) only for assert_pending!, assert_ready!, and wake-tracked single-future polling.

  • Add a small TestTask wrapper over WakeCounter in tests-integration, annotate expect_ready with #[track_caller] to preserve caller panic locations, and gate the non-Miri Duration import so --cfg miri builds stay warning-free.
  • Migrate barrier_test, rwlock_test, and upgradable_rwlock_test onto TestTask, poll_once, and expect_ready.
  • Remove tokio-test (and transitive tokio-stream) from the workspace dependencies and Cargo.lock.

`barrier_test`, `rwlock_test`, and `upgradable_rwlock_test` were the last integration test suites pulling in `tokio-test` (and transitively `tokio-stream`) only for `assert_pending!`, `assert_ready!`, and wake-tracked single-future polling.

Add a small `TestTask` wrapper over `WakeCounter` in `tests-integration` (and gate the non-Miri `Duration` import so Miri builds stay warning-free), migrate those three test files to `TestTask`, `poll_once`, and `expect_ready`, and remove `tokio-test` from the workspace dependencies.

Signed-off-by: tison <wander4096@gmail.com>
@tisonkun
tisonkun enabled auto-merge (squash) November 22, 2026 16:03
@tisonkun
tisonkun merged commit f199ce9 into main Nov 22, 2026
9 checks passed
@tisonkun
tisonkun deleted the test/remove-tokio-test branch November 22, 2026 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant