#! /bin/bash # Copyright (C) 2006-2007 Apple Inc. All rights reserved. # smbtorture-suite.sh - run the tests from the Samba4 smbtorture suite that # are expected to pass. This is equivalent to runing "make quick". SCRIPTBASE=${SCRIPTBASE:-$(cd $(dirname $0)/.. && pwd )} . $SCRIPTBASE/common.sh || exit 2 if [ $# -lt 2 ]; then cat <) { if (m/test: (\w+)/) { $testcount++; $testname = $1; } $successcount++ if (m/success: \Q$testname\E/); print; } exit ($testcount - $successcount); ' } test_success_output() { cat < 0 (=1) testing a conflict while a lock is pending Testing LOCKING_ANDX_CHANGE_LOCKTYPE success: LOCK EOF } test_failure_output() { cat <&1 | subunit_filter #test_success_output | subunit_filter #test_failure_output | subunit_filter } while read t ; do [ -z "$t" ] && continue if smbtorture "$t" ; then echo Finished smbtorture test $t: OK else echo Finished smbtorture test $t: FAILED failtest fi done <