From 785f9390461b40c855d77105d83b1e2e2badf7d9 Mon Sep 17 00:00:00 2001 From: Theodore Ts'o Date: Sun, 29 Nov 2009 01:28:14 -0500 Subject: [PATCH] tests: Add new test f_holedir2 This tests e2fsck's handling of both direct and extent-mapped directoris containing holes when the i_size is 0. Signed-off-by: "Theodore Ts'o" --- tests/f_holedir2/expect.1 | 24 ++++++++++++++++++++++++ tests/f_holedir2/expect.2 | 7 +++++++ tests/f_holedir2/image.gz | Bin 0 -> 612 bytes tests/f_holedir2/name | 2 ++ 4 files changed, 33 insertions(+) create mode 100644 tests/f_holedir2/expect.1 create mode 100644 tests/f_holedir2/expect.2 create mode 100644 tests/f_holedir2/image.gz create mode 100644 tests/f_holedir2/name diff --git a/tests/f_holedir2/expect.1 b/tests/f_holedir2/expect.1 new file mode 100644 index 0000000..5124f61 --- /dev/null +++ b/tests/f_holedir2/expect.1 @@ -0,0 +1,24 @@ +Pass 1: Checking inodes, blocks, and sizes +Inode 12, i_size is 0, should be 5120. Fix? yes + +Inode 13, i_size is 4096, should be 5120. Fix? yes + +Pass 2: Checking directory structure +Directory inode 12 has an unallocated block #3. Allocate? yes + +Directory inode 13 has an unallocated block #1. Allocate? yes + +Pass 3: Checking directory connectivity +Pass 3A: Optimizing directories +Pass 4: Checking reference counts +Pass 5: Checking group summary information +Free blocks count wrong for group #0 (79, counted=77). +Fix? yes + +Free blocks count wrong (79, counted=77). +Fix? yes + + +test_filesys: ***** FILE SYSTEM WAS MODIFIED ***** +test_filesys: 13/16 files (7.7% non-contiguous), 23/100 blocks +Exit status is 1 diff --git a/tests/f_holedir2/expect.2 b/tests/f_holedir2/expect.2 new file mode 100644 index 0000000..636c6e9 --- /dev/null +++ b/tests/f_holedir2/expect.2 @@ -0,0 +1,7 @@ +Pass 1: Checking inodes, blocks, and sizes +Pass 2: Checking directory structure +Pass 3: Checking directory connectivity +Pass 4: Checking reference counts +Pass 5: Checking group summary information +test_filesys: 13/16 files (0.0% non-contiguous), 23/100 blocks +Exit status is 0 diff --git a/tests/f_holedir2/image.gz b/tests/f_holedir2/image.gz new file mode 100644 index 0000000000000000000000000000000000000000..63dda0780dfedbd848446dd383a4fa553e0407a6 GIT binary patch literal 612 zcmb2|=HT!Z67ptZ&dg0rPi1&}XJfW-pbYzm-P5NWGYMTB`g)0Mj803COpMkQSH%a9 zo;|vtz;VfG^=#*(j<^3i&iTVFGe>9FPA%C#+;epJ$|eMLzAxG-wN*sxirc532h7WD z<0|$}|6YA3)^jq8M9A^vC_`t%>q%aQnfcA1D>s#ihrd3%-7wQ=;+;Q}%5K%huQZ=5 zEj@SH(cf-K(~|X$$GnyM|EDmi`cv@do2RdLfA-g_nQh%uymxBb@z-BpZ;xMdzOF)a z+p_BO#g8*>`k5!pO8T;K&ArpsU*o%er#3S&FS?t@FaG;>Zo+~&#w-Ras@~Uk|2h4- zzxU?WnQx{kzy5wHYu=k5x6T9zRlQr-9=ocLVVeBW=_`wVp8q-j-I@LSP17oV-Fe5LA4=Zwj}qyB$-`*Ld4W{->YOPAkW zxyJX*%y;J>|9fMVZ(zO-k%1~^pbp?WnBk-A>8zaRd?rn^#qIEp0}4MF_n4~wWthOo006o( BDu@68 literal 0 HcmV?d00001 diff --git a/tests/f_holedir2/name b/tests/f_holedir2/name new file mode 100644 index 0000000..ec153f3 --- /dev/null +++ b/tests/f_holedir2/name @@ -0,0 +1,2 @@ +directories with holes and zero i_size + -- 1.8.3.1