| Safe Haskell | None |
|---|---|
| Language | GHC2024 |
Arbiter.Test.Poll
Description
Polling helpers for tests.
Synopsis
- waitUntil :: HasCallStack => Int -> IO Bool -> IO ()
- withLinkedAsync :: MonadUnliftIO m => m a -> (Async a -> m b) -> m b
- bumpRef :: Num a => IORef a -> IO ()
Documentation
waitUntil :: HasCallStack => Int -> IO Bool -> IO ()Source #
Poll every pollIntervalMs until the predicate returns True.
Fails with expectationFailure after timeoutMs milliseconds.
withLinkedAsync :: MonadUnliftIO m => m a -> (Async a -> m b) -> m bSource #