diff options
Diffstat (limited to 'jimbrella/test')
-rw-r--r-- | jimbrella/test/test_routine.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/jimbrella/test/test_routine.py b/jimbrella/test/test_routine.py index 5a08fdf..2a65b35 100644 --- a/jimbrella/test/test_routine.py +++ b/jimbrella/test/test_routine.py @@ -3,12 +3,22 @@ from threading import Thread import json import os import shutil +import logging from .jform_data import mock_jform_data from ..routine import sync_database, process_overdue from ..database import Database from ..jform import JForm from ..config import * +"""Set up logging.""" +logging.basicConfig( + filename="/tmp/jimbrella.log", + encoding="utf-8", + level=logging.INFO, + format="[%(asctime)s] %(levelname)s:%(name)s:%(message)s", +) +logging.info("----- BEGIN ROUTINE TEST -----") + """Spin up a simple Flask app to mimic jForm.""" jform = Flask(__name__) @@ -59,3 +69,4 @@ process_overdue(db) """Cleanup""" os.remove(takeaway_jform._bookmark_fp) os.remove(giveback_jform._bookmark_fp) +logging.info("----- END ROUTINE TEST -----") |