aboutsummaryrefslogtreecommitdiff
path: root/tests/fstype.test
blob: cc7a620647d9c7d8c573bba17ed83e61d8bc7d68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash

[ -f testing.sh ] && . testing.sh

#testing "name" "command" "result" "infile" "stdin"

BDIR="$TOPDIR/tests/blkid"

bzcat "$BDIR"/squashfs.bz2 > temp.img
testing "file" "fstype temp.img" 'squashfs\n' "" ""
rm temp.img

for i in cramfs ext2 ext3 ext4 f2fs ntfs squashfs vfat xfs
do
  testing "$i" 'bzcat "$BDIR"/$i.bz2 | fstype -' "$i\n" "" ""
done

testing "msdos" 'bzcat "$BDIR"/msdos.bz2 | fstype -' 'vfat\n' "" ""
testing "reiserfs" 'bzcat "$BDIR"/reiser3.bz2 | fstype -' 'reiserfs\n' "" ""

#testing "blkid minix" 'bzcat "$BDIR"/minix.bz2 | blkid -'
#adfs bfs btrfs cramfs jfs nilfs romfs
#vfat  // fat32 fat12 fat16