]>
git.ipfire.org Git - thirdparty/e2fsprogs.git/blob - tests/Makefile.in
2 # Makefile for the tests directory
6 top_srcdir
= @top_srcdir@
16 test_script
: test_script.in Makefile
17 @echo
"Creating test_script..."
18 @echo
"#!/bin/sh" > test_script
19 @HTREE_CMT@ @echo
"HTREE=y" >> test_script
20 @echo
'EGREP="@EGREP@"' >> test_script
21 @echo
"SRCDIR=@srcdir@" >> test_script
22 @cat
$(srcdir)/test_script.in
>> test_script
26 @echo
"Running e2fsprogs test suite..."
31 # Target which creates a new testcase to simplify adding new regression tests.
33 @echo
"Creating a new e2fsck testcase in ${TDIR}"
35 dd if
=/dev
/zero of
=${TDIR}/image bs
=1k count
=8k
36 mke2fs
-j
-F
-N
256 ${TDIR}/image
37 @echo
"new test description" > ${TDIR}/name
38 @echo
; echo
; echo
"New test filesystem at ${TDIR}/image."
39 @echo
"Now, break the filesystem as appropriate, and run 'make testend'"
41 EXPECT1
=${TDIR}/expect
.1
42 EXPECT2
=${TDIR}/expect
.2
43 # Target which generates the expect files for the new testcase.
44 testend
: test_script
${TDIR}/image
46 @OUT1
=${EXPECT1} OUT2
=${EXPECT2} .
/test_script
${TDIR}
47 @echo
; echo
; echo
"*** output from first e2fsck run (${EXPECT1}) ***"
49 @echo
"*** output from second e2fsck run (${EXPECT2}) ***"
51 @echo
"*** end of e2fsck output ***"
52 @echo
; echo
"Hopefully e2fsck now fixes this problem properly."
53 @echo
"If all is well, edit ${TDIR}/name and rename ${TDIR}."
56 $(RM
) -f
*~
*.log
*.new
*.failed
*.ok
test.img test_script