@@ -1529,6 +1529,22 @@ onExceptionProp t =
1529 refValue <- run $ readIORef ioRef
1529 refValue <- run $ readIORef ioRef
1530 assert $ refValue == 1
1530 assert $ refValue == 1
1534+ => (t IO Int -> SerialT IO Int)
1538+ withMaxSuccess maxTestCount $
1544+ (\(ExampleException i) -> read i `S.cons` S.fromList vec)
1545+ (S.serially $ S.fromList vec <> throwM (ExampleException "0"))
1546+ assert $ res == vec ++ [0] ++ vec
1532exceptionOps ::
1548exceptionOps ::
1533 (IsStream t, MonadThrow (t IO))
1549 (IsStream t, MonadThrow (t IO))
1534 => String
1550 => String
@@ -1544,6 +1560,7 @@ exceptionOps desc t = do
1544 prop (desc <> " finally end of stream") $ finallyProp t
1560 prop (desc <> " finally end of stream") $ finallyProp t
1545 -- prop (desc <> " finally partial stream") $ finallyPartialStreamProp t
1561 -- prop (desc <> " finally partial stream") $ finallyPartialStreamProp t
1546 prop (desc <> " finally exception in stream") $ finallyExceptionProp t
1562 prop (desc <> " finally exception in stream") $ finallyExceptionProp t
1563+ prop (desc <> " handle") $ handleProp t
1548-------------------------------------------------------------------------------
1565-------------------------------------------------------------------------------
1549-- Compose with MonadThrow
1566-- Compose with MonadThrow