From d946de1c8170c33e3a1cbb4d49c60dee72f51eaa Mon Sep 17 00:00:00 2001 From: Ivan Baravy Date: Mon, 28 Oct 2019 06:10:38 +0300 Subject: [PATCH] Add test for file holes, allow comments in logs. --- img/makefile | 16 +- kofu.c | 5 +- ... => 000_f70s1_ls_all_dir_types_ftype0.ref} | 0 ....t => 000_f70s1_ls_all_dir_types_ftype0.t} | 0 ... => 001_f70s1_ls_all_dir_types_ftype1.ref} | 0 ....t => 001_f70s1_ls_all_dir_types_ftype1.t} | 0 ...f70s1_ls_all_dir_types_ftype0_b4k_n2b.ref} | 0 ...2_f70s1_ls_all_dir_types_ftype0_b4k_n2b.t} | 0 ...s.ref => 003_f70s0_read_without_holes.ref} | 3 + ...holes.t => 003_f70s0_read_without_holes.t} | 0 ...{004_sf705_stat.ref => 004_f70s5_stat.ref} | 0 test/{004_sf705_stat.t => 004_f70s5_stat.t} | 0 test/006_f70s0_read_with_holes.ref | 274 ++++++++++++++++++ test/006_f70s0_read_with_holes.t | 101 +++++++ test/makefile | 14 +- 15 files changed, 395 insertions(+), 18 deletions(-) rename test/{000_sf701_ls_all_dir_types_ftype0.ref => 000_f70s1_ls_all_dir_types_ftype0.ref} (100%) rename test/{000_sf701_ls_all_dir_types_ftype0.t => 000_f70s1_ls_all_dir_types_ftype0.t} (100%) rename test/{001_sf701_ls_all_dir_types_ftype1.ref => 001_f70s1_ls_all_dir_types_ftype1.ref} (100%) rename test/{001_sf701_ls_all_dir_types_ftype1.t => 001_f70s1_ls_all_dir_types_ftype1.t} (100%) rename test/{002_sf701_ls_all_dir_types_ftype0_b4k_n2b.ref => 002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.ref} (100%) rename test/{002_sf701_ls_all_dir_types_ftype0_b4k_n2b.t => 002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.t} (100%) rename test/{003_sf700_read_without_holes.ref => 003_f70s0_read_without_holes.ref} (98%) rename test/{003_sf700_read_without_holes.t => 003_f70s0_read_without_holes.t} (100%) rename test/{004_sf705_stat.ref => 004_f70s5_stat.ref} (100%) rename test/{004_sf705_stat.t => 004_f70s5_stat.t} (100%) create mode 100644 test/006_f70s0_read_with_holes.ref create mode 100644 test/006_f70s0_read_with_holes.t diff --git a/img/makefile b/img/makefile index 4f25d2e..df82abc 100644 --- a/img/makefile +++ b/img/makefile @@ -137,19 +137,15 @@ s512_xfs_v4_files.img: $(MKFILEPATTERN) $(TEMP_DIR)/no_hole 65536 # $(MKFILEPATTERN) $(TEMP_DIR)/hole_begin 65536 - fallocate -p -o 0 -l 16384 $(TEMP_DIR)/hole_begin + fallocate -p -o 0 -l 16KiB $(TEMP_DIR)/hole_begin # $(MKFILEPATTERN) $(TEMP_DIR)/hole_middle 65536 - fallocate -p -o 32768 -l 16384 $(TEMP_DIR)/hole_middle + fallocate -p -o 32KiB -l 16KiB $(TEMP_DIR)/hole_middle # $(MKFILEPATTERN) $(TEMP_DIR)/hole_end 65536 - fallocate -p -o 49152 -l 16384 $(TEMP_DIR)/hole_end + fallocate -p -o 48KiB -l 16KiB $(TEMP_DIR)/hole_end # -# fallocate -l 120GiB $(TEMP_DIR)/btree_l1_no_hole fallocate -l 4KiB $(TEMP_DIR)/btree_l1_no_hole -# $(MKFILEPATTERN) $(TEMP_DIR)/btree_l1_no_hole 2097152 -# fallocate -c -l 64KiB -o $$((64*$$n))KiB $(TEMP_DIR)/btree_l1_no_hole ; \ -# dd if=/dev/zero of=$(TEMP_DIR)/btree_l1_no_hole bs=1M count=128 for n in $$(seq 1 2000); do \ fallocate -i -l 4KiB -o 0KiB $(TEMP_DIR)/btree_l1_no_hole ; \ fallocate -z -l 4KiB -o 0KiB $(TEMP_DIR)/btree_l1_no_hole ; \ @@ -171,13 +167,13 @@ s512_xfs_v4_files_b4k_n2b.img: $(MKFILEPATTERN) $(TEMP_DIR)/no_hole 65536 # $(MKFILEPATTERN) $(TEMP_DIR)/hole_begin 65536 - fallocate -p -o 0 -l 16384 $(TEMP_DIR)/hole_begin + fallocate -p -o 0 -l 16KiB $(TEMP_DIR)/hole_begin # $(MKFILEPATTERN) $(TEMP_DIR)/hole_middle 65536 - fallocate -p -o 32768 -l 16384 $(TEMP_DIR)/hole_middle + fallocate -p -o 32KiB -l 16KiB $(TEMP_DIR)/hole_middle # $(MKFILEPATTERN) $(TEMP_DIR)/hole_end 65536 - fallocate -p -o 49152 -l 16384 $(TEMP_DIR)/hole_end + fallocate -p -o 48KiB -l 16KiB $(TEMP_DIR)/hole_end # # fallocate -l 120GiB $(TEMP_DIR)/btree_l1_no_hole fallocate -l 4KiB $(TEMP_DIR)/btree_l1_no_hole diff --git a/kofu.c b/kofu.c index 5fc7f8c..25a830c 100644 --- a/kofu.c +++ b/kofu.c @@ -350,7 +350,10 @@ int main(int argc, char **argv) { //msg_file_not_found db 'file not found: ' const char **cargv = (const char**)malloc(sizeof(const char*) * (MAX_COMMAND_ARGS + 1)); while(next_line()) { - if (cmd_buf[0] == '#' || cmd_buf[0] == '\n') continue; + if (cmd_buf[0] == '#' || cmd_buf[0] == '\n') { + printf("%s", cmd_buf); + continue; + } if (cmd_buf[0] == 'X') break; if (!is_tty) { prompt(); diff --git a/test/000_sf701_ls_all_dir_types_ftype0.ref b/test/000_f70s1_ls_all_dir_types_ftype0.ref similarity index 100% rename from test/000_sf701_ls_all_dir_types_ftype0.ref rename to test/000_f70s1_ls_all_dir_types_ftype0.ref diff --git a/test/000_sf701_ls_all_dir_types_ftype0.t b/test/000_f70s1_ls_all_dir_types_ftype0.t similarity index 100% rename from test/000_sf701_ls_all_dir_types_ftype0.t rename to test/000_f70s1_ls_all_dir_types_ftype0.t diff --git a/test/001_sf701_ls_all_dir_types_ftype1.ref b/test/001_f70s1_ls_all_dir_types_ftype1.ref similarity index 100% rename from test/001_sf701_ls_all_dir_types_ftype1.ref rename to test/001_f70s1_ls_all_dir_types_ftype1.ref diff --git a/test/001_sf701_ls_all_dir_types_ftype1.t b/test/001_f70s1_ls_all_dir_types_ftype1.t similarity index 100% rename from test/001_sf701_ls_all_dir_types_ftype1.t rename to test/001_f70s1_ls_all_dir_types_ftype1.t diff --git a/test/002_sf701_ls_all_dir_types_ftype0_b4k_n2b.ref b/test/002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.ref similarity index 100% rename from test/002_sf701_ls_all_dir_types_ftype0_b4k_n2b.ref rename to test/002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.ref diff --git a/test/002_sf701_ls_all_dir_types_ftype0_b4k_n2b.t b/test/002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.t similarity index 100% rename from test/002_sf701_ls_all_dir_types_ftype0_b4k_n2b.t rename to test/002_f70s1_ls_all_dir_types_ftype0_b4k_n2b.t diff --git a/test/003_sf700_read_without_holes.ref b/test/003_f70s0_read_without_holes.ref similarity index 98% rename from test/003_sf700_read_without_holes.ref rename to test/003_f70s0_read_without_holes.ref index 58ee8cd..b0ff816 100644 --- a/test/003_sf700_read_without_holes.ref +++ b/test/003_f70s0_read_without_holes.ref @@ -1,5 +1,6 @@ /> disk_add ../img/s512_xfs_v4_files_b4k_n2b.img hd0 /hd0/1: xfs +# zero length /> read /hd0/1/no_hole 0 0 -b status = 0 success, count = 0 @@ -72,6 +73,7 @@ status = 0 success, count = 0 /> read /hd0/1/no_hole 0xffffffffffffffff 0 -b status = 0 success, count = 0 +# one-byte length /> read /hd0/1/no_hole 0 1 -b status = 0 success, count = 1 00 @@ -144,6 +146,7 @@ status = 6 end_of_file, count = 0 /> read /hd0/1/no_hole 0xffffffffffffffff 1 -b status = 6 end_of_file, count = 0 +# fixed-size block, different begin/end positions /> read /hd0/1/no_hole 0 11 -b status = 0 success, count = 11 000102030405060708090a diff --git a/test/003_sf700_read_without_holes.t b/test/003_f70s0_read_without_holes.t similarity index 100% rename from test/003_sf700_read_without_holes.t rename to test/003_f70s0_read_without_holes.t diff --git a/test/004_sf705_stat.ref b/test/004_f70s5_stat.ref similarity index 100% rename from test/004_sf705_stat.ref rename to test/004_f70s5_stat.ref diff --git a/test/004_sf705_stat.t b/test/004_f70s5_stat.t similarity index 100% rename from test/004_sf705_stat.t rename to test/004_f70s5_stat.t diff --git a/test/006_f70s0_read_with_holes.ref b/test/006_f70s0_read_with_holes.ref new file mode 100644 index 0000000..6f57b70 --- /dev/null +++ b/test/006_f70s0_read_with_holes.ref @@ -0,0 +1,274 @@ +/> disk_add ../img/s512_xfs_v4_files_b4k_n2b.img hd0 +/hd0/1: xfs +# hole begin +# zero length +/> read /hd0/1/hole_begin 0 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_begin 1 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_begin 0x3ffe 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_begin 0x3fff 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_begin 0x4000 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_begin 0x4001 0 -b +status = 0 success, count = 0 + +# one-byte length +/> read /hd0/1/hole_begin 0 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_begin 1 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_begin 0x3ffe 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_begin 0x3fff 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_begin 0x4000 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_begin 0x4001 1 -b +status = 0 success, count = 1 +40 +# fixed-size block, different begin/end positions +/> read /hd0/1/hole_begin 0 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_begin 1 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_begin 0x3ff4 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_begin 0x3ff5 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_begin 0x3ff6 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_begin 0x3ff7 11 -b +status = 0 success, count = 11 +0000000000000000000040 +/> read /hd0/1/hole_begin 0x3ffe 11 -b +status = 0 success, count = 11 +0000004002400440064008 +/> read /hd0/1/hole_begin 0x3fff 11 -b +status = 0 success, count = 11 +0000400240044006400840 +/> read /hd0/1/hole_begin 0x4000 11 -b +status = 0 success, count = 11 +004002400440064008400a +/> read /hd0/1/hole_begin 0x4001 11 -b +status = 0 success, count = 11 +4002400440064008400a40 + +# hole middle +# zero length +/> read /hd0/1/hole_middle 0x7ffe 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0x7fff 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0x8000 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0x8001 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0xbffe 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0xbfff 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0xc000 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_middle 0xc001 0 -b +status = 0 success, count = 0 + +# one-byte length +/> read /hd0/1/hole_middle 0x7ffe 1 -b +status = 0 success, count = 1 +fe +/> read /hd0/1/hole_middle 0x7fff 1 -b +status = 0 success, count = 1 +7f +/> read /hd0/1/hole_middle 0x8000 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_middle 0x8001 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_middle 0xbffe 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_middle 0xbfff 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_middle 0xc000 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_middle 0xc001 1 -b +status = 0 success, count = 1 +c0 +# fixed-size block, different begin/end positions +/> read /hd0/1/hole_middle 0x7ff4 11 -b +status = 0 success, count = 11 +f47ff67ff87ffa7ffc7ffe +/> read /hd0/1/hole_middle 0x7ff5 11 -b +status = 0 success, count = 11 +7ff67ff87ffa7ffc7ffe7f +/> read /hd0/1/hole_middle 0x7ff6 11 -b +status = 0 success, count = 11 +f67ff87ffa7ffc7ffe7f00 +/> read /hd0/1/hole_middle 0x7ff7 11 -b +status = 0 success, count = 11 +7ff87ffa7ffc7ffe7f0000 +/> read /hd0/1/hole_middle 0x7ffe 11 -b +status = 0 success, count = 11 +fe7f000000000000000000 +/> read /hd0/1/hole_middle 0x7fff 11 -b +status = 0 success, count = 11 +7f00000000000000000000 +/> read /hd0/1/hole_middle 0x8000 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_middle 0x8001 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_middle 0xbff4 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_middle 0xbff5 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_middle 0xbff6 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_middle 0xbff7 11 -b +status = 0 success, count = 11 +00000000000000000000c0 +/> read /hd0/1/hole_middle 0xbffe 11 -b +status = 0 success, count = 11 +000000c002c004c006c008 +/> read /hd0/1/hole_middle 0xbfff 11 -b +status = 0 success, count = 11 +0000c002c004c006c008c0 +/> read /hd0/1/hole_middle 0xc000 11 -b +status = 0 success, count = 11 +00c002c004c006c008c00a +/> read /hd0/1/hole_middle 0xc001 11 -b +status = 0 success, count = 11 +c002c004c006c008c00ac0 + +# hole end +# zero length +/> read /hd0/1/hole_end 0xbffe 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0xbfff 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0xc000 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0xc001 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0xfffe 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0xffff 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0x10000 0 -b +status = 0 success, count = 0 + +/> read /hd0/1/hole_end 0x10001 0 -b +status = 0 success, count = 0 + +# one-byte length +/> read /hd0/1/hole_end 0xbffe 1 -b +status = 0 success, count = 1 +fe +/> read /hd0/1/hole_end 0xbfff 1 -b +status = 0 success, count = 1 +bf +/> read /hd0/1/hole_end 0xc000 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_end 0xc001 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_end 0xfffe 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_end 0xffff 1 -b +status = 0 success, count = 1 +00 +/> read /hd0/1/hole_end 0x10000 1 -b +status = 6 end_of_file, count = 0 + +/> read /hd0/1/hole_end 0x10001 1 -b +status = 6 end_of_file, count = 0 + +# fixed-size block, different begin/end positions +/> read /hd0/1/hole_end 0xbff4 11 -b +status = 0 success, count = 11 +f4bff6bff8bffabffcbffe +/> read /hd0/1/hole_end 0xbff5 11 -b +status = 0 success, count = 11 +bff6bff8bffabffcbffebf +/> read /hd0/1/hole_end 0xbff6 11 -b +status = 0 success, count = 11 +f6bff8bffabffcbffebf00 +/> read /hd0/1/hole_end 0xbff7 11 -b +status = 0 success, count = 11 +bff8bffabffcbffebf0000 +/> read /hd0/1/hole_end 0xbffe 11 -b +status = 0 success, count = 11 +febf000000000000000000 +/> read /hd0/1/hole_end 0xbfff 11 -b +status = 0 success, count = 11 +bf00000000000000000000 +/> read /hd0/1/hole_end 0xc000 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_end 0xc001 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_end 0xfff4 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_end 0xfff5 11 -b +status = 0 success, count = 11 +0000000000000000000000 +/> read /hd0/1/hole_end 0xfff6 11 -b +status = 6 end_of_file, count = 10 +00000000000000000000 +/> read /hd0/1/hole_end 0xfff7 11 -b +status = 6 end_of_file, count = 9 +000000000000000000 +/> read /hd0/1/hole_end 0xfffe 11 -b +status = 6 end_of_file, count = 2 +0000 +/> read /hd0/1/hole_end 0xffff 11 -b +status = 6 end_of_file, count = 1 +00 +/> read /hd0/1/hole_end 0x10000 11 -b +status = 6 end_of_file, count = 0 + +/> read /hd0/1/hole_end 0x10001 11 -b +status = 6 end_of_file, count = 0 + diff --git a/test/006_f70s0_read_with_holes.t b/test/006_f70s0_read_with_holes.t new file mode 100644 index 0000000..88789e3 --- /dev/null +++ b/test/006_f70s0_read_with_holes.t @@ -0,0 +1,101 @@ +disk_add ../img/s512_xfs_v4_files_b4k_n2b.img hd0 +# hole begin +# zero length +read /hd0/1/hole_begin 0 0 -b +read /hd0/1/hole_begin 1 0 -b +read /hd0/1/hole_begin 0x3ffe 0 -b +read /hd0/1/hole_begin 0x3fff 0 -b +read /hd0/1/hole_begin 0x4000 0 -b +read /hd0/1/hole_begin 0x4001 0 -b +# one-byte length +read /hd0/1/hole_begin 0 1 -b +read /hd0/1/hole_begin 1 1 -b +read /hd0/1/hole_begin 0x3ffe 1 -b +read /hd0/1/hole_begin 0x3fff 1 -b +read /hd0/1/hole_begin 0x4000 1 -b +read /hd0/1/hole_begin 0x4001 1 -b +# fixed-size block, different begin/end positions +read /hd0/1/hole_begin 0 11 -b +read /hd0/1/hole_begin 1 11 -b +read /hd0/1/hole_begin 0x3ff4 11 -b +read /hd0/1/hole_begin 0x3ff5 11 -b +read /hd0/1/hole_begin 0x3ff6 11 -b +read /hd0/1/hole_begin 0x3ff7 11 -b +read /hd0/1/hole_begin 0x3ffe 11 -b +read /hd0/1/hole_begin 0x3fff 11 -b +read /hd0/1/hole_begin 0x4000 11 -b +read /hd0/1/hole_begin 0x4001 11 -b + +# hole middle +# zero length +read /hd0/1/hole_middle 0x7ffe 0 -b +read /hd0/1/hole_middle 0x7fff 0 -b +read /hd0/1/hole_middle 0x8000 0 -b +read /hd0/1/hole_middle 0x8001 0 -b +read /hd0/1/hole_middle 0xbffe 0 -b +read /hd0/1/hole_middle 0xbfff 0 -b +read /hd0/1/hole_middle 0xc000 0 -b +read /hd0/1/hole_middle 0xc001 0 -b +# one-byte length +read /hd0/1/hole_middle 0x7ffe 1 -b +read /hd0/1/hole_middle 0x7fff 1 -b +read /hd0/1/hole_middle 0x8000 1 -b +read /hd0/1/hole_middle 0x8001 1 -b +read /hd0/1/hole_middle 0xbffe 1 -b +read /hd0/1/hole_middle 0xbfff 1 -b +read /hd0/1/hole_middle 0xc000 1 -b +read /hd0/1/hole_middle 0xc001 1 -b +# fixed-size block, different begin/end positions +read /hd0/1/hole_middle 0x7ff4 11 -b +read /hd0/1/hole_middle 0x7ff5 11 -b +read /hd0/1/hole_middle 0x7ff6 11 -b +read /hd0/1/hole_middle 0x7ff7 11 -b +read /hd0/1/hole_middle 0x7ffe 11 -b +read /hd0/1/hole_middle 0x7fff 11 -b +read /hd0/1/hole_middle 0x8000 11 -b +read /hd0/1/hole_middle 0x8001 11 -b +read /hd0/1/hole_middle 0xbff4 11 -b +read /hd0/1/hole_middle 0xbff5 11 -b +read /hd0/1/hole_middle 0xbff6 11 -b +read /hd0/1/hole_middle 0xbff7 11 -b +read /hd0/1/hole_middle 0xbffe 11 -b +read /hd0/1/hole_middle 0xbfff 11 -b +read /hd0/1/hole_middle 0xc000 11 -b +read /hd0/1/hole_middle 0xc001 11 -b + +# hole end +# zero length +read /hd0/1/hole_end 0xbffe 0 -b +read /hd0/1/hole_end 0xbfff 0 -b +read /hd0/1/hole_end 0xc000 0 -b +read /hd0/1/hole_end 0xc001 0 -b +read /hd0/1/hole_end 0xfffe 0 -b +read /hd0/1/hole_end 0xffff 0 -b +read /hd0/1/hole_end 0x10000 0 -b +read /hd0/1/hole_end 0x10001 0 -b +# one-byte length +read /hd0/1/hole_end 0xbffe 1 -b +read /hd0/1/hole_end 0xbfff 1 -b +read /hd0/1/hole_end 0xc000 1 -b +read /hd0/1/hole_end 0xc001 1 -b +read /hd0/1/hole_end 0xfffe 1 -b +read /hd0/1/hole_end 0xffff 1 -b +read /hd0/1/hole_end 0x10000 1 -b +read /hd0/1/hole_end 0x10001 1 -b +# fixed-size block, different begin/end positions +read /hd0/1/hole_end 0xbff4 11 -b +read /hd0/1/hole_end 0xbff5 11 -b +read /hd0/1/hole_end 0xbff6 11 -b +read /hd0/1/hole_end 0xbff7 11 -b +read /hd0/1/hole_end 0xbffe 11 -b +read /hd0/1/hole_end 0xbfff 11 -b +read /hd0/1/hole_end 0xc000 11 -b +read /hd0/1/hole_end 0xc001 11 -b +read /hd0/1/hole_end 0xfff4 11 -b +read /hd0/1/hole_end 0xfff5 11 -b +read /hd0/1/hole_end 0xfff6 11 -b +read /hd0/1/hole_end 0xfff7 11 -b +read /hd0/1/hole_end 0xfffe 11 -b +read /hd0/1/hole_end 0xffff 11 -b +read /hd0/1/hole_end 0x10000 11 -b +read /hd0/1/hole_end 0x10001 11 -b diff --git a/test/makefile b/test/makefile index 2e3e84d..12674d6 100644 --- a/test/makefile +++ b/test/makefile @@ -2,19 +2,19 @@ KOFU=../kofu f30_tests := $(addsuffix .out, $(basename $(wildcard ???_f30_*.t))) -sf700_tests := $(addsuffix .out, $(basename $(wildcard ???_sf700_*.t))) -sf701_tests := $(addsuffix .out, $(basename $(wildcard ???_sf701_*.t))) -sf705_tests := $(addsuffix .out, $(basename $(wildcard ???_sf705_*.t))) +f70s0_tests := $(addsuffix .out, $(basename $(wildcard ???_f70s0_*.t))) +f70s1_tests := $(addsuffix .out, $(basename $(wildcard ???_f70s1_*.t))) +f70s5_tests := $(addsuffix .out, $(basename $(wildcard ???_f70s5_*.t))) all: f30 f70 @echo all tests passed f30: $(f30_tests) -f70: sf700 sf701 sf705 -sf700: $(sf700_tests) -sf701: $(sf701_tests) -sf705: $(sf705_tests) +f70: f70s0 f70s1 f70s5 +f70s0: $(f70s0_tests) +f70s1: $(f70s1_tests) +f70s5: $(f70s5_tests) %.out: %.ref %.t $(KOFU) < $(word 2, $^) > $@