futures: tests/io_buf_writer.rs : Avoid compile failures w/o features
futures: tests/io_buf_writer.rs : Avoid compile failures w/o features

Tests in this file use combinations of "std" and "executor" features.

Imports and symbols moved to deeper lexical scopes to make owernship
clearer, and to facilitate easy feature gating.

Tests gated as appropriate with `#[cfg()]`

Tests now compile and pass with:

  cargo hack --each-feature \
    --skip bilock \
    --skip cfg-target-has-atomic \
    --skip read-initializer \
    test --test io_buf_writer

  cargo hack --feature-powerset \
    --skip bilock \
    --skip cfg-target-has-atomic \
    --skip read-initializer \
    test --test io_buf_writer

  cargo hack --features "unstable" \
    --each-feature \
    --skip "unstable" \
    test --test "io_buf_writer"

  cargo hack --features "unstable" \
    --feature-powerset \
    --skip "unstable" \
    test --test "io_buf_writer"

alexcrichton/futures-rs