Fix provider overriding tests

This commit is contained in:
Roman Mogilatov 2016-03-14 00:15:28 +02:00
parent d51f2fa79a
commit 043665f8e5

View File

@ -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."""