common: create _require_test_program to look for programs in src/

Create a helper that looks for a test program in src/ and fails the
test if it doesn't exist.  Refactor the existing testcases to use it.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
This commit is contained in:
Darrick J. Wong
2016-02-09 00:22:21 -08:00
parent 8522cbe656
commit d43f8034c5
9 changed files with 17 additions and 9 deletions
+1 -1
View File
@@ -62,7 +62,7 @@ _require_metadata_journaling $SCRATCH_DEV
# the test system supports fallocate() for allocation
_require_xfs_io_command "falloc"
[ -x $here/src/fsync-tester ] || _notrun "fsync-tester not built"
_require_test_program "fsync-tester"
rm -f $seqres.full
SEED=1