From 043665f8e557258324d6e774689100222a5189c5 Mon Sep 17 00:00:00 2001 From: Roman Mogilatov Date: Mon, 14 Mar 2016 00:15:28 +0200 Subject: [PATCH] Fix provider overriding tests --- tests/test_providers.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test_providers.py b/tests/test_providers.py index 47dd666d..5536c391 100644 --- a/tests/test_providers.py +++ b/tests/test_providers.py @@ -82,7 +82,9 @@ class ProviderTests(unittest.TestCase): def test_override_with_not_provider(self): """Test provider overriding with not provider instance.""" - self.assertRaises(errors.Error, self.provider.override, object()) + obj = object() + self.provider.override(obj) + self.assertIs(self.provider(), obj) def test_last_overriding(self): """Test getting last overriding provider."""