diff --git a/context_processors.py b/context_processors.py index 327f68a..37c5912 100644 --- a/context_processors.py +++ b/context_processors.py @@ -10,7 +10,7 @@ web_host = request.META["HTTP_HOST"].split(":")#TODO Django DEV only ! web_host = web_host[0] except: - web_host = request.META["HTTP_HOST"] + web_host = request.META["HTTP_HOST"] #querry the Domain object c = Client('http://localhost:8001/3.0', API_USER, API_PASS) d = c.get_domain(None,web_host) diff --git a/tests/setup.py b/tests/setup.py index cfc7f77..1314304 100644 --- a/tests/setup.py +++ b/tests/setup.py @@ -3,6 +3,7 @@ import shutil import tempfile import subprocess +from django.settings import MAILMAN_TEST_BINDIR class Testobject: bindir = None @@ -10,7 +11,7 @@ cfgfile = None def setup_mm(testobject): - os.environ['MAILMAN_TEST_BINDIR'] = '/home/florian/Development/mailman/bin' + os.environ['MAILMAN_TEST_BINDIR'] = MAILMAN_TEST_BINDIR bindir = testobject.bindir = os.environ.get('MAILMAN_TEST_BINDIR') if bindir is None: raise RuntimeError("something's not quite right") diff --git a/tests/tests.py b/tests/tests.py index 779662b..43cc8ec 100644 --- a/tests/tests.py +++ b/tests/tests.py @@ -121,7 +121,7 @@ We should now end up on a success page offering what to do next. Let's check that this was the case. - >>> print "What would you like to do next?" in response.content #TODO:Duplication Bug needs test DB + >>> print "What would you like to do next?" in response.content True @@ -166,7 +166,7 @@ If everything was successful, we shall get a positive response from the page. We'll check that this was the case. - >>> print ("The mass subscription was successful." in response.content) or ("HTTP Error 409: Member already subscribed" in response.content) #TODO - doubled data after multiple tests + >>> print "The mass subscription was successful." in response.content True Done with the admin stuff. Now let's log out.