debian/cubicweb-server.prerm
author Rémi Cardona <remi.cardona@logilab.fr>
Fri, 27 Nov 2015 12:26:17 +0100
changeset 10937 eb05348b0e2d
parent 0 b97547f5f1fa
permissions -rw-r--r--
[devtools] Disable anonymous login right before executing tests CubicWebTC.init_config is called many times, especially when creating the default database. This database is then reused by all tests in the same directory. The issue is that, if a test has 'anonymous_allowed' set to False, the anonymous user won't be created by postcreate.py in the default database. All other tests will fail miserably if they expected anonymous login to work. By actually disabling anonymous login after _init_repo, the default database (and configuration) will be initialized with a working anonymous user. Closes #7485127.

#! /bin/sh -e
 
case "$1" in
    remove)
	if [ -x "/etc/init.d/cubicweb-ctl" ]; then
	    invoke-rc.d cubicweb-ctl stop || true
	fi
    ;;
esac
 
#DEBHELPER#
 
exit 0