fstests: move test group info to test files
[xfstests-dev.git] / tests / xfs / 018
1 #! /bin/bash
2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2000-2002 Silicon Graphics, Inc.  All Rights Reserved.
4 #
5 # FS QA Test No. 018
6 #
7 # xfs_logprint test - test v2 logs of different LR sizes
8 #
9 seqfull=$0
10 . ./common/preamble
11 _begin_fstest deprecated # log logprint v2log
12
13 # Import common functions.
14 . ./common/filter
15 . ./common/log
16
17 # Override the default cleanup function.
18 _cleanup()
19 {
20     cd /
21     _cleanup_logfiles
22     rm -f $tmp.*
23     _scratch_unmount 2>/dev/null
24 }
25
26 # real QA test starts here
27 _supported_fs xfs
28 # prelim
29 _require_scratch
30 _require_v2log
31
32 echo "*** init FS"
33 _scratch_unmount >/dev/null 2>&1
34
35 cat >$tmp.seq.params <<EOF
36 # mkfs-opt        mount-opt
37   version=1     logbsize=32k
38   version=2     logbsize=32k
39   version=2     logbsize=64k
40   version=2     logbsize=128k
41   version=2     logbsize=256k
42 EOF
43
44 start_blk=2
45
46 # do the work for various log params which
47 # should not effect the data content of the log
48 cat $tmp.seq.params \
49 | while read mkfs mnt
50 do
51     if [ "$mkfs" = "#" ]; then
52         continue
53     fi
54     export MOUNT_OPTIONS="-o noalign,$mnt"
55     _mkfs_log "-l $mkfs"
56     _create_log
57     _check_log
58
59     _print_operation
60     _cmp_op_output $seqfull.op $filtered
61
62     _print_transaction_inode $start_blk
63     _cmp_output $seqfull.trans_inode $filtered
64
65     _print_transaction_buf $start_blk
66     _cmp_output $seqfull.trans_buf $filtered
67 done
68
69 # got thru it all so we may have success
70 status=0
71
72 exit