bitfield: fix bit ordering issue with YAML parsing

This commit is contained in:
Michael Sproul
2019-04-02 14:14:57 +11:00
parent 8da8730dca
commit 0a02567440
3 changed files with 56 additions and 5 deletions

View File

@@ -18,3 +18,16 @@ pub fn verify_bitfield_length(bitfield: &Bitfield, committee_size: usize) -> boo
true
}
#[cfg(test)]
mod test {
use super::*;
#[test]
fn bitfield_length() {
assert!(verify_bitfield_length(
&Bitfield::from_bytes(&[0b10000000]),
4
));
}
}