From 427afc27fc9bc53bbfa2fea92bc8fc6a2d1673b3 Mon Sep 17 00:00:00 2001 From: Lance Edgar Date: Mon, 20 Nov 2023 09:57:38 -0600 Subject: [PATCH] Add test to ensure we get correct app handler by default --- tests/test_conf.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/test_conf.py b/tests/test_conf.py index 29a37f1..90c5c6c 100644 --- a/tests/test_conf.py +++ b/tests/test_conf.py @@ -12,6 +12,7 @@ import sqlalchemy as sa from wuttjamaican import conf from wuttjamaican.exc import ConfigurationError from wuttjamaican.db import Session +from wuttjamaican.app import AppHandler class TestWuttaConfig(TestCase): @@ -386,6 +387,13 @@ configure_logging = true config.setdefault('foo.bar', 'hello world') self.assertEqual(config.get_list('foo.bar'), ['hello', 'world']) + def test_get_app(self): + config = conf.WuttaConfig() + app = config.get_app() + # make sure we get the true default handler class + self.assertIsInstance(app, AppHandler) + self.assertIs(type(app), AppHandler) + class TestGenericDefaultFiles(TestCase):