diff options
author | Sjoerd Simons <sjoerd.simons@collabora.co.uk> | 2012-09-11 10:10:52 +0200 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2012-09-11 11:20:17 +0100 |
commit | ccc8f443c94d14d9dd94a5f4fbc84183159e8d33 (patch) | |
tree | ab8dcc492520c1c2e7c3bb6510f36bd40bb17a27 | |
parent | 6f4aeea22388d325f056882224b87429da1e702c (diff) |
Set gabble twisted location both for installed and uninstalled tests
Set GABBLE_TWISTED_PATH in the environment which points to either the
installed (when using run-test.sh) or the srcdir location (when using
make check)
-rw-r--r-- | tests/twisted/Makefile.am | 2 | ||||
-rw-r--r-- | tests/twisted/run-test.sh.in | 3 | ||||
-rw-r--r-- | tests/twisted/tls/server-tls-channel.py | 4 |
3 files changed, 6 insertions, 3 deletions
diff --git a/tests/twisted/Makefile.am b/tests/twisted/Makefile.am index f8457f7a9..56d49b433 100644 --- a/tests/twisted/Makefile.am +++ b/tests/twisted/Makefile.am @@ -307,7 +307,7 @@ TESTS = TESTS_ENVIRONMENT = \ PYTHONPATH=@abs_top_srcdir@/tests/twisted:@abs_top_builddir@/tests/twisted \ - GABBLE_TWISTED_SRCDIR=@srcdir@ + GABBLE_TWISTED_PATH=@srcdir@ check-local: check-coding-style check-twisted diff --git a/tests/twisted/run-test.sh.in b/tests/twisted/run-test.sh.in index 6a4cc0f6e..311a89d15 100644 --- a/tests/twisted/run-test.sh.in +++ b/tests/twisted/run-test.sh.in @@ -9,6 +9,9 @@ fi PYTHONPATH=@gabbletestsdir@/twisted export PYTHONPATH +GABBLE_TWISTED_PATH=@gabbletestsdir@/twisted +export GABBLE_TWISTED_PATH + if [ -n "$1" ] ; then list="$1" else diff --git a/tests/twisted/tls/server-tls-channel.py b/tests/twisted/tls/server-tls-channel.py index 2835ed63f..7823eacc5 100644 --- a/tests/twisted/tls/server-tls-channel.py +++ b/tests/twisted/tls/server-tls-channel.py @@ -34,8 +34,8 @@ JID = "test@example.org" # the files are copied from wocky/tests/certs/tls-[cert,key].pem CA_CERT_HOSTNAME = 'weasel-juice.org' -CA_CERT = os.environ.get('GABBLE_TWISTED_SRCDIR', '.') + '/tls-cert.pem' -CA_KEY = os.environ.get('GABBLE_TWISTED_SRCDIR', '.') + '/tls-key.pem' +CA_CERT = os.environ.get('GABBLE_TWISTED_PATH', '.') + '/tls-cert.pem' +CA_KEY = os.environ.get('GABBLE_TWISTED_PATH', '.') + '/tls-key.pem' class TlsAuthenticator(XmppAuthenticator): def __init__(self, username, password, resource=None): |