From 1ab8ff76ef516510d61105be8126e67906d3b488 Mon Sep 17 00:00:00 2001 From: Griatch Date: Wed, 20 Mar 2019 00:41:23 +0100 Subject: [PATCH] Fix unit test issue with server name when running from mygame settings --- .travis.yml | 3 ++- evennia/contrib/security/auditing/tests.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index bcf1602f0a..e3b438afd4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -27,14 +27,15 @@ before_install: install: - pip install psycopg2-binary - pip install mysqlclient - - pip install -e . - pip install coveralls + - pip install -e . before_script: - evennia --init testing_mygame - cp .travis/${TESTING_DB}_settings.py testing_mygame/server/conf/settings.py - cd testing_mygame - evennia migrate + - evennia collectstatic script: - coverage run --source=../evennia --omit=*/migrations/*,*/urls.py,*/test*.py,*.sh,*.txt,*.md,*.pyc,*.service ../bin/unix/evennia test --settings=settings evennia diff --git a/evennia/contrib/security/auditing/tests.py b/evennia/contrib/security/auditing/tests.py index e6da244188..20498cac6e 100644 --- a/evennia/contrib/security/auditing/tests.py +++ b/evennia/contrib/security/auditing/tests.py @@ -2,6 +2,7 @@ Module containing the test cases for the Audit system. """ +from anything import Anything from django.test import override_settings from django.conf import settings from evennia.utils.test_resources import EvenniaTest @@ -85,7 +86,7 @@ class AuditingTest(EvenniaTest): self.assertEqual(obj, { 'direction': 'RCV', 'protocol': 'telnet', - 'application': 'Evennia', + 'application': Anything, # this will change if running tests from the game dir 'text': 'hello' })