-- | Single batch.
testBatch :: IO ()
testBatch = withConnection $ \c -> do
    let a = "5"
        b = "3"
    sendBatchAndSync c [makeQuery1 a, makeQuery1 b]

    r1 <- readNextData c
    r2 <- readNextData c
    waitReadyForQuery c
    a @=? fromMessage r1
    b @=? fromMessage r2

-- | Two batches in single transaction.
testBatch :: IO ()
testBatch = withConnection $ \c -> do
    let a = "5"
        b = "3"
    sendBatchAndSync c [makeQuery1 a, makeQuery1 b]

    r1 <- readNextData c
    r2 <- readNextData c
    waitReadyForQuery c
    a @=? fromMessage r1
    b @=? fromMessage r2

-- | Two batches in single transaction.
testBatch = withConnection $ \c -> do
    let a = "5"
        b = "3"
    sendBatchAndSync c [makeQuery1 a, makeQuery1 b]

    r1 <- readNextData c
    r2 <- readNextData c
    waitReadyForQuery c
    a @=? fromMessage r1
    b @=? fromMessage r2

-- | Two batches in single transaction.