# Repeat with the trip point set to successively higher numbers of writes until
# we hit ~200 writes or repair manages to run to completion without tripping.
-seq=`basename $0`
-seqres=$RESULT_DIR/$seq
-echo "QA output created by $seq"
+. ./common/preamble
+_begin_fstest auto repair
-here=`pwd`
-tmp=/tmp/$$
-status=1 # failure is the default!
-trap "_cleanup; exit \$status" 0 1 2 3 15
-
-_cleanup()
-{
- cd /
- rm -f $tmp.*
-}
-
-# get standard environment, filters and checks
-. ./common/rc
+# Import common functions.
. ./common/populate
. ./common/filter
_require_populate_commands
_require_libxfs_debug_flag LIBXFS_DEBUG_WRITE_CRASH
-rm -f $seqres.full
-
# Populate the filesystem
_scratch_populate_cached nofill >> $seqres.full 2>&1