mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
31d187be0f
We check the output with both --fullname and with the default shortname to ensure it works as expected. We also do tests for each level and test relative names are used. Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Sachin Prabhu <sprabhu@redhat.com> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User((no branch)): Stefan Metzmacher <metze@samba.org> Autobuild-Date((no branch)): Tue Jul 7 12:16:34 UTC 2020 on sn-devel-184
44 lines
2.0 KiB
Bash
Executable File
44 lines
2.0 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
#Tests if the --fullname parameter passed to smbtorture is working as expected.
|
|
|
|
if [ $# -ne 1 ]; then
|
|
cat <<EOF
|
|
Usage: test_smbtorture_test_names.sh SMBTORTURE
|
|
EOF
|
|
exit 1;
|
|
fi
|
|
|
|
SMBTORTURE="$1 //a/b"
|
|
|
|
. `dirname $0`/subunit.sh
|
|
|
|
failed=0
|
|
|
|
testit_grep "with_shortname local.smbtorture.level1.level2.level3.always_pass" \
|
|
'^success: always_pass$' \
|
|
$SMBTORTURE local.smbtorture.level1.level2.level3.always_pass || failed=`expr $failed + 1`
|
|
testit_grep "with_shortname local.smbtorture.level1.level2.level3" \
|
|
'^success: always_pass$' \
|
|
$SMBTORTURE local.smbtorture.level1.level2.level3 || failed=`expr $failed + 1`
|
|
testit_grep "with_shortname local.smbtorture.level1.level2"\
|
|
'^success: level3.always_pass$' \
|
|
$SMBTORTURE local.smbtorture.level1.level2 || failed=`expr $failed + 1`
|
|
testit_grep "with_shortname local.smbtorture.level1" \
|
|
'^success: level2.level3.always_pass$' \
|
|
$SMBTORTURE local.smbtorture.level1 || failed=`expr $failed + 1`
|
|
testit_grep "with_fullname local.smbtorture.level1.level2.level3.always_pass" \
|
|
'^success: local.smbtorture.level1.level2.level3.always_pass$' \
|
|
$SMBTORTURE --fullname local.smbtorture.level1.level2.level3.always_pass || failed=`expr $failed + 1`
|
|
testit_grep "with_fullname local.smbtorture.level1.level2.level3" \
|
|
'^success: local.smbtorture.level1.level2.level3.always_pass$' \
|
|
$SMBTORTURE --fullname local.smbtorture.level1.level2.level3 || failed=`expr $failed + 1`
|
|
testit_grep "with_fullname local.smbtorture.level1.level2" \
|
|
'^success: local.smbtorture.level1.level2.level3.always_pass$' \
|
|
$SMBTORTURE --fullname local.smbtorture.level1.level2 || failed=`expr $failed + 1`
|
|
testit_grep "with_fullname local.smbtorture.level1" \
|
|
'^success: local.smbtorture.level1.level2.level3.always_pass$' \
|
|
$SMBTORTURE --fullname local.smbtorture.level1 || failed=`expr $failed + 1`
|
|
|
|
testok $0 $failed
|