Fix test for config object

This commit is contained in:
Lance Edgar 2023-05-25 14:55:41 -05:00
parent b840ae7513
commit 0d9a502801

View file

@ -1,6 +1,4 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8; -*-
from __future__ import unicode_literals, absolute_import
import os import os
from unittest import TestCase from unittest import TestCase
@ -29,4 +27,6 @@ class TestRattailConfig(TestCase):
self.assertRaises(ConfigurationError, app.make_rattail_config, {}) self.assertRaises(ConfigurationError, app.make_rattail_config, {})
# get a config object if path provided # get a config object if path provided
result = app.make_rattail_config({'rattail.config': self.config_path}) result = app.make_rattail_config({'rattail.config': self.config_path})
self.assertTrue(isinstance(result, RattailConfig)) # nb. cannot test isinstance(RattailConfig) b/c now uses wrapper!
self.assertIsNotNone(result)
self.assertTrue(hasattr(result, 'get'))