use std::{
convert::Infallible,
pin::Pin,
task::{Context, Poll},
vec,
};
use futures::{stream, Sink, SinkExt, Stream, StreamExt};
use iso_tp::Frame;
struct Mock {
tx: Vec,
rx: stream::Iter>>,
}
impl Mock {
pub fn new(tx: Vec, rx: Vec>) -> Self {
Self {
tx,
rx: stream::iter(rx),
}
}
}
impl Stream for Mock {
type Item = Result;
fn poll_next(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll