MCPcopy Create free account
hub / github.com/cloud-hypervisor/cloud-hypervisor / test_header

Function test_header

block/src/qcow/mod.rs:3386–3395  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3384
3385 #[test]
3386 fn test_header() {
3387 with_basic_file(&valid_header_v2(), |disk_file: RawFile| {
3388 let q = QcowFile::from(disk_file).unwrap();
3389 assert_eq!(q.virtual_size(), 0x20_0000_0000);
3390 });
3391 with_basic_file(&valid_header_v3(), |disk_file: RawFile| {
3392 let q = QcowFile::from(disk_file).unwrap();
3393 assert_eq!(q.virtual_size(), 0x20_0000_0000);
3394 });
3395 }
3396
3397 #[test]
3398 fn read_small_buffer() {

Callers

nothing calls this directly

Calls 3

with_basic_fileFunction · 0.85
valid_header_v2Function · 0.85
valid_header_v3Function · 0.85

Tested by

no test coverage detected