pub type Result = std::result::Result<(), Box>; pub fn assert_err_display( res: std::result::Result, expected: impl AsRef, ) { match res { Ok(v) => panic!("Expected error '{}', got value {:?}", expected.as_ref(), v), Err(err) => assert_eq!(err.to_string(), expected.as_ref()), } } #[cfg(all(feature = "async-io", not(feature = "blocking-io")))] mod decode; #[cfg(all(feature = "async-io", not(feature = "blocking-io")))] mod encode; #[cfg(all(feature = "async-io", not(feature = "blocking-io")))] mod read; #[cfg(all(feature = "async-io", not(feature = "blocking-io")))] mod write;