echo "test: magic differs"
-if [
- "`./talloc_test_magic_differs_helper`" != "`./talloc_test_magic_differs_helper`"
-]; then
- echo "failure: magic remained the same between executions"
+helper=$1
+m1=$($helper)
+m2=$($helper)
+
+if [ $m1 -eq $m2 ]; then
+ echo "failure: magic remained the same between executions ($m1 vs $m2)"
exit 1
fi
cmd = os.path.join(Utils.g_module.blddir, 'talloc_testsuite')
ret = samba_utils.RUN_COMMAND(cmd)
print("testsuite returned %d" % ret)
+ magic_helper_cmd = os.path.join(Utils.g_module.blddir, 'talloc_test_magic_differs_helper')
magic_cmd = os.path.join(srcdir, 'lib', 'talloc',
'test_magic_differs.sh')
- magic_ret = samba_utils.RUN_COMMAND(magic_cmd)
+ magic_ret = samba_utils.RUN_COMMAND(magic_cmd + " " + magic_helper_cmd)
print("magic differs test returned %d" % magic_ret)
pyret = samba_utils.RUN_PYTHON_TESTS(['test_pytalloc.py'])
print("python testsuite returned %d" % pyret)