//! Test the `Consume` trait.

#![cfg(test)]

use le_stream::{Consume, Result};

#[test]
fn test_consume() {
    let bytes = [0xAB, 0xCD];
    let int: Result<u16> = bytes.into_iter().consume();
    assert_eq!(int, Ok(0xCDAB));
}
