futures: tests/io_read_exact.rs: Don't fail w/o executor
Reflow test to move imports into test function, and then gate
entire test function on "executor" feature.
cargo test --test io_read_exact
Now compiles and passes in every valid combination of features
( see previous commits by me in tests/ for the command )
i
+#[cfg(feature = "executor")]
+#[test]
+fn read_exact() {
use futures::executor::block_on;
use futures::io::AsyncReadExt;
-#[test]
-fn read_exact() {
let mut reader: &[u8] = &[1, 2, 3, 4, 5];
let mut out = [0u8; 3];
