Remove (some) bashisms from the test scripts
Uri Simchoni
uri at samba.org
Wed Jan 3 21:45:55 UTC 2018
On 01/02/2018 06:24 PM, Björn JACKE wrote:
> On 2017-12-27 at 07:36 +0200 Uri Simchoni via samba-technical sent off:
>>> But what is wrong with the ldbsearch one? It's obviously a bug in the
>>> script and that exposes clearly, if you compile with external t* libs.
>>>
>>> With regards,
>>> Timur Bakeyev.
>>>
>>
>> Nothing is wrong IMHO but it requires two reviewers. Please bear with us :)
>
> +1 from me
>
I tried pushing this and it consistently fails on
samba4.blackbox.dbcheck.release-4-0-0.
I suspect that the following patch is causing a test that previously
never ran to run, and fail:
--- a/testprogs/blackbox/dbcheck-oldrelease.sh
+++ b/testprogs/blackbox/dbcheck-oldrelease.sh
@@ -366,19 +366,19 @@ check_expected_after_deleted_objects() {
}
referenceprovision() {
- if [ x$RELEASE == x"release-4-0-0" ]; then
+ if [ x$RELEASE = x"release-4-0-0" ]; then
$PYTHON $BINDIR/samba-tool domain provision --server-role="dc"
--domain=SAMBA --host-name=ares --realm=${RELEASE}.samba.corp
--targetdir=$PREFIX_ABS/${RELEASE}_reference --use-ntvfs
--host-ip=127.0.0.1 --host-ip6=::1 --function-l
fi
}
ldapcmp() {
- if [ x$RELEASE == x"release-4-0-0" ]; then
+ if [ x$RELEASE = x"release-4-0-0" ]; then
$PYTHON $BINDIR/samba-tool ldapcmp
tdb://$PREFIX_ABS/${RELEASE}_reference/private/sam.ldb
tdb://$PREFIX_ABS/${RELEASE}/private/sam.ldb --two --skip-missing-dn
--filter=dnsRecord
fi
}
ldapcmp_sd() {
- if [ x$RELEASE == x"release-4-0-0" ]; then
+ if [ x$RELEASE = x"release-4-0-0" ]; then
$PYTHON $BINDIR/samba-tool ldapcmp
tdb://$PREFIX_ABS/${RELEASE}_reference/private/sam.ldb
tdb://$PREFIX_ABS/${RELEASE}/private/sam.ldb --two --sd --skip-missing-dn
fi
}
It also consistently fails without the patch on my bash-based autobuild
machine (consistent with bash understanding ==), but I can't yet explain
why it started failing, since this is an old test and I've been using
bash for autobuild all along.
Andrew, can you please have a look?
Thanks,
Uri.
More information about the samba-technical
mailing list