From 458d4c034c6399a4268b4d41106c0d47a027e617 Mon Sep 17 00:00:00 2001 From: Maik Hoepfel Date: Wed, 8 Jul 2015 16:28:00 +0200 Subject: [PATCH] Update tests In the feedback round, we spotted that the tests could be improved. --- tests/test_config.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test_config.py b/tests/test_config.py index 033531c..96d47a8 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -7,6 +7,7 @@ # We use get_config() instead of adyen_config because throughout # the tests, we repeatedly change the Django settings. from adyen.config import get_config, AbstractAdyenConfig +from adyen.settings_config import FromSettingsConfig @override_settings( @@ -17,12 +18,12 @@ ) class FromSettingsTestCase(TestCase): """ - This test case tests the FromSettings confic class, which just fetches its + This test case tests the FromSettings config class, which just fetches its values from the Django settings. """ def test_is_default(self): - assert 'FromSettingsConfig' in get_config().__class__.__name__ + assert isinstance(get_config(), FromSettingsConfig) def test_value_passing_works(self): assert get_config().get_action_url(None) == 'foo' @@ -51,7 +52,7 @@ class CustomConfigClassTestCase(TestCase): """ def test_class_gets_picked_up(self): - assert 'DummyConfigClass' in get_config().__class__.__name__ + assert isinstance(get_config(), DummyConfigClass) @override_settings(ADYEN_ACTION_URL='bar') def test_settings_ignored(self):