From: Denis Vlasenko Date: Wed, 13 Jun 2007 12:49:46 +0000 (-0000) Subject: minix.h: add very simple test script X-Git-Tag: 1_7_0~237 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=26017b1b048900fa994029d492987fbef2eb3b43;p=oweals%2Fbusybox.git minix.h: add very simple test script --- diff --git a/util-linux/minix.h b/util-linux/minix.h index 476f32735..e630fe033 100644 --- a/util-linux/minix.h +++ b/util-linux/minix.h @@ -74,3 +74,25 @@ enum { MINIX2_INODES_PER_BLOCK = BLOCK_SIZE / sizeof(struct minix2_inode), }; +/* +Basic test script for regressions in mkfs/fsck. +Copies current dir into image (typically bbox build tree). + +#!/bin/sh +tmpdir=/tmp/minixtest-$$ +tmpimg=/tmp/minix-img-$$ + +mkdir $tmpdir +dd if=/dev/zero of=$tmpimg bs=1M count=20 || exit +./busybox mkfs.minix $tmpimg || exit +mount -o loop $tmpimg $tmpdir || exit +cp -a "$PWD" $tmpdir +umount $tmpdir || exit +./busybox fsck.minix -vfm $tmpimg || exit +echo "Continue?" +read junk +./busybox fsck.minix -vfml $tmpimg || exit +rmdir $tmpdir +rm $tmpimg + +*/