s3:lib/netapi: s/Undefined/SMB_SIGNING_DEFAULT/
[Samba/gebeck_regimport.git] / testprogs / blackbox / renamedc.sh
blobb2fa87d242e762de95e36f4b3cf36a9c36c3bac7
1 #!/bin/sh
3 if [ $# -lt 1 ]; then
4 cat <<EOF
5 Usage: renamedc.sh PREFIX
6 EOF
7 exit 1;
8 fi
10 PREFIX="$1"
11 shift 1
13 . `dirname $0`/subunit.sh
15 if [ ! -d $PREFIX/upgradeprovision_full ]; then
16 $PYTHON $SRCDIR/source4/setup/provision --host-name=bar --domain=FOO --realm=foo.example.com --targetdir="$PREFIX/upgradeprovision_full" --server-role="dc"
20 testrenamedc() {
21 $PYTHON $SRCDIR/source4/scripting/bin/renamedc \
22 --oldname="BAR" \
23 --newname="RAYMONBAR" \
24 -s $PREFIX/upgradeprovision_full/etc/smb.conf
28 testrenamedc2() {
29 $PYTHON $SRCDIR/source4/scripting/bin/renamedc \
30 --oldname="RAYMONBAR" \
31 --newname="BAR" \
32 -s $PREFIX/upgradeprovision_full/etc/smb.conf
35 testit "renamedc" testrenamedc
36 testit "renamedc2" testrenamedc2
38 if [ $failed -eq 0 ]; then
39 rm -rf $PREFIX/upgradeprovision_full
42 exit $failed