Add test to ensure we get correct app handler by default
This commit is contained in:
parent
b4e9fb8ea7
commit
427afc27fc
|
@ -12,6 +12,7 @@ import sqlalchemy as sa
|
||||||
from wuttjamaican import conf
|
from wuttjamaican import conf
|
||||||
from wuttjamaican.exc import ConfigurationError
|
from wuttjamaican.exc import ConfigurationError
|
||||||
from wuttjamaican.db import Session
|
from wuttjamaican.db import Session
|
||||||
|
from wuttjamaican.app import AppHandler
|
||||||
|
|
||||||
|
|
||||||
class TestWuttaConfig(TestCase):
|
class TestWuttaConfig(TestCase):
|
||||||
|
@ -386,6 +387,13 @@ configure_logging = true
|
||||||
config.setdefault('foo.bar', 'hello world')
|
config.setdefault('foo.bar', 'hello world')
|
||||||
self.assertEqual(config.get_list('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):
|
class TestGenericDefaultFiles(TestCase):
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue