Skip to content

Commit 7a37f73

Browse files
committed
Tests related fixes
- fixed import - set default TEST_RUNNER setting (hushes django warnings) - enforce null prefix for tests
1 parent 025260e commit 7a37f73

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

settings.py

+2
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,8 @@ def get_from_env(var, default):
303303
USE_X_FORWARDED_HOST = True
304304
SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https')
305305

306+
TEST_RUNNER = "django.test.runner.DiscoverRunner"
307+
306308
# useful trick for custom settings
307309
try:
308310
from local_settings import *

test_settings.py

+1
Original file line numberDiff line numberDiff line change
@@ -96,3 +96,4 @@ def mkdir_p(path):
9696
ZEUS_RESULTS_FONT_BOLD_PATH = '/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-B.ttf'
9797

9898
USE_X_SENDFILE = False
99+
SERVER_PREFIX = ''

zeus/tests/test_functional.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
from helios import datatypes
1717
from helios.crypto.elgamal import DLog_challenge_generator
1818
from helios.crypto import algs
19-
from helios.views import ELGAMAL_PARAMS
2019
from helios.models import Election, Voter, Poll, Trustee
2120
from zeus.tests.utils import SetUpAdminAndClientMixin
2221
from zeus.core import to_relative_answers, gamma_encode, prove_encryption
2322
from zeus import auth
23+
from zeus.views.common import ELGAMAL_PARAMS
2424

2525
pytestmark = pytest.mark.django_db(transaction=True)
2626

0 commit comments

Comments
 (0)