()
| 361 | |
| 362 | #[test] |
| 363 | fn header_invalid_magic() { |
| 364 | let mut bytes = SegmentHeader::current().to_bytes(); |
| 365 | bytes[0] = b'X'; |
| 366 | assert!(matches!( |
| 367 | SegmentHeader::from_bytes(&bytes), |
| 368 | Err(crate::error::ColumnarError::InvalidMagic(_)) |
| 369 | )); |
| 370 | } |
| 371 | |
| 372 | #[test] |
| 373 | fn header_incompatible_major() { |