Improve test for Memo::from support

This commit is contained in:
Deirdre Connolly 2020-02-10 17:25:14 -05:00 committed by Deirdre Connolly
parent b8f7487e54
commit ecaaa21d1c
1 changed files with 4 additions and 1 deletions

View File

@ -80,5 +80,8 @@ fn memo_fmt() {
fn memo_from_string() {
let memo = Memo::from("foo bar baz");
println!("{:?}", memo);
let mut bytes = [0; 512];
bytes[0..11].copy_from_slice(&[102, 111, 111, 32, 98, 97, 114, 32, 98, 97, 122]);
assert!(memo.0.iter().eq(bytes.iter()));
}