aboutsummaryrefslogtreecommitdiff
path: root/budget/run.py
diff options
context:
space:
mode:
authorAlexis Metaireau <alexis@notmyidea.org>2016-04-05 00:56:14 +0200
committerAlexis Metaireau <alexis@notmyidea.org>2016-04-05 00:56:14 +0200
commit698efd7681d3d9fa6f621046a4dc95e0edc36a55 (patch)
tree724d03e09ff6aa189dc6e67ca9be505b5fcfaea5 /budget/run.py
parenta8841f9d3f90ec4c1915493a1b34fa1798895772 (diff)
parentb685fa74d641ceeb077005698cc63108350f1d36 (diff)
downloadihatemoney-mirror-698efd7681d3d9fa6f621046a4dc95e0edc36a55.zip
ihatemoney-mirror-698efd7681d3d9fa6f621046a4dc95e0edc36a55.tar.gz
ihatemoney-mirror-698efd7681d3d9fa6f621046a4dc95e0edc36a55.tar.bz2
Merge pull request #129 from JocelynDelalande/no-user-settings-in-tests
Do not load user-overriden settings in unit tests.
Diffstat (limited to 'budget/run.py')
-rw-r--r--budget/run.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/budget/run.py b/budget/run.py
index bdb8f46..1e5fe59 100644
--- a/budget/run.py
+++ b/budget/run.py
@@ -1,3 +1,4 @@
+import os
import warnings
from flask import Flask, g, request, session
@@ -14,7 +15,8 @@ app = Flask(__name__)
def configure():
""" A way to (re)configure the app, specially reset the settings
"""
- app.config.from_object("default_settings")
+ config_obj = os.environ.get('FLASK_SETTINGS_MODULE', 'merged_settings')
+ app.config.from_object(config_obj)
app.wsgi_app = PrefixedWSGI(app)
# Deprecations