ringbahn 0.0.0-experimental.1

an experimental safe API for io-uring
Documentation
use std::fs::File;

use futures::AsyncReadExt;

use ringbahn::Ring;

const ASSERT: &[u8] = b"But this formidable power of death -";

#[test]
fn read_file() {
    let file = File::open("props.txt").unwrap();
    let mut file: Ring<File> = Ring::new(file);
    futures::executor::block_on(async move {
        let mut buf = vec![0; 4096];
        assert!(file.read(&mut buf).await.is_ok());
        assert_eq!(&buf[0..ASSERT.len()], ASSERT);
    });
}